@mastra/mcp-docs-server 1.2.4-alpha.1 → 1.2.4-alpha.6

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 (773) hide show
  1. package/.docs/docs/agent-builder/access-control.md +2 -0
  2. package/.docs/docs/agent-builder/browser.md +2 -0
  3. package/.docs/docs/agent-builder/channels.md +2 -0
  4. package/.docs/docs/agent-builder/configuration.md +2 -0
  5. package/.docs/docs/agent-builder/deploying.md +2 -0
  6. package/.docs/docs/agent-builder/integrations.md +2 -0
  7. package/.docs/docs/agent-builder/memory.md +2 -0
  8. package/.docs/docs/agent-builder/model-policy.md +2 -0
  9. package/.docs/docs/agent-builder/overview.md +2 -0
  10. package/.docs/docs/agent-builder/skill-registries.md +2 -0
  11. package/.docs/docs/agent-builder/workspace.md +2 -0
  12. package/.docs/docs/agent-controller/modes.md +2 -0
  13. package/.docs/docs/agent-controller/overview.md +3 -0
  14. package/.docs/docs/agent-controller/session.md +2 -0
  15. package/.docs/docs/agent-controller/subagents.md +3 -0
  16. package/.docs/docs/agent-controller/threads-and-state.md +3 -0
  17. package/.docs/docs/agent-controller/tool-approvals.md +2 -0
  18. package/.docs/docs/agents/a2a.md +2 -0
  19. package/.docs/docs/agents/acp.md +2 -0
  20. package/.docs/docs/agents/adding-voice.md +2 -0
  21. package/.docs/docs/agents/agent-approval.md +2 -0
  22. package/.docs/docs/agents/background-tasks.md +5 -3
  23. package/.docs/docs/agents/channels.md +6 -1
  24. package/.docs/docs/agents/code-mode.md +4 -0
  25. package/.docs/docs/agents/durable-agents.md +3 -1
  26. package/.docs/docs/agents/file-based-agents.md +13 -2
  27. package/.docs/docs/agents/goals.md +4 -0
  28. package/.docs/docs/agents/guardrails.md +2 -0
  29. package/.docs/docs/agents/heartbeats.md +3 -1
  30. package/.docs/docs/agents/networks.md +2 -0
  31. package/.docs/docs/agents/overview.md +112 -0
  32. package/.docs/docs/agents/processors.md +10 -2
  33. package/.docs/docs/agents/sdk-agents.md +2 -0
  34. package/.docs/docs/agents/signal-providers.md +2 -0
  35. package/.docs/docs/agents/signals.md +2 -0
  36. package/.docs/docs/agents/skills.md +2 -0
  37. package/.docs/docs/agents/structured-output.md +2 -0
  38. package/.docs/docs/agents/supervisor-agents.md +3 -0
  39. package/.docs/docs/agents/using-tools.md +5 -0
  40. package/.docs/docs/browser/agent-browser.md +2 -0
  41. package/.docs/docs/browser/browser-viewer.md +2 -0
  42. package/.docs/docs/browser/overview.md +2 -0
  43. package/.docs/docs/browser/recording.md +6 -2
  44. package/.docs/docs/browser/stagehand.md +2 -0
  45. package/.docs/docs/community/contributing-templates.md +2 -0
  46. package/.docs/docs/community/discord.md +2 -0
  47. package/.docs/docs/community/licensing.md +2 -0
  48. package/.docs/docs/deployment/cloud-providers.md +2 -0
  49. package/.docs/docs/deployment/mastra-server.md +2 -0
  50. package/.docs/docs/deployment/monorepo.md +2 -0
  51. package/.docs/docs/deployment/overview.md +2 -0
  52. package/.docs/docs/deployment/web-framework.md +2 -0
  53. package/.docs/docs/deployment/workflow-runners.md +2 -0
  54. package/.docs/docs/editor/overview.md +3 -0
  55. package/.docs/docs/editor/prompts.md +2 -0
  56. package/.docs/docs/editor/tools.md +2 -0
  57. package/.docs/docs/evals/built-in-scorers.md +2 -0
  58. package/.docs/docs/evals/custom-scorers.md +2 -0
  59. package/.docs/docs/evals/datasets/overview.md +2 -0
  60. package/.docs/docs/evals/datasets/running-experiments.md +2 -0
  61. package/.docs/docs/evals/evals-with-memory.md +2 -0
  62. package/.docs/docs/evals/gates-and-verdicts.md +2 -0
  63. package/.docs/docs/evals/overview.md +3 -0
  64. package/.docs/docs/evals/quick-checks.md +3 -0
  65. package/.docs/docs/evals/running-in-ci.md +2 -0
  66. package/.docs/docs/getting-started/build-with-ai.md +5 -5
  67. package/.docs/docs/getting-started/manual-install.md +17 -5
  68. package/.docs/docs/getting-started/project-structure.md +2 -0
  69. package/.docs/docs/index.md +112 -0
  70. package/.docs/docs/mastra-platform/configuration.md +2 -0
  71. package/.docs/docs/mastra-platform/database.md +2 -0
  72. package/.docs/docs/mastra-platform/github.md +2 -0
  73. package/.docs/docs/mastra-platform/observability.md +2 -0
  74. package/.docs/docs/mastra-platform/overview.md +2 -0
  75. package/.docs/docs/mastra-platform/server.md +2 -0
  76. package/.docs/docs/mastra-platform/studio.md +2 -0
  77. package/.docs/docs/mcp/mcp-apps.md +2 -0
  78. package/.docs/docs/mcp/overview.md +2 -0
  79. package/.docs/docs/memory/memory-processors.md +4 -0
  80. package/.docs/docs/memory/message-history.md +2 -0
  81. package/.docs/docs/memory/multi-user-threads.md +2 -0
  82. package/.docs/docs/memory/observational-memory.md +6 -0
  83. package/.docs/docs/memory/overview.md +5 -1
  84. package/.docs/docs/memory/semantic-recall.md +8 -0
  85. package/.docs/docs/memory/storage.md +6 -0
  86. package/.docs/docs/memory/working-memory.md +2 -0
  87. package/.docs/docs/observability/config.md +2 -0
  88. package/.docs/docs/observability/integrations/bridges/datadog.md +2 -0
  89. package/.docs/docs/observability/integrations/bridges/otel.md +2 -0
  90. package/.docs/docs/observability/integrations/exporters/arize.md +2 -0
  91. package/.docs/docs/observability/integrations/exporters/arthur.md +2 -0
  92. package/.docs/docs/observability/integrations/exporters/braintrust.md +2 -0
  93. package/.docs/docs/observability/integrations/exporters/datadog.md +2 -0
  94. package/.docs/docs/observability/integrations/exporters/laminar.md +2 -0
  95. package/.docs/docs/observability/integrations/exporters/langfuse.md +3 -0
  96. package/.docs/docs/observability/integrations/exporters/langsmith.md +2 -0
  97. package/.docs/docs/observability/integrations/exporters/mastra-platform.md +2 -0
  98. package/.docs/docs/observability/integrations/exporters/mastra-storage.md +2 -0
  99. package/.docs/docs/observability/integrations/exporters/otel.md +2 -0
  100. package/.docs/docs/observability/integrations/exporters/posthog.md +2 -0
  101. package/.docs/docs/observability/integrations/exporters/sentry.md +2 -0
  102. package/.docs/docs/observability/integrations/overview.md +2 -0
  103. package/.docs/docs/observability/integrations/processors/sensitive-data-filter.md +2 -0
  104. package/.docs/docs/observability/logging.md +2 -0
  105. package/.docs/docs/observability/metrics/overview.md +2 -0
  106. package/.docs/docs/observability/metrics/querying.md +2 -0
  107. package/.docs/docs/observability/overview.md +2 -0
  108. package/.docs/docs/observability/storage.md +2 -0
  109. package/.docs/docs/observability/tracing/overview.md +2 -0
  110. package/.docs/docs/rag/chunking-and-embedding.md +2 -0
  111. package/.docs/docs/rag/graph-rag.md +2 -0
  112. package/.docs/docs/rag/overview.md +2 -0
  113. package/.docs/docs/rag/retrieval.md +2 -0
  114. package/.docs/docs/rag/vector-databases.md +2 -0
  115. package/.docs/docs/server/auth/auth0.md +2 -0
  116. package/.docs/docs/server/auth/better-auth.md +2 -0
  117. package/.docs/docs/server/auth/clerk.md +2 -0
  118. package/.docs/docs/server/auth/composite-auth.md +2 -0
  119. package/.docs/docs/server/auth/custom-auth-provider.md +2 -0
  120. package/.docs/docs/server/auth/fga.md +2 -0
  121. package/.docs/docs/server/auth/firebase.md +2 -0
  122. package/.docs/docs/server/auth/google.md +2 -0
  123. package/.docs/docs/server/auth/jwt.md +2 -0
  124. package/.docs/docs/server/auth/okta.md +2 -0
  125. package/.docs/docs/server/auth/simple-auth.md +2 -0
  126. package/.docs/docs/server/auth/supabase.md +2 -0
  127. package/.docs/docs/server/auth/workos.md +2 -0
  128. package/.docs/docs/server/auth.md +2 -0
  129. package/.docs/docs/server/custom-adapters.md +2 -0
  130. package/.docs/docs/server/custom-api-routes.md +2 -0
  131. package/.docs/docs/server/mastra-client.md +2 -0
  132. package/.docs/docs/server/mastra-server.md +2 -0
  133. package/.docs/docs/server/middleware.md +2 -0
  134. package/.docs/docs/server/pubsub.md +2 -0
  135. package/.docs/docs/server/request-context.md +2 -0
  136. package/.docs/docs/server/server-adapters.md +2 -0
  137. package/.docs/docs/studio/auth.md +2 -0
  138. package/.docs/docs/studio/deployment.md +2 -0
  139. package/.docs/docs/studio/observability.md +2 -0
  140. package/.docs/docs/studio/overview.md +2 -0
  141. package/.docs/docs/voice/overview.md +2 -0
  142. package/.docs/docs/voice/speech-to-speech.md +2 -0
  143. package/.docs/docs/voice/speech-to-text.md +2 -0
  144. package/.docs/docs/voice/text-to-speech.md +2 -0
  145. package/.docs/docs/workflows/agents-and-tools.md +2 -0
  146. package/.docs/docs/workflows/control-flow.md +2 -0
  147. package/.docs/docs/workflows/error-handling.md +2 -0
  148. package/.docs/docs/workflows/human-in-the-loop.md +2 -0
  149. package/.docs/docs/workflows/overview.md +2 -0
  150. package/.docs/docs/workflows/scheduled-workflows.md +2 -0
  151. package/.docs/docs/workflows/snapshots.md +2 -0
  152. package/.docs/docs/workflows/suspend-and-resume.md +2 -0
  153. package/.docs/docs/workflows/time-travel.md +2 -0
  154. package/.docs/docs/workflows/workflow-state.md +2 -0
  155. package/.docs/docs/workspace/filesystem.md +5 -1
  156. package/.docs/docs/workspace/lsp.md +2 -0
  157. package/.docs/docs/workspace/overview.md +2 -0
  158. package/.docs/docs/workspace/sandbox.md +4 -0
  159. package/.docs/docs/workspace/search.md +2 -0
  160. package/.docs/docs/workspace/skills.md +2 -0
  161. package/.docs/guides/agent-frameworks/ai-sdk.md +2 -0
  162. package/.docs/guides/build-your-ui/ai-sdk-ui.md +2 -0
  163. package/.docs/guides/build-your-ui/assistant-ui.md +2 -0
  164. package/.docs/guides/build-your-ui/copilotkit.md +2 -0
  165. package/.docs/guides/build-your-ui/openui.md +2 -0
  166. package/.docs/guides/concepts/multi-agent-systems.md +2 -0
  167. package/.docs/guides/concepts/streaming.md +2 -0
  168. package/.docs/guides/deployment/amazon-ec2.md +2 -0
  169. package/.docs/guides/deployment/aws-bedrock-agentcore.md +2 -0
  170. package/.docs/guides/deployment/aws-lambda.md +2 -0
  171. package/.docs/guides/deployment/azure-app-services.md +2 -0
  172. package/.docs/guides/deployment/cloudflare.md +2 -0
  173. package/.docs/guides/deployment/digital-ocean.md +2 -0
  174. package/.docs/guides/deployment/inngest.md +2 -0
  175. package/.docs/guides/deployment/netlify.md +2 -0
  176. package/.docs/guides/deployment/temporal.md +2 -0
  177. package/.docs/guides/deployment/vercel.md +2 -0
  178. package/.docs/guides/getting-started/astro.md +2 -0
  179. package/.docs/guides/getting-started/electron.md +2 -0
  180. package/.docs/guides/getting-started/express.md +2 -0
  181. package/.docs/guides/getting-started/hono.md +2 -0
  182. package/.docs/guides/getting-started/nestjs.md +2 -0
  183. package/.docs/guides/getting-started/next-js.md +2 -0
  184. package/.docs/guides/getting-started/nuxt.md +2 -0
  185. package/.docs/guides/getting-started/quickstart.md +4 -0
  186. package/.docs/guides/getting-started/sveltekit.md +2 -0
  187. package/.docs/guides/getting-started/vite-react.md +2 -0
  188. package/.docs/guides/guide/ai-recruiter.md +2 -0
  189. package/.docs/guides/guide/chef-michel.md +2 -0
  190. package/.docs/guides/guide/code-review-bot.md +2 -0
  191. package/.docs/guides/guide/dev-assistant.md +2 -0
  192. package/.docs/guides/guide/docs-manager.md +2 -0
  193. package/.docs/guides/guide/firecrawl.md +2 -0
  194. package/.docs/guides/guide/github-actions-pr-description.md +2 -0
  195. package/.docs/guides/guide/notes-mcp-server.md +2 -0
  196. package/.docs/guides/guide/publishing-mcp-server.md +2 -0
  197. package/.docs/guides/guide/research-assistant.md +2 -0
  198. package/.docs/guides/guide/research-coordinator.md +2 -0
  199. package/.docs/guides/guide/signal-provider.md +2 -0
  200. package/.docs/guides/guide/slack-assistant.md +2 -0
  201. package/.docs/guides/guide/stock-agent.md +2 -0
  202. package/.docs/guides/guide/web-search.md +2 -0
  203. package/.docs/guides/guide/whatsapp-chat-bot.md +2 -0
  204. package/.docs/guides/index.md +2 -0
  205. package/.docs/guides/migrations/agentnetwork.md +3 -0
  206. package/.docs/guides/migrations/ai-sdk-v4-to-v5.md +2 -0
  207. package/.docs/guides/migrations/mastra-cloud.md +2 -0
  208. package/.docs/guides/migrations/network-to-supervisor.md +2 -0
  209. package/.docs/guides/migrations/upgrade-to-v1/agent.md +2 -0
  210. package/.docs/guides/migrations/upgrade-to-v1/cli.md +2 -0
  211. package/.docs/guides/migrations/upgrade-to-v1/client.md +2 -0
  212. package/.docs/guides/migrations/upgrade-to-v1/deployment.md +2 -0
  213. package/.docs/guides/migrations/upgrade-to-v1/evals.md +2 -0
  214. package/.docs/guides/migrations/upgrade-to-v1/mastra.md +2 -0
  215. package/.docs/guides/migrations/upgrade-to-v1/mcp.md +2 -0
  216. package/.docs/guides/migrations/upgrade-to-v1/memory.md +3 -0
  217. package/.docs/guides/migrations/upgrade-to-v1/overview.md +2 -0
  218. package/.docs/guides/migrations/upgrade-to-v1/processors.md +2 -0
  219. package/.docs/guides/migrations/upgrade-to-v1/rag.md +2 -0
  220. package/.docs/guides/migrations/upgrade-to-v1/storage.md +2 -0
  221. package/.docs/guides/migrations/upgrade-to-v1/tools.md +2 -0
  222. package/.docs/guides/migrations/upgrade-to-v1/tracing.md +2 -0
  223. package/.docs/guides/migrations/upgrade-to-v1/vectors.md +2 -0
  224. package/.docs/guides/migrations/upgrade-to-v1/voice.md +3 -0
  225. package/.docs/guides/migrations/upgrade-to-v1/workflows.md +2 -0
  226. package/.docs/guides/migrations/vnext-to-standard-apis.md +2 -0
  227. package/.docs/models/embeddings.md +2 -0
  228. package/.docs/models/environment-variables.md +144 -0
  229. package/.docs/models/gateways/azure-openai.md +2 -0
  230. package/.docs/models/gateways/custom-gateways.md +2 -0
  231. package/.docs/models/gateways/mastra.md +2 -0
  232. package/.docs/models/gateways/netlify.md +5 -2
  233. package/.docs/models/gateways/openrouter.md +4 -1
  234. package/.docs/models/gateways/vercel.md +4 -1
  235. package/.docs/models/gateways.md +2 -0
  236. package/.docs/models/index.md +10 -8
  237. package/.docs/models/providers/302ai.md +2 -0
  238. package/.docs/models/providers/abacus.md +2 -0
  239. package/.docs/models/providers/abliteration-ai.md +2 -0
  240. package/.docs/models/providers/agentrouter.md +2 -0
  241. package/.docs/models/providers/aihubmix.md +2 -0
  242. package/.docs/models/providers/alibaba-cn.md +2 -0
  243. package/.docs/models/providers/alibaba-coding-plan-cn.md +2 -0
  244. package/.docs/models/providers/alibaba-coding-plan.md +2 -0
  245. package/.docs/models/providers/alibaba-token-plan-cn.md +2 -0
  246. package/.docs/models/providers/alibaba-token-plan.md +2 -0
  247. package/.docs/models/providers/alibaba.md +2 -0
  248. package/.docs/models/providers/amazon-bedrock.md +2 -0
  249. package/.docs/models/providers/ambient.md +2 -0
  250. package/.docs/models/providers/anthropic.md +2 -0
  251. package/.docs/models/providers/anyapi.md +2 -0
  252. package/.docs/models/providers/atomic-chat.md +2 -0
  253. package/.docs/models/providers/auriko.md +2 -0
  254. package/.docs/models/providers/azure.md +2 -0
  255. package/.docs/models/providers/bailing.md +2 -0
  256. package/.docs/models/providers/baseten.md +2 -0
  257. package/.docs/models/providers/berget.md +2 -0
  258. package/.docs/models/providers/cerebras.md +7 -4
  259. package/.docs/models/providers/chutes.md +2 -0
  260. package/.docs/models/providers/clarifai.md +2 -0
  261. package/.docs/models/providers/claudinio.md +2 -0
  262. package/.docs/models/providers/cloudferro-sherlock.md +2 -0
  263. package/.docs/models/providers/cloudflare-ai-gateway.md +2 -0
  264. package/.docs/models/providers/cloudflare-workers-ai.md +2 -0
  265. package/.docs/models/providers/cohere.md +2 -0
  266. package/.docs/models/providers/cortecs.md +2 -0
  267. package/.docs/models/providers/crof.md +2 -0
  268. package/.docs/models/providers/databricks.md +2 -0
  269. package/.docs/models/providers/deepinfra.md +2 -0
  270. package/.docs/models/providers/deepseek.md +2 -0
  271. package/.docs/models/providers/digitalocean.md +2 -0
  272. package/.docs/models/providers/dinference.md +2 -0
  273. package/.docs/models/providers/drun.md +2 -0
  274. package/.docs/models/providers/evroc.md +2 -0
  275. package/.docs/models/providers/fastrouter.md +2 -0
  276. package/.docs/models/providers/firepass.md +2 -0
  277. package/.docs/models/providers/fireworks-ai.md +2 -0
  278. package/.docs/models/providers/firmware.md +2 -0
  279. package/.docs/models/providers/freemodel.md +2 -0
  280. package/.docs/models/providers/friendli.md +2 -0
  281. package/.docs/models/providers/frogbot.md +2 -0
  282. package/.docs/models/providers/github-models.md +2 -0
  283. package/.docs/models/providers/gmicloud.md +5 -1
  284. package/.docs/models/providers/google-vertex.md +2 -0
  285. package/.docs/models/providers/google.md +5 -1
  286. package/.docs/models/providers/groq.md +2 -0
  287. package/.docs/models/providers/helicone.md +2 -0
  288. package/.docs/models/providers/hpc-ai.md +2 -0
  289. package/.docs/models/providers/huggingface.md +2 -0
  290. package/.docs/models/providers/iflowcn.md +2 -0
  291. package/.docs/models/providers/inception.md +2 -0
  292. package/.docs/models/providers/inceptron.md +2 -0
  293. package/.docs/models/providers/inference.md +2 -0
  294. package/.docs/models/providers/io-intelligence.md +2 -0
  295. package/.docs/models/providers/io-net.md +2 -0
  296. package/.docs/models/providers/jiekou.md +2 -0
  297. package/.docs/models/providers/kilo.md +2 -0
  298. package/.docs/models/providers/kimi-for-coding.md +2 -0
  299. package/.docs/models/providers/kiro.md +2 -0
  300. package/.docs/models/providers/kuae-cloud-coding-plan.md +2 -0
  301. package/.docs/models/providers/lilac.md +2 -0
  302. package/.docs/models/providers/llama.md +2 -0
  303. package/.docs/models/providers/llmgateway.md +4 -1
  304. package/.docs/models/providers/llmtr.md +2 -0
  305. package/.docs/models/providers/lmstudio.md +2 -0
  306. package/.docs/models/providers/lucidquery.md +2 -0
  307. package/.docs/models/providers/meganova.md +2 -0
  308. package/.docs/models/providers/minimax-cn-coding-plan.md +2 -0
  309. package/.docs/models/providers/minimax-cn.md +2 -0
  310. package/.docs/models/providers/minimax-coding-plan.md +2 -0
  311. package/.docs/models/providers/minimax.md +2 -0
  312. package/.docs/models/providers/mistral.md +2 -0
  313. package/.docs/models/providers/mixlayer.md +2 -0
  314. package/.docs/models/providers/moark.md +2 -0
  315. package/.docs/models/providers/modelscope.md +2 -0
  316. package/.docs/models/providers/moonshotai-cn.md +2 -0
  317. package/.docs/models/providers/moonshotai.md +2 -0
  318. package/.docs/models/providers/morph.md +2 -0
  319. package/.docs/models/providers/nano-gpt.md +2 -0
  320. package/.docs/models/providers/nearai.md +2 -0
  321. package/.docs/models/providers/nebius.md +2 -0
  322. package/.docs/models/providers/neon.md +2 -0
  323. package/.docs/models/providers/neuralwatt.md +2 -0
  324. package/.docs/models/providers/nova.md +2 -0
  325. package/.docs/models/providers/novita-ai.md +2 -0
  326. package/.docs/models/providers/nvidia.md +2 -0
  327. package/.docs/models/providers/ollama-cloud.md +2 -0
  328. package/.docs/models/providers/ollama.md +2 -0
  329. package/.docs/models/providers/openai.md +2 -0
  330. package/.docs/models/providers/opencode-go.md +2 -0
  331. package/.docs/models/providers/opencode.md +4 -1
  332. package/.docs/models/providers/orcarouter.md +2 -0
  333. package/.docs/models/providers/ovhcloud.md +2 -0
  334. package/.docs/models/providers/perplexity-agent.md +2 -0
  335. package/.docs/models/providers/perplexity.md +2 -0
  336. package/.docs/models/providers/poe.md +2 -0
  337. package/.docs/models/providers/poolside.md +2 -0
  338. package/.docs/models/providers/privatemode-ai.md +2 -0
  339. package/.docs/models/providers/qihang-ai.md +2 -0
  340. package/.docs/models/providers/qiniu-ai.md +2 -0
  341. package/.docs/models/providers/regolo-ai.md +2 -0
  342. package/.docs/models/providers/requesty.md +2 -0
  343. package/.docs/models/providers/routing-run.md +2 -0
  344. package/.docs/models/providers/sakana.md +2 -0
  345. package/.docs/models/providers/sarvam.md +2 -0
  346. package/.docs/models/providers/scaleway.md +2 -0
  347. package/.docs/models/providers/siliconflow-cn.md +2 -0
  348. package/.docs/models/providers/siliconflow.md +2 -0
  349. package/.docs/models/providers/snowflake-cortex.md +2 -0
  350. package/.docs/models/providers/stackit.md +2 -0
  351. package/.docs/models/providers/stepfun-ai.md +2 -0
  352. package/.docs/models/providers/stepfun.md +2 -0
  353. package/.docs/models/providers/subconscious.md +2 -0
  354. package/.docs/models/providers/submodel.md +2 -0
  355. package/.docs/models/providers/synthetic.md +4 -5
  356. package/.docs/models/providers/tencent-coding-plan.md +2 -0
  357. package/.docs/models/providers/tencent-token-plan.md +2 -0
  358. package/.docs/models/providers/tencent-tokenhub.md +2 -0
  359. package/.docs/models/providers/the-grid-ai.md +2 -0
  360. package/.docs/models/providers/tinfoil.md +2 -0
  361. package/.docs/models/providers/togetherai.md +2 -0
  362. package/.docs/models/providers/umans-ai-coding-plan.md +2 -0
  363. package/.docs/models/providers/umans-ai.md +2 -0
  364. package/.docs/models/providers/upstage.md +2 -0
  365. package/.docs/models/providers/venice.md +2 -0
  366. package/.docs/models/providers/vivgrid.md +2 -0
  367. package/.docs/models/providers/vultr.md +2 -0
  368. package/.docs/models/providers/wafer.ai.md +2 -0
  369. package/.docs/models/providers/wandb.md +2 -0
  370. package/.docs/models/providers/xai.md +2 -0
  371. package/.docs/models/providers/xiaomi-token-plan-ams.md +2 -0
  372. package/.docs/models/providers/xiaomi-token-plan-cn.md +2 -0
  373. package/.docs/models/providers/xiaomi-token-plan-sgp.md +2 -0
  374. package/.docs/models/providers/xiaomi.md +2 -0
  375. package/.docs/models/providers/xpersona.md +2 -0
  376. package/.docs/models/providers/zai-coding-plan.md +2 -0
  377. package/.docs/models/providers/zai.md +2 -0
  378. package/.docs/models/providers/zeldoc.md +2 -0
  379. package/.docs/models/providers/zenmux.md +2 -0
  380. package/.docs/models/providers/zhipuai-coding-plan.md +2 -0
  381. package/.docs/models/providers/zhipuai.md +3 -1
  382. package/.docs/models/providers.md +2 -0
  383. package/.docs/reference/acp/acp-agent.md +2 -0
  384. package/.docs/reference/acp/create-acp-tool.md +2 -0
  385. package/.docs/reference/agent-controller/agent-controller-class.md +2 -0
  386. package/.docs/reference/agent-controller/session.md +2 -0
  387. package/.docs/reference/agents/agent.md +35 -4
  388. package/.docs/reference/agents/channels.md +7 -0
  389. package/.docs/reference/agents/createSkill.md +2 -0
  390. package/.docs/reference/agents/durable-agent.md +2 -0
  391. package/.docs/reference/agents/generate.md +94 -92
  392. package/.docs/reference/agents/generateLegacy.md +2 -0
  393. package/.docs/reference/agents/getDefaultGenerateOptions.md +2 -0
  394. package/.docs/reference/agents/getDefaultOptions.md +2 -0
  395. package/.docs/reference/agents/getDefaultStreamOptions.md +2 -0
  396. package/.docs/reference/agents/getDescription.md +2 -0
  397. package/.docs/reference/agents/getInstructions.md +2 -0
  398. package/.docs/reference/agents/getLLM.md +2 -0
  399. package/.docs/reference/agents/getMemory.md +2 -0
  400. package/.docs/reference/agents/getMetadata.md +2 -0
  401. package/.docs/reference/agents/getModel.md +2 -0
  402. package/.docs/reference/agents/getSkill.md +2 -0
  403. package/.docs/reference/agents/getTools.md +2 -0
  404. package/.docs/reference/agents/getVoice.md +2 -0
  405. package/.docs/reference/agents/inngest-agent.md +2 -0
  406. package/.docs/reference/agents/listAgents.md +2 -0
  407. package/.docs/reference/agents/listScorers.md +2 -0
  408. package/.docs/reference/agents/listSkills.md +2 -0
  409. package/.docs/reference/agents/listSuspendedRuns.md +2 -0
  410. package/.docs/reference/agents/listTools.md +2 -0
  411. package/.docs/reference/agents/listWorkflows.md +2 -0
  412. package/.docs/reference/agents/network.md +2 -0
  413. package/.docs/reference/ai-sdk/chat-route.md +2 -0
  414. package/.docs/reference/ai-sdk/handle-chat-stream.md +2 -0
  415. package/.docs/reference/ai-sdk/handle-network-stream.md +2 -0
  416. package/.docs/reference/ai-sdk/handle-workflow-stream.md +2 -0
  417. package/.docs/reference/ai-sdk/network-route.md +2 -0
  418. package/.docs/reference/ai-sdk/to-ai-sdk-messages.md +2 -0
  419. package/.docs/reference/ai-sdk/to-ai-sdk-stream.md +2 -0
  420. package/.docs/reference/ai-sdk/to-ai-sdk-v4-messages.md +2 -0
  421. package/.docs/reference/ai-sdk/to-ai-sdk-v5-messages.md +2 -0
  422. package/.docs/reference/ai-sdk/with-mastra.md +2 -0
  423. package/.docs/reference/ai-sdk/workflow-route.md +2 -0
  424. package/.docs/reference/ai-sdk/workflow-snapshot-to-stream.md +2 -0
  425. package/.docs/reference/auth/auth0.md +2 -0
  426. package/.docs/reference/auth/better-auth.md +2 -0
  427. package/.docs/reference/auth/clerk.md +2 -0
  428. package/.docs/reference/auth/firebase.md +2 -0
  429. package/.docs/reference/auth/google.md +2 -0
  430. package/.docs/reference/auth/jwt.md +2 -0
  431. package/.docs/reference/auth/okta.md +2 -0
  432. package/.docs/reference/auth/supabase.md +2 -0
  433. package/.docs/reference/auth/workos.md +2 -0
  434. package/.docs/reference/browser/agent-browser.md +2 -0
  435. package/.docs/reference/browser/browser-viewer.md +2 -0
  436. package/.docs/reference/browser/mastra-browser.md +2 -0
  437. package/.docs/reference/browser/stagehand-browser.md +2 -0
  438. package/.docs/reference/channels/channel-provider.md +2 -0
  439. package/.docs/reference/channels/slack-provider.md +2 -0
  440. package/.docs/reference/cli/create-mastra.md +2 -0
  441. package/.docs/reference/cli/mastra.md +2 -0
  442. package/.docs/reference/client-js/agent-builder.md +2 -0
  443. package/.docs/reference/client-js/agents.md +2 -0
  444. package/.docs/reference/client-js/conversations.md +2 -0
  445. package/.docs/reference/client-js/error-handling.md +2 -0
  446. package/.docs/reference/client-js/logs.md +2 -0
  447. package/.docs/reference/client-js/mastra-client.md +2 -0
  448. package/.docs/reference/client-js/memory.md +2 -0
  449. package/.docs/reference/client-js/observability.md +2 -0
  450. package/.docs/reference/client-js/responses.md +2 -0
  451. package/.docs/reference/client-js/telemetry.md +2 -0
  452. package/.docs/reference/client-js/tools.md +2 -0
  453. package/.docs/reference/client-js/vectors.md +2 -0
  454. package/.docs/reference/client-js/workflows.md +2 -0
  455. package/.docs/reference/coding-agent/build-base-prompt.md +2 -0
  456. package/.docs/reference/coding-agent/create-coding-agent.md +2 -0
  457. package/.docs/reference/configuration.md +2 -0
  458. package/.docs/reference/core/addGateway.md +2 -0
  459. package/.docs/reference/core/getAgent.md +2 -0
  460. package/.docs/reference/core/getAgentById.md +2 -0
  461. package/.docs/reference/core/getDeployer.md +2 -0
  462. package/.docs/reference/core/getEditor.md +2 -0
  463. package/.docs/reference/core/getGateway.md +2 -0
  464. package/.docs/reference/core/getGatewayById.md +2 -0
  465. package/.docs/reference/core/getLogger.md +2 -0
  466. package/.docs/reference/core/getMCPServer.md +2 -0
  467. package/.docs/reference/core/getMCPServerById.md +2 -0
  468. package/.docs/reference/core/getMemory.md +2 -0
  469. package/.docs/reference/core/getScorer.md +2 -0
  470. package/.docs/reference/core/getScorerById.md +2 -0
  471. package/.docs/reference/core/getServer.md +2 -0
  472. package/.docs/reference/core/getStorage.md +2 -0
  473. package/.docs/reference/core/getTelemetry.md +2 -0
  474. package/.docs/reference/core/getVector.md +2 -0
  475. package/.docs/reference/core/getWorkflow.md +2 -0
  476. package/.docs/reference/core/listAgents.md +2 -0
  477. package/.docs/reference/core/listGateways.md +2 -0
  478. package/.docs/reference/core/listLogs.md +2 -0
  479. package/.docs/reference/core/listLogsByRunId.md +2 -0
  480. package/.docs/reference/core/listMCPServers.md +2 -0
  481. package/.docs/reference/core/listMemory.md +2 -0
  482. package/.docs/reference/core/listScorers.md +2 -0
  483. package/.docs/reference/core/listVectors.md +2 -0
  484. package/.docs/reference/core/listWorkflows.md +2 -0
  485. package/.docs/reference/core/mastra-class.md +2 -0
  486. package/.docs/reference/core/mastra-model-gateway.md +2 -0
  487. package/.docs/reference/core/removeWorkspace.md +2 -0
  488. package/.docs/reference/core/setLogger.md +2 -0
  489. package/.docs/reference/core/setStorage.md +2 -0
  490. package/.docs/reference/datasets/addItem.md +2 -0
  491. package/.docs/reference/datasets/addItems.md +2 -0
  492. package/.docs/reference/datasets/compareExperiments.md +2 -0
  493. package/.docs/reference/datasets/create.md +2 -0
  494. package/.docs/reference/datasets/dataset.md +2 -0
  495. package/.docs/reference/datasets/datasets-manager.md +2 -0
  496. package/.docs/reference/datasets/delete.md +2 -0
  497. package/.docs/reference/datasets/deleteExperiment.md +2 -0
  498. package/.docs/reference/datasets/deleteItem.md +2 -0
  499. package/.docs/reference/datasets/deleteItems.md +2 -0
  500. package/.docs/reference/datasets/get.md +2 -0
  501. package/.docs/reference/datasets/getDetails.md +2 -0
  502. package/.docs/reference/datasets/getExperiment.md +2 -0
  503. package/.docs/reference/datasets/getItem.md +2 -0
  504. package/.docs/reference/datasets/getItemHistory.md +2 -0
  505. package/.docs/reference/datasets/list.md +2 -0
  506. package/.docs/reference/datasets/listExperimentResults.md +2 -0
  507. package/.docs/reference/datasets/listExperiments.md +2 -0
  508. package/.docs/reference/datasets/listItems.md +2 -0
  509. package/.docs/reference/datasets/listVersions.md +2 -0
  510. package/.docs/reference/datasets/startExperiment.md +2 -0
  511. package/.docs/reference/datasets/startExperimentAsync.md +2 -0
  512. package/.docs/reference/datasets/update.md +2 -0
  513. package/.docs/reference/datasets/updateItem.md +2 -0
  514. package/.docs/reference/deployer/cloudflare.md +2 -0
  515. package/.docs/reference/deployer/netlify.md +2 -0
  516. package/.docs/reference/deployer/vercel.md +2 -0
  517. package/.docs/reference/deployer.md +2 -0
  518. package/.docs/reference/editor/agent-builder/agent-builder-options.md +2 -0
  519. package/.docs/reference/editor/agent-builder/builder-agent-defaults.md +2 -0
  520. package/.docs/reference/editor/agent-builder/builder-models.md +2 -0
  521. package/.docs/reference/editor/blob-store-provider.md +2 -0
  522. package/.docs/reference/editor/browser-provider.md +2 -0
  523. package/.docs/reference/editor/filesystem-provider.md +2 -0
  524. package/.docs/reference/editor/mastra-editor.md +2 -0
  525. package/.docs/reference/editor/processor-provider.md +2 -0
  526. package/.docs/reference/editor/sandbox-provider.md +2 -0
  527. package/.docs/reference/editor/storage-browser-ref.md +2 -0
  528. package/.docs/reference/editor/storage-workspace-ref.md +2 -0
  529. package/.docs/reference/editor/tool-provider.md +2 -0
  530. package/.docs/reference/evals/answer-relevancy.md +2 -0
  531. package/.docs/reference/evals/answer-similarity.md +2 -0
  532. package/.docs/reference/evals/bias.md +2 -0
  533. package/.docs/reference/evals/checks.md +2 -0
  534. package/.docs/reference/evals/completeness.md +2 -0
  535. package/.docs/reference/evals/content-similarity.md +2 -0
  536. package/.docs/reference/evals/context-precision.md +2 -0
  537. package/.docs/reference/evals/context-relevance.md +2 -0
  538. package/.docs/reference/evals/create-scorer.md +2 -0
  539. package/.docs/reference/evals/faithfulness.md +2 -0
  540. package/.docs/reference/evals/filter-run.md +2 -0
  541. package/.docs/reference/evals/hallucination.md +3 -0
  542. package/.docs/reference/evals/keyword-coverage.md +2 -0
  543. package/.docs/reference/evals/mastra-scorer.md +2 -0
  544. package/.docs/reference/evals/noise-sensitivity.md +2 -0
  545. package/.docs/reference/evals/prompt-alignment.md +3 -0
  546. package/.docs/reference/evals/rubric.md +2 -0
  547. package/.docs/reference/evals/run-evals.md +2 -0
  548. package/.docs/reference/evals/scorer-utils.md +2 -0
  549. package/.docs/reference/evals/textual-difference.md +2 -0
  550. package/.docs/reference/evals/tone-consistency.md +2 -0
  551. package/.docs/reference/evals/tool-call-accuracy.md +2 -0
  552. package/.docs/reference/evals/toxicity.md +2 -0
  553. package/.docs/reference/evals/trajectory-accuracy.md +2 -0
  554. package/.docs/reference/index.md +5 -0
  555. package/.docs/reference/logging/pino-logger.md +2 -0
  556. package/.docs/reference/mastra-platform/api.md +2 -0
  557. package/.docs/reference/memory/clone-utilities.md +2 -0
  558. package/.docs/reference/memory/cloneThread.md +2 -0
  559. package/.docs/reference/memory/createThread.md +2 -0
  560. package/.docs/reference/memory/deleteMessages.md +2 -0
  561. package/.docs/reference/memory/getThreadById.md +2 -0
  562. package/.docs/reference/memory/listThreads.md +2 -0
  563. package/.docs/reference/memory/memory-class.md +3 -0
  564. package/.docs/reference/memory/observational-memory.md +10 -0
  565. package/.docs/reference/memory/recall.md +2 -0
  566. package/.docs/reference/memory/serialized-memory-config.md +2 -0
  567. package/.docs/reference/observability/metrics/automatic-metrics.md +2 -0
  568. package/.docs/reference/observability/tracing/bridges/datadog.md +2 -0
  569. package/.docs/reference/observability/tracing/bridges/otel.md +2 -0
  570. package/.docs/reference/observability/tracing/configuration.md +2 -0
  571. package/.docs/reference/observability/tracing/exporters/arize.md +2 -0
  572. package/.docs/reference/observability/tracing/exporters/arthur.md +2 -0
  573. package/.docs/reference/observability/tracing/exporters/braintrust.md +2 -0
  574. package/.docs/reference/observability/tracing/exporters/cloud-exporter.md +2 -0
  575. package/.docs/reference/observability/tracing/exporters/console-exporter.md +2 -0
  576. package/.docs/reference/observability/tracing/exporters/datadog.md +2 -0
  577. package/.docs/reference/observability/tracing/exporters/default-exporter.md +2 -0
  578. package/.docs/reference/observability/tracing/exporters/laminar.md +2 -0
  579. package/.docs/reference/observability/tracing/exporters/langfuse.md +3 -0
  580. package/.docs/reference/observability/tracing/exporters/langsmith.md +2 -0
  581. package/.docs/reference/observability/tracing/exporters/mastra-platform-exporter.md +2 -0
  582. package/.docs/reference/observability/tracing/exporters/mastra-storage-exporter.md +2 -0
  583. package/.docs/reference/observability/tracing/exporters/otel.md +2 -0
  584. package/.docs/reference/observability/tracing/exporters/posthog.md +2 -0
  585. package/.docs/reference/observability/tracing/exporters/sentry.md +2 -0
  586. package/.docs/reference/observability/tracing/instances.md +2 -0
  587. package/.docs/reference/observability/tracing/interfaces.md +2 -0
  588. package/.docs/reference/observability/tracing/processors/sensitive-data-filter.md +2 -0
  589. package/.docs/reference/observability/tracing/span-filtering.md +2 -0
  590. package/.docs/reference/observability/tracing/spans.md +2 -0
  591. package/.docs/reference/processors/batch-parts-processor.md +3 -0
  592. package/.docs/reference/processors/cost-guard-processor.md +3 -0
  593. package/.docs/reference/processors/language-detector.md +2 -0
  594. package/.docs/reference/processors/message-history-processor.md +3 -0
  595. package/.docs/reference/processors/moderation-processor.md +4 -0
  596. package/.docs/reference/processors/pii-detector.md +4 -0
  597. package/.docs/reference/processors/prefill-error-handler.md +4 -0
  598. package/.docs/reference/processors/processor-interface.md +5 -2
  599. package/.docs/reference/processors/prompt-injection-detector.md +3 -0
  600. package/.docs/reference/processors/provider-history-compat.md +4 -0
  601. package/.docs/reference/processors/regex-filter-processor.md +3 -0
  602. package/.docs/reference/processors/response-cache.md +3 -0
  603. package/.docs/reference/processors/semantic-recall-processor.md +3 -0
  604. package/.docs/reference/processors/skill-search-processor.md +3 -0
  605. package/.docs/reference/processors/stream-error-retry-processor.md +4 -0
  606. package/.docs/reference/processors/system-prompt-scrubber.md +3 -0
  607. package/.docs/reference/processors/token-limiter-processor.md +5 -0
  608. package/.docs/reference/processors/tool-call-filter.md +4 -0
  609. package/.docs/reference/processors/tool-search-processor.md +4 -0
  610. package/.docs/reference/processors/unicode-normalizer.md +2 -0
  611. package/.docs/reference/processors/working-memory-processor.md +3 -0
  612. package/.docs/reference/pubsub/base.md +2 -0
  613. package/.docs/reference/pubsub/caching-pubsub.md +2 -0
  614. package/.docs/reference/pubsub/event-emitter.md +2 -0
  615. package/.docs/reference/pubsub/google-cloud-pubsub.md +2 -0
  616. package/.docs/reference/pubsub/lease-provider.md +2 -0
  617. package/.docs/reference/pubsub/redis-streams.md +2 -0
  618. package/.docs/reference/pubsub/unix-socket-pubsub.md +2 -0
  619. package/.docs/reference/rag/chunk.md +2 -0
  620. package/.docs/reference/rag/database-config.md +2 -0
  621. package/.docs/reference/rag/document.md +2 -0
  622. package/.docs/reference/rag/embeddings.md +2 -0
  623. package/.docs/reference/rag/extract-params.md +2 -0
  624. package/.docs/reference/rag/graph-rag.md +2 -0
  625. package/.docs/reference/rag/metadata-filters.md +2 -0
  626. package/.docs/reference/rag/rerank.md +2 -0
  627. package/.docs/reference/rag/rerankWithScorer.md +2 -0
  628. package/.docs/reference/server/create-route.md +2 -0
  629. package/.docs/reference/server/express-adapter.md +2 -0
  630. package/.docs/reference/server/fastify-adapter.md +2 -0
  631. package/.docs/reference/server/hono-adapter.md +2 -0
  632. package/.docs/reference/server/koa-adapter.md +2 -0
  633. package/.docs/reference/server/mastra-server.md +2 -0
  634. package/.docs/reference/server/nestjs-adapter.md +2 -0
  635. package/.docs/reference/server/register-api-route.md +2 -0
  636. package/.docs/reference/server/routes.md +2 -0
  637. package/.docs/reference/signals/create-notification-inbox-tool.md +2 -0
  638. package/.docs/reference/signals/signal-provider.md +3 -0
  639. package/.docs/reference/signals/task-signal-provider.md +3 -0
  640. package/.docs/reference/signals/webhook-signal-provider.md +3 -0
  641. package/.docs/reference/storage/clickhouse.md +2 -0
  642. package/.docs/reference/storage/cloudflare-d1.md +2 -0
  643. package/.docs/reference/storage/cloudflare.md +2 -0
  644. package/.docs/reference/storage/composite.md +2 -0
  645. package/.docs/reference/storage/convex.md +2 -0
  646. package/.docs/reference/storage/dsql.md +2 -0
  647. package/.docs/reference/storage/duckdb.md +2 -0
  648. package/.docs/reference/storage/dynamodb.md +2 -0
  649. package/.docs/reference/storage/lance.md +2 -0
  650. package/.docs/reference/storage/libsql.md +2 -0
  651. package/.docs/reference/storage/mongodb.md +2 -0
  652. package/.docs/reference/storage/mssql.md +2 -0
  653. package/.docs/reference/storage/overview.md +2 -0
  654. package/.docs/reference/storage/postgresql.md +2 -0
  655. package/.docs/reference/storage/redis.md +2 -0
  656. package/.docs/reference/storage/retention.md +180 -0
  657. package/.docs/reference/storage/spanner.md +2 -0
  658. package/.docs/reference/storage/upstash.md +2 -0
  659. package/.docs/reference/streaming/ChunkType.md +2 -0
  660. package/.docs/reference/streaming/agents/MastraModelOutput.md +2 -0
  661. package/.docs/reference/streaming/agents/stream.md +2 -0
  662. package/.docs/reference/streaming/agents/streamLegacy.md +2 -0
  663. package/.docs/reference/streaming/agents/streamUntilIdle.md +2 -0
  664. package/.docs/reference/streaming/workflows/observeStream.md +2 -0
  665. package/.docs/reference/streaming/workflows/resumeStream.md +2 -0
  666. package/.docs/reference/streaming/workflows/stream.md +2 -0
  667. package/.docs/reference/streaming/workflows/timeTravelStream.md +2 -0
  668. package/.docs/reference/templates/overview.md +3 -0
  669. package/.docs/reference/tools/brightdata.md +2 -0
  670. package/.docs/reference/tools/create-code-mode.md +3 -0
  671. package/.docs/reference/tools/create-tool.md +62 -58
  672. package/.docs/reference/tools/document-chunker-tool.md +2 -0
  673. package/.docs/reference/tools/graph-rag-tool.md +2 -0
  674. package/.docs/reference/tools/mcp-client.md +3 -0
  675. package/.docs/reference/tools/mcp-server.md +3 -1
  676. package/.docs/reference/tools/perplexity.md +2 -0
  677. package/.docs/reference/tools/tavily.md +2 -0
  678. package/.docs/reference/tools/vector-query-tool.md +2 -0
  679. package/.docs/reference/vectors/astra.md +2 -0
  680. package/.docs/reference/vectors/chroma.md +2 -0
  681. package/.docs/reference/vectors/convex.md +2 -0
  682. package/.docs/reference/vectors/couchbase.md +2 -0
  683. package/.docs/reference/vectors/duckdb.md +2 -0
  684. package/.docs/reference/vectors/elasticsearch.md +2 -0
  685. package/.docs/reference/vectors/lance.md +2 -0
  686. package/.docs/reference/vectors/libsql.md +2 -0
  687. package/.docs/reference/vectors/mongodb.md +2 -0
  688. package/.docs/reference/vectors/opensearch.md +2 -0
  689. package/.docs/reference/vectors/pg.md +2 -0
  690. package/.docs/reference/vectors/pinecone.md +2 -0
  691. package/.docs/reference/vectors/qdrant.md +2 -0
  692. package/.docs/reference/vectors/s3vectors.md +2 -0
  693. package/.docs/reference/vectors/turbopuffer.md +2 -0
  694. package/.docs/reference/vectors/upstash.md +2 -0
  695. package/.docs/reference/vectors/vectorize.md +2 -0
  696. package/.docs/reference/voice/aws-nova-sonic.md +2 -0
  697. package/.docs/reference/voice/azure.md +2 -0
  698. package/.docs/reference/voice/cloudflare.md +2 -0
  699. package/.docs/reference/voice/composite-voice.md +2 -0
  700. package/.docs/reference/voice/deepgram.md +2 -0
  701. package/.docs/reference/voice/elevenlabs.md +2 -0
  702. package/.docs/reference/voice/google-gemini-live.md +2 -0
  703. package/.docs/reference/voice/google.md +2 -0
  704. package/.docs/reference/voice/inworld-realtime.md +2 -0
  705. package/.docs/reference/voice/inworld.md +2 -0
  706. package/.docs/reference/voice/mastra-voice.md +2 -0
  707. package/.docs/reference/voice/murf.md +2 -0
  708. package/.docs/reference/voice/openai-realtime.md +2 -0
  709. package/.docs/reference/voice/openai.md +2 -0
  710. package/.docs/reference/voice/playai.md +2 -0
  711. package/.docs/reference/voice/sarvam.md +2 -0
  712. package/.docs/reference/voice/speechify.md +2 -0
  713. package/.docs/reference/voice/voice.addInstructions.md +3 -0
  714. package/.docs/reference/voice/voice.addTools.md +2 -0
  715. package/.docs/reference/voice/voice.answer.md +2 -0
  716. package/.docs/reference/voice/voice.close.md +2 -0
  717. package/.docs/reference/voice/voice.connect.md +2 -0
  718. package/.docs/reference/voice/voice.events.md +2 -0
  719. package/.docs/reference/voice/voice.getSpeakers.md +2 -0
  720. package/.docs/reference/voice/voice.listen.md +2 -0
  721. package/.docs/reference/voice/voice.off.md +2 -0
  722. package/.docs/reference/voice/voice.on.md +2 -0
  723. package/.docs/reference/voice/voice.send.md +2 -0
  724. package/.docs/reference/voice/voice.speak.md +2 -0
  725. package/.docs/reference/voice/voice.updateConfig.md +2 -0
  726. package/.docs/reference/voice/xai-realtime.md +2 -0
  727. package/.docs/reference/workflows/run-methods/cancel.md +2 -0
  728. package/.docs/reference/workflows/run-methods/restart.md +2 -0
  729. package/.docs/reference/workflows/run-methods/resume.md +2 -0
  730. package/.docs/reference/workflows/run-methods/start.md +2 -0
  731. package/.docs/reference/workflows/run-methods/startAsync.md +2 -0
  732. package/.docs/reference/workflows/run-methods/timeTravel.md +2 -0
  733. package/.docs/reference/workflows/run.md +2 -0
  734. package/.docs/reference/workflows/step.md +2 -0
  735. package/.docs/reference/workflows/workflow-methods/branch.md +2 -0
  736. package/.docs/reference/workflows/workflow-methods/commit.md +2 -0
  737. package/.docs/reference/workflows/workflow-methods/create-run.md +2 -0
  738. package/.docs/reference/workflows/workflow-methods/dountil.md +2 -0
  739. package/.docs/reference/workflows/workflow-methods/dowhile.md +2 -0
  740. package/.docs/reference/workflows/workflow-methods/foreach.md +2 -0
  741. package/.docs/reference/workflows/workflow-methods/map.md +2 -0
  742. package/.docs/reference/workflows/workflow-methods/parallel.md +2 -0
  743. package/.docs/reference/workflows/workflow-methods/sleep.md +2 -0
  744. package/.docs/reference/workflows/workflow-methods/sleepUntil.md +2 -0
  745. package/.docs/reference/workflows/workflow-methods/then.md +2 -0
  746. package/.docs/reference/workflows/workflow-state-reader.md +2 -0
  747. package/.docs/reference/workflows/workflow.md +2 -0
  748. package/.docs/reference/workspace/agentcore-runtime-sandbox.md +3 -0
  749. package/.docs/reference/workspace/agentfs-filesystem.md +3 -0
  750. package/.docs/reference/workspace/apple-container-sandbox.md +259 -0
  751. package/.docs/reference/workspace/archil-filesystem.md +3 -0
  752. package/.docs/reference/workspace/azure-blob-filesystem.md +3 -0
  753. package/.docs/reference/workspace/blaxel-sandbox.md +2 -0
  754. package/.docs/reference/workspace/daytona-sandbox.md +2 -0
  755. package/.docs/reference/workspace/docker-sandbox.md +3 -0
  756. package/.docs/reference/workspace/e2b-sandbox.md +3 -0
  757. package/.docs/reference/workspace/files-sdk-filesystem.md +3 -0
  758. package/.docs/reference/workspace/filesystem.md +2 -0
  759. package/.docs/reference/workspace/gcs-filesystem.md +3 -0
  760. package/.docs/reference/workspace/google-drive-filesystem.md +2 -0
  761. package/.docs/reference/workspace/local-filesystem.md +2 -0
  762. package/.docs/reference/workspace/local-sandbox.md +2 -0
  763. package/.docs/reference/workspace/mesa-filesystem.md +321 -0
  764. package/.docs/reference/workspace/modal-sandbox.md +2 -0
  765. package/.docs/reference/workspace/process-manager.md +2 -0
  766. package/.docs/reference/workspace/railway-sandbox.md +2 -0
  767. package/.docs/reference/workspace/s3-filesystem.md +3 -0
  768. package/.docs/reference/workspace/sandbox.md +2 -0
  769. package/.docs/reference/workspace/vercel-microvm-sandbox.md +2 -0
  770. package/.docs/reference/workspace/vercel.md +3 -0
  771. package/.docs/reference/workspace/workspace-class.md +2 -0
  772. package/CHANGELOG.md +23 -0
  773. package/package.json +4 -4
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Access control
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Browser
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Channels
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Configuration
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Deploying
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Tool providers
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Memory
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Model policy
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agent Builder overview
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Skill registries
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Workspace
2
4
 
