@mastra/mcp-docs-server 1.0.0-beta.9 → 1.0.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.
- package/.docs/organized/changelogs/%40internal%2Fchangeset-cli.md +3 -1
- package/.docs/organized/changelogs/%40internal%2Fexternal-types.md +3 -1
- package/.docs/organized/changelogs/%40internal%2Fplayground.md +60 -0
- package/.docs/organized/changelogs/%40internal%2Fstorage-test-utils.md +15 -15
- package/.docs/organized/changelogs/%40internal%2Ftypes-builder.md +3 -1
- package/.docs/organized/changelogs/%40mastra%2Fagent-builder.md +287 -287
- package/.docs/organized/changelogs/%40mastra%2Fai-sdk.md +302 -302
- package/.docs/organized/changelogs/%40mastra%2Fastra.md +53 -53
- package/.docs/organized/changelogs/%40mastra%2Fauth.md +38 -0
- package/.docs/organized/changelogs/%40mastra%2Fchroma.md +66 -66
- package/.docs/organized/changelogs/%40mastra%2Fclickhouse.md +522 -212
- package/.docs/organized/changelogs/%40mastra%2Fclient-js.md +239 -239
- package/.docs/organized/changelogs/%40mastra%2Fcloudflare-d1.md +439 -234
- package/.docs/organized/changelogs/%40mastra%2Fcloudflare.md +450 -211
- package/.docs/organized/changelogs/%40mastra%2Fcodemod.md +202 -0
- package/.docs/organized/changelogs/%40mastra%2Fconvex.md +448 -22
- package/.docs/organized/changelogs/%40mastra%2Fcore.md +348 -348
- package/.docs/organized/changelogs/%40mastra%2Fcouchbase.md +60 -60
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloud.md +287 -287
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloudflare.md +106 -106
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-netlify.md +90 -90
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-vercel.md +86 -86
- package/.docs/organized/changelogs/%40mastra%2Fdeployer.md +221 -221
- package/.docs/organized/changelogs/%40mastra%2Fduckdb.md +70 -0
- package/.docs/organized/changelogs/%40mastra%2Fdynamodb.md +403 -225
- package/.docs/organized/changelogs/%40mastra%2Felasticsearch.md +72 -0
- package/.docs/organized/changelogs/%40mastra%2Fevals.md +145 -145
- package/.docs/organized/changelogs/%40mastra%2Ffastembed.md +54 -0
- package/.docs/organized/changelogs/%40mastra%2Flance.md +456 -226
- package/.docs/organized/changelogs/%40mastra%2Flibsql.md +625 -229
- package/.docs/organized/changelogs/%40mastra%2Floggers.md +71 -71
- package/.docs/organized/changelogs/%40mastra%2Fmcp-docs-server.md +245 -245
- package/.docs/organized/changelogs/%40mastra%2Fmcp-registry-registry.md +28 -28
- package/.docs/organized/changelogs/%40mastra%2Fmcp.md +281 -281
- package/.docs/organized/changelogs/%40mastra%2Fmemory.md +354 -156
- package/.docs/organized/changelogs/%40mastra%2Fmongodb.md +545 -212
- package/.docs/organized/changelogs/%40mastra%2Fmssql.md +481 -202
- package/.docs/organized/changelogs/%40mastra%2Fopensearch.md +194 -194
- package/.docs/organized/changelogs/%40mastra%2Fpg.md +781 -235
- package/.docs/organized/changelogs/%40mastra%2Fpinecone.md +198 -198
- package/.docs/organized/changelogs/%40mastra%2Fplayground-ui.md +282 -282
- package/.docs/organized/changelogs/%40mastra%2Fqdrant.md +163 -163
- package/.docs/organized/changelogs/%40mastra%2Frag.md +310 -310
- package/.docs/organized/changelogs/%40mastra%2Freact.md +328 -237
- package/.docs/organized/changelogs/%40mastra%2Fs3vectors.md +64 -0
- package/.docs/organized/changelogs/%40mastra%2Fschema-compat.md +160 -0
- package/.docs/organized/changelogs/%40mastra%2Fserver.md +230 -230
- package/.docs/organized/changelogs/%40mastra%2Fturbopuffer.md +57 -57
- package/.docs/organized/changelogs/%40mastra%2Fupstash.md +479 -232
- package/.docs/organized/changelogs/%40mastra%2Fvectorize.md +53 -53
- package/.docs/organized/changelogs/%40mastra%2Fvoice-azure.md +45 -45
- package/.docs/organized/changelogs/%40mastra%2Fvoice-cloudflare.md +45 -45
- package/.docs/organized/changelogs/%40mastra%2Fvoice-deepgram.md +47 -47
- package/.docs/organized/changelogs/%40mastra%2Fvoice-elevenlabs.md +110 -110
- package/.docs/organized/changelogs/%40mastra%2Fvoice-gladia.md +15 -0
- package/.docs/organized/changelogs/%40mastra%2Fvoice-google-gemini-live.md +98 -0
- package/.docs/organized/changelogs/%40mastra%2Fvoice-google.md +54 -54
- package/.docs/organized/changelogs/%40mastra%2Fvoice-murf.md +46 -46
- package/.docs/organized/changelogs/%40mastra%2Fvoice-openai-realtime.md +93 -93
- package/.docs/organized/changelogs/%40mastra%2Fvoice-openai.md +47 -47
- package/.docs/organized/changelogs/%40mastra%2Fvoice-playai.md +45 -45
- package/.docs/organized/changelogs/%40mastra%2Fvoice-sarvam.md +45 -45
- package/.docs/organized/changelogs/%40mastra%2Fvoice-speechify.md +45 -45
- package/.docs/organized/changelogs/create-mastra.md +219 -219
- package/.docs/organized/changelogs/mastra.md +276 -276
- package/.docs/organized/code-examples/a2a.md +2 -2
- package/.docs/organized/code-examples/agent-v6.md +221 -0
- package/.docs/organized/code-examples/agui.md +4 -4
- package/.docs/organized/code-examples/ai-elements.md +3 -3
- package/.docs/organized/code-examples/ai-sdk-useChat.md +2 -2
- package/.docs/organized/code-examples/ai-sdk-v5.md +3 -3
- package/.docs/organized/code-examples/assistant-ui.md +5 -5
- package/.docs/organized/code-examples/bird-checker-with-express.md +1 -1
- package/.docs/organized/code-examples/bird-checker-with-nextjs-and-eval.md +2 -2
- package/.docs/organized/code-examples/bird-checker-with-nextjs.md +3 -3
- package/.docs/organized/code-examples/client-side-tools.md +4 -4
- package/.docs/organized/code-examples/crypto-chatbot.md +5 -5
- package/.docs/organized/code-examples/experimental-auth-weather-agent.md +1 -1
- package/.docs/organized/code-examples/fireworks-r1.md +2 -2
- package/.docs/organized/code-examples/heads-up-game.md +7 -7
- package/.docs/organized/code-examples/inngest.md +1075 -0
- package/.docs/organized/code-examples/mcp-configuration.md +1 -1
- package/.docs/organized/code-examples/mcp-server-adapters.md +2 -2
- package/.docs/organized/code-examples/memory-per-resource-example.md +3 -3
- package/.docs/organized/code-examples/memory-todo-agent.md +1 -1
- package/.docs/organized/code-examples/memory-with-context.md +1 -1
- package/.docs/organized/code-examples/memory-with-processors.md +1 -1
- package/.docs/organized/code-examples/openapi-spec-writer.md +3 -3
- package/.docs/organized/code-examples/quick-start.md +1 -5
- package/.docs/organized/code-examples/server-app-access.md +2 -2
- package/.docs/organized/code-examples/server-express-adapter.md +1 -1
- package/.docs/organized/code-examples/server-fastify-adapter.md +83 -0
- package/.docs/organized/code-examples/server-hono-adapter.md +2 -2
- package/.docs/organized/code-examples/server-koa-adapter.md +94 -0
- package/.docs/organized/code-examples/stock-price-tool.md +21 -2
- package/.docs/organized/code-examples/workflow-ai-recruiter.md +1 -1
- package/.docs/organized/code-examples/workflow-with-inline-steps.md +1 -1
- package/.docs/organized/code-examples/workflow-with-memory.md +1 -1
- package/.docs/organized/code-examples/workflow-with-separate-steps.md +1 -1
- package/.docs/organized/code-examples/workflow-with-suspend-resume.md +1 -1
- package/.docs/raw/agents/adding-voice.mdx +24 -6
- package/.docs/raw/agents/agent-approval.mdx +209 -12
- package/.docs/raw/agents/agent-memory.mdx +36 -32
- package/.docs/raw/agents/guardrails.mdx +105 -56
- package/.docs/raw/agents/network-approval.mdx +281 -0
- package/.docs/raw/agents/networks.mdx +69 -13
- package/.docs/raw/agents/overview.mdx +43 -25
- package/.docs/raw/agents/processors.mdx +234 -17
- package/.docs/raw/agents/structured-output.mdx +78 -8
- package/.docs/raw/agents/using-tools.mdx +67 -6
- package/.docs/raw/course/01-first-agent/07-creating-your-agent.md +1 -2
- package/.docs/raw/course/01-first-agent/12-connecting-tool-to-agent.md +1 -1
- package/.docs/raw/course/01-first-agent/16-adding-memory-to-agent.md +1 -2
- package/.docs/raw/course/02-agent-tools-mcp/05-updating-your-agent.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/10-updating-agent-instructions-zapier.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/16-updating-agent-instructions-github.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/21-updating-agent-instructions-hackernews.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/27-updating-agent-instructions-filesystem.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/31-enhancing-memory-configuration.md +3 -3
- package/.docs/raw/course/03-agent-memory/04-creating-basic-memory-agent.md +1 -2
- package/.docs/raw/course/03-agent-memory/07-understanding-memory-threads.md +35 -0
- package/.docs/raw/course/03-agent-memory/08-configuring-conversation-history.md +1 -2
- package/.docs/raw/course/03-agent-memory/13-vector-store-configuration.md +1 -1
- package/.docs/raw/course/03-agent-memory/16-configuring-semantic-recall.md +4 -5
- package/.docs/raw/course/03-agent-memory/18-advanced-configuration-semantic-recall.md +1 -1
- package/.docs/raw/course/03-agent-memory/21-configuring-working-memory.md +3 -4
- package/.docs/raw/course/03-agent-memory/22-custom-working-memory-templates.md +3 -4
- package/.docs/raw/course/03-agent-memory/25-combining-memory-features.md +3 -4
- package/.docs/raw/course/03-agent-memory/27-creating-learning-assistant.md +3 -4
- package/.docs/raw/course/04-workflows/11-creating-an-ai-agent.md +2 -3
- package/.docs/raw/deployment/cloud-providers.mdx +22 -0
- package/.docs/raw/deployment/mastra-server.mdx +140 -0
- package/.docs/raw/deployment/monorepo.mdx +106 -42
- package/.docs/raw/deployment/overview.mdx +35 -48
- package/.docs/raw/deployment/web-framework.mdx +17 -19
- package/.docs/raw/deployment/workflow-runners.mdx +16 -0
- package/.docs/raw/evals/built-in-scorers.mdx +2 -0
- package/.docs/raw/evals/custom-scorers.mdx +60 -12
- package/.docs/raw/evals/overview.mdx +6 -6
- package/.docs/raw/evals/running-in-ci.mdx +4 -2
- package/.docs/raw/getting-started/manual-install.mdx +20 -20
- package/.docs/raw/getting-started/mcp-docs-server.mdx +59 -2
- package/.docs/raw/getting-started/project-structure.mdx +2 -2
- package/.docs/raw/getting-started/start.mdx +17 -1
- package/.docs/raw/getting-started/studio.mdx +6 -35
- package/.docs/raw/guides/agent-frameworks/ai-sdk.mdx +23 -33
- package/.docs/raw/guides/build-your-ui/ai-sdk-ui.mdx +1034 -80
- package/.docs/raw/guides/build-your-ui/assistant-ui.mdx +8 -8
- package/.docs/raw/guides/build-your-ui/copilotkit.mdx +32 -11
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/amazon-ec2.mdx +9 -9
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/aws-lambda.mdx +13 -16
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/azure-app-services.mdx +5 -7
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/cloudflare-deployer.mdx +8 -5
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/digital-ocean.mdx +18 -23
- package/.docs/raw/guides/deployment/index.mdx +32 -0
- package/.docs/raw/guides/deployment/inngest.mdx +673 -0
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/netlify-deployer.mdx +7 -3
- package/.docs/raw/{deployment/cloud-providers → guides/deployment}/vercel-deployer.mdx +8 -5
- package/.docs/raw/guides/getting-started/astro.mdx +292 -451
- package/.docs/raw/guides/getting-started/express.mdx +72 -153
- package/.docs/raw/guides/getting-started/hono.mdx +227 -0
- package/.docs/raw/guides/getting-started/next-js.mdx +173 -61
- package/.docs/raw/guides/getting-started/nuxt.mdx +505 -0
- package/.docs/raw/guides/getting-started/quickstart.mdx +5 -5
- package/.docs/raw/guides/getting-started/sveltekit.mdx +238 -409
- package/.docs/raw/guides/getting-started/vite-react.mdx +317 -147
- package/.docs/raw/guides/guide/ai-recruiter.mdx +10 -10
- package/.docs/raw/guides/guide/chef-michel.mdx +9 -11
- package/.docs/raw/guides/guide/notes-mcp-server.mdx +15 -15
- package/.docs/raw/guides/guide/research-assistant.mdx +20 -20
- package/.docs/raw/guides/guide/stock-agent.mdx +5 -5
- package/.docs/raw/guides/guide/web-search.mdx +38 -38
- package/.docs/raw/guides/guide/whatsapp-chat-bot.mdx +7 -7
- package/.docs/raw/guides/index.mdx +0 -1
- package/.docs/raw/guides/migrations/ai-sdk-v4-to-v5.mdx +2 -2
- package/.docs/raw/guides/migrations/upgrade-to-v1/agent.mdx +105 -4
- package/.docs/raw/guides/migrations/upgrade-to-v1/cli.mdx +15 -1
- package/.docs/raw/guides/migrations/upgrade-to-v1/client.mdx +170 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/deployment.mdx +42 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/mastra.mdx +0 -35
- package/.docs/raw/guides/migrations/upgrade-to-v1/memory.mdx +40 -3
- package/.docs/raw/guides/migrations/upgrade-to-v1/overview.mdx +17 -2
- package/.docs/raw/guides/migrations/upgrade-to-v1/processors.mdx +11 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/rag.mdx +47 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/storage.mdx +271 -25
- package/.docs/raw/guides/migrations/upgrade-to-v1/tracing.mdx +72 -17
- package/.docs/raw/guides/migrations/upgrade-to-v1/vectors.mdx +46 -1
- package/.docs/raw/guides/migrations/upgrade-to-v1/workflows.mdx +50 -7
- package/.docs/raw/guides/migrations/vnext-to-standard-apis.mdx +21 -23
- package/.docs/raw/index.mdx +2 -2
- package/.docs/raw/mastra-cloud/deployment.mdx +86 -0
- package/.docs/raw/mastra-cloud/observability.mdx +43 -0
- package/.docs/raw/mastra-cloud/overview.mdx +31 -0
- package/.docs/raw/mastra-cloud/setup.mdx +64 -0
- package/.docs/raw/mastra-cloud/studio.mdx +35 -0
- package/.docs/raw/mcp/overview.mdx +60 -25
- package/.docs/raw/mcp/publishing-mcp-server.mdx +7 -4
- package/.docs/raw/memory/memory-processors.mdx +17 -12
- package/.docs/raw/memory/message-history.mdx +72 -0
- package/.docs/raw/memory/overview.mdx +38 -76
- package/.docs/raw/memory/semantic-recall.mdx +65 -52
- package/.docs/raw/memory/storage.mdx +248 -0
- package/.docs/raw/memory/working-memory.mdx +24 -13
- package/.docs/raw/observability/logging.mdx +16 -15
- package/.docs/raw/observability/overview.mdx +27 -7
- package/.docs/raw/observability/tracing/bridges/otel.mdx +7 -4
- package/.docs/raw/observability/tracing/exporters/arize.mdx +61 -24
- package/.docs/raw/observability/tracing/exporters/braintrust.mdx +32 -22
- package/.docs/raw/observability/tracing/exporters/cloud.mdx +24 -5
- package/.docs/raw/observability/tracing/exporters/datadog.mdx +175 -0
- package/.docs/raw/observability/tracing/exporters/default.mdx +28 -7
- package/.docs/raw/observability/tracing/exporters/laminar.mdx +89 -0
- package/.docs/raw/observability/tracing/exporters/langfuse.mdx +31 -22
- package/.docs/raw/observability/tracing/exporters/langsmith.mdx +33 -3
- package/.docs/raw/observability/tracing/exporters/otel.mdx +194 -22
- package/.docs/raw/observability/tracing/exporters/posthog.mdx +32 -22
- package/.docs/raw/observability/tracing/exporters/sentry.mdx +198 -0
- package/.docs/raw/observability/tracing/overview.mdx +388 -108
- package/.docs/raw/observability/tracing/processors/sensitive-data-filter.mdx +27 -7
- package/.docs/raw/rag/chunking-and-embedding.mdx +22 -33
- package/.docs/raw/rag/graph-rag.mdx +223 -0
- package/.docs/raw/rag/overview.mdx +6 -3
- package/.docs/raw/rag/retrieval.mdx +53 -57
- package/.docs/raw/rag/vector-databases.mdx +55 -31
- package/.docs/raw/reference/agents/agent.mdx +17 -14
- package/.docs/raw/reference/agents/generate.mdx +172 -44
- package/.docs/raw/reference/agents/generateLegacy.mdx +5 -3
- package/.docs/raw/reference/agents/getDefaultGenerateOptions.mdx +5 -3
- package/.docs/raw/reference/agents/getDefaultOptions.mdx +5 -3
- package/.docs/raw/reference/agents/getDefaultStreamOptions.mdx +5 -3
- package/.docs/raw/reference/agents/getDescription.mdx +3 -1
- package/.docs/raw/reference/agents/getInstructions.mdx +5 -3
- package/.docs/raw/reference/agents/getLLM.mdx +5 -3
- package/.docs/raw/reference/agents/getMemory.mdx +5 -3
- package/.docs/raw/reference/agents/getModel.mdx +5 -3
- package/.docs/raw/reference/agents/getTools.mdx +4 -2
- package/.docs/raw/reference/agents/getVoice.mdx +4 -2
- package/.docs/raw/reference/agents/listAgents.mdx +4 -2
- package/.docs/raw/reference/agents/listScorers.mdx +5 -3
- package/.docs/raw/reference/agents/listTools.mdx +4 -2
- package/.docs/raw/reference/agents/listWorkflows.mdx +4 -2
- package/.docs/raw/reference/agents/network.mdx +113 -1
- package/.docs/raw/reference/ai-sdk/chat-route.mdx +6 -3
- package/.docs/raw/reference/ai-sdk/handle-chat-stream.mdx +4 -2
- package/.docs/raw/reference/ai-sdk/handle-network-stream.mdx +4 -2
- package/.docs/raw/reference/ai-sdk/handle-workflow-stream.mdx +5 -3
- package/.docs/raw/reference/ai-sdk/network-route.mdx +6 -3
- package/.docs/raw/reference/ai-sdk/to-ai-sdk-stream.mdx +10 -6
- package/.docs/raw/reference/ai-sdk/to-ai-sdk-v4-messages.mdx +130 -0
- package/.docs/raw/reference/ai-sdk/to-ai-sdk-v5-messages.mdx +110 -0
- package/.docs/raw/reference/ai-sdk/with-mastra.mdx +122 -0
- package/.docs/raw/reference/ai-sdk/workflow-route.mdx +7 -4
- package/.docs/raw/reference/auth/auth0.mdx +5 -3
- package/.docs/raw/reference/auth/clerk.mdx +5 -3
- package/.docs/raw/reference/auth/firebase.mdx +6 -5
- package/.docs/raw/reference/auth/jwt.mdx +5 -3
- package/.docs/raw/reference/auth/supabase.mdx +5 -3
- package/.docs/raw/reference/auth/workos.mdx +5 -3
- package/.docs/raw/reference/cli/create-mastra.mdx +12 -10
- package/.docs/raw/reference/cli/mastra.mdx +63 -15
- package/.docs/raw/reference/client-js/agents.mdx +77 -35
- package/.docs/raw/reference/client-js/error-handling.mdx +3 -3
- package/.docs/raw/reference/client-js/logs.mdx +2 -0
- package/.docs/raw/reference/client-js/mastra-client.mdx +4 -2
- package/.docs/raw/reference/client-js/memory.mdx +43 -1
- package/.docs/raw/reference/client-js/observability.mdx +2 -0
- package/.docs/raw/reference/client-js/telemetry.mdx +2 -0
- package/.docs/raw/reference/client-js/tools.mdx +2 -0
- package/.docs/raw/reference/client-js/vectors.mdx +2 -0
- package/.docs/raw/reference/client-js/workflows.mdx +47 -3
- package/.docs/raw/reference/configuration.mdx +761 -0
- package/.docs/raw/reference/core/addGateway.mdx +2 -0
- package/.docs/raw/reference/core/getAgent.mdx +3 -1
- package/.docs/raw/reference/core/getAgentById.mdx +3 -1
- package/.docs/raw/reference/core/getDeployer.mdx +3 -1
- package/.docs/raw/reference/core/getGateway.mdx +2 -0
- package/.docs/raw/reference/core/getGatewayById.mdx +2 -0
- package/.docs/raw/reference/core/getLogger.mdx +3 -1
- package/.docs/raw/reference/core/getMCPServer.mdx +3 -1
- package/.docs/raw/reference/core/getMCPServerById.mdx +3 -1
- package/.docs/raw/reference/core/getMemory.mdx +7 -3
- package/.docs/raw/reference/core/getScorer.mdx +2 -0
- package/.docs/raw/reference/core/getScorerById.mdx +2 -0
- package/.docs/raw/reference/core/getServer.mdx +6 -4
- package/.docs/raw/reference/core/getStorage.mdx +5 -3
- package/.docs/raw/reference/core/getStoredAgentById.mdx +6 -4
- package/.docs/raw/reference/core/getTelemetry.mdx +3 -1
- package/.docs/raw/reference/core/getVector.mdx +3 -1
- package/.docs/raw/reference/core/getWorkflow.mdx +3 -1
- package/.docs/raw/reference/core/listAgents.mdx +3 -1
- package/.docs/raw/reference/core/listGateways.mdx +2 -0
- package/.docs/raw/reference/core/listLogs.mdx +3 -1
- package/.docs/raw/reference/core/listLogsByRunId.mdx +3 -1
- package/.docs/raw/reference/core/listMCPServers.mdx +3 -1
- package/.docs/raw/reference/core/listMemory.mdx +8 -4
- package/.docs/raw/reference/core/listScorers.mdx +2 -0
- package/.docs/raw/reference/core/listStoredAgents.mdx +7 -5
- package/.docs/raw/reference/core/listVectors.mdx +3 -1
- package/.docs/raw/reference/core/listWorkflows.mdx +3 -1
- package/.docs/raw/reference/core/mastra-class.mdx +27 -20
- package/.docs/raw/reference/core/mastra-model-gateway.mdx +2 -0
- package/.docs/raw/reference/core/setLogger.mdx +3 -1
- package/.docs/raw/reference/core/setStorage.mdx +6 -4
- package/.docs/raw/reference/deployer/cloudflare.mdx +22 -53
- package/.docs/raw/reference/deployer/deployer.mdx +2 -1
- package/.docs/raw/reference/deployer/netlify.mdx +4 -1
- package/.docs/raw/reference/deployer/vercel.mdx +5 -4
- package/.docs/raw/reference/evals/answer-relevancy.mdx +4 -1
- package/.docs/raw/reference/evals/answer-similarity.mdx +4 -1
- package/.docs/raw/reference/evals/bias.mdx +4 -1
- package/.docs/raw/reference/evals/completeness.mdx +4 -1
- package/.docs/raw/reference/evals/content-similarity.mdx +4 -1
- package/.docs/raw/reference/evals/context-precision.mdx +4 -1
- package/.docs/raw/reference/evals/context-relevance.mdx +2 -0
- package/.docs/raw/reference/evals/create-scorer.mdx +11 -3
- package/.docs/raw/reference/evals/faithfulness.mdx +4 -1
- package/.docs/raw/reference/evals/hallucination.mdx +4 -1
- package/.docs/raw/reference/evals/keyword-coverage.mdx +4 -1
- package/.docs/raw/reference/evals/mastra-scorer.mdx +2 -0
- package/.docs/raw/reference/evals/noise-sensitivity.mdx +2 -0
- package/.docs/raw/reference/evals/prompt-alignment.mdx +9 -7
- package/.docs/raw/reference/evals/run-evals.mdx +3 -1
- package/.docs/raw/reference/evals/scorer-utils.mdx +3 -0
- package/.docs/raw/reference/evals/textual-difference.mdx +4 -1
- package/.docs/raw/reference/evals/tone-consistency.mdx +4 -1
- package/.docs/raw/reference/evals/tool-call-accuracy.mdx +25 -23
- package/.docs/raw/reference/evals/toxicity.mdx +4 -1
- package/.docs/raw/reference/index.mdx +2 -1
- package/.docs/raw/reference/logging/pino-logger.mdx +10 -8
- package/.docs/raw/reference/memory/clone-utilities.mdx +345 -0
- package/.docs/raw/reference/memory/cloneThread.mdx +237 -0
- package/.docs/raw/reference/memory/createThread.mdx +6 -4
- package/.docs/raw/reference/memory/deleteMessages.mdx +4 -2
- package/.docs/raw/reference/memory/getThreadById.mdx +3 -1
- package/.docs/raw/reference/memory/listThreads.mdx +187 -0
- package/.docs/raw/reference/memory/memory-class.mdx +27 -20
- package/.docs/raw/reference/memory/recall.mdx +6 -4
- package/.docs/raw/reference/observability/tracing/bridges/otel.mdx +6 -2
- package/.docs/raw/reference/observability/tracing/configuration.mdx +51 -0
- package/.docs/raw/reference/observability/tracing/exporters/arize.mdx +25 -6
- package/.docs/raw/reference/observability/tracing/exporters/braintrust.mdx +23 -2
- package/.docs/raw/reference/observability/tracing/exporters/cloud-exporter.mdx +10 -0
- package/.docs/raw/reference/observability/tracing/exporters/console-exporter.mdx +3 -0
- package/.docs/raw/reference/observability/tracing/exporters/datadog.mdx +172 -0
- package/.docs/raw/reference/observability/tracing/exporters/default-exporter.mdx +10 -0
- package/.docs/raw/reference/observability/tracing/exporters/laminar.mdx +139 -0
- package/.docs/raw/reference/observability/tracing/exporters/langfuse.mdx +26 -4
- package/.docs/raw/reference/observability/tracing/exporters/langsmith.mdx +10 -0
- package/.docs/raw/reference/observability/tracing/exporters/otel.mdx +51 -34
- package/.docs/raw/reference/observability/tracing/exporters/posthog.mdx +25 -4
- package/.docs/raw/reference/observability/tracing/exporters/sentry.mdx +224 -0
- package/.docs/raw/reference/observability/tracing/instances.mdx +2 -0
- package/.docs/raw/reference/observability/tracing/interfaces.mdx +20 -0
- package/.docs/raw/reference/observability/tracing/processors/sensitive-data-filter.mdx +2 -0
- package/.docs/raw/reference/observability/tracing/spans.mdx +2 -0
- package/.docs/raw/reference/processors/batch-parts-processor.mdx +4 -2
- package/.docs/raw/reference/processors/language-detector.mdx +6 -3
- package/.docs/raw/reference/processors/message-history-processor.mdx +5 -2
- package/.docs/raw/reference/processors/moderation-processor.mdx +6 -4
- package/.docs/raw/reference/processors/pii-detector.mdx +6 -4
- package/.docs/raw/reference/processors/processor-interface.mdx +326 -23
- package/.docs/raw/reference/processors/prompt-injection-detector.mdx +5 -3
- package/.docs/raw/reference/processors/semantic-recall-processor.mdx +7 -2
- package/.docs/raw/reference/processors/system-prompt-scrubber.mdx +5 -3
- package/.docs/raw/reference/processors/token-limiter-processor.mdx +62 -19
- package/.docs/raw/reference/processors/tool-call-filter.mdx +5 -3
- package/.docs/raw/reference/processors/unicode-normalizer.mdx +6 -3
- package/.docs/raw/reference/processors/working-memory-processor.mdx +6 -3
- package/.docs/raw/reference/rag/chunk.mdx +7 -6
- package/.docs/raw/reference/rag/database-config.mdx +8 -6
- package/.docs/raw/reference/rag/document.mdx +2 -0
- package/.docs/raw/reference/rag/embeddings.mdx +2 -0
- package/.docs/raw/reference/rag/extract-params.mdx +57 -3
- package/.docs/raw/reference/rag/graph-rag.mdx +2 -0
- package/.docs/raw/reference/rag/metadata-filters.mdx +27 -7
- package/.docs/raw/reference/rag/rerank.mdx +2 -0
- package/.docs/raw/reference/rag/rerankWithScorer.mdx +2 -0
- package/.docs/raw/reference/server/create-route.mdx +34 -18
- package/.docs/raw/reference/server/express-adapter.mdx +27 -51
- package/.docs/raw/reference/server/fastify-adapter.mdx +130 -0
- package/.docs/raw/reference/server/hono-adapter.mdx +27 -51
- package/.docs/raw/reference/server/koa-adapter.mdx +129 -0
- package/.docs/raw/reference/server/mastra-server.mdx +52 -34
- package/.docs/raw/reference/server/routes.mdx +73 -10
- package/.docs/raw/reference/storage/cloudflare-d1.mdx +10 -5
- package/.docs/raw/reference/storage/cloudflare.mdx +12 -2
- package/.docs/raw/reference/storage/composite.mdx +245 -0
- package/.docs/raw/reference/storage/convex.mdx +8 -6
- package/.docs/raw/reference/storage/dynamodb.mdx +134 -8
- package/.docs/raw/reference/storage/lance.mdx +9 -5
- package/.docs/raw/reference/storage/libsql.mdx +76 -54
- package/.docs/raw/reference/storage/mongodb.mdx +115 -16
- package/.docs/raw/reference/storage/mssql.mdx +11 -6
- package/.docs/raw/{server-db/storage.mdx → reference/storage/overview.mdx} +15 -111
- package/.docs/raw/reference/storage/postgresql.mdx +228 -83
- package/.docs/raw/reference/storage/upstash.mdx +78 -2
- package/.docs/raw/reference/streaming/ChunkType.mdx +31 -3
- package/.docs/raw/reference/streaming/agents/MastraModelOutput.mdx +67 -6
- package/.docs/raw/reference/streaming/agents/stream.mdx +48 -51
- package/.docs/raw/reference/streaming/agents/streamLegacy.mdx +5 -3
- package/.docs/raw/reference/streaming/workflows/observeStream.mdx +3 -1
- package/.docs/raw/reference/streaming/workflows/resumeStream.mdx +3 -1
- package/.docs/raw/reference/streaming/workflows/stream.mdx +37 -22
- package/.docs/raw/reference/streaming/workflows/timeTravelStream.mdx +6 -4
- package/.docs/raw/reference/templates/overview.mdx +3 -2
- package/.docs/raw/reference/tools/client.mdx +3 -0
- package/.docs/raw/reference/tools/create-tool.mdx +127 -5
- package/.docs/raw/reference/tools/document-chunker-tool.mdx +2 -0
- package/.docs/raw/reference/tools/graph-rag-tool.mdx +40 -3
- package/.docs/raw/reference/tools/mcp-client.mdx +110 -1
- package/.docs/raw/reference/tools/mcp-server.mdx +278 -24
- package/.docs/raw/reference/tools/vector-query-tool.mdx +68 -4
- package/.docs/raw/reference/vectors/astra.mdx +5 -3
- package/.docs/raw/reference/vectors/chroma.mdx +5 -3
- package/.docs/raw/reference/vectors/convex.mdx +14 -12
- package/.docs/raw/reference/vectors/couchbase.mdx +7 -5
- package/.docs/raw/reference/vectors/duckdb.mdx +12 -10
- package/.docs/raw/reference/vectors/elasticsearch.mdx +12 -4
- package/.docs/raw/reference/vectors/lance.mdx +6 -4
- package/.docs/raw/reference/vectors/libsql.mdx +66 -13
- package/.docs/raw/reference/vectors/mongodb.mdx +90 -10
- package/.docs/raw/reference/vectors/opensearch.mdx +30 -3
- package/.docs/raw/reference/vectors/pg.mdx +58 -6
- package/.docs/raw/reference/vectors/pinecone.mdx +23 -8
- package/.docs/raw/reference/vectors/qdrant.mdx +148 -4
- package/.docs/raw/reference/vectors/s3vectors.mdx +8 -6
- package/.docs/raw/reference/vectors/turbopuffer.mdx +6 -4
- package/.docs/raw/reference/vectors/upstash.mdx +60 -6
- package/.docs/raw/reference/vectors/vectorize.mdx +5 -3
- package/.docs/raw/reference/voice/azure.mdx +2 -0
- package/.docs/raw/reference/voice/cloudflare.mdx +2 -0
- package/.docs/raw/reference/voice/composite-voice.mdx +4 -0
- package/.docs/raw/reference/voice/deepgram.mdx +2 -0
- package/.docs/raw/reference/voice/elevenlabs.mdx +2 -0
- package/.docs/raw/reference/voice/google-gemini-live.mdx +3 -0
- package/.docs/raw/reference/voice/google.mdx +2 -0
- package/.docs/raw/reference/voice/mastra-voice.mdx +2 -0
- package/.docs/raw/reference/voice/murf.mdx +2 -0
- package/.docs/raw/reference/voice/openai-realtime.mdx +3 -0
- package/.docs/raw/reference/voice/openai.mdx +2 -0
- package/.docs/raw/reference/voice/playai.mdx +2 -0
- package/.docs/raw/reference/voice/sarvam.mdx +2 -0
- package/.docs/raw/reference/voice/speechify.mdx +2 -0
- package/.docs/raw/reference/voice/voice.addInstructions.mdx +3 -0
- package/.docs/raw/reference/voice/voice.addTools.mdx +3 -0
- package/.docs/raw/reference/voice/voice.answer.mdx +4 -0
- package/.docs/raw/reference/voice/voice.close.mdx +3 -0
- package/.docs/raw/reference/voice/voice.connect.mdx +5 -1
- package/.docs/raw/reference/voice/voice.events.mdx +2 -0
- package/.docs/raw/reference/voice/voice.getSpeakers.mdx +3 -0
- package/.docs/raw/reference/voice/voice.listen.mdx +6 -0
- package/.docs/raw/reference/voice/voice.off.mdx +2 -0
- package/.docs/raw/reference/voice/voice.on.mdx +5 -1
- package/.docs/raw/reference/voice/voice.send.mdx +4 -0
- package/.docs/raw/reference/voice/voice.speak.mdx +6 -0
- package/.docs/raw/reference/voice/voice.updateConfig.mdx +2 -0
- package/.docs/raw/reference/workflows/run-methods/cancel.mdx +55 -5
- package/.docs/raw/reference/workflows/run-methods/restart.mdx +3 -3
- package/.docs/raw/reference/workflows/run-methods/resume.mdx +6 -4
- package/.docs/raw/reference/workflows/run-methods/start.mdx +7 -5
- package/.docs/raw/reference/workflows/run-methods/startAsync.mdx +145 -0
- package/.docs/raw/reference/workflows/run-methods/timeTravel.mdx +10 -8
- package/.docs/raw/reference/workflows/run.mdx +11 -3
- package/.docs/raw/reference/workflows/step.mdx +56 -3
- package/.docs/raw/reference/workflows/workflow-methods/branch.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow-methods/commit.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow-methods/create-run.mdx +39 -2
- package/.docs/raw/reference/workflows/workflow-methods/dountil.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow-methods/dowhile.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow-methods/foreach.mdx +71 -4
- package/.docs/raw/reference/workflows/workflow-methods/map.mdx +9 -7
- package/.docs/raw/reference/workflows/workflow-methods/parallel.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow-methods/sleep.mdx +4 -6
- package/.docs/raw/reference/workflows/workflow-methods/sleepUntil.mdx +4 -6
- package/.docs/raw/reference/workflows/workflow-methods/then.mdx +3 -1
- package/.docs/raw/reference/workflows/workflow.mdx +193 -2
- package/.docs/raw/{auth → server/auth}/auth0.mdx +40 -21
- package/.docs/raw/{auth → server/auth}/clerk.mdx +37 -16
- package/.docs/raw/{auth → server/auth}/firebase.mdx +47 -25
- package/.docs/raw/{auth → server/auth}/index.mdx +8 -6
- package/.docs/raw/{auth → server/auth}/jwt.mdx +22 -10
- package/.docs/raw/{auth → server/auth}/supabase.mdx +45 -25
- package/.docs/raw/{auth → server/auth}/workos.mdx +39 -20
- package/.docs/raw/{server-db → server}/custom-adapters.mdx +40 -24
- package/.docs/raw/{server-db → server}/custom-api-routes.mdx +6 -6
- package/.docs/raw/{server-db → server}/mastra-client.mdx +35 -38
- package/.docs/raw/server/mastra-server.mdx +86 -0
- package/.docs/raw/{server-db → server}/middleware.mdx +11 -9
- package/.docs/raw/{server-db → server}/request-context.mdx +85 -43
- package/.docs/raw/{server-db → server}/server-adapters.mdx +154 -33
- package/.docs/raw/streaming/events.mdx +16 -7
- package/.docs/raw/streaming/overview.mdx +30 -17
- package/.docs/raw/streaming/tool-streaming.mdx +8 -6
- package/.docs/raw/streaming/workflow-streaming.mdx +8 -8
- package/.docs/raw/tools-mcp/advanced-usage.mdx +4 -2
- package/.docs/raw/tools-mcp/mcp-overview.mdx +46 -12
- package/.docs/raw/tools-mcp/overview.mdx +14 -13
- package/.docs/raw/voice/overview.mdx +17 -2
- package/.docs/raw/voice/speech-to-speech.mdx +5 -0
- package/.docs/raw/voice/speech-to-text.mdx +4 -0
- package/.docs/raw/voice/text-to-speech.mdx +3 -0
- package/.docs/raw/workflows/agents-and-tools.mdx +70 -21
- package/.docs/raw/workflows/control-flow.mdx +369 -34
- package/.docs/raw/workflows/error-handling.mdx +192 -18
- package/.docs/raw/workflows/human-in-the-loop.mdx +8 -7
- package/.docs/raw/workflows/input-data-mapping.mdx +9 -7
- package/.docs/raw/workflows/overview.mdx +80 -34
- package/.docs/raw/workflows/snapshots.mdx +19 -45
- package/.docs/raw/workflows/suspend-and-resume.mdx +14 -14
- package/.docs/raw/workflows/time-travel.mdx +25 -21
- package/.docs/raw/workflows/workflow-state.mdx +7 -8
- package/CHANGELOG.md +260 -0
- package/README.md +36 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/logger.d.ts +3 -0
- package/dist/logger.d.ts.map +1 -1
- package/dist/stdio.js +746 -49
- package/dist/tools/course.d.ts.map +1 -1
- package/dist/tools/embedded-docs.d.ts +276 -0
- package/dist/tools/embedded-docs.d.ts.map +1 -0
- package/package.json +9 -8
- package/.docs/organized/changelogs/%40internal%2Fai-sdk-v4.md +0 -1
- package/.docs/raw/deployment/building-mastra.mdx +0 -73
- package/.docs/raw/deployment/cloud-providers/index.mdx +0 -55
- package/.docs/raw/deployment/mastra-cloud/dashboard.mdx +0 -100
- package/.docs/raw/deployment/mastra-cloud/observability.mdx +0 -53
- package/.docs/raw/deployment/mastra-cloud/overview.mdx +0 -65
- package/.docs/raw/deployment/mastra-cloud/setting-up.mdx +0 -105
- package/.docs/raw/memory/conversation-history.mdx +0 -24
- package/.docs/raw/memory/storage/memory-with-libsql.mdx +0 -140
- package/.docs/raw/memory/storage/memory-with-mongodb.mdx +0 -150
- package/.docs/raw/memory/storage/memory-with-pg.mdx +0 -138
- package/.docs/raw/memory/storage/memory-with-upstash.mdx +0 -146
- package/.docs/raw/memory/threads-and-resources.mdx +0 -95
- package/.docs/raw/reference/core/setTelemetry.mdx +0 -36
- package/.docs/raw/reference/memory/listThreadsByResourceId.mdx +0 -110
- package/.docs/raw/reference/memory/query.mdx +0 -189
- package/.docs/raw/reference/workflows/workflow-methods/sendEvent.mdx +0 -70
- package/.docs/raw/reference/workflows/workflow-methods/waitForEvent.mdx +0 -66
- package/.docs/raw/server-db/mastra-server.mdx +0 -97
- package/.docs/raw/workflows/inngest-workflow.mdx +0 -363
|
@@ -1,224 +1,24 @@
|
|
|
1
1
|
# @mastra/server
|
|
2
2
|
|
|
3
|
-
## 1.0.
|
|
4
|
-
|
|
5
|
-
### Minor Changes
|
|
6
|
-
|
|
7
|
-
- Add stored agents support ([#10953](https://github.com/mastra-ai/mastra/pull/10953))
|
|
8
|
-
|
|
9
|
-
Agents can now be stored in the database and loaded at runtime. This lets you persist agent configurations and dynamically create executable Agent instances from storage.
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
import { Mastra } from '@mastra/core';
|
|
13
|
-
import { LibSQLStore } from '@mastra/libsql';
|
|
14
|
-
|
|
15
|
-
const mastra = new Mastra({
|
|
16
|
-
storage: new LibSQLStore({ url: ':memory:' }),
|
|
17
|
-
tools: { myTool },
|
|
18
|
-
scorers: { myScorer },
|
|
19
|
-
});
|
|
20
|
-
|
|
21
|
-
// Create agent in storage via API or directly
|
|
22
|
-
await mastra.getStorage().createAgent({
|
|
23
|
-
agent: {
|
|
24
|
-
id: 'my-agent',
|
|
25
|
-
name: 'My Agent',
|
|
26
|
-
instructions: 'You are helpful',
|
|
27
|
-
model: { provider: 'openai', name: 'gpt-4' },
|
|
28
|
-
tools: { myTool: {} },
|
|
29
|
-
scorers: { myScorer: { sampling: { type: 'ratio', rate: 0.5 } } },
|
|
30
|
-
},
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
// Load and use the agent
|
|
34
|
-
const agent = await mastra.getStoredAgentById('my-agent');
|
|
35
|
-
const response = await agent.generate({ messages: 'Hello!' });
|
|
36
|
-
|
|
37
|
-
// List all stored agents with pagination
|
|
38
|
-
const { agents, total, hasMore } = await mastra.listStoredAgents({
|
|
39
|
-
page: 0,
|
|
40
|
-
perPage: 10,
|
|
41
|
-
});
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
Also adds a memory registry to Mastra so stored agents can reference memory instances by key.
|
|
45
|
-
|
|
46
|
-
### Patch Changes
|
|
47
|
-
|
|
48
|
-
- Updated dependencies [[`72df8ae`](https://github.com/mastra-ai/mastra/commit/72df8ae595584cdd7747d5c39ffaca45e4507227), [`9198899`](https://github.com/mastra-ai/mastra/commit/91988995c427b185c33714b7f3be955367911324), [`653e65a`](https://github.com/mastra-ai/mastra/commit/653e65ae1f9502c2958a32f47a5a2df11e612a92), [`c6fd6fe`](https://github.com/mastra-ai/mastra/commit/c6fd6fedd09e9cf8004b03a80925f5e94826ad7e), [`0bed332`](https://github.com/mastra-ai/mastra/commit/0bed332843f627202c6520eaf671771313cd20f3)]:
|
|
49
|
-
- @mastra/core@1.0.0-beta.9
|
|
50
|
-
|
|
51
|
-
## 1.0.0-beta.8
|
|
52
|
-
|
|
53
|
-
### Patch Changes
|
|
54
|
-
|
|
55
|
-
- Updated dependencies [[`0d41fe2`](https://github.com/mastra-ai/mastra/commit/0d41fe245355dfc66d61a0d9c85d9400aac351ff), [`6b3ba91`](https://github.com/mastra-ai/mastra/commit/6b3ba91494cc10394df96782f349a4f7b1e152cc), [`7907fd1`](https://github.com/mastra-ai/mastra/commit/7907fd1c5059813b7b870b81ca71041dc807331b)]:
|
|
56
|
-
- @mastra/core@1.0.0-beta.8
|
|
57
|
-
|
|
58
|
-
## 1.0.0-beta.7
|
|
59
|
-
|
|
60
|
-
### Patch Changes
|
|
61
|
-
|
|
62
|
-
- fix: standardize pagination params to page/perPage with backwards compatibility for limit/offset ([#10790](https://github.com/mastra-ai/mastra/pull/10790))
|
|
63
|
-
- Server now accepts both `page`/`perPage` and legacy `limit`/`offset` params for workflow runs and MCP server listing endpoints
|
|
64
|
-
- Client SDK sends both param formats to support older server versions
|
|
65
|
-
- Added `createCombinedPaginationSchema` helper for endpoints needing backwards compatibility
|
|
66
|
-
- Marked `limit` and `offset` as deprecated in client types
|
|
67
|
-
|
|
68
|
-
- feat: Add partial response support for agent and workflow list endpoints ([#10886](https://github.com/mastra-ai/mastra/pull/10886))
|
|
69
|
-
|
|
70
|
-
Add optional `partial` query parameter to `/api/agents` and `/api/workflows` endpoints to return minimal data without schemas, reducing payload size for list views:
|
|
71
|
-
- When `partial=true`: tool schemas (inputSchema, outputSchema) are omitted
|
|
72
|
-
- When `partial=true`: workflow steps are replaced with stepCount integer
|
|
73
|
-
- When `partial=true`: workflow root schemas (inputSchema, outputSchema) are omitted
|
|
74
|
-
- Maintains backward compatibility when partial parameter is not provided
|
|
75
|
-
|
|
76
|
-
## Server Endpoint Usage
|
|
77
|
-
|
|
78
|
-
```http
|
|
79
|
-
# Get partial agent data (no tool schemas)
|
|
80
|
-
GET /api/agents?partial=true
|
|
81
|
-
|
|
82
|
-
# Get full agent data (default behavior)
|
|
83
|
-
GET /api/agents
|
|
84
|
-
|
|
85
|
-
# Get partial workflow data (stepCount instead of steps, no schemas)
|
|
86
|
-
GET /api/workflows?partial=true
|
|
87
|
-
|
|
88
|
-
# Get full workflow data (default behavior)
|
|
89
|
-
GET /api/workflows
|
|
90
|
-
```
|
|
91
|
-
|
|
92
|
-
## Client SDK Usage
|
|
93
|
-
|
|
94
|
-
```typescript
|
|
95
|
-
import { MastraClient } from '@mastra/client-js';
|
|
96
|
-
|
|
97
|
-
const client = new MastraClient({ baseUrl: 'http://localhost:4111' });
|
|
98
|
-
|
|
99
|
-
// Get partial agent list (smaller payload)
|
|
100
|
-
const partialAgents = await client.listAgents({ partial: true });
|
|
101
|
-
|
|
102
|
-
// Get full agent list with tool schemas
|
|
103
|
-
const fullAgents = await client.listAgents();
|
|
104
|
-
|
|
105
|
-
// Get partial workflow list (smaller payload)
|
|
106
|
-
const partialWorkflows = await client.listWorkflows({ partial: true });
|
|
107
|
-
|
|
108
|
-
// Get full workflow list with steps and schemas
|
|
109
|
-
const fullWorkflows = await client.listWorkflows();
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
- Updated dependencies [[`3076c67`](https://github.com/mastra-ai/mastra/commit/3076c6778b18988ae7d5c4c5c466366974b2d63f), [`85d7ee1`](https://github.com/mastra-ai/mastra/commit/85d7ee18ff4e14d625a8a30ec6656bb49804989b), [`c6c1092`](https://github.com/mastra-ai/mastra/commit/c6c1092f8fbf76109303f69e000e96fd1960c4ce), [`81dc110`](https://github.com/mastra-ai/mastra/commit/81dc11008d147cf5bdc8996ead1aa61dbdebb6fc), [`7aedb74`](https://github.com/mastra-ai/mastra/commit/7aedb74883adf66af38e270e4068fd42e7a37036), [`8f02d80`](https://github.com/mastra-ai/mastra/commit/8f02d800777397e4b45d7f1ad041988a8b0c6630), [`d7aad50`](https://github.com/mastra-ai/mastra/commit/d7aad501ce61646b76b4b511e558ac4eea9884d0), [`ce0a73a`](https://github.com/mastra-ai/mastra/commit/ce0a73abeaa75b10ca38f9e40a255a645d50ebfb), [`a02e542`](https://github.com/mastra-ai/mastra/commit/a02e542d23179bad250b044b17ff023caa61739f), [`a372c64`](https://github.com/mastra-ai/mastra/commit/a372c640ad1fd12e8f0613cebdc682fc156b4d95), [`8846867`](https://github.com/mastra-ai/mastra/commit/8846867ffa9a3746767618e314bebac08eb77d87), [`42a42cf`](https://github.com/mastra-ai/mastra/commit/42a42cf3132b9786feecbb8c13c583dce5b0e198), [`ae08bf0`](https://github.com/mastra-ai/mastra/commit/ae08bf0ebc6a4e4da992b711c4a389c32ba84cf4), [`21735a7`](https://github.com/mastra-ai/mastra/commit/21735a7ef306963554a69a89b44f06c3bcd85141), [`1d877b8`](https://github.com/mastra-ai/mastra/commit/1d877b8d7b536a251c1a7a18db7ddcf4f68d6f8b)]:
|
|
113
|
-
- @mastra/core@1.0.0-beta.7
|
|
114
|
-
|
|
115
|
-
## 1.0.0-beta.6
|
|
3
|
+
## 1.0.4
|
|
116
4
|
|
|
117
5
|
### Patch Changes
|
|
118
6
|
|
|
119
|
-
-
|
|
120
|
-
|
|
121
|
-
**Breaking Changes:**
|
|
122
|
-
- Renamed `HonoServerAdapter` to `MastraServer` in `@mastra/hono`
|
|
123
|
-
- Renamed `ExpressServerAdapter` to `MastraServer` in `@mastra/express`
|
|
124
|
-
- Configuration now passed to constructor instead of separate method calls
|
|
125
|
-
- Renamed base class from `ServerAdapter` to `MastraServerBase` in `@mastra/server`
|
|
126
|
-
|
|
127
|
-
**New Features:**
|
|
128
|
-
- Added MCP transport routes (HTTP and SSE) to server adapters
|
|
129
|
-
- MCP endpoints available at `/api/mcp/:serverId/mcp` (HTTP) and `/api/mcp/:serverId/sse` (SSE)
|
|
130
|
-
- Added `express.json()` middleware compatibility for MCP routes
|
|
131
|
-
- Moved authentication helpers from deployer to `@mastra/server/auth`
|
|
132
|
-
|
|
133
|
-
**Testing:**
|
|
134
|
-
- Added shared MCP route and transport test suites in `@internal/server-adapter-test-utils`
|
|
135
|
-
- Added comprehensive MCP endpoint tests for both Hono and Express adapters
|
|
136
|
-
- Added GitHub Actions workflow for server adapter CI testing
|
|
137
|
-
|
|
138
|
-
- Allow direct access to server app handle directly from Mastra instance. ([#10598](https://github.com/mastra-ai/mastra/pull/10598))
|
|
139
|
-
|
|
140
|
-
```ts
|
|
141
|
-
// Before: HTTP request to localhost
|
|
142
|
-
const response = await fetch(`http://localhost:5000/api/tools`);
|
|
143
|
-
|
|
144
|
-
// After: Direct call via app.fetch()
|
|
145
|
-
const app = mastra.getServerApp<Hono>();
|
|
146
|
-
const response = await app.fetch(new Request('http://internal/api/tools'));
|
|
147
|
-
```
|
|
148
|
-
|
|
149
|
-
- Added `mastra.getServerApp<T>()` to access the underlying Hono/Express app
|
|
150
|
-
- Added `mastra.getMastraServer()` and `mastra.setMastraServer()` for adapter access
|
|
151
|
-
- Added `MastraServerBase` class in `@mastra/core/server` for adapter implementations
|
|
152
|
-
- Server adapters now auto-register with Mastra in their constructor
|
|
153
|
-
|
|
154
|
-
- fix(a2a): fix streaming and memory support for A2A protocol ([#10653](https://github.com/mastra-ai/mastra/pull/10653))
|
|
155
|
-
|
|
156
|
-
**Client (`@mastra/client-js`):**
|
|
157
|
-
- Fixed `sendStreamingMessage` to properly return a streaming response instead of attempting to parse it as JSON
|
|
7
|
+
- Release stable ([#12102](https://github.com/mastra-ai/mastra/pull/12102))
|
|
158
8
|
|
|
159
|
-
|
|
160
|
-
-
|
|
161
|
-
- Added support for user-provided `resourceId` via `params.metadata.resourceId` or `message.metadata.resourceId`, falling back to `agentId`
|
|
9
|
+
- Updated dependencies:
|
|
10
|
+
- @mastra/core@1.0.4
|
|
162
11
|
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
The `stream` API endpoint now automatically redacts `request` data from stream chunks (`step-start`, `step-finish`, `finish`) which could contain system prompts, tool definitions, and API keys. Redaction is enabled by default and can be disabled for debugging/internal services via `streamOptions.redact`.
|
|
166
|
-
|
|
167
|
-
- Updated dependencies [[`ac0d2f4`](https://github.com/mastra-ai/mastra/commit/ac0d2f4ff8831f72c1c66c2be809706d17f65789), [`1a0d3fc`](https://github.com/mastra-ai/mastra/commit/1a0d3fc811482c9c376cdf79ee615c23bae9b2d6), [`85a628b`](https://github.com/mastra-ai/mastra/commit/85a628b1224a8f64cd82ea7f033774bf22df7a7e), [`c237233`](https://github.com/mastra-ai/mastra/commit/c23723399ccedf7f5744b3f40997b79246bfbe64), [`15f9e21`](https://github.com/mastra-ai/mastra/commit/15f9e216177201ea6e3f6d0bfb063fcc0953444f), [`ff94dea`](https://github.com/mastra-ai/mastra/commit/ff94dea935f4e34545c63bcb6c29804732698809), [`5b2ff46`](https://github.com/mastra-ai/mastra/commit/5b2ff4651df70c146523a7fca773f8eb0a2272f8), [`db41688`](https://github.com/mastra-ai/mastra/commit/db4168806d007417e2e60b4f68656dca4e5f40c9), [`5ca599d`](https://github.com/mastra-ai/mastra/commit/5ca599d0bb59a1595f19f58473fcd67cc71cef58), [`bff1145`](https://github.com/mastra-ai/mastra/commit/bff114556b3cbadad9b2768488708f8ad0e91475), [`5c8ca24`](https://github.com/mastra-ai/mastra/commit/5c8ca247094e0cc2cdbd7137822fb47241f86e77), [`e191844`](https://github.com/mastra-ai/mastra/commit/e1918444ca3f80e82feef1dad506cd4ec6e2875f), [`22553f1`](https://github.com/mastra-ai/mastra/commit/22553f11c63ee5e966a9c034a349822249584691), [`7237163`](https://github.com/mastra-ai/mastra/commit/72371635dbf96a87df4b073cc48fc655afbdce3d), [`2500740`](https://github.com/mastra-ai/mastra/commit/2500740ea23da067d6e50ec71c625ab3ce275e64), [`873ecbb`](https://github.com/mastra-ai/mastra/commit/873ecbb517586aa17d2f1e99283755b3ebb2863f), [`4f9bbe5`](https://github.com/mastra-ai/mastra/commit/4f9bbe5968f42c86f4930b8193de3c3c17e5bd36), [`02e51fe`](https://github.com/mastra-ai/mastra/commit/02e51feddb3d4155cfbcc42624fd0d0970d032c0), [`8f3fa3a`](https://github.com/mastra-ai/mastra/commit/8f3fa3a652bb77da092f913ec51ae46e3a7e27dc), [`cd29ad2`](https://github.com/mastra-ai/mastra/commit/cd29ad23a255534e8191f249593849ed29160886), [`bdf4d8c`](https://github.com/mastra-ai/mastra/commit/bdf4d8cdc656d8a2c21d81834bfa3bfa70f56c16), [`854e3da`](https://github.com/mastra-ai/mastra/commit/854e3dad5daac17a91a20986399d3a51f54bf68b), [`ce18d38`](https://github.com/mastra-ai/mastra/commit/ce18d38678c65870350d123955014a8432075fd9), [`cccf9c8`](https://github.com/mastra-ai/mastra/commit/cccf9c8b2d2dfc1a5e63919395b83d78c89682a0), [`61a5705`](https://github.com/mastra-ai/mastra/commit/61a570551278b6743e64243b3ce7d73de915ca8a), [`db70a48`](https://github.com/mastra-ai/mastra/commit/db70a48aeeeeb8e5f92007e8ede52c364ce15287), [`f0fdc14`](https://github.com/mastra-ai/mastra/commit/f0fdc14ee233d619266b3d2bbdeea7d25cfc6d13), [`db18bc9`](https://github.com/mastra-ai/mastra/commit/db18bc9c3825e2c1a0ad9a183cc9935f6691bfa1), [`9b37b56`](https://github.com/mastra-ai/mastra/commit/9b37b565e1f2a76c24f728945cc740c2b09be9da), [`41a23c3`](https://github.com/mastra-ai/mastra/commit/41a23c32f9877d71810f37e24930515df2ff7a0f), [`5d171ad`](https://github.com/mastra-ai/mastra/commit/5d171ad9ef340387276b77c2bb3e83e83332d729), [`f03ae60`](https://github.com/mastra-ai/mastra/commit/f03ae60500fe350c9d828621006cdafe1975fdd8), [`d1e74a0`](https://github.com/mastra-ai/mastra/commit/d1e74a0a293866dece31022047f5dbab65a304d0), [`39e7869`](https://github.com/mastra-ai/mastra/commit/39e7869bc7d0ee391077ce291474d8a84eedccff), [`5761926`](https://github.com/mastra-ai/mastra/commit/57619260c4a2cdd598763abbacd90de594c6bc76), [`c900fdd`](https://github.com/mastra-ai/mastra/commit/c900fdd504c41348efdffb205cfe80d48c38fa33), [`604a79f`](https://github.com/mastra-ai/mastra/commit/604a79fecf276e26a54a3fe01bb94e65315d2e0e), [`887f0b4`](https://github.com/mastra-ai/mastra/commit/887f0b4746cdbd7cb7d6b17ac9f82aeb58037ea5), [`2562143`](https://github.com/mastra-ai/mastra/commit/256214336b4faa78646c9c1776612393790d8784), [`ef11a61`](https://github.com/mastra-ai/mastra/commit/ef11a61920fa0ed08a5b7ceedd192875af119749)]:
|
|
168
|
-
- @mastra/core@1.0.0-beta.6
|
|
169
|
-
|
|
170
|
-
## 1.0.0-beta.5
|
|
171
|
-
|
|
172
|
-
### Patch Changes
|
|
173
|
-
|
|
174
|
-
- Extract routing from @deployer/server into server adapter packages. ([#10263](https://github.com/mastra-ai/mastra/pull/10263))
|
|
175
|
-
New packages:
|
|
176
|
-
- @mastra/express
|
|
177
|
-
- @mastra/hono
|
|
178
|
-
|
|
179
|
-
These packages support mastra server routes on express and hono respectively.
|
|
180
|
-
Better abstractions will be built on top of these packages in the near future, enabling users to easily attach mastra routes to any existing server framework.
|
|
181
|
-
|
|
182
|
-
- Add timeTravel APIs and add timeTravel feature to studio ([#10361](https://github.com/mastra-ai/mastra/pull/10361))
|
|
183
|
-
|
|
184
|
-
- Fixed server handler bugs: filter parsing now handles colons in values (timestamps, URLs), dateRange validation now converts JSON strings to Date objects, deleteMessages schema accepts object forms, and added missing responseSchema for legacy stream route ([#10362](https://github.com/mastra-ai/mastra/pull/10362))
|
|
185
|
-
|
|
186
|
-
- Updated dependencies [[`21a15de`](https://github.com/mastra-ai/mastra/commit/21a15de369fe82aac26bb642ed7be73505475e8b), [`feb7ee4`](https://github.com/mastra-ai/mastra/commit/feb7ee4d09a75edb46c6669a3beaceec78811747), [`b0e2ea5`](https://github.com/mastra-ai/mastra/commit/b0e2ea5b52c40fae438b9e2f7baee6f0f89c5442), [`c456e01`](https://github.com/mastra-ai/mastra/commit/c456e0149e3c176afcefdbd9bb1d2c5917723725), [`ab035c2`](https://github.com/mastra-ai/mastra/commit/ab035c2ef6d8cc7bb25f06f1a38508bd9e6f126b), [`1a46a56`](https://github.com/mastra-ai/mastra/commit/1a46a566f45a3fcbadc1cf36bf86d351f264bfa3), [`3cf540b`](https://github.com/mastra-ai/mastra/commit/3cf540b9fbfea8f4fc8d3a2319a4e6c0b0cbfd52), [`1c6ce51`](https://github.com/mastra-ai/mastra/commit/1c6ce51f875915ab57fd36873623013699a2a65d), [`898a972`](https://github.com/mastra-ai/mastra/commit/898a9727d286c2510d6b702dfd367e6aaf5c6b0f), [`a97003a`](https://github.com/mastra-ai/mastra/commit/a97003aa1cf2f4022a41912324a1e77263b326b8), [`ccc141e`](https://github.com/mastra-ai/mastra/commit/ccc141ed27da0abc3a3fc28e9e5128152e8e37f4), [`fe3b897`](https://github.com/mastra-ai/mastra/commit/fe3b897c2ccbcd2b10e81b099438c7337feddf89), [`00123ba`](https://github.com/mastra-ai/mastra/commit/00123ba96dc9e5cd0b110420ebdba56d8f237b25), [`29c4309`](https://github.com/mastra-ai/mastra/commit/29c4309f818b24304c041bcb4a8f19b5f13f6b62), [`16785ce`](https://github.com/mastra-ai/mastra/commit/16785ced928f6f22638f4488cf8a125d99211799), [`de8239b`](https://github.com/mastra-ai/mastra/commit/de8239bdcb1d8c0cfa06da21f1569912a66bbc8a), [`b5e6cd7`](https://github.com/mastra-ai/mastra/commit/b5e6cd77fc8c8e64e0494c1d06cee3d84e795d1e), [`3759cb0`](https://github.com/mastra-ai/mastra/commit/3759cb064935b5f74c65ac2f52a1145f7352899d), [`651e772`](https://github.com/mastra-ai/mastra/commit/651e772eb1475fb13e126d3fcc01751297a88214), [`b61b93f`](https://github.com/mastra-ai/mastra/commit/b61b93f9e058b11dd2eec169853175d31dbdd567), [`bae33d9`](https://github.com/mastra-ai/mastra/commit/bae33d91a63fbb64d1e80519e1fc1acaed1e9013), [`c0b731f`](https://github.com/mastra-ai/mastra/commit/c0b731fb27d712dc8582e846df5c0332a6a0c5ba), [`43ca8f2`](https://github.com/mastra-ai/mastra/commit/43ca8f2c7334851cc7b4d3d2f037d8784bfbdd5f), [`2ca67cc`](https://github.com/mastra-ai/mastra/commit/2ca67cc3bb1f6a617353fdcab197d9efebe60d6f), [`9e67002`](https://github.com/mastra-ai/mastra/commit/9e67002b52c9be19936c420a489dbee9c5fd6a78), [`35edc49`](https://github.com/mastra-ai/mastra/commit/35edc49ac0556db609189641d6341e76771b81fc)]:
|
|
187
|
-
- @mastra/core@1.0.0-beta.5
|
|
188
|
-
|
|
189
|
-
## 1.0.0-beta.4
|
|
190
|
-
|
|
191
|
-
### Patch Changes
|
|
192
|
-
|
|
193
|
-
- Network handler now accesses thread and resource parameters from the nested memory object instead of directly from request body. ([#10294](https://github.com/mastra-ai/mastra/pull/10294))
|
|
194
|
-
|
|
195
|
-
- Updated dependencies [[`352a5d6`](https://github.com/mastra-ai/mastra/commit/352a5d625cfe09849b21e8f52a24c9f0366759d5), [`a0a5b4b`](https://github.com/mastra-ai/mastra/commit/a0a5b4bbebe6c701ebbadf744873aa0d5ca01371), [`69ea758`](https://github.com/mastra-ai/mastra/commit/69ea758358edd7117f191c2e69c8bb5fc79e7a1a), [`993ad98`](https://github.com/mastra-ai/mastra/commit/993ad98d7ad3bebda9ecef5fec5c94349a0d04bc), [`3ff2c17`](https://github.com/mastra-ai/mastra/commit/3ff2c17a58e312fad5ea37377262c12d92ca0908)]:
|
|
196
|
-
- @mastra/core@1.0.0-beta.4
|
|
197
|
-
|
|
198
|
-
## 1.0.0-beta.3
|
|
12
|
+
## 1.0.4-alpha.0
|
|
199
13
|
|
|
200
14
|
### Patch Changes
|
|
201
15
|
|
|
202
|
-
-
|
|
203
|
-
|
|
204
|
-
- Updated dependencies [[`2319326`](https://github.com/mastra-ai/mastra/commit/2319326f8c64e503a09bbcf14be2dd65405445e0), [`d629361`](https://github.com/mastra-ai/mastra/commit/d629361a60f6565b5bfb11976fdaf7308af858e2), [`08c31c1`](https://github.com/mastra-ai/mastra/commit/08c31c188ebccd598acaf55e888b6397d01f7eae), [`fd3d338`](https://github.com/mastra-ai/mastra/commit/fd3d338a2c362174ed5b383f1f011ad9fb0302aa), [`c30400a`](https://github.com/mastra-ai/mastra/commit/c30400a49b994b1b97256fe785eb6c906fc2b232), [`69e0a87`](https://github.com/mastra-ai/mastra/commit/69e0a878896a2da9494945d86e056a5f8f05b851), [`01f8878`](https://github.com/mastra-ai/mastra/commit/01f88783de25e4de048c1c8aace43e26373c6ea5), [`4c77209`](https://github.com/mastra-ai/mastra/commit/4c77209e6c11678808b365d545845918c40045c8), [`d827d08`](https://github.com/mastra-ai/mastra/commit/d827d0808ffe1f3553a84e975806cc989b9735dd), [`23c10a1`](https://github.com/mastra-ai/mastra/commit/23c10a1efdd9a693c405511ab2dc8a1236603162), [`676ccc7`](https://github.com/mastra-ai/mastra/commit/676ccc7fe92468d2d45d39c31a87825c89fd1ea0), [`c10398d`](https://github.com/mastra-ai/mastra/commit/c10398d5b88f1d4af556f4267ff06f1d11e89179), [`00c2387`](https://github.com/mastra-ai/mastra/commit/00c2387f5f04a365316f851e58666ac43f8c4edf), [`ad6250d`](https://github.com/mastra-ai/mastra/commit/ad6250dbdaad927e29f74a27b83f6c468b50a705), [`3a73998`](https://github.com/mastra-ai/mastra/commit/3a73998fa4ebeb7f3dc9301afe78095fc63e7999), [`e16d553`](https://github.com/mastra-ai/mastra/commit/e16d55338403c7553531cc568125c63d53653dff), [`4d59f58`](https://github.com/mastra-ai/mastra/commit/4d59f58de2d90d6e2810a19d4518e38ddddb9038), [`e1bb9c9`](https://github.com/mastra-ai/mastra/commit/e1bb9c94b4eb68b019ae275981be3feb769b5365), [`351a11f`](https://github.com/mastra-ai/mastra/commit/351a11fcaf2ed1008977fa9b9a489fc422e51cd4)]:
|
|
205
|
-
- @mastra/core@1.0.0-beta.3
|
|
206
|
-
|
|
207
|
-
## 1.0.0-beta.2
|
|
208
|
-
|
|
209
|
-
### Patch Changes
|
|
16
|
+
- Release stable ([#12102](https://github.com/mastra-ai/mastra/pull/12102))
|
|
210
17
|
|
|
211
|
-
- Updated dependencies
|
|
212
|
-
- @mastra/core@1.0.
|
|
18
|
+
- Updated dependencies:
|
|
19
|
+
- @mastra/core@1.0.4-alpha.0
|
|
213
20
|
|
|
214
|
-
## 1.0.0
|
|
215
|
-
|
|
216
|
-
### Patch Changes
|
|
217
|
-
|
|
218
|
-
- Updated dependencies [[`910db9e`](https://github.com/mastra-ai/mastra/commit/910db9e0312888495eb5617b567f247d03303814), [`e7266a2`](https://github.com/mastra-ai/mastra/commit/e7266a278db02035c97a5e9cd9d1669a6b7a535d)]:
|
|
219
|
-
- @mastra/core@1.0.0-beta.1
|
|
220
|
-
|
|
221
|
-
## 1.0.0-beta.0
|
|
21
|
+
## 1.0.0
|
|
222
22
|
|
|
223
23
|
### Major Changes
|
|
224
24
|
|
|
@@ -230,7 +30,7 @@
|
|
|
230
30
|
|
|
231
31
|
- Update handlers to use `listWorkflowRuns` instead of `getWorkflowRuns`. Fix type names from `StoragelistThreadsByResourceIdInput/Output` to `StorageListThreadsByResourceIdInput/Output`. ([#9507](https://github.com/mastra-ai/mastra/pull/9507))
|
|
232
32
|
|
|
233
|
-
-
|
|
33
|
+
- Remove `getMessagesPaginated()` and add `perPage: false` support ([#9670](https://github.com/mastra-ai/mastra/pull/9670))
|
|
234
34
|
|
|
235
35
|
Removes deprecated `getMessagesPaginated()` method. The `listMessages()` API and score handlers now support `perPage: false` to fetch all records without pagination limits.
|
|
236
36
|
|
|
@@ -265,11 +65,7 @@
|
|
|
265
65
|
+ thread.listMessages({ page: 0, perPage: 20 })
|
|
266
66
|
```
|
|
267
67
|
|
|
268
|
-
-
|
|
269
|
-
|
|
270
|
-
## Storage Layer
|
|
271
|
-
|
|
272
|
-
### BREAKING: Removed `storage.getMessages()`
|
|
68
|
+
- **Removed `storage.getMessages()`** ([#9695](https://github.com/mastra-ai/mastra/pull/9695))
|
|
273
69
|
|
|
274
70
|
The `getMessages()` method has been removed from all storage implementations. Use `listMessages()` instead, which provides pagination support.
|
|
275
71
|
|
|
@@ -290,7 +86,7 @@
|
|
|
290
86
|
console.log(result.hasMore); // Whether more pages exist
|
|
291
87
|
```
|
|
292
88
|
|
|
293
|
-
|
|
89
|
+
**Message ordering default**
|
|
294
90
|
|
|
295
91
|
`listMessages()` defaults to ASC (oldest first) ordering by `createdAt`, matching the previous `getMessages()` behavior.
|
|
296
92
|
|
|
@@ -303,9 +99,7 @@
|
|
|
303
99
|
});
|
|
304
100
|
```
|
|
305
101
|
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
### BREAKING: Renamed `client.getThreadMessages()` → `client.listThreadMessages()`
|
|
102
|
+
**Renamed `client.getThreadMessages()` → `client.listThreadMessages()`**
|
|
309
103
|
|
|
310
104
|
**Migration:**
|
|
311
105
|
|
|
@@ -319,9 +113,7 @@
|
|
|
319
113
|
|
|
320
114
|
The response format remains the same.
|
|
321
115
|
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
### BREAKING: Removed `StorageGetMessagesArg` type
|
|
116
|
+
**Removed `StorageGetMessagesArg` type**
|
|
325
117
|
|
|
326
118
|
Use `StorageListMessagesInput` instead:
|
|
327
119
|
|
|
@@ -362,6 +154,40 @@
|
|
|
362
154
|
|
|
363
155
|
- Rename `defaultVNextStreamOptions` to `defaultOptions`. Add "Legacy" suffix to v1 option properties and methods (`defaultGenerateOptions` → `defaultGenerateOptionsLegacy`, `defaultStreamOptions` → `defaultStreamOptionsLegacy`). ([#9535](https://github.com/mastra-ai/mastra/pull/9535))
|
|
364
156
|
|
|
157
|
+
- **Breaking Change**: Convert OUTPUT generic from `OutputSchema` constraint to plain generic ([#11741](https://github.com/mastra-ai/mastra/pull/11741))
|
|
158
|
+
|
|
159
|
+
This change removes the direct dependency on Zod typings in the public API by converting all `OUTPUT extends OutputSchema` generic constraints to plain `OUTPUT` generics throughout the codebase. This is preparation for moving to a standard schema approach.
|
|
160
|
+
- All generic type parameters previously constrained to `OutputSchema` (e.g., `<OUTPUT extends OutputSchema = undefined>`) are now plain generics with defaults (e.g., `<OUTPUT = undefined>`)
|
|
161
|
+
- Affects all public APIs including `Agent`, `MastraModelOutput`, `AgentExecutionOptions`, and stream/generate methods
|
|
162
|
+
- `InferSchemaOutput<OUTPUT>` replaced with `OUTPUT` throughout
|
|
163
|
+
- `PartialSchemaOutput<OUTPUT>` replaced with `Partial<OUTPUT>`
|
|
164
|
+
- Schema fields now use `NonNullable<OutputSchema<OUTPUT>>` instead of `OUTPUT` directly
|
|
165
|
+
- Added `FullOutput<OUTPUT>` type representing complete output with all fields
|
|
166
|
+
- Added `AgentExecutionOptionsBase<OUTPUT>` type
|
|
167
|
+
- `getFullOutput()` method now returns `Promise<FullOutput<OUTPUT>>`
|
|
168
|
+
- `Agent` class now generic: `Agent<TAgentId, TTools, TOutput>`
|
|
169
|
+
- `agent.generate()` and `agent.stream()` methods have updated signatures
|
|
170
|
+
- `MastraModelOutput<OUTPUT>` no longer requires `OutputSchema` constraint
|
|
171
|
+
- Network route and streaming APIs updated to use plain OUTPUT generic
|
|
172
|
+
|
|
173
|
+
**Before:**
|
|
174
|
+
|
|
175
|
+
```typescript
|
|
176
|
+
const output = await agent.generate<z.ZodType>([...], {
|
|
177
|
+
structuredOutput: { schema: mySchema }
|
|
178
|
+
});
|
|
179
|
+
|
|
180
|
+
**After:**
|
|
181
|
+
const output = await agent.generate<z.infer<typeof mySchema>>([...], {
|
|
182
|
+
structuredOutput: { schema: mySchema }
|
|
183
|
+
});
|
|
184
|
+
// Or rely on type inference:
|
|
185
|
+
const output = await agent.generate([...], {
|
|
186
|
+
structuredOutput: { schema: mySchema }
|
|
187
|
+
});
|
|
188
|
+
|
|
189
|
+
```
|
|
190
|
+
|
|
365
191
|
- Remove `getThreadsByResourceId` and `getThreadsByResourceIdPaginated` methods from storage interfaces in favor of `listThreadsByResourceId`. The new method uses `offset`/`limit` pagination and a nested `orderBy` object structure (`{ field, direction }`). ([#9536](https://github.com/mastra-ai/mastra/pull/9536))
|
|
366
192
|
|
|
367
193
|
- Renamed a bunch of observability/tracing-related things to drop the AI prefix. ([#9744](https://github.com/mastra-ai/mastra/pull/9744))
|
|
@@ -370,14 +196,14 @@
|
|
|
370
196
|
|
|
371
197
|
This change simplifies the workflow watching API by removing the legacy v1 event system and promoting v2 as the standard (renamed to just `watch`).
|
|
372
198
|
|
|
373
|
-
|
|
199
|
+
**What's Changed**
|
|
374
200
|
- Removed legacy v1 watch event handlers and types
|
|
375
201
|
- Renamed `watch-v2` to `watch` throughout the codebase
|
|
376
202
|
- Removed `.watch()` method from client-js SDK (`Workflow` and `AgentBuilder` classes)
|
|
377
203
|
- Removed `/watch` HTTP endpoints from server and deployer
|
|
378
204
|
- Removed `WorkflowWatchResult` and v1 `WatchEvent` types
|
|
379
205
|
|
|
380
|
-
-
|
|
206
|
+
- Pagination APIs now use `page`/`perPage` instead of `offset`/`limit` ([#9592](https://github.com/mastra-ai/mastra/pull/9592))
|
|
381
207
|
|
|
382
208
|
All storage and memory pagination APIs have been updated to use `page` (0-indexed) and `perPage` instead of `offset` and `limit`, aligning with standard REST API patterns.
|
|
383
209
|
|
|
@@ -456,9 +282,96 @@
|
|
|
456
282
|
|
|
457
283
|
### Minor Changes
|
|
458
284
|
|
|
285
|
+
- Add stored agents support ([#10953](https://github.com/mastra-ai/mastra/pull/10953))
|
|
286
|
+
|
|
287
|
+
Agents can now be stored in the database and loaded at runtime. This lets you persist agent configurations and dynamically create executable Agent instances from storage.
|
|
288
|
+
|
|
289
|
+
```typescript
|
|
290
|
+
import { Mastra } from '@mastra/core';
|
|
291
|
+
import { LibSQLStore } from '@mastra/libsql';
|
|
292
|
+
|
|
293
|
+
const mastra = new Mastra({
|
|
294
|
+
storage: new LibSQLStore({ url: ':memory:' }),
|
|
295
|
+
tools: { myTool },
|
|
296
|
+
scorers: { myScorer },
|
|
297
|
+
});
|
|
298
|
+
|
|
299
|
+
// Create agent in storage via API or directly
|
|
300
|
+
await mastra.getStorage().createAgent({
|
|
301
|
+
agent: {
|
|
302
|
+
id: 'my-agent',
|
|
303
|
+
name: 'My Agent',
|
|
304
|
+
instructions: 'You are helpful',
|
|
305
|
+
model: { provider: 'openai', name: 'gpt-4' },
|
|
306
|
+
tools: { myTool: {} },
|
|
307
|
+
scorers: { myScorer: { sampling: { type: 'ratio', rate: 0.5 } } },
|
|
308
|
+
},
|
|
309
|
+
});
|
|
310
|
+
|
|
311
|
+
// Load and use the agent
|
|
312
|
+
const agent = await mastra.getStoredAgentById('my-agent');
|
|
313
|
+
const response = await agent.generate('Hello!');
|
|
314
|
+
|
|
315
|
+
// List all stored agents with pagination
|
|
316
|
+
const { agents, total, hasMore } = await mastra.listStoredAgents({
|
|
317
|
+
page: 0,
|
|
318
|
+
perPage: 10,
|
|
319
|
+
});
|
|
320
|
+
```
|
|
321
|
+
|
|
322
|
+
Also adds a memory registry to Mastra so stored agents can reference memory instances by key.
|
|
323
|
+
|
|
324
|
+
- Added human-in-the-loop (HITL) tool approval support for `generate()` method. ([#12056](https://github.com/mastra-ai/mastra/pull/12056))
|
|
325
|
+
|
|
326
|
+
**Why:** This provides parity between `stream()` and `generate()` for tool approval flows, allowing non-streaming use cases to leverage `requireToolApproval` without needing to switch to streaming.
|
|
327
|
+
|
|
328
|
+
Previously, tool approval with `requireToolApproval` only worked with `stream()`. Now you can use the same approval flow with `generate()` for non-streaming use cases.
|
|
329
|
+
|
|
330
|
+
**Using tool approval with generate()**
|
|
331
|
+
|
|
332
|
+
```typescript
|
|
333
|
+
const output = await agent.generate('Find user John', {
|
|
334
|
+
requireToolApproval: true,
|
|
335
|
+
});
|
|
336
|
+
|
|
337
|
+
// Check if a tool is waiting for approval
|
|
338
|
+
if (output.finishReason === 'suspended') {
|
|
339
|
+
console.log('Tool requires approval:', output.suspendPayload.toolName);
|
|
340
|
+
|
|
341
|
+
// Approve the tool call
|
|
342
|
+
const result = await agent.approveToolCallGenerate({
|
|
343
|
+
runId: output.runId,
|
|
344
|
+
toolCallId: output.suspendPayload.toolCallId,
|
|
345
|
+
});
|
|
346
|
+
|
|
347
|
+
console.log(result.text);
|
|
348
|
+
}
|
|
349
|
+
```
|
|
350
|
+
|
|
351
|
+
**Declining a tool call**
|
|
352
|
+
|
|
353
|
+
```typescript
|
|
354
|
+
if (output.finishReason === 'suspended') {
|
|
355
|
+
const result = await agent.declineToolCallGenerate({
|
|
356
|
+
runId: output.runId,
|
|
357
|
+
toolCallId: output.suspendPayload.toolCallId,
|
|
358
|
+
});
|
|
359
|
+
}
|
|
360
|
+
```
|
|
361
|
+
|
|
362
|
+
**New methods added:**
|
|
363
|
+
- `agent.approveToolCallGenerate({ runId, toolCallId })` - Approves a pending tool call and returns the complete result
|
|
364
|
+
- `agent.declineToolCallGenerate({ runId, toolCallId })` - Declines a pending tool call and returns the complete result
|
|
365
|
+
|
|
366
|
+
**Server routes added:**
|
|
367
|
+
- `POST /api/agents/:agentId/approve-tool-call-generate`
|
|
368
|
+
- `POST /api/agents/:agentId/decline-tool-call-generate`
|
|
369
|
+
|
|
370
|
+
The playground UI now also supports tool approval when using generate mode.
|
|
371
|
+
|
|
459
372
|
- Update peer dependencies to match core package version bump (1.0.0) ([#9237](https://github.com/mastra-ai/mastra/pull/9237))
|
|
460
373
|
|
|
461
|
-
-
|
|
374
|
+
- Memory scope defaults changed from 'thread' to 'resource' ([#8983](https://github.com/mastra-ai/mastra/pull/8983))
|
|
462
375
|
|
|
463
376
|
Both `workingMemory.scope` and `semanticRecall.scope` now default to `'resource'` instead of `'thread'`. This means:
|
|
464
377
|
- Working memory persists across all conversations for the same user/resource
|
|
@@ -479,8 +392,6 @@
|
|
|
479
392
|
}),
|
|
480
393
|
```
|
|
481
394
|
|
|
482
|
-
See the [migration guide](https://mastra.ai/docs/guides/migrations/memory-scope-defaults) for more details.
|
|
483
|
-
|
|
484
395
|
Also fixed issues where playground semantic recall search could show missing or incorrect results in certain cases.
|
|
485
396
|
|
|
486
397
|
- Update peer dependencies to match core package version bump (1.0.0) ([#9495](https://github.com/mastra-ai/mastra/pull/9495))
|
|
@@ -495,8 +406,97 @@
|
|
|
495
406
|
|
|
496
407
|
- Update peer dependencies to match core package version bump (0.22.0) ([#8983](https://github.com/mastra-ai/mastra/pull/8983))
|
|
497
408
|
|
|
498
|
-
-
|
|
409
|
+
- Unified observability schema with entity-based span identification ([#11132](https://github.com/mastra-ai/mastra/pull/11132))
|
|
499
410
|
|
|
500
|
-
|
|
411
|
+
## What changed
|
|
412
|
+
|
|
413
|
+
Spans now use a unified identification model with `entityId`, `entityType`, and `entityName` instead of separate `agentId`, `toolId`, `workflowId` fields.
|
|
414
|
+
|
|
415
|
+
**Before:**
|
|
416
|
+
|
|
417
|
+
```typescript
|
|
418
|
+
// Old span structure
|
|
419
|
+
span.agentId; // 'my-agent'
|
|
420
|
+
span.toolId; // undefined
|
|
421
|
+
span.workflowId; // undefined
|
|
422
|
+
```
|
|
423
|
+
|
|
424
|
+
**After:**
|
|
425
|
+
|
|
426
|
+
```typescript
|
|
427
|
+
// New span structure
|
|
428
|
+
span.entityType; // EntityType.AGENT
|
|
429
|
+
span.entityId; // 'my-agent'
|
|
430
|
+
span.entityName; // 'My Agent'
|
|
431
|
+
```
|
|
432
|
+
|
|
433
|
+
## New `listTraces()` API
|
|
434
|
+
|
|
435
|
+
Query traces with filtering, pagination, and sorting:
|
|
436
|
+
|
|
437
|
+
```typescript
|
|
438
|
+
const { spans, pagination } = await storage.listTraces({
|
|
439
|
+
filters: {
|
|
440
|
+
entityType: EntityType.AGENT,
|
|
441
|
+
entityId: 'my-agent',
|
|
442
|
+
userId: 'user-123',
|
|
443
|
+
environment: 'production',
|
|
444
|
+
status: TraceStatus.SUCCESS,
|
|
445
|
+
startedAt: { start: new Date('2024-01-01'), end: new Date('2024-01-31') },
|
|
446
|
+
},
|
|
447
|
+
pagination: { page: 0, perPage: 50 },
|
|
448
|
+
orderBy: { field: 'startedAt', direction: 'DESC' },
|
|
449
|
+
});
|
|
450
|
+
```
|
|
451
|
+
|
|
452
|
+
**Available filters:** date ranges (`startedAt`, `endedAt`), entity (`entityType`, `entityId`, `entityName`), identity (`userId`, `organizationId`), correlation IDs (`runId`, `sessionId`, `threadId`), deployment (`environment`, `source`, `serviceName`), `tags`, `metadata`, and `status`.
|
|
453
|
+
|
|
454
|
+
## New retrieval methods
|
|
455
|
+
- `getSpan({ traceId, spanId })` - Get a single span
|
|
456
|
+
- `getRootSpan({ traceId })` - Get the root span of a trace
|
|
457
|
+
- `getTrace({ traceId })` - Get all spans for a trace
|
|
458
|
+
|
|
459
|
+
## Backward compatibility
|
|
460
|
+
|
|
461
|
+
The legacy `getTraces()` method continues to work. When you pass `name: "agent run: my-agent"`, it automatically transforms to `entityId: "my-agent", entityType: AGENT`.
|
|
462
|
+
|
|
463
|
+
## Migration
|
|
464
|
+
|
|
465
|
+
**Automatic:** SQL-based stores (PostgreSQL, LibSQL, MSSQL) automatically add new columns to existing `spans` tables on initialization. Existing data is preserved with new columns set to `NULL`.
|
|
466
|
+
|
|
467
|
+
**No action required:** Your existing code continues to work. Adopt the new fields and `listTraces()` API at your convenience.
|
|
468
|
+
|
|
469
|
+
- Added new `listThreads` method for flexible thread filtering across all storage adapters. ([#11832](https://github.com/mastra-ai/mastra/pull/11832))
|
|
470
|
+
|
|
471
|
+
**New Features**
|
|
472
|
+
- Filter threads by `resourceId`, `metadata`, or both (with AND logic for metadata key-value pairs)
|
|
473
|
+
- All filter parameters are optional, allowing you to list all threads or filter as needed
|
|
474
|
+
- Full pagination and sorting support
|
|
475
|
+
|
|
476
|
+
**Example Usage**
|
|
477
|
+
|
|
478
|
+
```typescript
|
|
479
|
+
// List all threads
|
|
480
|
+
const allThreads = await memory.listThreads({});
|
|
481
|
+
|
|
482
|
+
// Filter by resourceId only
|
|
483
|
+
const userThreads = await memory.listThreads({
|
|
484
|
+
filter: { resourceId: 'user-123' },
|
|
485
|
+
});
|
|
486
|
+
|
|
487
|
+
// Filter by metadata only
|
|
488
|
+
const supportThreads = await memory.listThreads({
|
|
489
|
+
filter: { metadata: { category: 'support' } },
|
|
490
|
+
});
|
|
491
|
+
|
|
492
|
+
// Filter by both with pagination
|
|
493
|
+
const filteredThreads = await memory.listThreads({
|
|
494
|
+
filter: {
|
|
495
|
+
resourceId: 'user-123',
|
|
496
|
+
metadata: { priority: 'high', status: 'open' },
|
|
497
|
+
},
|
|
498
|
+
orderBy: { field: 'updatedAt', direction: 'DESC' },
|
|
499
|
+
page: 0,
|
|
500
|
+
perPage: 20,
|
|
501
501
|
|
|
502
|
-
...
|
|
502
|
+
... 6097 more lines hidden. See full changelog in package directory.
|