@mastra/mcp-docs-server 1.0.0-beta.0 → 1.0.0-beta.2
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/%40mastra%2Fai-sdk.md +10 -10
- package/.docs/organized/changelogs/%40mastra%2Fclient-js.md +17 -17
- package/.docs/organized/changelogs/%40mastra%2Fcodemod.md +8 -0
- package/.docs/organized/changelogs/%40mastra%2Fcore.md +18 -18
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloud.md +19 -19
- package/.docs/organized/changelogs/%40mastra%2Fdeployer.md +19 -19
- package/.docs/organized/changelogs/%40mastra%2Fmcp-docs-server.md +18 -18
- package/.docs/organized/changelogs/%40mastra%2Fmcp.md +12 -12
- package/.docs/organized/changelogs/%40mastra%2Fmssql.md +16 -16
- package/.docs/organized/changelogs/%40mastra%2Fplayground-ui.md +32 -32
- package/.docs/organized/changelogs/%40mastra%2Freact.md +15 -15
- package/.docs/organized/changelogs/%40mastra%2Fserver.md +15 -15
- package/.docs/organized/changelogs/create-mastra.md +7 -7
- package/.docs/organized/changelogs/mastra.md +13 -13
- package/.docs/raw/agents/agent-memory.mdx +1 -1
- package/.docs/raw/agents/overview.mdx +2 -2
- package/.docs/raw/auth/auth0.mdx +1 -1
- package/.docs/raw/auth/clerk.mdx +1 -1
- package/.docs/raw/auth/firebase.mdx +1 -1
- package/.docs/raw/auth/jwt.mdx +1 -1
- package/.docs/raw/auth/supabase.mdx +1 -1
- package/.docs/raw/auth/workos.mdx +1 -1
- package/.docs/raw/course/01-first-agent/03-verifying-installation.md +1 -1
- package/.docs/raw/course/02-agent-tools-mcp/02-installing-mcp.md +1 -1
- package/.docs/raw/course/03-agent-memory/03-installing-memory.md +1 -1
- package/.docs/raw/deployment/cloud-providers/amazon-ec2.mdx +1 -1
- package/.docs/raw/deployment/cloud-providers/aws-lambda.mdx +1 -1
- package/.docs/raw/deployment/cloud-providers/azure-app-services.mdx +2 -2
- package/.docs/raw/deployment/cloud-providers/digital-ocean.mdx +1 -1
- package/.docs/raw/deployment/serverless-platforms/cloudflare-deployer.mdx +1 -1
- package/.docs/raw/deployment/serverless-platforms/netlify-deployer.mdx +1 -1
- package/.docs/raw/deployment/serverless-platforms/vercel-deployer.mdx +1 -1
- package/.docs/raw/evals/overview.mdx +1 -1
- package/.docs/raw/frameworks/agentic-uis/ai-sdk.mdx +8 -4
- package/.docs/raw/frameworks/agentic-uis/assistant-ui.mdx +1 -1
- package/.docs/raw/frameworks/agentic-uis/copilotkit.mdx +9 -9
- package/.docs/raw/frameworks/agentic-uis/openrouter.mdx +1 -1
- package/.docs/raw/frameworks/servers/express.mdx +1 -1
- package/.docs/raw/frameworks/web-frameworks/astro.mdx +12 -12
- package/.docs/raw/frameworks/web-frameworks/next-js.mdx +4 -4
- package/.docs/raw/frameworks/web-frameworks/sveltekit.mdx +12 -12
- package/.docs/raw/frameworks/web-frameworks/vite-react.mdx +5 -5
- package/.docs/raw/getting-started/installation.mdx +13 -13
- package/.docs/raw/getting-started/templates.mdx +5 -5
- package/.docs/raw/guides/guide/notes-mcp-server.mdx +1 -1
- package/.docs/raw/guides/guide/research-assistant.mdx +1 -10
- package/.docs/raw/guides/migrations/upgrade-to-v1/agent.mdx +16 -6
- package/.docs/raw/guides/migrations/upgrade-to-v1/client.mdx +42 -2
- package/.docs/raw/guides/migrations/upgrade-to-v1/evals.mdx +31 -1
- package/.docs/raw/guides/migrations/upgrade-to-v1/mastra.mdx +28 -4
- package/.docs/raw/guides/migrations/upgrade-to-v1/mcp.mdx +3 -3
- package/.docs/raw/guides/migrations/upgrade-to-v1/memory.mdx +28 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/overview.mdx +50 -36
- package/.docs/raw/guides/migrations/upgrade-to-v1/storage.mdx +80 -0
- package/.docs/raw/guides/migrations/upgrade-to-v1/tools.mdx +2 -2
- package/.docs/raw/guides/migrations/upgrade-to-v1/tracing.mdx +13 -13
- package/.docs/raw/guides/migrations/upgrade-to-v1/vectors.mdx +25 -1
- package/.docs/raw/guides/migrations/upgrade-to-v1/voice.mdx +1 -1
- package/.docs/raw/guides/migrations/upgrade-to-v1/workflows.mdx +32 -2
- package/.docs/raw/guides/quickstarts/nextjs.mdx +275 -0
- package/.docs/raw/index.mdx +1 -1
- package/.docs/raw/logging.mdx +3 -3
- package/.docs/raw/mastra-cloud/observability.mdx +6 -6
- package/.docs/raw/memory/overview.mdx +2 -2
- package/.docs/raw/memory/semantic-recall.mdx +2 -2
- package/.docs/raw/memory/storage/memory-with-libsql.mdx +2 -2
- package/.docs/raw/memory/storage/memory-with-mongodb.mdx +152 -0
- package/.docs/raw/memory/storage/memory-with-pg.mdx +2 -2
- package/.docs/raw/memory/storage/memory-with-upstash.mdx +2 -2
- package/.docs/raw/observability/overview.mdx +5 -5
- package/.docs/raw/observability/tracing/exporters/arize.mdx +2 -2
- package/.docs/raw/observability/tracing/exporters/braintrust.mdx +2 -2
- package/.docs/raw/observability/tracing/exporters/cloud.mdx +2 -2
- package/.docs/raw/observability/tracing/exporters/default.mdx +5 -5
- package/.docs/raw/observability/tracing/exporters/langfuse.mdx +2 -2
- package/.docs/raw/observability/tracing/exporters/langsmith.mdx +2 -2
- package/.docs/raw/observability/tracing/exporters/otel.mdx +5 -5
- package/.docs/raw/observability/tracing/overview.mdx +21 -21
- package/.docs/raw/observability/tracing/processors/sensitive-data-filter.mdx +2 -2
- package/.docs/raw/rag/overview.mdx +1 -1
- package/.docs/raw/reference/agents/agent.mdx +2 -2
- package/.docs/raw/reference/cli/create-mastra.mdx +10 -10
- package/.docs/raw/reference/cli/mastra.mdx +7 -7
- package/.docs/raw/reference/core/getLogger.mdx +2 -2
- package/.docs/raw/reference/core/getMCPServer.mdx +2 -2
- package/.docs/raw/reference/core/getMCPServerById.mdx +4 -4
- package/.docs/raw/reference/core/getTelemetry.mdx +2 -2
- package/.docs/raw/reference/core/listLogs.mdx +2 -2
- package/.docs/raw/reference/core/listLogsByRunId.mdx +2 -2
- package/.docs/raw/reference/core/listMCPServers.mdx +4 -4
- package/.docs/raw/reference/core/setLogger.mdx +2 -2
- package/.docs/raw/reference/core/setTelemetry.mdx +2 -2
- package/.docs/raw/reference/evals/create-scorer.mdx +58 -49
- package/.docs/raw/reference/evals/mastra-scorer.mdx +2 -0
- package/.docs/raw/reference/observability/tracing/configuration.mdx +12 -12
- package/.docs/raw/reference/observability/tracing/exporters/arize.mdx +1 -1
- package/.docs/raw/reference/observability/tracing/exporters/cloud-exporter.mdx +8 -8
- package/.docs/raw/reference/observability/tracing/exporters/console-exporter.mdx +8 -8
- package/.docs/raw/reference/observability/tracing/exporters/default-exporter.mdx +8 -8
- package/.docs/raw/reference/observability/tracing/instances.mdx +8 -8
- package/.docs/raw/reference/observability/tracing/interfaces.mdx +7 -7
- package/.docs/raw/reference/observability/tracing/spans.mdx +7 -7
- package/.docs/raw/reference/processors/batch-parts-processor.mdx +8 -2
- package/.docs/raw/reference/processors/language-detector.mdx +8 -2
- package/.docs/raw/reference/processors/moderation-processor.mdx +8 -2
- package/.docs/raw/reference/processors/pii-detector.mdx +8 -2
- package/.docs/raw/reference/processors/prompt-injection-detector.mdx +8 -2
- package/.docs/raw/reference/processors/system-prompt-scrubber.mdx +8 -2
- package/.docs/raw/reference/processors/token-limiter-processor.mdx +8 -2
- package/.docs/raw/reference/processors/unicode-normalizer.mdx +8 -2
- package/.docs/raw/reference/storage/cloudflare-d1.mdx +1 -1
- package/.docs/raw/reference/storage/cloudflare.mdx +1 -1
- package/.docs/raw/reference/storage/dynamodb.mdx +3 -3
- package/.docs/raw/reference/storage/lance.mdx +1 -1
- package/.docs/raw/reference/storage/libsql.mdx +1 -1
- package/.docs/raw/reference/storage/mongodb.mdx +1 -1
- package/.docs/raw/reference/storage/mssql.mdx +1 -1
- package/.docs/raw/reference/storage/postgresql.mdx +1 -1
- package/.docs/raw/reference/storage/upstash.mdx +1 -1
- package/.docs/raw/reference/templates/overview.mdx +1 -1
- package/.docs/raw/reference/tools/mcp-server.mdx +49 -0
- package/.docs/raw/reference/vectors/couchbase.mdx +8 -2
- package/.docs/raw/reference/vectors/libsql.mdx +1 -1
- package/.docs/raw/reference/vectors/mongodb.mdx +7 -1
- package/.docs/raw/reference/vectors/s3vectors.mdx +1 -1
- package/.docs/raw/server-db/mastra-client.mdx +4 -4
- package/.docs/raw/tools-mcp/mcp-overview.mdx +1 -1
- package/.docs/raw/voice/speech-to-text.mdx +1 -1
- package/.docs/raw/voice/text-to-speech.mdx +1 -1
- package/.docs/raw/workflows/inngest-workflow.mdx +1 -1
- package/CHANGELOG.md +17 -0
- package/dist/stdio.js +11 -15
- package/package.json +4 -4
|
@@ -65,11 +65,17 @@ const processor = new BatchPartsProcessor({
|
|
|
65
65
|
<PropertiesTable
|
|
66
66
|
content={[
|
|
67
67
|
{
|
|
68
|
-
name: "
|
|
68
|
+
name: "id",
|
|
69
69
|
type: "string",
|
|
70
|
-
description: "Processor
|
|
70
|
+
description: "Processor identifier set to 'batch-parts'",
|
|
71
71
|
isOptional: false,
|
|
72
72
|
},
|
|
73
|
+
{
|
|
74
|
+
name: "name",
|
|
75
|
+
type: "string",
|
|
76
|
+
description: "Optional processor display name",
|
|
77
|
+
isOptional: true,
|
|
78
|
+
},
|
|
73
79
|
{
|
|
74
80
|
name: "processOutputStream",
|
|
75
81
|
type: "(args: { part: ChunkType; streamParts: ChunkType[]; state: Record<string, any>; abort: (reason?: string) => never }) => Promise<ChunkType | null>",
|
|
@@ -107,11 +107,17 @@ const processor = new LanguageDetector({
|
|
|
107
107
|
<PropertiesTable
|
|
108
108
|
content={[
|
|
109
109
|
{
|
|
110
|
-
name: "
|
|
110
|
+
name: "id",
|
|
111
111
|
type: "string",
|
|
112
|
-
description: "Processor
|
|
112
|
+
description: "Processor identifier set to 'language-detector'",
|
|
113
113
|
isOptional: false,
|
|
114
114
|
},
|
|
115
|
+
{
|
|
116
|
+
name: "name",
|
|
117
|
+
type: "string",
|
|
118
|
+
description: "Optional processor display name",
|
|
119
|
+
isOptional: true,
|
|
120
|
+
},
|
|
115
121
|
{
|
|
116
122
|
name: "processInput",
|
|
117
123
|
type: "(args: { messages: MastraMessageV2[]; abort: (reason?: string) => never; tracingContext?: TracingContext }) => Promise<MastraMessageV2[]>",
|
|
@@ -93,11 +93,17 @@ const processor = new ModerationProcessor({
|
|
|
93
93
|
<PropertiesTable
|
|
94
94
|
content={[
|
|
95
95
|
{
|
|
96
|
-
name: "
|
|
96
|
+
name: "id",
|
|
97
97
|
type: "string",
|
|
98
|
-
description: "Processor
|
|
98
|
+
description: "Processor identifier set to 'moderation'",
|
|
99
99
|
isOptional: false,
|
|
100
100
|
},
|
|
101
|
+
{
|
|
102
|
+
name: "name",
|
|
103
|
+
type: "string",
|
|
104
|
+
description: "Optional processor display name",
|
|
105
|
+
isOptional: true,
|
|
106
|
+
},
|
|
101
107
|
{
|
|
102
108
|
name: "processInput",
|
|
103
109
|
type: "(args: { messages: MastraMessageV2[]; abort: (reason?: string) => never; tracingContext?: TracingContext }) => Promise<MastraMessageV2[]>",
|
|
@@ -100,11 +100,17 @@ const processor = new PIIDetector({
|
|
|
100
100
|
<PropertiesTable
|
|
101
101
|
content={[
|
|
102
102
|
{
|
|
103
|
-
name: "
|
|
103
|
+
name: "id",
|
|
104
104
|
type: "string",
|
|
105
|
-
description: "Processor
|
|
105
|
+
description: "Processor identifier set to 'pii-detector'",
|
|
106
106
|
isOptional: false,
|
|
107
107
|
},
|
|
108
|
+
{
|
|
109
|
+
name: "name",
|
|
110
|
+
type: "string",
|
|
111
|
+
description: "Optional processor display name",
|
|
112
|
+
isOptional: true,
|
|
113
|
+
},
|
|
108
114
|
{
|
|
109
115
|
name: "processInput",
|
|
110
116
|
type: "(args: { messages: MastraMessageV2[]; abort: (reason?: string) => never; tracingContext?: TracingContext }) => Promise<MastraMessageV2[]>",
|
|
@@ -86,11 +86,17 @@ const processor = new PromptInjectionDetector({
|
|
|
86
86
|
<PropertiesTable
|
|
87
87
|
content={[
|
|
88
88
|
{
|
|
89
|
-
name: "
|
|
89
|
+
name: "id",
|
|
90
90
|
type: "string",
|
|
91
|
-
description: "Processor
|
|
91
|
+
description: "Processor identifier set to 'prompt-injection-detector'",
|
|
92
92
|
isOptional: false,
|
|
93
93
|
},
|
|
94
|
+
{
|
|
95
|
+
name: "name",
|
|
96
|
+
type: "string",
|
|
97
|
+
description: "Optional processor display name",
|
|
98
|
+
isOptional: true,
|
|
99
|
+
},
|
|
94
100
|
{
|
|
95
101
|
name: "processInput",
|
|
96
102
|
type: "(args: { messages: MastraMessageV2[]; abort: (reason?: string) => never; tracingContext?: TracingContext }) => Promise<MastraMessageV2[]>",
|
|
@@ -94,11 +94,17 @@ const processor = new SystemPromptScrubber({
|
|
|
94
94
|
<PropertiesTable
|
|
95
95
|
content={[
|
|
96
96
|
{
|
|
97
|
-
name: "
|
|
97
|
+
name: "id",
|
|
98
98
|
type: "string",
|
|
99
|
-
description: "Processor
|
|
99
|
+
description: "Processor identifier set to 'system-prompt-scrubber'",
|
|
100
100
|
isOptional: false,
|
|
101
101
|
},
|
|
102
|
+
{
|
|
103
|
+
name: "name",
|
|
104
|
+
type: "string",
|
|
105
|
+
description: "Optional processor display name",
|
|
106
|
+
isOptional: true,
|
|
107
|
+
},
|
|
102
108
|
{
|
|
103
109
|
name: "processOutputStream",
|
|
104
110
|
type: "(args: { part: ChunkType; streamParts: ChunkType[]; state: Record<string, any>; abort: (reason?: string) => never; tracingContext?: TracingContext }) => Promise<ChunkType | null>",
|
|
@@ -71,11 +71,17 @@ const processor = new TokenLimiterProcessor({
|
|
|
71
71
|
<PropertiesTable
|
|
72
72
|
content={[
|
|
73
73
|
{
|
|
74
|
-
name: "
|
|
74
|
+
name: "id",
|
|
75
75
|
type: "string",
|
|
76
|
-
description: "Processor
|
|
76
|
+
description: "Processor identifier set to 'token-limiter'",
|
|
77
77
|
isOptional: false,
|
|
78
78
|
},
|
|
79
|
+
{
|
|
80
|
+
name: "name",
|
|
81
|
+
type: "string",
|
|
82
|
+
description: "Optional processor display name",
|
|
83
|
+
isOptional: true,
|
|
84
|
+
},
|
|
79
85
|
{
|
|
80
86
|
name: "processOutputStream",
|
|
81
87
|
type: "(args: { part: ChunkType; streamParts: ChunkType[]; state: Record<string, any>; abort: (reason?: string) => never }) => Promise<ChunkType | null>",
|
|
@@ -71,11 +71,17 @@ const processor = new UnicodeNormalizer({
|
|
|
71
71
|
<PropertiesTable
|
|
72
72
|
content={[
|
|
73
73
|
{
|
|
74
|
-
name: "
|
|
74
|
+
name: "id",
|
|
75
75
|
type: "string",
|
|
76
|
-
description: "Processor
|
|
76
|
+
description: "Processor identifier set to 'unicode-normalizer'",
|
|
77
77
|
isOptional: false,
|
|
78
78
|
},
|
|
79
|
+
{
|
|
80
|
+
name: "name",
|
|
81
|
+
type: "string",
|
|
82
|
+
description: "Optional processor display name",
|
|
83
|
+
isOptional: true,
|
|
84
|
+
},
|
|
79
85
|
{
|
|
80
86
|
name: "processInput",
|
|
81
87
|
type: "(args: { messages: MastraMessageV2[]; abort: (reason?: string) => never }) => MastraMessageV2[]",
|
|
@@ -19,11 +19,11 @@ The DynamoDB storage implementation provides a scalable and performant NoSQL dat
|
|
|
19
19
|
## Installation
|
|
20
20
|
|
|
21
21
|
```bash copy
|
|
22
|
-
npm install @mastra/dynamodb@
|
|
22
|
+
npm install @mastra/dynamodb@beta
|
|
23
23
|
# or
|
|
24
|
-
pnpm add @mastra/dynamodb@
|
|
24
|
+
pnpm add @mastra/dynamodb@beta
|
|
25
25
|
# or
|
|
26
|
-
yarn add @mastra/dynamodb@
|
|
26
|
+
yarn add @mastra/dynamodb@beta
|
|
27
27
|
```
|
|
28
28
|
|
|
29
29
|
## Prerequisites
|
|
@@ -21,7 +21,7 @@ Mastra templates are pre-built project structures that demonstrate specific use
|
|
|
21
21
|
Install a template using the `create-mastra` command:
|
|
22
22
|
|
|
23
23
|
```bash copy
|
|
24
|
-
npx create-mastra@
|
|
24
|
+
npx create-mastra@beta --template template-name
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
This creates a complete project with all necessary code and configuration.
|
|
@@ -186,6 +186,55 @@ The description for this generated tool will be: "Ask agent `<agent.name>` a que
|
|
|
186
186
|
|
|
187
187
|
This allows you to quickly expose the generative capabilities of your agents through the MCP, enabling clients to "ask" your agents questions directly.
|
|
188
188
|
|
|
189
|
+
### Accessing MCP Context in Tools
|
|
190
|
+
|
|
191
|
+
Tools exposed through `MCPServer` can access MCP request context (authentication, session IDs, etc.) via two different properties depending on how the tool is invoked:
|
|
192
|
+
|
|
193
|
+
| Call Pattern | Access Method |
|
|
194
|
+
|-------------|---------------|
|
|
195
|
+
| Direct tool call | `context?.mcp?.extra` |
|
|
196
|
+
| Agent tool call | `context?.requestContext?.get("mcp.extra")` |
|
|
197
|
+
|
|
198
|
+
**Universal pattern** (works in both contexts):
|
|
199
|
+
```typescript
|
|
200
|
+
const mcpExtra = context?.mcp?.extra ?? context?.requestContext?.get("mcp.extra");
|
|
201
|
+
const authInfo = mcpExtra?.authInfo;
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
#### Example: Tool that works in both contexts
|
|
205
|
+
|
|
206
|
+
```typescript
|
|
207
|
+
import { createTool } from "@mastra/core/tools";
|
|
208
|
+
import { z } from "zod";
|
|
209
|
+
|
|
210
|
+
const fetchUserData = createTool({
|
|
211
|
+
id: "fetchUserData",
|
|
212
|
+
description: "Fetches user data using authentication from MCP context",
|
|
213
|
+
inputSchema: z.object({
|
|
214
|
+
userId: z.string().describe("The ID of the user to fetch"),
|
|
215
|
+
}),
|
|
216
|
+
execute: async (inputData, context) => {
|
|
217
|
+
// Access MCP authentication context
|
|
218
|
+
// When called directly via MCP: context.mcp.extra
|
|
219
|
+
// When called via agent: context.requestContext.get('mcp.extra')
|
|
220
|
+
const mcpExtra = context?.mcp?.extra || context?.requestContext?.get("mcp.extra");
|
|
221
|
+
const authInfo = mcpExtra?.authInfo;
|
|
222
|
+
|
|
223
|
+
if (!authInfo?.token) {
|
|
224
|
+
throw new Error("Authentication required");
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
const response = await fetch(`https://api.example.com/users/${inputData.userId}`, {
|
|
228
|
+
headers: {
|
|
229
|
+
Authorization: `Bearer ${authInfo.token}`,
|
|
230
|
+
},
|
|
231
|
+
});
|
|
232
|
+
|
|
233
|
+
return response.json();
|
|
234
|
+
},
|
|
235
|
+
});
|
|
236
|
+
```
|
|
237
|
+
|
|
189
238
|
## Methods
|
|
190
239
|
|
|
191
240
|
These are the functions you can call on an `MCPServer` instance to control its behavior and get information.
|
|
@@ -15,15 +15,16 @@ The `CouchbaseVector` class provides vector search using [Couchbase Vector Searc
|
|
|
15
15
|
## Installation
|
|
16
16
|
|
|
17
17
|
```bash copy
|
|
18
|
-
npm install @mastra/couchbase
|
|
18
|
+
npm install @mastra/couchbase@beta
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
## Usage Example
|
|
22
22
|
|
|
23
|
-
```typescript copy
|
|
23
|
+
```typescript copy
|
|
24
24
|
import { CouchbaseVector } from "@mastra/couchbase";
|
|
25
25
|
|
|
26
26
|
const store = new CouchbaseVector({
|
|
27
|
+
id: 'couchbase-vector',
|
|
27
28
|
connectionString: process.env.COUCHBASE_CONNECTION_STRING,
|
|
28
29
|
username: process.env.COUCHBASE_USERNAME,
|
|
29
30
|
password: process.env.COUCHBASE_PASSWORD,
|
|
@@ -37,6 +38,11 @@ const store = new CouchbaseVector({
|
|
|
37
38
|
|
|
38
39
|
<PropertiesTable
|
|
39
40
|
content={[
|
|
41
|
+
{
|
|
42
|
+
name: "id",
|
|
43
|
+
type: "string",
|
|
44
|
+
description: "Unique identifier for this vector store instance",
|
|
45
|
+
},
|
|
40
46
|
{
|
|
41
47
|
name: "connectionString",
|
|
42
48
|
type: "string",
|
|
@@ -10,7 +10,7 @@ The `MongoDBVector` class provides vector search using [MongoDB Atlas Vector Sea
|
|
|
10
10
|
## Installation
|
|
11
11
|
|
|
12
12
|
```bash copy
|
|
13
|
-
npm install @mastra/mongodb
|
|
13
|
+
npm install @mastra/mongodb@beta
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
## Usage Example
|
|
@@ -19,6 +19,7 @@ npm install @mastra/mongodb
|
|
|
19
19
|
import { MongoDBVector } from "@mastra/mongodb";
|
|
20
20
|
|
|
21
21
|
const store = new MongoDBVector({
|
|
22
|
+
id: 'mongodb-vector',
|
|
22
23
|
url: process.env.MONGODB_URL,
|
|
23
24
|
database: process.env.MONGODB_DATABASE,
|
|
24
25
|
});
|
|
@@ -28,6 +29,11 @@ const store = new MongoDBVector({
|
|
|
28
29
|
|
|
29
30
|
<PropertiesTable
|
|
30
31
|
content={[
|
|
32
|
+
{
|
|
33
|
+
name: "id",
|
|
34
|
+
type: "string",
|
|
35
|
+
description: "Unique identifier for this vector store instance",
|
|
36
|
+
},
|
|
31
37
|
{
|
|
32
38
|
name: "url",
|
|
33
39
|
type: "string",
|
|
@@ -30,28 +30,28 @@ To use the Mastra Client SDK, install the required dependencies:
|
|
|
30
30
|
<TabItem value="npm" label="npm">
|
|
31
31
|
|
|
32
32
|
```bash copy
|
|
33
|
-
npm install @mastra/client-js@
|
|
33
|
+
npm install @mastra/client-js@beta
|
|
34
34
|
```
|
|
35
35
|
|
|
36
36
|
</TabItem>
|
|
37
37
|
<TabItem value="pnpm" label="pnpm">
|
|
38
38
|
|
|
39
39
|
```bash copy
|
|
40
|
-
pnpm add @mastra/client-js@
|
|
40
|
+
pnpm add @mastra/client-js@beta
|
|
41
41
|
```
|
|
42
42
|
|
|
43
43
|
</TabItem>
|
|
44
44
|
<TabItem value="yarn" label="yarn">
|
|
45
45
|
|
|
46
46
|
```bash copy
|
|
47
|
-
yarn add @mastra/client-js@
|
|
47
|
+
yarn add @mastra/client-js@beta
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
</TabItem>
|
|
51
51
|
<TabItem value="bun" label="bun">
|
|
52
52
|
|
|
53
53
|
```bash copy
|
|
54
|
-
bun add @mastra/client-js@
|
|
54
|
+
bun add @mastra/client-js@beta
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
</TabItem>
|
|
@@ -45,7 +45,7 @@ Mastra supports several Speech-to-Text providers, each with their own capabiliti
|
|
|
45
45
|
Each provider is implemented as a separate package that you can install as needed:
|
|
46
46
|
|
|
47
47
|
```bash
|
|
48
|
-
pnpm add @mastra/voice-openai # Example for OpenAI
|
|
48
|
+
pnpm add @mastra/voice-openai@beta # Example for OpenAI
|
|
49
49
|
```
|
|
50
50
|
|
|
51
51
|
## Using the Listen Method
|
|
@@ -53,7 +53,7 @@ Mastra supports a wide range of Text-to-Speech providers, each with their own un
|
|
|
53
53
|
Each provider is implemented as a separate package that you can install as needed:
|
|
54
54
|
|
|
55
55
|
```bash
|
|
56
|
-
pnpm add @mastra/voice-openai # Example for OpenAI
|
|
56
|
+
pnpm add @mastra/voice-openai@beta # Example for OpenAI
|
|
57
57
|
```
|
|
58
58
|
|
|
59
59
|
## Using the Speak Method
|
|
@@ -20,7 +20,7 @@ Real-time monitoring, suspend/resume, and step-level observability are enabled v
|
|
|
20
20
|
## Setup
|
|
21
21
|
|
|
22
22
|
```sh
|
|
23
|
-
npm install @mastra/inngest @mastra/core @mastra/deployer
|
|
23
|
+
npm install @mastra/inngest@beta @mastra/core@beta @mastra/deployer@beta
|
|
24
24
|
```
|
|
25
25
|
|
|
26
26
|
## Building an Inngest Workflow
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @mastra/mcp-docs-server
|
|
2
2
|
|
|
3
|
+
## 1.0.0-beta.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Clean up mcp docs server migration tool to have a better prompt. ([#9930](https://github.com/mastra-ai/mastra/pull/9930))
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`d70e742`](https://github.com/mastra-ai/mastra/commit/d70e74243401d070e167e3bc19c329c1d98d8a5b), [`465ac05`](https://github.com/mastra-ai/mastra/commit/465ac0526a91d175542091c675181f1a96c98c46)]:
|
|
10
|
+
- @mastra/mcp@1.0.0-beta.1
|
|
11
|
+
- @mastra/core@1.0.0-beta.2
|
|
12
|
+
|
|
13
|
+
## 1.0.0-beta.1
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- Updated dependencies [[`910db9e`](https://github.com/mastra-ai/mastra/commit/910db9e0312888495eb5617b567f247d03303814), [`e7266a2`](https://github.com/mastra-ai/mastra/commit/e7266a278db02035c97a5e9cd9d1669a6b7a535d)]:
|
|
18
|
+
- @mastra/core@1.0.0-beta.1
|
|
19
|
+
|
|
3
20
|
## 1.0.0-beta.0
|
|
4
21
|
|
|
5
22
|
### Major Changes
|
package/dist/stdio.js
CHANGED
|
@@ -112,7 +112,7 @@ var migrationPrompts = [
|
|
|
112
112
|
arguments: [
|
|
113
113
|
{
|
|
114
114
|
name: "area",
|
|
115
|
-
description: "Optional: Focus on a specific area (
|
|
115
|
+
description: "Optional: Focus on a specific area (e.g., agent, tools, workflows, memory, storage, voice). The tool will check if a migration guide exists for this area and suggest alternatives if not found. If not provided, gives an overview of all changes.",
|
|
116
116
|
required: false
|
|
117
117
|
}
|
|
118
118
|
]
|
|
@@ -141,24 +141,20 @@ var migrationPromptMessages = {
|
|
|
141
141
|
};
|
|
142
142
|
function getUpgradeToV1Messages(area) {
|
|
143
143
|
if (area) {
|
|
144
|
-
const validAreas = ["agents", "tools", "workflows", "memory", "evals", "mcp", "vectors", "syncs"];
|
|
145
|
-
if (!validAreas.includes(area.toLowerCase())) {
|
|
146
|
-
return [
|
|
147
|
-
{
|
|
148
|
-
role: "user",
|
|
149
|
-
content: {
|
|
150
|
-
type: "text",
|
|
151
|
-
text: `Invalid area: ${area}. Valid areas are: ${validAreas.join(", ")}`
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
];
|
|
155
|
-
}
|
|
156
144
|
return [
|
|
157
145
|
{
|
|
158
146
|
role: "user",
|
|
159
147
|
content: {
|
|
160
148
|
type: "text",
|
|
161
|
-
text: `I need help migrating my Mastra ${area} code from v0.x to v1.0. Use the mastraMigration tool to
|
|
149
|
+
text: `I need help migrating my Mastra ${area} code from v0.x to v1.0. Use the mastraMigration tool to:
|
|
150
|
+
|
|
151
|
+
1. First, try to get the specific migration guide for "${area}" using path: "upgrade-to-v1/${area}"
|
|
152
|
+
2. If that doesn't exist, try the alternate form (singular/plural):
|
|
153
|
+
- If "${area}" ends with 's', try without the 's' (e.g., "agents" \u2192 "agent")
|
|
154
|
+
- If "${area}" doesn't end with 's', try adding 's' (e.g., "agent" \u2192 "agents")
|
|
155
|
+
3. If the guide exists, walk me through the changes step by step
|
|
156
|
+
4. If neither form exists, list available migration guides in "upgrade-to-v1/" and suggest which ones might be relevant to "${area}"
|
|
157
|
+
5. After you find the guide, collect all the codemod calls to run to codemods. These callouts are marked with ":::tip[Codemod]" in the docs. Run the codemods with "npx @mastra/codemod@beta <codemod-name> <path>" to automate all those changes. Afterwards, help me with any remaining manual changes needed.`
|
|
162
158
|
}
|
|
163
159
|
}
|
|
164
160
|
];
|
|
@@ -173,7 +169,7 @@ function getUpgradeToV1Messages(area) {
|
|
|
173
169
|
1. First, list all available migration guides with path: "upgrade-to-v1/"
|
|
174
170
|
2. Give me a high-level overview of what changed in each area
|
|
175
171
|
3. Ask me which areas I'm using in my project so we can focus on relevant changes
|
|
176
|
-
4. After I decided on the areas, check the migration guides for callouts to codemods. These callouts are marked with ":::tip[Codemod]" in the docs. Run the codemods with "npx @mastra/codemod v1" to automate all those changes. Afterwards, help me with any remaining manual changes needed.
|
|
172
|
+
4. After I decided on the areas, check the migration guides for callouts to codemods. These callouts are marked with ":::tip[Codemod]" in the docs. Run the codemods with "npx @mastra/codemod@beta v1" to automate all those changes. Afterwards, help me with any remaining manual changes needed.
|
|
177
173
|
|
|
178
174
|
After I tell you which areas I use, we'll go through each one systematically.`
|
|
179
175
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/mcp-docs-server",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.2",
|
|
4
4
|
"description": "MCP server for accessing Mastra.ai documentation, changelogs, and news.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"uuid": "^11.1.0",
|
|
34
34
|
"zod": "^3.25.76",
|
|
35
35
|
"zod-to-json-schema": "^3.24.6",
|
|
36
|
-
"@mastra/core": "1.0.0-beta.
|
|
37
|
-
"@mastra/mcp": "^1.0.0-beta.
|
|
36
|
+
"@mastra/core": "1.0.0-beta.2",
|
|
37
|
+
"@mastra/mcp": "^1.0.0-beta.1"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@hono/node-server": "^1.19.6",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"typescript": "^5.8.3",
|
|
51
51
|
"vitest": "^3.2.4",
|
|
52
52
|
"@internal/lint": "0.0.53",
|
|
53
|
-
"@mastra/core": "1.0.0-beta.
|
|
53
|
+
"@mastra/core": "1.0.0-beta.2"
|
|
54
54
|
},
|
|
55
55
|
"homepage": "https://mastra.ai",
|
|
56
56
|
"repository": {
|