3
5
  > **Note:** The Agent Builder is part of the Mastra Enterprise Edition. Production deployments require a valid EE license. [Contact sales](https://mastra.ai/contact) for more information.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Modes
2
4
 
3
5
  Modes define the different behaviors an AgentController can run. Each mode layers its own instructions and tool overrides on top of a shared backing agent, so the same agent can act as a planner in one mode and an executor in another. The AgentController keeps exactly one mode active at a time, carries the thread and state across switches, and handles the transition between them.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # AgentController overview
2
4
 
3
5
  > **Beta:** The `AgentController` feature is in beta stage and subject to breaking changes in minor versions until it graduates from its beta status.
@@ -54,6 +56,7 @@ import { AgentController } from '@mastra/core/agent-controller'
54
56
  import { LibSQLStore } from '@mastra/libsql'
55
57
 
56
58
  const agent = new Agent({
59
+ id: 'assistant',
57
60
  name: 'assistant',
58
61
  instructions: 'Help the user plan and complete tasks.',
59
62
  model: 'openai/gpt-5.5',
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Session
2
4
 
3
5
  A [`Session`](https://mastra.ai/reference/agent-controller/session) holds the live state of an AgentController: who the session is for, which thread is active, the selected mode and model, permission grants, queued follow-ups, token usage, application state, and the display snapshot. You reach it through `agentController.session`.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Subagents
2
4
 
3
5
  Subagents let a parent agent delegate focused tasks to child agents with constrained tools and instructions. The AgentController auto-generates a `subagent` built-in tool that the parent model can call to spawn any configured subagent type. Reach for a subagent when a task needs a different toolset or instruction set than the parent agent, when you want to isolate a subtask's messages from the parent thread, or when the parent should delegate to a cheaper or faster model for specific work.
@@ -11,6 +13,7 @@ import { Agent } from '@mastra/core/agent'
11
13
  import { AgentController } from '@mastra/core/agent-controller'
12
14
 
13
15
  const agent = new Agent({
16
+ id: 'assistant',
14
17
  name: 'assistant',
15
18
  instructions: 'Use subagents when a focused task needs a narrower toolset.',
16
19
  model: 'openai/gpt-5.5',
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Threads and state
2
4
 
3
5
  Threads and state are how an AgentController conversation survives beyond a single exchange. A **thread** is the persistent record of a conversation — its messages and metadata, saved to storage so a user can close the app and resume the same conversation later, or switch between several conversations. **State** is structured data attached to the conversation — values like model preferences, feature flags, or progress — that agents and your UI read and write as the conversation runs.
@@ -84,6 +86,7 @@ import { AgentController } from '@mastra/core/agent-controller'
84
86
  import { z } from 'zod'
85
87
 
86
88
  const agent = new Agent({
89
+ id: 'assistant',
87
90
  name: 'assistant',
88
91
  instructions: 'Help the user manage a stateful session.',
89
92
  model: 'openai/gpt-5.5',
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Tool approvals and permissions
2
4
 
3
5
  The AgentController provides a permission system that controls which tools require user approval before execution. You can configure policies at the category level or per-tool, and grant session-wide exceptions for trusted tools. This gives agents with access to destructive or sensitive tools — file writes, command execution, API calls — a human-in-the-loop checkpoint before those tools run.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # A2A (Agent-to-Agent)
2
4
 
3
5
  Mastra supports the [Agent-to-Agent (A2A) protocol](https://a2a-protocol.org/latest/) for cross-platform multi-agent systems. Use A2A to expose Mastra agents as remote agents, consume remote A2A agents as Mastra subagents, or call A2A endpoints with the JavaScript client SDK.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agent Client Protocol
2
4
 
3
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.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Voice
2
4
 
3
5
  Mastra agents can be enhanced with voice capabilities, allowing them to speak responses and listen to user input. You can configure an agent to use either a single voice provider or combine multiple providers for different operations.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agent approval
2
4
 
3
5
  Agents sometimes require the same [human-in-the-loop](https://mastra.ai/docs/workflows/human-in-the-loop) oversight used in workflows when calling tools that handle sensitive operations, like deleting resources or running long processes. With agent approval you can suspend a tool call before it executes so a human can approve or decline it, or let tools suspend themselves to request additional context from the user.
@@ -1,8 +1,10 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Background tasks
2
4
 
3
5
  **Added in:** `@mastra/core@1.29.0`
4
6
 
5
- Background tasks let an agent dispatch a long-running tool call without blocking the agentic loop. The tool returns an immediate acknowledgement, the LLM continues responding, and the task runs to completion in the background. When it finishes, its result is written to memory and if you use `stream()` with the [`untilIdle`](https://mastra.ai/reference/agents/agent) option the agent is re-invoked automatically so the result is processed in the same call.
7
+ Background tasks let an agent dispatch a long-running tool call without blocking the agentic loop. The tool returns an immediate acknowledgement, the LLM continues responding, and the task runs to completion in the background. When it finishes, its result is written to memory and if you use `stream()` with the [`untilIdle`](https://mastra.ai/reference/streaming/agents/stream) option the agent is re-invoked automatically so the result is processed in the same call.
6
8
 
7
9
  ## When to use background tasks
8
10
 
@@ -166,7 +168,7 @@ const stream = await agent.stream('Research solana for me', {
166
168
  })
167
169
  ```
168
170
 
169
- > **Note:** Visit [`Agent.stream()`](https://mastra.ai/reference/agents/agent) for the full API.
171
+ > **Note:** Visit [`Agent.stream()`](https://mastra.ai/reference/streaming/agents/stream) for the full API.
170
172
 
171
173
  ### Aggregate properties
172
174
 
@@ -372,7 +374,7 @@ These read from storage rather than the pubsub stream, so they're suitable for p
372
374
 
373
375
  ## Related
374
376
 
375
- - [`Agent.stream()` reference](https://mastra.ai/reference/agents/agent)
377
+ - [`Agent.stream()` reference](https://mastra.ai/reference/streaming/agents/stream)
376
378
  - [backgroundTasks configuration reference](https://mastra.ai/reference/configuration)
377
379
  - [Durable agents](https://mastra.ai/docs/agents/durable-agents)
378
380
  - [Supervisor agents](https://mastra.ai/docs/agents/supervisor-agents)
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Channels
2
4
 
3
5
  **Added in:** `@mastra/core@1.22.0`
@@ -135,6 +137,7 @@ import { createDiscordAdapter } from '@chat-adapter/discord'
135
137
  import { google } from '@ai-sdk/google'
136
138
 
137
139
  export const visionAgent = new Agent({
140
+ id: 'vision-agent',
138
141
  name: 'Vision Agent',
139
142
  instructions: 'You can see images, watch videos, and listen to audio.',
140
143
  model: google('gemini-3.1-flash-image-preview'),
@@ -175,10 +178,12 @@ A channel webhook returns a `200` response right away, then the agent runs in th
175
178
  On Vercel, pass `waitUntil` from `@vercel/functions`:
176
179
 
177
180
  ```typescript
181
+ import { Agent } from '@mastra/core/agent'
182
+ import { createSlackAdapter } from '@chat-adapter/slack'
178
183
  import { waitUntil } from '@vercel/functions'
179
184
 
180
185
  export const agent = new Agent({
181
- // ...
186
+ id: 'agent',
182
187
  channels: {
183
188
  adapters: {
184
189
  slack: createSlackAdapter(),
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Code mode
2
4
 
3
5
  **Added in:** `@mastra/core@1.38.0`
@@ -59,6 +61,7 @@ const { tool, instructions } = createCodeMode({
59
61
  })
60
62
 
61
63
  const agent = new Agent({
64
+ id: 'shop-assistant',
62
65
  name: 'shop-assistant',
63
66
  instructions: ['You are a helpful shopping assistant.', instructions],
64
67
  model: 'openai/gpt-5.5',
@@ -113,6 +116,7 @@ const inventory = createCodeMode({
113
116
  })
114
117
 
115
118
  const agent = new Agent({
119
+ id: 'ops-assistant',
116
120
  name: 'ops-assistant',
117
121
  instructions: ['You are an ops assistant.', sales.instructions, inventory.instructions],
118
122
  model: 'openai/gpt-5.5',
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Durable agents
2
4
 
3
5
  **Added in:** `@mastra/core@1.45.0`
@@ -172,7 +174,7 @@ export const durableAgent = createDurableAgent({
172
174
 
173
175
  ## Streaming with background tasks
174
176
 
175
- Durable agents support the same [`untilIdle`](https://mastra.ai/reference/agents/durable-agent) option as regular agents. When `untilIdle` is set, `stream()` keeps the connection open across background-task continuations until the agent is idle:
177
+ Durable agents support the same [`untilIdle`](https://mastra.ai/reference/streaming/agents/stream) option as regular agents. When `untilIdle` is set, `stream()` keeps the connection open across background-task continuations until the agent is idle:
176
178
 
177
179
  ```typescript
178
180
  const { output, cleanup } = await durableAgent.stream('Research and summarize the topic', {
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # File-based agents
2
4
 
3
5
  **Added in:** `@mastra/core@1.48.0`
@@ -223,7 +225,16 @@ export default agentConfig({
223
225
 
224
226
  Subagents are isolated. A subagent inherits nothing from its parent. Its tools, skills, and workspace come only from its own directory, and any absent slot falls back to the same framework defaults as a top-level agent.
225
227
 
226
- Subagents are one level deep. A `subagents/` directory nested inside a subagent is ignored with a warning.
228
+ Subagents can declare their own `subagents/` directories, nesting up to three levels below the top-level agent. A `subagents/` directory deeper than that is ignored with a warning.
229
+
230
+ ```text
231
+ src/mastra/agents/
232
+ supervisor/ # depth 0
233
+ subagents/
234
+ researcher/ # depth 1
235
+ subagents/
236
+ summarizer/ # depth 2
237
+ ```
227
238
 
228
239
  Naming rules:
229
240
 
@@ -237,7 +248,7 @@ Naming rules:
237
248
  File-based and code-based agents coexist with deterministic rules:
238
249
 
239
250
  - **Code wins on name collisions:** If an agent name exists in both code and the filesystem, the code-registered agent is kept and a warning is logged.
240
- - **A folder can hold a code agent:** If `config.ts` exports `new Agent({...})`, that instance is used as-is. Sibling `instructions.md`, `tools/`, `skills/`, `memory.ts`, `workspace.ts`, and `subagents/` entries are ignored with warnings.
251
+ - **A folder can hold a code agent:** If `config.ts` exports a configured `new Agent({ id: 'file-based-agent', ... })`, that instance is used as-is. Sibling `instructions.md`, `tools/`, `skills/`, `memory.ts`, `workspace.ts`, and `subagents/` entries are ignored with warnings.
241
252
  - **Instructions:** Dynamic function instructions in `config.ts` win over `instructions.md`. Otherwise, `instructions.md` wins over a static `instructions` string. If neither is present, the build fails for that agent.
242
253
  - **Model:** A missing `model` fails the build and names the agent directory.
243
254
  - **Tools:** Tools from `tools/*.ts` merge with `config.tools`. On a key collision, `config.tools` wins and a warning is logged. If `config.tools` is a function, discovered tools are ignored with a warning.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Goals
2
4
 
3
5
  **Added in:** `@mastra/core@1.42.0`
@@ -26,6 +28,7 @@ Goals require a configured [storage](https://mastra.ai/docs/memory/storage) back
26
28
  import { Agent } from '@mastra/core/agent'
27
29
 
28
30
  const worker = new Agent({
31
+ id: 'worker',
29
32
  name: 'worker',
30
33
  instructions: 'You complete software tasks end to end.',
31
34
  model: 'openai/gpt-5.5',
@@ -66,6 +69,7 @@ By default the step uses a built-in LLM-as-judge scorer that returns `1` when th
66
69
 
67
70
  ```typescript
68
71
  const worker = new Agent({
72
+ id: 'worker',
69
73
  name: 'worker',
70
74
  instructions: 'You complete software tasks end to end.',
71
75
  model: 'openai/gpt-5.5',
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Guardrails
2
4
 
3
5
  Mastra provides built-in processors that add security and safety controls to your agent. These processors detect, transform, or block harmful content before it reaches the language model or the user.
@@ -1,8 +1,10 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Heartbeats
2
4
 
3
5
  **Added in:** `@mastra/core@1.46.0`
4
6
 
5
- > **Beta:** This feature is in alpha. Breaking changes may occur without a major version bump until the API is stable.
7
+ > **Beta:** This feature is in beta. Breaking changes may occur without a major version bump until the API is stable.
6
8
 
7
9
  A heartbeat runs an agent on a cron schedule. On each fire, Mastra sends a prompt to the agent, either as a [signal](https://mastra.ai/docs/agents/signals) into a thread or as a threadless `agent.generate()` run. Use heartbeats for recurring agent work such as daily summaries, periodic checks, or scheduled nudges into a conversation.
8
10
 
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agent networks
2
4
 
3
5
  > **Deprecated — Use supervisor agents:** Agent networks are deprecated and will be removed in a future major release. [Supervisor agents](https://mastra.ai/docs/agents/supervisor-agents) 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.
@@ -1,7 +1,119 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agents overview
2
4
 
3
5
  Agents use LLMs and tools to solve open-ended tasks. They reason about goals, decide which tools to use, retain conversation memory, and iterate internally until the model emits a final answer or an optional stop condition is met. Agents produce structured responses you can render in your UI or process programmatically. Use agents directly or compose them into workflows or multi-agent systems.
4
6
 
7
+ **For AI agents:** If you're tasked to build a Mastra project from scratch, follow the condensed instructions until the next heading. Adjust the example code for the agent & tool to your needs.
8
+
9
+ Create a `package.json` file with `{ "type": "module" }`. Install the required dependencies: `npm install @mastra/core@latest zod@latest typescript@latest @types/node@latest mastra@latest`
10
+
11
+ Create a tsconfig.json file:
12
+
13
+ ```json
14
+ {
15
+ "compilerOptions": {
16
+ "target": "ES2022",
17
+ "module": "ES2022",
18
+ "moduleResolution": "bundler",
19
+ "esModuleInterop": true,
20
+ "forceConsistentCasingInFileNames": true,
21
+ "strict": true,
22
+ "skipLibCheck": true,
23
+ "noEmit": true,
24
+ "allowImportingTsExtensions": true,
25
+ "outDir": "dist"
26
+ },
27
+ "include": ["src/**/*"]
28
+ }
29
+ ```
30
+
31
+ If you need to add a tool to the agent, create a new file and use `import { createTool } from "@mastra/core/tools"`. Plain object tool definitions silently fail to execute; tools MUST be defined via `createTool()` with `id`, `description`, `inputSchema` (zod), `execute()`. `execute()` receives two parameters: the validated input data based on inputSchema (first parameter) and an optional execution context object (second parameter) containing `requestContext`, `tracingContext`, `abortSignal`, and other execution metadata.
32
+
33
+ Example:
34
+
35
+ ```ts
36
+ // src/mastra/tools/weather-tool.ts
37
+ import { createTool } from '@mastra/core/tools'
38
+ import { z } from 'zod'
39
+
40
+ export const weatherTool = createTool({
41
+ id: 'get-weather',
42
+ description: 'Get current weather for a location',
43
+ inputSchema: z.object({
44
+ location: z.string().describe('City name'),
45
+ }),
46
+ outputSchema: z.object({
47
+ output: z.string(),
48
+ }),
49
+ execute: async ({ location }) => {
50
+ return {
51
+ output: `The weather in ${location} is sunny`,
52
+ }
53
+ },
54
+ })
55
+ ```
56
+
57
+ If you need to create an agent, create a new file and use `import { Agent } from "@mastra/core/agent"`. Constructor takes `{ id, name, instructions, model: 'openai/gpt-5.5' }`. The model string is Mastra's model router format ('provider/model'; use / and not : to separate provider and model). It's a bundled model gateway. Do not install any ai-sdk package unless Mastra's documentation says otherwise.
58
+
59
+ Add a tool an agent by importing the tool and passing it to the agent constructor as a tools object.
60
+
61
+ Example:
62
+
63
+ ```ts
64
+ // src/mastra/agents/weather-agent.ts
65
+ import { Agent } from '@mastra/core/agent'
66
+ import { weatherTool } from '../tools/weather-tool.ts'
67
+
68
+ export const weatherAgent = new Agent({
69
+ id: 'weather-agent',
70
+ name: 'Weather Agent',
71
+ instructions: `
72
+ You are a helpful weather assistant that provides accurate weather information.
73
+
74
+ Your primary function is to help users get weather details for specific locations. When responding:
75
+ - Include relevant details like humidity, wind conditions, and precipitation
76
+ - Keep responses concise but informative
77
+
78
+ Use the weatherTool to fetch current weather data.
79
+ `,
80
+ model: 'openai/gpt-5.5',
81
+ tools: { weatherTool },
82
+ })
83
+ ```
84
+
85
+ By defining the model using `provider/model` format Mastra automatically looks for environment variables for the given provider. The defined model requires an environment variable to be set for the provider. OpenAI: `OPENAI_API_KEY`. Anthropic: `ANTHROPIC_API_KEY`. Google: `GOOGLE_API_KEY`. Example: Any `openai/<model>` requires the `OPENAI_API_KEY` environment variable. Go to <https://mastra.ai/models/environment-variables> for a full list of supported providers and their environment variable names.
86
+
87
+ Short list of known model IDs are:
88
+
89
+ - `openai/gpt-5.5`, `openai/gpt-5-mini`
90
+ - `anthropic/claude-sonnet-4-6`, `anthropic/claude-opus-4-7`, `anthropic/claude-haiku-4-5`
91
+ - `google/gemini-2.5-flash`
92
+
93
+ Go to <https://mastra.ai/models> for a full list of supported models.
94
+
95
+ Create a Mastra entry point at `src/mastra/index.ts` and register the agent:
96
+
97
+ ```ts
98
+ import { Mastra } from '@mastra/core'
99
+ import { weatherAgent } from './agents/weather-agent.ts'
100
+
101
+ export const mastra = new Mastra({
102
+ agents: { weatherAgent },
103
+ })
104
+ ```
105
+
106
+ You're now able to run the agent directly. For this, import the Mastra instance and call the agent.generate() after retrieving the agent by its id. Node.js 22.18.0 and later are able to run TypeScript files directly. Make sure to add file extensions when importing local files. Example:
107
+
108
+ ```ts
109
+ // run.mjs
110
+ import { mastra } from './src/mastra/index.ts'
111
+
112
+ const agent = mastra.getAgentById('weather-agent')
113
+ const response = await agent.generate('Weather in SF')
114
+ console.log(response.text)
115
+ ```
116
+
5
117
  ## When to use agents
6
118
 
7
119
  Use agents when the task is open-ended and the steps aren't known in advance. An agent decides which tools to call, how many times to loop, and when to stop. You provide the goal and constraints instead of defining each step. For predetermined, multi-step processes with explicit control flow, use [workflows](https://mastra.ai/docs/workflows/overview) instead.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Processors
2
4
 
3
5
  Processors transform, validate, or control messages as they pass through an agent. They run at specific points in the agent's execution pipeline, allowing you to modify inputs before they reach the language model or outputs before they're returned to users.
@@ -37,6 +39,7 @@ import { Agent } from '@mastra/core/agent'
37
39
  import { ModerationProcessor } from '@mastra/core/processors'
38
40
 
39
41
  export const moderatedAgent = new Agent({
42
+ id: 'moderated-agent',
40
43
  name: 'moderated-agent',
41
44
  instructions: 'You are a helpful assistant',
42
45
  model: 'openai/gpt-5-mini',
@@ -92,6 +95,7 @@ import { Agent } from '@mastra/core/agent'
92
95
  import { PrefillErrorHandler, TokenLimiter, ModerationProcessor } from '@mastra/core/processors'
93
96
 
94
97
  const agent = new Agent({
98
+ id: 'support-agent',
95
99
  name: 'support-agent',
96
100
  model: 'openai/gpt-5',
97
101
  instructions: '...',
@@ -112,7 +116,7 @@ Each array also accepts a function that returns an array, so processors can be b
112
116
 
113
117
  ```typescript
114
118
  new Agent({
115
- // ...
119
+ id: 'processors-agent',
116
120
  inputProcessors: ({ requestContext }) => {
117
121
  const limit = requestContext.get('tokenLimit') ?? 4000
118
122
  return [new TokenLimiter(limit)]
@@ -381,6 +385,7 @@ import { Agent } from '@mastra/core/agent'
381
385
  import { TokenLimiter } from '@mastra/core/processors'
382
386
 
383
387
  const agent = new Agent({
388
+ id: 'my-agent',
384
389
  name: 'my-agent',
385
390
  model: 'openai/gpt-5.5',
386
391
  inputProcessors: [new TokenLimiter(127000)],
@@ -449,6 +454,7 @@ import { ResponseCache } from '@mastra/core/processors'
449
454
  const cache = new InMemoryServerCache()
450
455
 
451
456
  export const searchAgent = new Agent({
457
+ id: 'search-agent',
452
458
  name: 'Search Agent',
453
459
  instructions: 'You answer questions concisely.',
454
460
  model: 'openai/gpt-5',
@@ -494,7 +500,7 @@ Override explicitly when you need a different scope:
494
500
 
495
501
  ```typescript
496
502
  new Agent({
497
- // ...
503
+ id: 'processors-agent',
498
504
  inputProcessors: [
499
505
  new ResponseCache({
500
506
  cache,
@@ -518,6 +524,7 @@ import { RedisCache } from '@mastra/redis'
518
524
  const cache = new RedisCache({ url: process.env.REDIS_URL })
519
525
 
520
526
  export const agent = new Agent({
527
+ id: 'cached-agent',
521
528
  name: 'Cached Agent',
522
529
  instructions: '...',
523
530
  model: 'openai/gpt-5',
@@ -617,6 +624,7 @@ import { EnsureFinalResponseProcessor } from '../processors/ensure-final-respons
617
624
  const MAX_STEPS = 5
618
625
 
619
626
  const agent = new Agent({
627
+ id: 'agent',
620
628
  instructions: `You are a helpful assistant.
621
629
 
622
630
  Some messages you receive may contain <system-reminder>...</system-reminder> tags.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # SDK agents
2
4
 
3
5
  SDK agents let you use other agent SDK frameworks inside Mastra. Use them to register SDK-backed agents in a Mastra project while the provider SDK keeps its own runtime, tools, permissions, and agent loop.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Signal providers
2
4
 
3
5
  **Added in:** `@mastra/core@1.39.0`
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Signals
2
4
 
3
5
  **Added in:** `@mastra/core@1.39.0`
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Agent skills
2
4
 
3
5
  Skills are reusable instructions that teach agents how to perform specific tasks. They follow the [Agent Skills specification](https://agentskills.io).
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Structured output
2
4
 
3
5
  Structured output lets an agent return an object that matches the shape defined by a schema instead of returning text. The schema tells the model what fields to produce, and the model ensures the final result fits that shape.
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Supervisor agents
2
4
 
3
5
  **Added in:** `@mastra/core@1.8.0`
@@ -351,6 +353,7 @@ Each subagent should have a clear `description` that explains what it does, what
351
353
 
352
354
  ```typescript
353
355
  const supervisor = new Agent({
356
+ id: 'supervisor',
354
357
  instructions: `You coordinate research and writing tasks.
355
358
 
356
359
  Available resources:
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # Tools
2
4
 
3
5
  Agents use tools to call APIs, query databases, or 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.
@@ -242,6 +244,7 @@ Use `hooks` to run custom logic before and after every tool call an agent makes.
242
244
  import { Agent } from '@mastra/core/agent'
243
245
 
244
246
  export const supportAgent = new Agent({
247
+ id: 'support-agent',
245
248
  name: 'support-agent',
246
249
  instructions: 'Help users with their questions.',
247
250
  model: 'openai/gpt-5.5',
@@ -260,6 +263,7 @@ export const supportAgent = new Agent({
260
263
 
261
264
  ```typescript
262
265
  const guardedAgent = new Agent({
266
+ id: 'guarded-agent',
263
267
  name: 'guarded-agent',
264
268
  instructions: 'Run shell commands for the user.',
265
269
  model: 'openai/gpt-5.5',
@@ -392,6 +396,7 @@ Subagents and workflows follow the same pattern. They're converted to tools with
392
396
 
393
397
  ```typescript
394
398
  const orchestrator = new Agent({
399
+ id: 'orchestrator',
395
400
  agents: {
396
401
  weather: weatherAgent, // toolName: "agent-weather"
397
402
  },
@@ -1,3 +1,5 @@
1
+ > Discover all available pages from the documentation index: https://mastra.ai/llms.txt
2
+
1
3
  # AgentBrowser
2
4
 
3
5
  The `@mastra/agent-browser` package provides browser automation using Playwright with accessibility-first element targeting. Elements are identified by refs from the page's accessibility tree, making interactions reliable across different page layouts.