CrewAI multi-agent workflows often need to hand off work between agents — one agent produces an output, another consumes it. Artifacta is the durable store for that handoff: a producer agent stores an artifact, and a downstream agent retrieves it by id. This recipe wires the Artifacta MCP server into a crew as a tool source via CrewAI’s MCP support (Documentation Index
Fetch the complete documentation index at: https://docs.artifacta.io/llms.txt
Use this file to discover all available pages before exploring further.
crewai-tools’
MCPServerAdapter).
This is a recipe, not a packaged adapter. CrewAI’s MCP integration is newer
than the others Artifacta supports, so the API may shift — if your
crewai-tools
version differs, check its MCP docs for the current MCPServerAdapter
signature. We’ll ship a packaged adapter (like the LangChain
one) if CrewAI demand grows.Prerequisites
- Python 3.10+ and Node.js is not required — the Python
artifacta-mcpserver is launched directly. - An Artifacta API key (
ak_live_…) from the API keys page. - An LLM provider configured for CrewAI (e.g.
OPENAI_API_KEY).
1. Install
Install the Artifacta MCP server, CrewAI, and the CrewAI tools package (which provides the MCP adapter):artifacta-mcp installs the artifacta-mcp console script that the adapter
launches as a stdio subprocess.
2. Register Artifacta as a CrewAI tool source
MCPServerAdapter takes StdioServerParameters and yields a list of CrewAI
tools — one per Artifacta MCP tool. Use the artifacta-mcp helper
build_stdio_params to assemble the launch command, args, and env (it injects
ARTIFACTA_API_KEY and translates the --allow-path / --allow-destructive
flags):
with block keeps the MCP server process alive while the crew runs; the
tools are valid only inside it. If you prefer not to use the helper, build
StdioServerParameters(command="artifacta-mcp", args=[...], env={"ARTIFACTA_API_KEY": "..."})
directly.
3. Example crew — producer hands an artifact to a consumer
A two-agent crew: a researcher writes a summary and stores it in Artifacta; an editor retrieves that stored artifact by id and polishes it. The artifact is the handoff medium between the two agents.context=[write_task] wiring passes the researcher’s output (the art_…
id) to the editor’s task, and both agents share the same Artifacta tool set —
so the editor can fetch exactly what the researcher stored. This is the
multi-agent handoff pattern from
ARTIFACTA_MVP_SPEC_v5.md use case #5.
Recipe validation
CrewAI’s MCP integration is evolving, so this recipe is re-validated at each docs update and the live run is signed off by the operator.| Field | Value |
|---|---|
| Integration API targeted | crewai-tools MCPServerAdapter + mcp.StdioServerParameters (stdio) |
| Recipe authored / reviewed | 2026-05-29 |
| Live-tested CrewAI / crewai-tools version | recorded at operator HITL sign-off |
| Live-test date | recorded at operator HITL sign-off |
| Result | PASS recorded at sign-off |
If a CrewAI release changes the
MCPServerAdapter signature or tool-binding
shape, update the code samples and this table. If CrewAI traction warrants it,
this recipe is promoted to a packaged artifacta_mcp.crewai adapter.Troubleshooting
The Artifacta-side failures (auth, server not starting, path refusals) are the same as every other client — see Troubleshooting. For CrewAI-specific issues (the adapter not yielding tools, thewith block
closing before the crew runs), confirm your crewai-tools version supports
MCPServerAdapter and that the with MCPServerAdapter(...) block wraps the
entire crew.kickoff() call.