@mastra/mcp-docs-server 1.2.17-alpha.9 → 1.2.18-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (258) hide show
  1. package/.docs/course/02-agent-tools-mcp/32-conclusion.md +1 -1
  2. package/.docs/docs/agents/code-mode.md +3 -3
  3. package/.docs/docs/agents/guardrails.md +1 -1
  4. package/.docs/docs/agents/{agent-approval.md → human-in-the-loop.md} +5 -5
  5. package/.docs/docs/agents/networks.md +3 -3
  6. package/.docs/docs/agents/overview.md +7 -7
  7. package/.docs/docs/agents/processors.md +3 -3
  8. package/.docs/docs/agents/{using-tools.md → tools.md} +7 -7
  9. package/.docs/docs/{server/auth → auth}/custom-auth-provider.md +1 -1
  10. package/.docs/docs/{server/auth → auth}/fga.md +27 -1
  11. package/.docs/docs/{server/auth.md → auth/overview.md} +4 -4
  12. package/.docs/docs/{server/auth → auth}/simple-auth.md +1 -1
  13. package/.docs/docs/{server/auth → auth}/workers.md +2 -2
  14. package/.docs/docs/{capabilities/channels.md → channels.md} +2 -2
  15. package/.docs/docs/{agents → connections}/a2a.md +2 -2
  16. package/.docs/docs/{agents → connections}/acp.md +18 -6
  17. package/.docs/docs/{mcp/overview.md → connections/mcp.md} +1 -1
  18. package/.docs/docs/connections/overview.md +5 -5
  19. package/.docs/docs/{agents → connections}/sdk-agents.md +3 -1
  20. package/.docs/docs/deployment/cloud-providers.md +1 -0
  21. package/.docs/docs/deployment/mastra-server.md +2 -2
  22. package/.docs/docs/deployment/overview.md +2 -1
  23. package/.docs/docs/deployment/sandbox.md +3 -3
  24. package/.docs/docs/deployment/workers.md +4 -4
  25. package/.docs/docs/guides/context-engineering.md +297 -0
  26. package/.docs/docs/guides/multi-agent-systems.md +7 -7
  27. package/.docs/docs/guides/streaming.md +1 -1
  28. package/.docs/docs/harness/agent-controller.md +5 -3
  29. package/.docs/docs/{long-running-agents → harness}/background-tasks.md +5 -5
  30. package/.docs/docs/{long-running-agents → harness}/durable-agents.md +18 -2
  31. package/.docs/docs/{long-running-agents → harness}/goals.md +6 -6
  32. package/.docs/docs/harness/overview.md +11 -10
  33. package/.docs/docs/{long-running-agents → harness}/schedules.md +5 -5
  34. package/.docs/docs/{long-running-agents → harness}/signal-providers.md +4 -4
  35. package/.docs/docs/mastra-platform/deploy.md +1 -1
  36. package/.docs/docs/mastra-platform/overview.md +1 -1
  37. package/.docs/docs/mastra-platform/server.md +1 -1
  38. package/.docs/docs/memory/message-history.md +1 -1
  39. package/.docs/docs/memory/overview.md +4 -4
  40. package/.docs/docs/memory/working-memory.md +1 -1
  41. package/.docs/docs/observability/integrations/exporters/mastra-storage.md +1 -1
  42. package/.docs/docs/{workspace → sandbox}/filesystem.md +2 -2
  43. package/.docs/docs/{workspace → sandbox}/lsp.md +3 -3
  44. package/.docs/docs/{workspace/sandbox.md → sandbox/overview.md} +4 -3
  45. package/.docs/docs/{workspace → sandbox}/search.md +2 -2
  46. package/.docs/docs/{workspace → sandbox}/skills.md +5 -5
  47. package/.docs/docs/server/custom-api-routes.md +2 -2
  48. package/.docs/docs/server/mastra-client.md +2 -2
  49. package/.docs/docs/server/{mastra-server.md → overview.md} +3 -3
  50. package/.docs/docs/server/pubsub.md +2 -2
  51. package/.docs/docs/server/server-adapters.md +4 -4
  52. package/.docs/docs/{agents/skills.md → skills.md} +4 -4
  53. package/.docs/docs/{storage/overview.md → storage.md} +2 -1
  54. package/.docs/docs/studio/auth.md +4 -4
  55. package/.docs/docs/studio/overview.md +2 -2
  56. package/.docs/docs/{capabilities/subagents.md → subagents.md} +35 -5
  57. package/.docs/docs/workflows/agents-and-tools.md +1 -1
  58. package/.docs/docs/workflows/control-flow.md +0 -4
  59. package/.docs/docs/workflows/human-in-the-loop.md +0 -4
  60. package/.docs/docs/workflows/overview.md +1 -1
  61. package/.docs/docs/workflows/scheduled-workflows.md +2 -2
  62. package/.docs/docs/workflows/snapshots.md +1 -1
  63. package/.docs/docs/workflows/suspend-and-resume.md +0 -4
  64. package/.docs/integrations/agentic-ui/ai-sdk-ui.md +1 -1
  65. package/.docs/integrations/agentic-ui/copilotkit.md +1 -1
  66. package/.docs/integrations/auth/google.md +2 -2
  67. package/.docs/integrations/auth/workos.md +1 -1
  68. package/.docs/integrations/browsers/agent-browser.md +2 -2
  69. package/.docs/integrations/browsers/browser-viewer.md +6 -6
  70. package/.docs/integrations/browsers/firecrawl.md +1 -1
  71. package/.docs/integrations/browsers/stagehand.md +2 -2
  72. package/.docs/integrations/channels/discord.md +2 -2
  73. package/.docs/integrations/channels/github.md +1 -1
  74. package/.docs/integrations/channels/imessage.md +4 -4
  75. package/.docs/integrations/channels/slack.md +5 -5
  76. package/.docs/integrations/channels/teams.md +2 -2
  77. package/.docs/integrations/channels/telegram.md +2 -2
  78. package/.docs/integrations/channels/whatsapp.md +2 -2
  79. package/.docs/integrations/databases/postgresql.md +1 -0
  80. package/.docs/integrations/deploy/amazon-ec2.md +2 -2
  81. package/.docs/integrations/deploy/aws-lambda.md +3 -3
  82. package/.docs/integrations/deploy/azure-app-services.md +2 -2
  83. package/.docs/integrations/deploy/cloudflare.md +2 -2
  84. package/.docs/integrations/deploy/digital-ocean.md +3 -3
  85. package/.docs/integrations/deploy/kubernetes.md +11 -11
  86. package/.docs/integrations/deploy/netlify.md +3 -3
  87. package/.docs/integrations/deploy/render.md +389 -0
  88. package/.docs/integrations/deploy/vercel.md +2 -2
  89. package/.docs/integrations/file-storage/amazon-s3.md +1 -1
  90. package/.docs/integrations/file-storage/azure-blob.md +1 -1
  91. package/.docs/integrations/file-storage/google-cloud-storage.md +1 -1
  92. package/.docs/integrations/file-storage/mesa.md +2 -2
  93. package/.docs/integrations/file-storage/vercel-files.md +1 -1
  94. package/.docs/integrations/frameworks/astro.md +6 -2
  95. package/.docs/integrations/frameworks/electron.md +1 -1
  96. package/.docs/integrations/frameworks/express.md +1 -1
  97. package/.docs/integrations/frameworks/hono.md +1 -1
  98. package/.docs/integrations/frameworks/nestjs.md +1 -1
  99. package/.docs/integrations/frameworks/next-js.md +6 -2
  100. package/.docs/integrations/frameworks/nuxt.md +1 -1
  101. package/.docs/integrations/frameworks/sveltekit.md +1 -1
  102. package/.docs/integrations/frameworks/vite-react.md +6 -2
  103. package/.docs/integrations/sandboxes/agentcore.md +1 -1
  104. package/.docs/integrations/sandboxes/apple-container.md +1 -1
  105. package/.docs/integrations/sandboxes/cloudflare-sandbox.md +118 -0
  106. package/.docs/integrations/sandboxes/daytona.md +1 -1
  107. package/.docs/integrations/sandboxes/docker.md +4 -3
  108. package/.docs/integrations/sandboxes/e2b.md +1 -1
  109. package/.docs/integrations/sandboxes/modal.md +1 -1
  110. package/.docs/integrations/sandboxes/railway.md +11 -0
  111. package/.docs/integrations.md +4 -0
  112. package/.docs/models/environment-variables.md +9 -2
  113. package/.docs/models/gateways/merge-gateway.md +212 -0
  114. package/.docs/models/gateways/openrouter.md +3 -1
  115. package/.docs/models/gateways/vercel.md +22 -1
  116. package/.docs/models/gateways.md +1 -0
  117. package/.docs/models/index.md +1 -1
  118. package/.docs/models/providers/alibaba-token-plan-cn.md +2 -1
  119. package/.docs/models/providers/alibaba-token-plan.md +2 -1
  120. package/.docs/models/providers/ambient.md +2 -2
  121. package/.docs/models/providers/amd.md +73 -0
  122. package/.docs/models/providers/arcee.md +79 -0
  123. package/.docs/models/providers/baseten.md +1 -1
  124. package/.docs/models/providers/cerebras.md +2 -3
  125. package/.docs/models/providers/chutes.md +2 -1
  126. package/.docs/models/providers/cloudflare-workers-ai.md +3 -2
  127. package/.docs/models/providers/cortecs.md +2 -1
  128. package/.docs/models/providers/crof.md +1 -1
  129. package/.docs/models/providers/crossmodel.md +3 -2
  130. package/.docs/models/providers/deepinfra.md +5 -1
  131. package/.docs/models/providers/digitalocean.md +3 -2
  132. package/.docs/models/providers/echo.md +73 -0
  133. package/.docs/models/providers/edenai.md +26 -11
  134. package/.docs/models/providers/empiriolabs.md +11 -1
  135. package/.docs/models/providers/hetzner.md +6 -8
  136. package/.docs/models/providers/huggingface.md +4 -1
  137. package/.docs/models/providers/hyper.md +8 -7
  138. package/.docs/models/providers/inferx.md +19 -13
  139. package/.docs/models/providers/jalapeno.md +89 -0
  140. package/.docs/models/providers/kilo.md +12 -11
  141. package/.docs/models/providers/kosmik.md +73 -0
  142. package/.docs/models/providers/llmgateway.md +3 -3
  143. package/.docs/models/providers/llmtr.md +35 -10
  144. package/.docs/models/providers/nano-gpt.md +13 -17
  145. package/.docs/models/providers/ofox.md +8 -4
  146. package/.docs/models/providers/opencode-go.md +23 -22
  147. package/.docs/models/providers/requesty.md +143 -53
  148. package/.docs/models/providers/runinfra.md +76 -0
  149. package/.docs/models/providers/sakana.md +3 -2
  150. package/.docs/models/providers/scnet-token-plan.md +85 -0
  151. package/.docs/models/providers/scx-ai.md +76 -0
  152. package/.docs/models/providers/togetherai.md +2 -1
  153. package/.docs/models/providers/umans-ai-coding-plan.md +2 -1
  154. package/.docs/models/providers/umans-ai.md +2 -1
  155. package/.docs/models/providers/vivgrid.md +2 -1
  156. package/.docs/models/providers/wandb.md +2 -1
  157. package/.docs/models/providers/xai.md +2 -1
  158. package/.docs/models/providers.md +8 -2
  159. package/.docs/reference/acp/acp-agent.md +2 -2
  160. package/.docs/reference/acp/create-acp-tool.md +1 -1
  161. package/.docs/reference/agent-controller/agent-controller-class.md +2 -2
  162. package/.docs/reference/agents/agent.md +2 -2
  163. package/.docs/reference/agents/channels.md +2 -2
  164. package/.docs/reference/agents/createSkill.md +2 -2
  165. package/.docs/reference/agents/durable-agent.md +1 -1
  166. package/.docs/reference/agents/generate.md +3 -1
  167. package/.docs/reference/agents/getSkill.md +1 -1
  168. package/.docs/reference/agents/listSkills.md +1 -1
  169. package/.docs/reference/agents/listSuspendedRuns.md +6 -6
  170. package/.docs/reference/agents/listTools.md +2 -2
  171. package/.docs/reference/agents/network.md +3 -1
  172. package/.docs/reference/ai-sdk/chat-route.md +1 -1
  173. package/.docs/reference/ai-sdk/handle-chat-stream.md +1 -1
  174. package/.docs/reference/ai-sdk/handle-network-stream.md +2 -2
  175. package/.docs/reference/ai-sdk/handle-workflow-stream.md +1 -1
  176. package/.docs/reference/ai-sdk/network-route.md +2 -2
  177. package/.docs/reference/ai-sdk/to-ai-sdk-messages.md +1 -1
  178. package/.docs/reference/ai-sdk/to-ai-sdk-stream.md +1 -1
  179. package/.docs/reference/ai-sdk/workflow-route.md +1 -1
  180. package/.docs/reference/auth/fga.md +7 -5
  181. package/.docs/reference/auth/jwt.md +1 -1
  182. package/.docs/reference/browser/agent-browser.md +2 -2
  183. package/.docs/reference/browser/browser-viewer.md +2 -2
  184. package/.docs/reference/browser/firecrawl-browser.md +1 -1
  185. package/.docs/reference/browser/mastra-browser.md +1 -1
  186. package/.docs/reference/browser/stagehand-browser.md +2 -2
  187. package/.docs/reference/build-with-ai.md +2 -2
  188. package/.docs/reference/channels/channel-provider.md +1 -1
  189. package/.docs/reference/channels/slack-provider.md +1 -1
  190. package/.docs/reference/cli/mastra.md +2 -0
  191. package/.docs/reference/client-js/agents.md +24 -4
  192. package/.docs/reference/coding-agent/create-coding-agent.md +142 -13
  193. package/.docs/reference/configuration.md +6 -6
  194. package/.docs/reference/core/getEditor.md +1 -1
  195. package/.docs/reference/core/getMCPServer.md +1 -1
  196. package/.docs/reference/core/getMCPServerById.md +1 -1
  197. package/.docs/reference/core/getTool.md +1 -1
  198. package/.docs/reference/core/getToolById.md +1 -1
  199. package/.docs/reference/core/listMCPServers.md +1 -1
  200. package/.docs/reference/core/listTools.md +1 -1
  201. package/.docs/reference/core/removeWorkspace.md +1 -1
  202. package/.docs/reference/editor/mastra-editor.md +2 -2
  203. package/.docs/reference/editor/prompt-blocks.md +2 -2
  204. package/.docs/reference/editor/tool-provider.md +108 -1
  205. package/.docs/reference/editor/tools.md +1 -1
  206. package/.docs/reference/editor/versioning.md +3 -3
  207. package/.docs/reference/evals/prompt-alignment.md +18 -0
  208. package/.docs/reference/evals/rubric.md +1 -1
  209. package/.docs/reference/file-based-agents/memory.md +2 -2
  210. package/.docs/reference/file-based-agents/server.md +3 -3
  211. package/.docs/reference/file-based-agents/skills.md +1 -1
  212. package/.docs/reference/file-based-agents/storage.md +3 -3
  213. package/.docs/reference/file-based-agents/subagents.md +1 -1
  214. package/.docs/reference/file-based-agents/workspace.md +3 -3
  215. package/.docs/reference/index.md +1 -0
  216. package/.docs/reference/manual-install.md +3 -3
  217. package/.docs/reference/memory/memory-class.md +1 -0
  218. package/.docs/reference/memory/settled.md +57 -0
  219. package/.docs/reference/migrations/network-to-supervisor.md +2 -2
  220. package/.docs/reference/processors/provider-history-compat.md +6 -5
  221. package/.docs/reference/processors/skill-search-processor.md +3 -1
  222. package/.docs/reference/processors/token-limiter-processor.md +4 -0
  223. package/.docs/reference/processors/tool-call-filter.md +7 -7
  224. package/.docs/reference/processors/tool-search-processor.md +1 -1
  225. package/.docs/reference/project-structure.md +1 -1
  226. package/.docs/reference/pubsub/lease-provider.md +3 -3
  227. package/.docs/reference/pubsub/redis-streams.md +1 -1
  228. package/.docs/reference/rag/graph-rag.md +71 -8
  229. package/.docs/reference/rag/retrieval.md +26 -18
  230. package/.docs/reference/schedules/overview.md +1 -1
  231. package/.docs/reference/streaming/ChunkType.md +2 -2
  232. package/.docs/reference/streaming/agents/stream.md +29 -4
  233. package/.docs/reference/streaming/agents/streamUntilIdle.md +1 -1
  234. package/.docs/reference/tools/ask-user-tool.md +1 -1
  235. package/.docs/reference/tools/create-code-mode.md +1 -1
  236. package/.docs/reference/tools/create-tool.md +4 -4
  237. package/.docs/reference/tools/mcp-client.md +2 -0
  238. package/.docs/reference/tools/mcp-server.md +97 -4
  239. package/.docs/reference/tools/submit-plan-tool.md +1 -1
  240. package/.docs/reference/tools/task-tools.md +2 -2
  241. package/.docs/reference/vectors/vectorize.md +12 -2
  242. package/.docs/reference/workers/overview.md +2 -2
  243. package/.docs/reference/workflows/run-methods/resume.md +21 -0
  244. package/.docs/reference/workspace/local-filesystem.md +1 -1
  245. package/.docs/reference/workspace/local-sandbox.md +4 -3
  246. package/.docs/reference/workspace/platform-sandbox.md +11 -0
  247. package/.docs/reference/workspace/process-manager.md +20 -4
  248. package/.docs/reference/workspace/sandbox.md +1 -1
  249. package/.docs/reference/workspace/workspace-class.md +5 -5
  250. package/CHANGELOG.md +81 -0
  251. package/package.json +6 -6
  252. package/.docs/models/providers/merge-gateway.md +0 -265
  253. /package/.docs/docs/{server/auth → auth}/composite-auth.md +0 -0
  254. /package/.docs/docs/{server/auth → auth}/jwt.md +0 -0
  255. /package/.docs/docs/{browser/overview.md → browser.md} +0 -0
  256. /package/.docs/docs/{getting-started/develop.md → develop.md} +0 -0
  257. /package/.docs/docs/{long-running-agents → harness}/signals.md +0 -0
  258. /package/.docs/docs/{editor/overview.md → studio/editor.md} +0 -0
@@ -14,4 +14,4 @@ The power of MCP lies in its ability to connect your agent to a wide variety of
14
14
 
15
15
  As you continue to develop your Mastra agent, consider exploring other MCP servers and tools that might be useful for your specific use case. The Mastra ecosystem is constantly growing, with new tools and capabilities being added regularly.
16
16
 
17
- For more information on MCP and available servers, check out the [Mastra MCP documentation](https://mastra.ai/docs/mcp/overview).
17
+ For more information on MCP and available servers, check out the [Mastra MCP documentation](https://mastra.ai/docs/connections/mcp).
@@ -29,7 +29,7 @@ Each turn adds the full tool response to the agent's context window which can le
29
29
 
30
30
  With code mode, your tools keep running on the host with full validation, request context, and tracing. Only the model's orchestration code runs in the sandbox. Each `external_*` call is bridged back to the real tool on the host, and the function can reduce or aggregate results before returning one response to the agent.
31
31
 
32
- The function runs in a [Workspace sandbox](https://mastra.ai/docs/workspace/sandbox). A sandbox is required, because code mode runs model-authored code and the execution boundary must be chosen deliberately. Pass one via `sandbox`, or run the agent in a workspace that provides one. To execute on the host machine, pass `new LocalSandbox()` explicitly. This runs the function as a host `node` process with host privileges, so only use it for trusted or local development.
32
+ The function runs in a [Workspace sandbox](https://mastra.ai/docs/sandbox/overview). A sandbox is required, because code mode runs model-authored code and the execution boundary must be chosen deliberately. Pass one via `sandbox`, or run the agent in a workspace that provides one. To execute on the host machine, pass `new LocalSandbox()` explicitly. This runs the function as a host `node` process with host privileges, so only use it for trusted or local development.
33
33
 
34
34
  Transports that bring their own execution boundary are the exception: with [`IsolatedVmCodeModeTransport`](https://mastra.ai/reference/tools/isolated-vm-transport) the program runs in an in-process V8 isolate and no sandbox is needed (see [In-process isolation](#in-process-isolation)).
35
35
 
@@ -183,5 +183,5 @@ See [Choosing a transport](https://mastra.ai/reference/tools/quickjs-transport)
183
183
  - [createCodeMode() reference](https://mastra.ai/reference/tools/create-code-mode)
184
184
  - [IsolatedVmCodeModeTransport reference](https://mastra.ai/reference/tools/isolated-vm-transport)
185
185
  - [QuickJsCodeModeTransport reference](https://mastra.ai/reference/tools/quickjs-transport)
186
- - [Tools](https://mastra.ai/docs/agents/using-tools)
187
- - [Sandbox](https://mastra.ai/docs/workspace/sandbox)
186
+ - [Tools](https://mastra.ai/docs/agents/tools)
187
+ - [Sandbox](https://mastra.ai/docs/sandbox/overview)
@@ -130,7 +130,7 @@ const scrubbedAgent = new Agent({
130
130
 
131
131
  Visit [`SystemPromptScrubber()`](https://mastra.ai/reference/processors/system-prompt-scrubber) reference for a full list of configuration options.
132
132
 
133
- > **Note:** When streaming responses over HTTP, Mastra redacts sensitive request data (system prompts, tool definitions, API keys) from stream chunks at the server level by default. See [Stream data redaction](https://mastra.ai/docs/server/mastra-server) for details.
133
+ > **Note:** When streaming responses over HTTP, Mastra redacts sensitive request data (system prompts, tool definitions, API keys) from stream chunks at the server level by default. See [Stream data redaction](https://mastra.ai/docs/server/overview) for details.
134
134
 
135
135
  ## Hybrid processors
136
136
 
@@ -48,7 +48,7 @@ for await (const chunk of stream.fullStream) {
48
48
  }
49
49
  ```
50
50
 
51
- > **Note:** Human-in-the-loop uses snapshots to capture request state. Configure a [storage provider](https://mastra.ai/docs/storage/overview) on your Mastra instance or you'll see a "snapshot not found" error.
51
+ > **Note:** Human-in-the-loop uses snapshots to capture request state. Configure a [storage provider](https://mastra.ai/docs/storage) on your Mastra instance or you'll see a "snapshot not found" error.
52
52
  >
53
53
  > Snapshots for agent runs are minimal resume artifacts: they hold only what's needed to resume the suspended run and are deleted once the run finishes. Use [tracing](https://mastra.ai/docs/observability/overview) for the execution record and [memory](https://mastra.ai/docs/memory/overview) for the conversation history.
54
54
 
@@ -510,11 +510,11 @@ Each returned run includes the suspended tool calls (`toolCallId`, `toolName`, `
510
510
 
511
511
  The same discovery is available over HTTP as `GET /agents/:agentId/suspended-runs` and in the client SDK as [`agent.listSuspendedRuns()`](https://mastra.ai/reference/client-js/agents), so browser-based approval UIs can rediscover pending runs directly.
512
512
 
513
- > **Note:** Suspended runs only survive restarts when your Mastra instance is configured with a persistent [storage provider](https://mastra.ai/docs/storage/overview). The default in-memory store loses snapshots when the process exits.
513
+ > **Note:** Suspended runs only survive restarts when your Mastra instance is configured with a persistent [storage provider](https://mastra.ai/docs/storage). The default in-memory store loses snapshots when the process exits.
514
514
 
515
515
  ## Tool approval: Supervisor agents
516
516
 
517
- A [supervisor agent](https://mastra.ai/docs/capabilities/subagents) coordinates multiple subagents using `.stream()` or `.generate()`. When a subagent calls a tool that requires approval, the request propagates up through the delegation chain and surfaces at the supervisor level:
517
+ A [supervisor agent](https://mastra.ai/docs/subagents) coordinates multiple subagents using `.stream()` or `.generate()`. When a subagent calls a tool that requires approval, the request propagates up through the delegation chain and surfaces at the supervisor level:
518
518
 
519
519
  1. The supervisor delegates a task to a subagent.
520
520
  2. The subagent calls a tool that has `requireApproval: true` or uses `suspend()`.
@@ -673,8 +673,8 @@ if (output.finishReason === 'suspended') {
673
673
 
674
674
  ## Related
675
675
 
676
- - [Tools](https://mastra.ai/docs/agents/using-tools)
676
+ - [Tools](https://mastra.ai/docs/agents/tools)
677
677
  - [Agent overview](https://mastra.ai/docs/agents/overview)
678
- - [MCP overview](https://mastra.ai/docs/mcp/overview)
678
+ - [MCP overview](https://mastra.ai/docs/connections/mcp)
679
679
  - [Memory](https://mastra.ai/docs/memory/overview)
680
680
  - [Request context](https://mastra.ai/docs/server/request-context)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Agent networks
4
4
 
5
- > **Deprecated:** Agent networks are deprecated and will be removed in a future major release. [Supervisor agents](https://mastra.ai/docs/capabilities/subagents) using `agent.stream()` or `agent.generate()` are now the recommended approach. It provides the same multi-agent coordination with better control, a simpler API, and easier debugging.
5
+ > **Deprecated:** Agent networks are deprecated and will be removed in a future major release. [Supervisor agents](https://mastra.ai/docs/subagents) using `agent.stream()` or `agent.generate()` are now the recommended approach. It provides the same multi-agent coordination with better control, a simpler API, and easier debugging.
6
6
  >
7
7
  > See the [migration guide](https://mastra.ai/reference/migrations/network-to-supervisor) to upgrade.
8
8
 
@@ -95,7 +95,7 @@ console.log(final?.summary)
95
95
 
96
96
  When a primitive requires approval, the stream emits an `agent-execution-approval` or `tool-execution-approval` chunk. Use `approveNetworkToolCall()` or `declineNetworkToolCall()` to respond.
97
97
 
98
- Network approval uses snapshots to capture execution state. Ensure a [storage provider](https://mastra.ai/docs/storage/overview) is enabled in your Mastra instance.
98
+ Network approval uses snapshots to capture execution state. Ensure a [storage provider](https://mastra.ai/docs/storage) is enabled in your Mastra instance.
99
99
 
100
100
  ```typescript
101
101
  const stream = await routingAgent.network('Perform some sensitive action', {
@@ -180,5 +180,5 @@ Requirements for automatic resumption:
180
180
 
181
181
  ## Related
182
182
 
183
- - [Supervisor agents](https://mastra.ai/docs/capabilities/subagents)
183
+ - [Supervisor agents](https://mastra.ai/docs/subagents)
184
184
  - [Migration: `.network()` to supervisor agents](https://mastra.ai/reference/migrations/network-to-supervisor)
@@ -165,7 +165,7 @@ Visit the [agent reference](https://mastra.ai/reference/agents/agent) for more i
165
165
 
166
166
  ## Use your agent
167
167
 
168
- After registration, retrieve your agent with [`mastra.getAgentById()`](https://mastra.ai/reference/core/getAgentById). Call `.generate()` for a complete response or `.stream()` to deliver tokens in real time. You can call agents from [workflow steps](https://mastra.ai/docs/workflows/agents-and-tools), [tools](https://mastra.ai/docs/agents/using-tools), the [Mastra Client](https://mastra.ai/reference/client-js/mastra-client), route handlers, [server adapters](https://mastra.ai/docs/server/server-adapters), or the command line. See [Integrations](https://mastra.ai/integrations) to use agents in your application framework.
168
+ After registration, retrieve your agent with [`mastra.getAgentById()`](https://mastra.ai/reference/core/getAgentById). Call `.generate()` for a complete response or `.stream()` to deliver tokens in real time. You can call agents from [workflow steps](https://mastra.ai/docs/workflows/agents-and-tools), [tools](https://mastra.ai/docs/agents/tools), the [Mastra Client](https://mastra.ai/reference/client-js/mastra-client), route handlers, [server adapters](https://mastra.ai/docs/server/server-adapters), or the command line. See [Integrations](https://mastra.ai/integrations) to use agents in your application framework.
169
169
 
170
170
  When referencing an agent from your Mastra instance, use `mastra.getAgentById()` to ensure it has access to shared services such as instance-level storage, logging, and agent registry. A directly imported agent can still work with its own local configuration, but it won't have access to those shared services.
171
171
 
@@ -202,18 +202,18 @@ Once your agent is running, use this table to find the right page for what you w
202
202
 
203
203
  | Goal | Start here |
204
204
  | -------------------------------------------------------------- | ---------------------------------------------------------------------- |
205
- | Give your agent tools to call external APIs or services | [Tools](https://mastra.ai/docs/agents/using-tools) |
205
+ | Give your agent tools to call external APIs or services | [Tools](https://mastra.ai/docs/agents/tools) |
206
206
  | Keep context and preferences across conversations | [Memory](https://mastra.ai/docs/memory/overview) |
207
207
  | Get typed objects back instead of plain text | [Structured output](https://mastra.ai/docs/agents/structured-output) |
208
- | Human-in-the-loop: Pause execution and wait for human approval | [Human-in-the-loop](https://mastra.ai/docs/agents/agent-approval) |
209
- | Build a multi-agent network | [Supervisor agents](https://mastra.ai/docs/capabilities/subagents) |
210
- | Register subagents | [Tools](https://mastra.ai/docs/agents/using-tools) |
208
+ | Human-in-the-loop: Pause execution and wait for human approval | [Human-in-the-loop](https://mastra.ai/docs/agents/human-in-the-loop) |
209
+ | Build a multi-agent network | [Supervisor agents](https://mastra.ai/docs/subagents) |
210
+ | Register subagents | [Tools](https://mastra.ai/docs/agents/tools) |
211
211
  | Intercept or transform messages before and after generation | [Processors](https://mastra.ai/docs/agents/processors) |
212
212
  | Keep your agent safe | [Guardrails](https://mastra.ai/docs/agents/guardrails) |
213
- | Build agents that correct their work | [Rubric scorer](https://mastra.ai/docs/capabilities/subagents) |
213
+ | Build agents that correct their work | [Rubric scorer](https://mastra.ai/docs/subagents) |
214
214
  | Swap instructions or models based on request context | [Dynamic configuration](https://mastra.ai/docs/server/request-context) |
215
215
  | Add speech-to-text or text-to-speech | [Voice](https://mastra.ai/reference/voice/overview) |
216
- | Connect to Slack, Discord, or Telegram | [Channels](https://mastra.ai/docs/capabilities/channels) |
216
+ | Connect to Slack, Discord, or Telegram | [Channels](https://mastra.ai/docs/channels) |
217
217
 
218
218
  ## Multi-agent systems
219
219
 
@@ -398,7 +398,7 @@ See the [`TokenLimiterProcessor` reference](https://mastra.ai/reference/processo
398
398
 
399
399
  Removes tool calls and results from messages sent to the LLM, saving tokens on verbose tool interactions. Optionally exclude only specific tools. This filter only affects the LLM input, filtered messages are still saved to memory.
400
400
 
401
- By default, `ToolCallFilter` filters the initial input before the agent loop starts. Use `filterAfterToolSteps` to also filter during each loop step while preserving recent tool-producing steps.
401
+ By default, `ToolCallFilter` filters tool calls from prior history and leaves tool calls made during the current agent loop in place. Use `filterAfterToolSteps` to also filter during the loop while preserving the most recent tool-producing steps.
402
402
 
403
403
  ```typescript
404
404
  new ToolCallFilter({
@@ -426,7 +426,7 @@ See the [`ToolSearchProcessor` reference](https://mastra.ai/reference/processors
426
426
 
427
427
  Handles provider-specific history incompatibilities when agents reuse messages across model providers. It can rewrite the outbound LLM request before the provider call, or recover from known provider API errors and retry.
428
428
 
429
- Add `ProviderHistoryCompat` explicitly when you need provider history compatibility rules, reactive API error recovery, custom compatibility rules, or predictable processor ordering.
429
+ Add `ProviderHistoryCompat` explicitly when you need provider history compatibility rules, reactive API error recovery, custom compatibility rules, or predictable processor ordering. For Azure OpenAI agents that use observational memory, the processor rewrites `<system-reminder>` wrappers in outbound prompts to avoid content moderation refusals. Stored history remains unchanged.
430
430
 
431
431
  See the [`ProviderHistoryCompat` reference](https://mastra.ai/reference/processors/provider-history-compat) for setup, built-in rules, and custom rule options.
432
432
 
@@ -640,7 +640,7 @@ Do not mention the reminder to the user or quote the tags back to them.`,
640
640
  await agent.generate('Your prompt', { maxSteps: MAX_STEPS })
641
641
  ```
642
642
 
643
- > **Note:** Reactive signals default to `tagName: 'system-reminder'`. Visit [Signals](https://mastra.ai/docs/long-running-agents/signals) for more on processor-emitted signals.
643
+ > **Note:** Reactive signals default to `tagName: 'system-reminder'`. Visit [Signals](https://mastra.ai/docs/harness/signals) for more on processor-emitted signals.
644
644
 
645
645
  ### Deliver a reminder without retaining it
646
646
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Tools
4
4
 
5
- Agents use tools to call APIs or query databases. They can also run custom functions from your codebase. Tools give agents capabilities beyond language generation by providing structured access to data and performing clearly defined operations. You can also load tools from remote [MCP servers](https://mastra.ai/docs/mcp/overview) to expand an agent's capabilities.
5
+ Agents use tools to call APIs or query databases. They can also run custom functions from your codebase. Tools give agents capabilities beyond language generation by providing structured access to data and performing clearly defined operations. You can also load tools from remote [MCP servers](https://mastra.ai/docs/connections/mcp) to expand an agent's capabilities.
6
6
 
7
7
  **For AI agents:** Run `npx mastra api tool execute weather-tool '{"location":"San Francisco"}'` to test this tool directly instead of writing a temporary script. The command requires a running Mastra server; start the local server with `npx mastra dev`, or pass the reachable server's base URL with `--url`. Run `npx mastra api tool execute --schema` before constructing different input. Install Mastra's skill with `npx skills add mastra-ai/skills --skill mastra` for complete API CLI discovery, targeting, schema, authentication, and error-handling guidance.
8
8
 
@@ -166,7 +166,7 @@ export const weatherAgent = new Agent({
166
166
 
167
167
  ## Agents as tools
168
168
 
169
- Add subagents through the `agents` configuration to create a [supervisor](https://mastra.ai/docs/capabilities/subagents). Mastra converts each subagent to an `agent-<key>` tool. Include a `description` on each subagent so the supervisor knows when to delegate.
169
+ Add subagents through the `agents` configuration to create a [supervisor](https://mastra.ai/docs/subagents). Mastra converts each subagent to an `agent-<key>` tool. Include a `description` on each subagent so the supervisor knows when to delegate.
170
170
 
171
171
  ```typescript
172
172
  import { Agent } from '@mastra/core/agent'
@@ -605,7 +605,7 @@ for await (const chunk of stream.fullStream) {
605
605
  }
606
606
  ```
607
607
 
608
- `askUserTool` supports free-text, single-select (`options` array), and multi-select (`selectionMode: 'multi_select'`) prompts. Pair it with `autoResumeSuspendedTools` so the agent resumes automatically from the user's next chat message. See [Automatic tool resumption](https://mastra.ai/docs/agents/agent-approval) for details.
608
+ `askUserTool` supports free-text, single-select (`options` array), and multi-select (`selectionMode: 'multi_select'`) prompts. Pair it with `autoResumeSuspendedTools` so the agent resumes automatically from the user's next chat message. See [Automatic tool resumption](https://mastra.ai/docs/agents/human-in-the-loop) for details.
609
609
 
610
610
  ### Submit a plan for review
611
611
 
@@ -643,7 +643,7 @@ const agent = new Agent({
643
643
  })
644
644
  ```
645
645
 
646
- Only one task can be `in_progress` at a time. The list is stored in the thread-scoped `threadState` storage domain and projected onto the agent's [state-signal](https://mastra.ai/docs/long-running-agents/signals) lane, so it survives observational-memory truncation. See the [Task tools reference](https://mastra.ai/reference/tools/task-tools) for full schemas.
646
+ Only one task can be `in_progress` at a time. The list is stored in the thread-scoped `threadState` storage domain and projected onto the agent's [state-signal](https://mastra.ai/docs/harness/signals) lane, so it survives observational-memory truncation. See the [Task tools reference](https://mastra.ai/reference/tools/task-tools) for full schemas.
647
647
 
648
648
  The [AgentController](https://mastra.ai/docs/harness/agent-controller) automatically includes all built-in tools in every mode, you don't need to add them manually. See [Tool approvals](https://mastra.ai/docs/harness/agent-controller) for AgentController-specific behavior.
649
649
 
@@ -651,11 +651,11 @@ The [AgentController](https://mastra.ai/docs/harness/agent-controller) automatic
651
651
 
652
652
  - [`createTool` reference](https://mastra.ai/reference/tools/create-tool)
653
653
  - [`Agent.generate()` reference](https://mastra.ai/reference/agents/generate): Runtime options for tool selection, steps, and callbacks
654
- - [Background tasks](https://mastra.ai/docs/long-running-agents/background-tasks): Run long-running tools without blocking the agent loop
655
- - [MCP overview](https://mastra.ai/docs/mcp/overview)
654
+ - [Background tasks](https://mastra.ai/docs/harness/background-tasks): Run long-running tools without blocking the agent loop
655
+ - [MCP overview](https://mastra.ai/docs/connections/mcp)
656
656
  - [Dynamic tool search](https://mastra.ai/reference/processors/tool-search-processor): Load tools on demand for agents with large tool libraries
657
657
  - [Tools with structured output](https://mastra.ai/docs/agents/structured-output): Model compatibility when combining tools and structured output
658
- - [Agent approval](https://mastra.ai/docs/agents/agent-approval)
658
+ - [Agent approval](https://mastra.ai/docs/agents/human-in-the-loop)
659
659
  - [`askUserTool` reference](https://mastra.ai/reference/tools/ask-user-tool)
660
660
  - [`submitPlanTool` reference](https://mastra.ai/reference/tools/submit-plan-tool)
661
661
  - [Task tools reference](https://mastra.ai/reference/tools/task-tools)
@@ -509,5 +509,5 @@ See the [source code](https://github.com/mastra-ai/mastra/tree/main/auth) for im
509
509
 
510
510
  ## Related
511
511
 
512
- - [Auth Overview](https://mastra.ai/docs/server/auth): Authentication concepts and configuration
512
+ - [Auth Overview](https://mastra.ai/docs/auth/overview): Authentication concepts and configuration
513
513
  - [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes): Controlling authentication on custom endpoints
@@ -284,6 +284,32 @@ class MyFGAProvider implements IFGAProvider {
284
284
  }
285
285
  ```
286
286
 
287
+ ### Propagating an actor into workflow steps
288
+
289
+ A workflow run's `actor` reaches each step's execute context, but it isn't passed to the agent and tool calls that step makes. Steps that call an agent without an `actor` fall back to user membership resolution, which fails on system runs that have no user.
290
+
291
+ Set `propagate: true` on the actor to have the framework forward it into the agent and tool calls it makes for declarative `.then(agent)` and `.then(tool)` steps in the run:
292
+
293
+ ```typescript
294
+ await run.start({
295
+ inputData: { city: 'London' },
296
+ actor: { actorKind: 'system', sourceWorkflow: 'nightly-report', propagate: true },
297
+ })
298
+ ```
299
+
300
+ Propagation is opt-in and deliberately narrow:
301
+
302
+ - The `true` shorthand never propagates. Use the object form to opt in.
303
+ - Custom step `execute` functions are never covered. Read `actor` from the step context and pass it explicitly, so a step that acts on a user's behalf can't silently inherit system trust.
304
+ - Pass `actor` when creating the step to override the run actor for that step, including `actor: undefined` to drop back to user authorization mid-run.
305
+
306
+ ```typescript
307
+ // Runs as the system actor even though it loads user-supplied data.
308
+ workflow.then(createStep(reportAgent))
309
+ // Explicitly runs as the user instead.
310
+ workflow.then(createStep(summaryAgent, { actor: undefined }))
311
+ ```
312
+
287
313
  ### Trust requirements
288
314
 
289
315
  The actor signal is trusted input, so construct it server-side:
@@ -299,5 +325,5 @@ The actor signal is trusted input, so construct it server-side:
299
325
  ## Related
300
326
 
301
327
  - [`IFGAProvider` reference](https://mastra.ai/reference/auth/fga)
302
- - [Authentication overview](https://mastra.ai/docs/server/auth)
328
+ - [Authentication overview](https://mastra.ai/docs/auth/overview)
303
329
  - [WorkOS authentication](https://mastra.ai/integrations/auth/workos)
@@ -25,8 +25,8 @@ See [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes) for con
25
25
 
26
26
  ### Built-in
27
27
 
28
- - [Simple Auth](https://mastra.ai/docs/server/auth/simple-auth)
29
- - [JSON Web Token](https://mastra.ai/docs/server/auth/jwt)
28
+ - [Simple Auth](https://mastra.ai/docs/auth/simple-auth)
29
+ - [JSON Web Token](https://mastra.ai/docs/auth/jwt)
30
30
 
31
31
  ### Third-party integrations
32
32
 
@@ -41,5 +41,5 @@ See [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes) for con
41
41
 
42
42
  ### Advanced
43
43
 
44
- - [Composite Auth](https://mastra.ai/docs/server/auth/composite-auth)
45
- - [Custom Provider](https://mastra.ai/docs/server/auth/custom-auth-provider)
44
+ - [Composite Auth](https://mastra.ai/docs/auth/composite-auth)
45
+ - [Custom Provider](https://mastra.ai/docs/auth/custom-auth-provider)
@@ -171,4 +171,4 @@ SimpleAuth is designed for simplicity, not production security:
171
171
  - No cryptographic verification
172
172
  - All tokens must be known at startup
173
173
 
174
- For production applications, consider using [JWT](https://mastra.ai/docs/server/auth/jwt), [Clerk](https://mastra.ai/integrations/auth/clerk), [Auth0](https://mastra.ai/integrations/auth/auth0), or another identity provider.
174
+ For production applications, consider using [JWT](https://mastra.ai/docs/auth/jwt), [Clerk](https://mastra.ai/integrations/auth/clerk), [Auth0](https://mastra.ai/integrations/auth/auth0), or another identity provider.
@@ -130,8 +130,8 @@ Your auth provider's `authenticateToken` callback must recognize whatever creden
130
130
 
131
131
  ## Related
132
132
 
133
- - [Auth overview](https://mastra.ai/docs/server/auth): Available auth providers and how they work
134
- - [Token-based auth](https://mastra.ai/docs/server/auth/simple-auth): Token-to-user mapping authentication
133
+ - [Auth overview](https://mastra.ai/docs/auth/overview): Available auth providers and how they work
134
+ - [Token-based auth](https://mastra.ai/docs/auth/simple-auth): Token-to-user mapping authentication
135
135
  - [Worker deployment](https://mastra.ai/docs/deployment/workers): Set up split worker processes
136
136
  - [Workers reference](https://mastra.ai/reference/workers/overview): Configuration details for all worker types
137
137
  - [CLI reference](https://mastra.ai/reference/cli/mastra): `mastra worker build` and `mastra worker start`
@@ -50,7 +50,7 @@ export const yourAgent = new Agent({
50
50
 
51
51
  > **Note:** Channel adapters require provider-specific environment variables for credentials and request verification, such as bot tokens, signing secrets, app IDs, and webhook verification tokens. Check the guide for your platform or the [Chat SDK adapter catalog](https://chat-sdk.dev/adapters) for the exact variable names.
52
52
 
53
- We recommend configuring [storage](https://mastra.ai/docs/storage/overview) for channels. Storage lets Mastra persist channel state, thread subscriptions, tool approvals, and memory across restarts:
53
+ We recommend configuring [storage](https://mastra.ai/docs/storage) for channels. Storage lets Mastra persist channel state, thread subscriptions, tool approvals, and memory across restarts:
54
54
 
55
55
  ```typescript
56
56
  import { Mastra } from '@mastra/core'
@@ -284,7 +284,7 @@ Vercel and AWS Lambda require `waitUntil`, since they freeze the function as soo
284
284
 
285
285
  ### Coordinate instances with a shared pub/sub
286
286
 
287
- Channels route messages through the agent's [signal pipeline](https://mastra.ai/docs/long-running-agents/signals), and each run acquires a lease on its thread so one run owns the conversation at a time.
287
+ Channels route messages through the agent's [signal pipeline](https://mastra.ai/docs/harness/signals), and each run acquires a lease on its thread so one run owns the conversation at a time.
288
288
 
289
289
  The default in-memory pub/sub can't cross instance boundaries, so on serverless a follow-up message can be routed to a different instance than the one running the agent.
290
290
 
@@ -80,7 +80,7 @@ Use `A2AAgent` when another Mastra agent should delegate work to a remote agent.
80
80
 
81
81
  ## Consume A2A agents as subagents
82
82
 
83
- Use `A2AAgent` to wrap a remote A2A agent, then add it to a parent agent with the [supervisor agents](https://mastra.ai/docs/capabilities/subagents) pattern. Pass an explicit agent card URL when the remote server hosts multiple agents or uses a custom well-known path.
83
+ Use `A2AAgent` to wrap a remote A2A agent, then add it to a parent agent with the [supervisor agents](https://mastra.ai/docs/subagents) pattern. Pass an explicit agent card URL when the remote server hosts multiple agents or uses a custom well-known path.
84
84
 
85
85
  ```typescript
86
86
  import { Agent } from '@mastra/core/agent'
@@ -221,7 +221,7 @@ A2A models human-in-the-loop (HITL) work with the `input-required` task state. W
221
221
 
222
222
  Mastra maps its agent suspension model to this state in both directions:
223
223
 
224
- - **As a server**: when an exposed agent suspends, the task transitions to `input-required`. This includes suspensions caused by [tool approval](https://mastra.ai/docs/agents/agent-approval) or a tool that calls `suspend()`. The task status message includes a text prompt and a data part with the structured `suspendPayload` and `resumeSchema`. A follow-up `message/send` or `message/stream` request with the same `taskId` resumes the suspended run with the provided input.
224
+ - **As a server**: when an exposed agent suspends, the task transitions to `input-required`. This includes suspensions caused by [tool approval](https://mastra.ai/docs/agents/human-in-the-loop) or a tool that calls `suspend()`. The task status message includes a text prompt and a data part with the structured `suspendPayload` and `resumeSchema`. A follow-up `message/send` or `message/stream` request with the same `taskId` resumes the suspended run with the provided input.
225
225
  - **As a client**: when a remote task reaches `input-required` or `auth-required`, `A2AAgent` returns a suspended result with `finishReason: 'suspended'` and a `suspendPayload`. Calling `resumeGenerate()` or `resumeStream()` sends the input or credentials back to the remote task with the original `taskId`.
226
226
 
227
227
  ```typescript
@@ -4,7 +4,7 @@
4
4
 
5
5
  Mastra supports the [Agent Client Protocol (ACP)](https://agentclientprotocol.com/overview/introduction) for running ACP-compatible coding agents from a Mastra agent. Use `@mastra/acp` to wrap a coding agent process as a Mastra tool or as a subagent.
6
6
 
7
- ACP is useful for coding agents such as Claude Code, Amp, Codex, or any other executable that implements ACP over standard input and output.
7
+ ACP is useful for coding agents such as Claude Code, Cline, OpenCode, Amp, Codex, or any other executable that implements ACP over standard input and output.
8
8
 
9
9
  ## When to use ACP
10
10
 
@@ -30,6 +30,18 @@ The flow is:
30
30
 
31
31
  During execution, the ACP client also handles permission requests and file operations. File reads and writes go through Mastra's `Workspace`, so the ACP agent operates inside the workspace you provide.
32
32
 
33
+ ## Compatible agents
34
+
35
+ Any executable that implements ACP over standard input and output works with `@mastra/acp`. You don't need a dedicated Mastra package for each agent. Install the agent, then pass its launch command through `command` and `args`.
36
+
37
+ | Agent | `command` | `args` |
38
+ | ---------- | ---------- | ----------- |
39
+ | Cline | `cline` | `['--acp']` |
40
+ | OpenCode | `opencode` | `['acp']` |
41
+ | Gemini CLI | `gemini` | `['--acp']` |
42
+
43
+ Each agent documents its own ACP mode, and launch flags change between releases. Check the agent's documentation for the current command, such as [Cline ACP](https://docs.cline.bot/usage/acp) or [OpenCode ACP](https://opencode.ai/docs/acp/).
44
+
33
45
  ## Getting started
34
46
 
35
47
  Install `@mastra/acp` in a project that already uses `@mastra/core`. The package requires `@mastra/core` version `1.34.0` or later.
@@ -75,8 +87,8 @@ const codeAgent = new AcpAgent({
75
87
  id: 'code-agent',
76
88
  name: 'Code Agent',
77
89
  description: 'An ACP-compatible coding agent that can inspect and edit files',
78
- command: 'acp-agent',
79
- args: ['--stdio'],
90
+ command: 'opencode',
91
+ args: ['acp'],
80
92
  cwd: process.cwd(),
81
93
  })
82
94
 
@@ -104,8 +116,8 @@ import { Agent } from '@mastra/core/agent'
104
116
  const codeAgentTool = createACPTool({
105
117
  id: 'code-agent',
106
118
  description: 'Use an ACP-compatible coding agent to inspect and edit code',
107
- command: 'acp-agent',
108
- args: ['--stdio'],
119
+ command: 'opencode',
120
+ args: ['acp'],
109
121
  cwd: process.cwd(),
110
122
  })
111
123
 
@@ -151,6 +163,6 @@ See the [AcpAgent workspace integration](https://mastra.ai/reference/acp/acp-age
151
163
  - [AcpAgent reference](https://mastra.ai/reference/acp/acp-agent)
152
164
  - [createACPTool() reference](https://mastra.ai/reference/acp/create-acp-tool)
153
165
  - [Agent reference](https://mastra.ai/reference/agents/agent)
154
- - [Subagents](https://mastra.ai/docs/capabilities/subagents)
166
+ - [Subagents](https://mastra.ai/docs/subagents)
155
167
  - [Agent Client Protocol introduction](https://agentclientprotocol.com/overview/introduction)
156
168
  - [Agent Client Protocol schema](https://agentclientprotocol.com/protocol/schema)
@@ -406,7 +406,7 @@ App iframes allow scripts, forms, and popups. They can't access the parent page'
406
406
 
407
407
  ## Next steps
408
408
 
409
- - [Use tools with agents](https://mastra.ai/docs/agents/using-tools)
409
+ - [Use tools with agents](https://mastra.ai/docs/agents/tools)
410
410
  - [`MCPClient` reference](https://mastra.ai/reference/tools/mcp-client)
411
411
  - [`MCPServer` reference](https://mastra.ai/reference/tools/mcp-server)
412
412
  - [MCP Apps extension specification](https://github.com/modelcontextprotocol/ext-apps)
@@ -4,10 +4,10 @@
4
4
 
5
5
  Connections let Mastra work with remote agents, coding agents, provider software development kit (SDK) runtimes, and external tools and resources. Choose a connection type based on which system owns the agent runtime and what you need to exchange.
6
6
 
7
- - [**Agent-to-Agent (A2A)**](https://mastra.ai/docs/agents/a2a): Expose or consume remote agents across service, framework, vendor, and language boundaries.
8
- - [**Agent Client Protocol (ACP)**](https://mastra.ai/docs/agents/acp): Run compatible coding-agent processes as Mastra tools or subagents.
9
- - [**SDK agents**](https://mastra.ai/docs/agents/sdk-agents): Register Claude, Cursor, or OpenAI SDK-backed agents while the provider SDK retains control of the runtime, tools, permissions, and agent loop.
10
- - [**Model Context Protocol (MCP)**](https://mastra.ai/docs/mcp/overview): Connect agents to external tools and resources, or expose Mastra agents, tools, workflows, prompts, and resources to MCP-compatible systems.
7
+ - [**Model Context Protocol (MCP)**](https://mastra.ai/docs/connections/mcp): Connect agents to external tools and resources, or expose Mastra agents, tools, workflows, prompts, and resources to MCP-compatible systems.
8
+ - [**Agent-to-Agent (A2A)**](https://mastra.ai/docs/connections/a2a): Expose or consume remote agents across service, framework, vendor, and language boundaries.
9
+ - [**Agent Client Protocol (ACP)**](https://mastra.ai/docs/connections/acp): Run compatible coding-agent processes, such as Claude Code, Cline, or OpenCode, as Mastra tools or subagents.
10
+ - [**SDK agents**](https://mastra.ai/docs/connections/sdk-agents): Register Claude, Cursor, or OpenAI SDK-backed agents while the provider SDK retains control of the runtime, tools, permissions, and agent loop.
11
11
 
12
12
  ## When to use connections
13
13
 
@@ -20,7 +20,7 @@ Use connections when you need to:
20
20
 
21
21
  ## Get started
22
22
 
23
- Start with the boundary you need to cross. Use [A2A](https://mastra.ai/docs/agents/a2a) for remote agent endpoints, [ACP](https://mastra.ai/docs/agents/acp) for coding-agent processes, [SDK agents](https://mastra.ai/docs/agents/sdk-agents) for provider-owned runtimes, or [MCP](https://mastra.ai/docs/mcp/overview) for tools and resources.
23
+ Start with the boundary you need to cross. Use [A2A](https://mastra.ai/docs/connections/a2a) for remote agent endpoints, [ACP](https://mastra.ai/docs/connections/acp) for coding-agent processes, [SDK agents](https://mastra.ai/docs/connections/sdk-agents) for provider-owned runtimes, or [MCP](https://mastra.ai/docs/connections/mcp) for tools and resources.
24
24
 
25
25
  **A2A**:
26
26
 
@@ -17,6 +17,8 @@ SDK agents let you use other agent SDK frameworks inside Mastra. Use them to reg
17
17
  - [Cursor Agent SDK](#cursor-agent-sdk): Use `@mastra/cursor` to register a Cursor SDK agent and call it with Mastra `generate()` and `stream()`.
18
18
  - [OpenAI Agents SDK](#openai-agents-sdk): Use `@mastra/openai` to register an OpenAI SDK agent and call it with Mastra `generate()` and `stream()`.
19
19
 
20
+ Coding agents without a dedicated Mastra package, such as Cline and OpenCode, run through the [Agent Client Protocol](https://mastra.ai/docs/connections/acp) instead.
21
+
20
22
  ## Claude Agent SDK
21
23
 
22
24
  Use `@mastra/claude` for Claude Code runtime configuration, permissions, tools, and agent-loop behavior.
@@ -423,5 +425,5 @@ For storage and dashboard setup, see [Observability](https://mastra.ai/docs/obse
423
425
  ## Related
424
426
 
425
427
  - [Agents overview](https://mastra.ai/docs/agents/overview)
426
- - [Tools](https://mastra.ai/docs/agents/using-tools)
428
+ - [Tools](https://mastra.ai/docs/agents/tools)
427
429
  - [Observability](https://mastra.ai/docs/observability/overview)
@@ -21,5 +21,6 @@ The following pages show you how to deploy Mastra to specific cloud providers.
21
21
  - [Inngest](https://mastra.ai/integrations/deploy/inngest)
22
22
  - [Kubernetes](https://mastra.ai/integrations/deploy/kubernetes)
23
23
  - [Netlify](https://mastra.ai/integrations/deploy/netlify)
24
+ - [Render](https://mastra.ai/integrations/deploy/render)
24
25
  - [Temporal](https://mastra.ai/integrations/deploy/temporal)
25
26
  - [Vercel](https://mastra.ai/integrations/deploy/vercel)
@@ -102,7 +102,7 @@ If a `public` folder exists in your Mastra directory (`src/mastra/public`), its
102
102
 
103
103
  ### Mastra configuration
104
104
 
105
- The build process respects configuration in your Mastra instance. For server behavior like CORS, timeouts, and middleware, see [server overview](https://mastra.ai/docs/server/mastra-server). For all available options, see the [configuration reference](https://mastra.ai/reference/configuration).
105
+ The build process respects configuration in your Mastra instance. For server behavior like CORS, timeouts, and middleware, see [server overview](https://mastra.ai/docs/server/overview). For all available options, see the [configuration reference](https://mastra.ai/reference/configuration).
106
106
 
107
107
  ## Build process
108
108
 
@@ -151,7 +151,7 @@ NODE_OPTIONS="--max-old-space-size=4096" mastra build
151
151
 
152
152
  ## Related
153
153
 
154
- - [Server Overview](https://mastra.ai/docs/server/mastra-server): Configure server behavior, middleware, and authentication
154
+ - [Server Overview](https://mastra.ai/docs/server/overview): Configure server behavior, middleware, and authentication
155
155
  - [Server Adapters](https://mastra.ai/docs/server/server-adapters): Use Express or Hono instead of `mastra build`
156
156
  - [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes): Add custom HTTP endpoints
157
157
  - [Configuration Reference](https://mastra.ai/reference/configuration): Full configuration options
@@ -17,7 +17,7 @@ Mastra can run against any of these runtime environments:
17
17
 
18
18
  ### Mastra server
19
19
 
20
- Mastra provides a [server](https://mastra.ai/docs/server/mastra-server) powered by Hono that can be deployed independently. Use the `mastra build` command to build your application and deploy the output to your preferred VM, container, or PaaS platform.
20
+ Mastra provides a [server](https://mastra.ai/docs/server/overview) powered by Hono that can be deployed independently. Use the `mastra build` command to build your application and deploy the output to your preferred VM, container, or PaaS platform.
21
21
 
22
22
  Use this option when you need full control over your infrastructure, long-running processes, or WebSocket connections. The [Mastra server deployment guide](https://mastra.ai/docs/deployment/mastra-server) provides more details.
23
23
 
@@ -52,6 +52,7 @@ Use this option for auto-scaling, minimal infrastructure management, or when you
52
52
  - [Inngest](https://mastra.ai/integrations/deploy/inngest)
53
53
  - [Kubernetes](https://mastra.ai/integrations/deploy/kubernetes)
54
54
  - [Netlify](https://mastra.ai/integrations/deploy/netlify)
55
+ - [Render](https://mastra.ai/integrations/deploy/render)
55
56
  - [Temporal](https://mastra.ai/integrations/deploy/temporal)
56
57
  - [Vercel](https://mastra.ai/integrations/deploy/vercel)
57
58
 
@@ -362,12 +362,12 @@ jobs:
362
362
 
363
363
  ## Security
364
364
 
365
- - The sandbox URL is public. Anyone with the URL can reach your Mastra server, including Studio. Enable [server auth](https://mastra.ai/docs/server/auth) for anything beyond throwaway previews.
365
+ - The sandbox URL is public. Anyone with the URL can reach your Mastra server, including Studio. Enable [server auth](https://mastra.ai/docs/auth/overview) for anything beyond throwaway previews.
366
366
  - Environment variables from your `.env` files are injected into the remote sandbox VM so the server can run. The deploy logs a warning when this happens. Don't deploy secrets you wouldn't put on a shared preview server.
367
- - To restrict access to Tier 3 traffic, pass a `secret` to `createSandboxHandler()` or `createSandboxProxy()`. The helpers attach it as the `x-mastra-sandbox-secret` header on forwarded requests. Configure [server auth](https://mastra.ai/docs/server/auth) to require that header, and direct hits to the sandbox URL get rejected while traffic through your domain works.
367
+ - To restrict access to Tier 3 traffic, pass a `secret` to `createSandboxHandler()` or `createSandboxProxy()`. The helpers attach it as the `x-mastra-sandbox-secret` header on forwarded requests. Configure [server auth](https://mastra.ai/docs/auth/overview) to require that header, and direct hits to the sandbox URL get rejected while traffic through your domain works.
368
368
 
369
369
  ## Related
370
370
 
371
371
  - [Deployment overview](https://mastra.ai/docs/deployment/overview)
372
- - [Server authentication](https://mastra.ai/docs/server/auth)
372
+ - [Server authentication](https://mastra.ai/docs/auth/overview)
373
373
  - [`WorkspaceSandbox` reference](https://mastra.ai/reference/workspace/sandbox)
@@ -339,7 +339,7 @@ MASTRA_STEP_EXECUTION_URL=http://api:4111/api
339
339
 
340
340
  Without this variable, the orchestration worker attempts to execute steps in its own process, which doesn't have access to the full Mastra runtime in a split deployment.
341
341
 
342
- The endpoint uses the server's normal auth pipeline. If the API has an auth provider, set `MASTRA_WORKER_AUTH_TOKEN` to a bearer token that provider accepts. Mastra forwards the value as an `Authorization: Bearer` credential. The configured auth provider validates the token. See [Worker authentication](https://mastra.ai/docs/server/auth/workers) for server configuration and other credential formats.
342
+ The endpoint uses the server's normal auth pipeline. If the API has an auth provider, set `MASTRA_WORKER_AUTH_TOKEN` to a bearer token that provider accepts. Mastra forwards the value as an `Authorization: Bearer` credential. The configured auth provider validates the token. See [Worker authentication](https://mastra.ai/docs/auth/workers) for server configuration and other credential formats.
343
343
 
344
344
  ### Scale workers
345
345
 
@@ -365,18 +365,18 @@ A distributed PubSub backend persists unacknowledged events, which lets orchestr
365
365
 
366
366
  The scheduler calculates the next fire time from the current time after it restarts. It doesn't replay schedules that elapsed while it was unavailable.
367
367
 
368
- If the API crashes while a step is executing, that work can be lost and the workflow run can remain in a `running` state. See [known limitations](#known-limitations) and [durable agent crash recovery](https://mastra.ai/docs/long-running-agents/durable-agents).
368
+ If the API crashes while a step is executing, that work can be lost and the workflow run can remain in a `running` state. See [known limitations](#known-limitations) and [durable agent crash recovery](https://mastra.ai/docs/harness/durable-agents).
369
369
 
370
370
  ## Known limitations
371
371
 
372
372
  - **No dead-letter queue**: Failed events are nacked and retried, but there's no DLQ for events that fail after all retries.
373
373
  - **No built-in health endpoint**: Workers don't expose an HTTP health check. Use container-level liveness probes or process monitoring.
374
374
  - **Scheduler is single-instance**: Running multiple scheduler processes causes duplicate schedule fires.
375
- - **Runs stuck in "running" after API crash**: If the API process crashes while executing a workflow step, the run remains in `running` status with no automatic retry. For [durable agents](https://mastra.ai/docs/long-running-agents/durable-agents), set `recovery.durableAgents` to `'auto'` in the Mastra config to automatically re-drive orphaned runs on server restart. See [Crash recovery](https://mastra.ai/docs/long-running-agents/durable-agents) for details.
375
+ - **Runs stuck in "running" after API crash**: If the API process crashes while executing a workflow step, the run remains in `running` status with no automatic retry. For [durable agents](https://mastra.ai/docs/harness/durable-agents), set `recovery.durableAgents` to `'auto'` in the Mastra config to automatically re-drive orphaned runs on server restart. See [Crash recovery](https://mastra.ai/docs/harness/durable-agents) for details.
376
376
 
377
377
  ## Related
378
378
 
379
- - [Worker authentication](https://mastra.ai/docs/server/auth/workers): Secure worker-to-API communication
379
+ - [Worker authentication](https://mastra.ai/docs/auth/workers): Secure worker-to-API communication
380
380
  - [Workers reference](https://mastra.ai/reference/workers/overview): Details about worker environment variables and types, with a list of supported storage backends
381
381
  - [CLI reference](https://mastra.ai/reference/cli/mastra): `mastra worker build` and `mastra worker start`
382
382
  - [PubSub](https://mastra.ai/docs/server/pubsub): Event delivery backends