@mastra/mcp-docs-server 1.1.21 → 1.1.22-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.docs/docs/server/mastra-client.md +2 -2
- package/.docs/docs/server/mastra-server.md +1 -1
- package/.docs/docs/workspace/overview.md +35 -7
- package/.docs/models/gateways/vercel.md +7 -2
- package/.docs/models/index.md +1 -1
- package/.docs/models/providers/alibaba-cn.md +3 -2
- package/.docs/models/providers/google.md +4 -2
- package/.docs/models/providers/xiaomi-token-plan-ams.md +73 -0
- package/.docs/models/providers/xiaomi-token-plan-cn.md +73 -0
- package/.docs/models/providers/xiaomi-token-plan-sgp.md +73 -0
- package/.docs/models/providers/zenmux.md +5 -2
- package/.docs/models/providers.md +3 -0
- package/.docs/reference/client-js/conversations.md +1 -1
- package/.docs/reference/client-js/responses.md +1 -1
- package/CHANGELOG.md +14 -0
- package/package.json +4 -4
|
@@ -61,8 +61,8 @@ The Mastra Client SDK exposes all resources served by the Mastra Server.
|
|
|
61
61
|
- **[Tools](https://mastra.ai/reference/client-js/tools)**: Executed and managed tools.
|
|
62
62
|
- **[Workflows](https://mastra.ai/reference/client-js/workflows)**: Trigger workflows and track their execution.
|
|
63
63
|
- **[Vectors](https://mastra.ai/reference/client-js/vectors)**: Use vector embeddings for semantic search.
|
|
64
|
-
- **[Responses](https://mastra.ai/reference/client-js/responses)**:
|
|
65
|
-
- **[Conversations](https://mastra.ai/reference/client-js/conversations)**: Work with
|
|
64
|
+
- **[Responses](https://mastra.ai/reference/client-js/responses)**: Use Mastra Agents as a Responses API with an OpenAI-compatible, agent-backed interface. This API is currently experimental.
|
|
65
|
+
- **[Conversations](https://mastra.ai/reference/client-js/conversations)**: Work with the stored conversation threads and item history behind Mastra Agents as a Responses API. This API is currently experimental.
|
|
66
66
|
- **[Logs](https://mastra.ai/reference/client-js/logs)**: View logs and debug system behavior.
|
|
67
67
|
- **[Telemetry](https://mastra.ai/reference/client-js/telemetry)**: View app performance and trace activity.
|
|
68
68
|
|
|
@@ -53,7 +53,7 @@ To explore the API interactively, visit the Swagger UI at <http://localhost:4111
|
|
|
53
53
|
|
|
54
54
|
## OpenAI Responses API
|
|
55
55
|
|
|
56
|
-
Mastra exposes OpenAI-compatible Responses and Conversations routes. These routes are agent-backed adapters over Mastra agents, memory, and storage, so requests run through the selected Mastra agent instead of acting as a raw provider proxy.
|
|
56
|
+
Mastra exposes OpenAI-compatible Responses and Conversations routes that let you use Mastra Agents as a Responses API. These routes are agent-backed adapters over Mastra agents, memory, and storage, so requests run through the selected Mastra agent instead of acting as a raw provider proxy.
|
|
57
57
|
|
|
58
58
|
These APIs are currently experimental.
|
|
59
59
|
|
|
@@ -195,13 +195,41 @@ const workspace = new Workspace({
|
|
|
195
195
|
|
|
196
196
|
### Tool options
|
|
197
197
|
|
|
198
|
-
| Option | Type
|
|
199
|
-
| ------------------------ |
|
|
200
|
-
| `enabled` | `boolean` | Whether the tool is available (default: `true`)
|
|
201
|
-
| `requireApproval` | `boolean` | Whether the tool requires user approval before execution (default: `false`)
|
|
202
|
-
| `requireReadBeforeWrite` | `boolean` | For write tools: require reading the file first (default: `false`)
|
|
203
|
-
| `name` | `string`
|
|
204
|
-
| `maxOutputTokens` | `number`
|
|
198
|
+
| Option | Type | Description |
|
|
199
|
+
| ------------------------ | --------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
200
|
+
| `enabled` | `boolean \| (context) => boolean` | Whether the tool is available (default: `true`). When a function, evaluated at tool-listing time. |
|
|
201
|
+
| `requireApproval` | `boolean \| (context) => boolean` | Whether the tool requires user approval before execution (default: `false`). When a function, evaluated at execution time with access to `args`. |
|
|
202
|
+
| `requireReadBeforeWrite` | `boolean \| (context) => boolean` | For write tools: require reading the file first (default: `false`). When a function, evaluated at execution time with access to `args`. |
|
|
203
|
+
| `name` | `string` | Custom name for the tool. Replaces the default `mastra_workspace_*` name. |
|
|
204
|
+
| `maxOutputTokens` | `number` | Maximum tokens for tool output (default: `2000`). Output exceeding this limit is truncated using tiktoken. |
|
|
205
|
+
|
|
206
|
+
### Dynamic tool configuration
|
|
207
|
+
|
|
208
|
+
Tool options that accept functions receive a context object and return a boolean. This enables context-aware tool behavior.
|
|
209
|
+
|
|
210
|
+
```typescript
|
|
211
|
+
const workspace = new Workspace({
|
|
212
|
+
filesystem: new LocalFilesystem({ basePath: './workspace' }),
|
|
213
|
+
tools: {
|
|
214
|
+
// Dynamic enabled: disable command execution unless explicitly allowed
|
|
215
|
+
[WORKSPACE_TOOLS.SANDBOX.EXECUTE_COMMAND]: {
|
|
216
|
+
enabled: async ({ requestContext }) => {
|
|
217
|
+
return requestContext['allowExecution'] === 'true'
|
|
218
|
+
},
|
|
219
|
+
},
|
|
220
|
+
|
|
221
|
+
// Dynamic requireApproval: only require approval for protected paths
|
|
222
|
+
[WORKSPACE_TOOLS.FILESYSTEM.WRITE_FILE]: {
|
|
223
|
+
requireApproval: async ({ args }) => {
|
|
224
|
+
return (args.path as string).startsWith('/protected')
|
|
225
|
+
},
|
|
226
|
+
requireReadBeforeWrite: true,
|
|
227
|
+
},
|
|
228
|
+
},
|
|
229
|
+
})
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
Functions for `enabled` receive `{ requestContext, workspace }`. Functions for `requireApproval` and `requireReadBeforeWrite` also receive `args` since they are evaluated when the tool is called.
|
|
205
233
|
|
|
206
234
|
### Tool name remapping
|
|
207
235
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Vercel
|
|
2
2
|
|
|
3
|
-
Vercel aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
3
|
+
Vercel aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 231 models through Mastra's model router.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Vercel documentation](https://ai-sdk.dev/providers/ai-sdk-providers).
|
|
6
6
|
|
|
@@ -55,6 +55,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
55
55
|
| `alibaba/qwen3-vl-thinking` |
|
|
56
56
|
| `alibaba/qwen3.5-flash` |
|
|
57
57
|
| `alibaba/qwen3.5-plus` |
|
|
58
|
+
| `alibaba/qwen3.6-plus` |
|
|
58
59
|
| `amazon/nova-2-lite` |
|
|
59
60
|
| `amazon/nova-lite` |
|
|
60
61
|
| `amazon/nova-micro` |
|
|
@@ -75,6 +76,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
75
76
|
| `anthropic/claude-sonnet-4.5` |
|
|
76
77
|
| `anthropic/claude-sonnet-4.6` |
|
|
77
78
|
| `arcee-ai/trinity-large-preview` |
|
|
79
|
+
| `arcee-ai/trinity-large-thinking` |
|
|
78
80
|
| `arcee-ai/trinity-mini` |
|
|
79
81
|
| `bfl/flux-kontext-max` |
|
|
80
82
|
| `bfl/flux-kontext-pro` |
|
|
@@ -109,6 +111,8 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
109
111
|
| `google/gemini-3.1-pro-preview` |
|
|
110
112
|
| `google/gemini-embedding-001` |
|
|
111
113
|
| `google/gemini-embedding-2` |
|
|
114
|
+
| `google/gemma-4-26b-a4b-it` |
|
|
115
|
+
| `google/gemma-4-31b-it` |
|
|
112
116
|
| `google/imagen-4.0-fast-generate-001` |
|
|
113
117
|
| `google/imagen-4.0-generate-001` |
|
|
114
118
|
| `google/imagen-4.0-ultra-generate-001` |
|
|
@@ -259,4 +263,5 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
259
263
|
| `zai/glm-4.7-flash` |
|
|
260
264
|
| `zai/glm-4.7-flashx` |
|
|
261
265
|
| `zai/glm-5` |
|
|
262
|
-
| `zai/glm-5-turbo` |
|
|
266
|
+
| `zai/glm-5-turbo` |
|
|
267
|
+
| `zai/glm-5v-turbo` |
|
package/.docs/models/index.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Model Providers
|
|
2
2
|
|
|
3
|
-
Mastra provides a unified interface for working with LLMs across multiple providers, giving you access to
|
|
3
|
+
Mastra provides a unified interface for working with LLMs across multiple providers, giving you access to 3601 models from 98 providers through a single API.
|
|
4
4
|
|
|
5
5
|
## Features
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Alibaba (China)
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 75 Alibaba (China) models through Mastra's model router. Authentication is handled automatically using the `DASHSCOPE_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Alibaba (China) documentation](https://www.alibabacloud.com/help/en/model-studio/models).
|
|
6
6
|
|
|
@@ -50,7 +50,7 @@ for await (const chunk of stream) {
|
|
|
50
50
|
| `alibaba-cn/kimi-k2.5` | 262K | | | | | | $0.57 | $2 |
|
|
51
51
|
| `alibaba-cn/kimi/kimi-k2.5` | 262K | | | | | | $0.60 | $3 |
|
|
52
52
|
| `alibaba-cn/MiniMax-M2.5` | 205K | | | | | | $0.30 | $1 |
|
|
53
|
-
| `alibaba-cn/MiniMax/MiniMax-M2.
|
|
53
|
+
| `alibaba-cn/MiniMax/MiniMax-M2.7` | 205K | | | | | | $0.30 | $1 |
|
|
54
54
|
| `alibaba-cn/moonshot-kimi-k2-instruct` | 131K | | | | | | $0.57 | $2 |
|
|
55
55
|
| `alibaba-cn/qvq-max` | 131K | | | | | | $1 | $5 |
|
|
56
56
|
| `alibaba-cn/qwen-deep-research` | 1.0M | | | | | | $8 | $23 |
|
|
@@ -101,6 +101,7 @@ for await (const chunk of stream) {
|
|
|
101
101
|
| `alibaba-cn/qwen3.5-397b-a17b` | 262K | | | | | | $0.43 | $3 |
|
|
102
102
|
| `alibaba-cn/qwen3.5-flash` | 1.0M | | | | | | $0.17 | $2 |
|
|
103
103
|
| `alibaba-cn/qwen3.5-plus` | 1.0M | | | | | | $0.57 | $3 |
|
|
104
|
+
| `alibaba-cn/qwen3.6-plus` | 1.0M | | | | | | $1 | $7 |
|
|
104
105
|
| `alibaba-cn/qwq-32b` | 131K | | | | | | $0.29 | $0.86 |
|
|
105
106
|
| `alibaba-cn/qwq-plus` | 131K | | | | | | $0.23 | $0.57 |
|
|
106
107
|
| `alibaba-cn/siliconflow/deepseek-r1-0528` | 164K | | | | | | $0.50 | $2 |
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Google
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 37 Google models through Mastra's model router. Authentication is handled automatically using the `GOOGLE_GENERATIVE_AI_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Google documentation](https://ai.google.dev/gemini-api/docs/pricing).
|
|
6
6
|
|
|
@@ -67,6 +67,8 @@ for await (const chunk of stream) {
|
|
|
67
67
|
| `google/gemma-3-4b-it` | 33K | | | | | | — | — |
|
|
68
68
|
| `google/gemma-3n-e2b-it` | 8K | | | | | | — | — |
|
|
69
69
|
| `google/gemma-3n-e4b-it` | 8K | | | | | | — | — |
|
|
70
|
+
| `google/gemma-4-26b` | 256K | | | | | | — | — |
|
|
71
|
+
| `google/gemma-4-31b` | 256K | | | | | | — | — |
|
|
70
72
|
|
|
71
73
|
## Advanced configuration
|
|
72
74
|
|
|
@@ -95,7 +97,7 @@ const agent = new Agent({
|
|
|
95
97
|
model: ({ requestContext }) => {
|
|
96
98
|
const useAdvanced = requestContext.task === "complex";
|
|
97
99
|
return useAdvanced
|
|
98
|
-
? "google/gemma-
|
|
100
|
+
? "google/gemma-4-31b"
|
|
99
101
|
: "google/gemini-1.5-flash";
|
|
100
102
|
}
|
|
101
103
|
});
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Xiaomi Token Plan (Europe)
|
|
2
|
+
|
|
3
|
+
Access 3 Xiaomi Token Plan (Europe) models through Mastra's model router. Authentication is handled automatically using the `XIAOMI_API_KEY` environment variable.
|
|
4
|
+
|
|
5
|
+
Learn more in the [Xiaomi Token Plan (Europe) documentation](https://platform.xiaomimimo.com/#/docs).
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
XIAOMI_API_KEY=your-api-key
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
import { Agent } from "@mastra/core/agent";
|
|
13
|
+
|
|
14
|
+
const agent = new Agent({
|
|
15
|
+
id: "my-agent",
|
|
16
|
+
name: "My Agent",
|
|
17
|
+
instructions: "You are a helpful assistant",
|
|
18
|
+
model: "xiaomi-token-plan-ams/mimo-v2-omni"
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
// Generate a response
|
|
22
|
+
const response = await agent.generate("Hello!");
|
|
23
|
+
|
|
24
|
+
// Stream a response
|
|
25
|
+
const stream = await agent.stream("Tell me a story");
|
|
26
|
+
for await (const chunk of stream) {
|
|
27
|
+
console.log(chunk);
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
> **Info:** Mastra uses the OpenAI-compatible `/chat/completions` endpoint. Some provider-specific features may not be available. Check the [Xiaomi Token Plan (Europe) documentation](https://platform.xiaomimimo.com/#/docs) for details.
|
|
32
|
+
|
|
33
|
+
## Models
|
|
34
|
+
|
|
35
|
+
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
|
+
| ------------------------------------ | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
+
| `xiaomi-token-plan-ams/mimo-v2-omni` | 256K | | | | | | — | — |
|
|
38
|
+
| `xiaomi-token-plan-ams/mimo-v2-pro` | 1.0M | | | | | | — | — |
|
|
39
|
+
| `xiaomi-token-plan-ams/mimo-v2-tts` | 8K | | | | | | — | — |
|
|
40
|
+
|
|
41
|
+
## Advanced configuration
|
|
42
|
+
|
|
43
|
+
### Custom headers
|
|
44
|
+
|
|
45
|
+
```typescript
|
|
46
|
+
const agent = new Agent({
|
|
47
|
+
id: "custom-agent",
|
|
48
|
+
name: "custom-agent",
|
|
49
|
+
model: {
|
|
50
|
+
url: "https://token-plan-ams.xiaomimimo.com/v1",
|
|
51
|
+
id: "xiaomi-token-plan-ams/mimo-v2-omni",
|
|
52
|
+
apiKey: process.env.XIAOMI_API_KEY,
|
|
53
|
+
headers: {
|
|
54
|
+
"X-Custom-Header": "value"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### Dynamic model selection
|
|
61
|
+
|
|
62
|
+
```typescript
|
|
63
|
+
const agent = new Agent({
|
|
64
|
+
id: "dynamic-agent",
|
|
65
|
+
name: "Dynamic Agent",
|
|
66
|
+
model: ({ requestContext }) => {
|
|
67
|
+
const useAdvanced = requestContext.task === "complex";
|
|
68
|
+
return useAdvanced
|
|
69
|
+
? "xiaomi-token-plan-ams/mimo-v2-tts"
|
|
70
|
+
: "xiaomi-token-plan-ams/mimo-v2-omni";
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
```
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Xiaomi Token Plan (China)
|
|
2
|
+
|
|
3
|
+
Access 3 Xiaomi Token Plan (China) models through Mastra's model router. Authentication is handled automatically using the `XIAOMI_API_KEY` environment variable.
|
|
4
|
+
|
|
5
|
+
Learn more in the [Xiaomi Token Plan (China) documentation](https://platform.xiaomimimo.com/#/docs).
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
XIAOMI_API_KEY=your-api-key
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
import { Agent } from "@mastra/core/agent";
|
|
13
|
+
|
|
14
|
+
const agent = new Agent({
|
|
15
|
+
id: "my-agent",
|
|
16
|
+
name: "My Agent",
|
|
17
|
+
instructions: "You are a helpful assistant",
|
|
18
|
+
model: "xiaomi-token-plan-cn/mimo-v2-omni"
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
// Generate a response
|
|
22
|
+
const response = await agent.generate("Hello!");
|
|
23
|
+
|
|
24
|
+
// Stream a response
|
|
25
|
+
const stream = await agent.stream("Tell me a story");
|
|
26
|
+
for await (const chunk of stream) {
|
|
27
|
+
console.log(chunk);
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
> **Info:** Mastra uses the OpenAI-compatible `/chat/completions` endpoint. Some provider-specific features may not be available. Check the [Xiaomi Token Plan (China) documentation](https://platform.xiaomimimo.com/#/docs) for details.
|
|
32
|
+
|
|
33
|
+
## Models
|
|
34
|
+
|
|
35
|
+
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
|
+
| ----------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
+
| `xiaomi-token-plan-cn/mimo-v2-omni` | 256K | | | | | | — | — |
|
|
38
|
+
| `xiaomi-token-plan-cn/mimo-v2-pro` | 1.0M | | | | | | — | — |
|
|
39
|
+
| `xiaomi-token-plan-cn/mimo-v2-tts` | 8K | | | | | | — | — |
|
|
40
|
+
|
|
41
|
+
## Advanced configuration
|
|
42
|
+
|
|
43
|
+
### Custom headers
|
|
44
|
+
|
|
45
|
+
```typescript
|
|
46
|
+
const agent = new Agent({
|
|
47
|
+
id: "custom-agent",
|
|
48
|
+
name: "custom-agent",
|
|
49
|
+
model: {
|
|
50
|
+
url: "https://token-plan-cn.xiaomimimo.com/v1",
|
|
51
|
+
id: "xiaomi-token-plan-cn/mimo-v2-omni",
|
|
52
|
+
apiKey: process.env.XIAOMI_API_KEY,
|
|
53
|
+
headers: {
|
|
54
|
+
"X-Custom-Header": "value"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### Dynamic model selection
|
|
61
|
+
|
|
62
|
+
```typescript
|
|
63
|
+
const agent = new Agent({
|
|
64
|
+
id: "dynamic-agent",
|
|
65
|
+
name: "Dynamic Agent",
|
|
66
|
+
model: ({ requestContext }) => {
|
|
67
|
+
const useAdvanced = requestContext.task === "complex";
|
|
68
|
+
return useAdvanced
|
|
69
|
+
? "xiaomi-token-plan-cn/mimo-v2-tts"
|
|
70
|
+
: "xiaomi-token-plan-cn/mimo-v2-omni";
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
```
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Xiaomi Token Plan (Singapore)
|
|
2
|
+
|
|
3
|
+
Access 3 Xiaomi Token Plan (Singapore) models through Mastra's model router. Authentication is handled automatically using the `XIAOMI_API_KEY` environment variable.
|
|
4
|
+
|
|
5
|
+
Learn more in the [Xiaomi Token Plan (Singapore) documentation](https://platform.xiaomimimo.com/#/docs).
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
XIAOMI_API_KEY=your-api-key
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
import { Agent } from "@mastra/core/agent";
|
|
13
|
+
|
|
14
|
+
const agent = new Agent({
|
|
15
|
+
id: "my-agent",
|
|
16
|
+
name: "My Agent",
|
|
17
|
+
instructions: "You are a helpful assistant",
|
|
18
|
+
model: "xiaomi-token-plan-sgp/mimo-v2-omni"
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
// Generate a response
|
|
22
|
+
const response = await agent.generate("Hello!");
|
|
23
|
+
|
|
24
|
+
// Stream a response
|
|
25
|
+
const stream = await agent.stream("Tell me a story");
|
|
26
|
+
for await (const chunk of stream) {
|
|
27
|
+
console.log(chunk);
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
> **Info:** Mastra uses the OpenAI-compatible `/chat/completions` endpoint. Some provider-specific features may not be available. Check the [Xiaomi Token Plan (Singapore) documentation](https://platform.xiaomimimo.com/#/docs) for details.
|
|
32
|
+
|
|
33
|
+
## Models
|
|
34
|
+
|
|
35
|
+
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
|
+
| ------------------------------------ | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
+
| `xiaomi-token-plan-sgp/mimo-v2-omni` | 256K | | | | | | — | — |
|
|
38
|
+
| `xiaomi-token-plan-sgp/mimo-v2-pro` | 1.0M | | | | | | — | — |
|
|
39
|
+
| `xiaomi-token-plan-sgp/mimo-v2-tts` | 8K | | | | | | — | — |
|
|
40
|
+
|
|
41
|
+
## Advanced configuration
|
|
42
|
+
|
|
43
|
+
### Custom headers
|
|
44
|
+
|
|
45
|
+
```typescript
|
|
46
|
+
const agent = new Agent({
|
|
47
|
+
id: "custom-agent",
|
|
48
|
+
name: "custom-agent",
|
|
49
|
+
model: {
|
|
50
|
+
url: "https://token-plan-sgp.xiaomimimo.com/v1",
|
|
51
|
+
id: "xiaomi-token-plan-sgp/mimo-v2-omni",
|
|
52
|
+
apiKey: process.env.XIAOMI_API_KEY,
|
|
53
|
+
headers: {
|
|
54
|
+
"X-Custom-Header": "value"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### Dynamic model selection
|
|
61
|
+
|
|
62
|
+
```typescript
|
|
63
|
+
const agent = new Agent({
|
|
64
|
+
id: "dynamic-agent",
|
|
65
|
+
name: "Dynamic Agent",
|
|
66
|
+
model: ({ requestContext }) => {
|
|
67
|
+
const useAdvanced = requestContext.task === "complex";
|
|
68
|
+
return useAdvanced
|
|
69
|
+
? "xiaomi-token-plan-sgp/mimo-v2-tts"
|
|
70
|
+
: "xiaomi-token-plan-sgp/mimo-v2-omni";
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
```
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# ZenMux
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 88 ZenMux models through Mastra's model router. Authentication is handled automatically using the `ZENMUX_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [ZenMux documentation](https://docs.zenmux.ai).
|
|
6
6
|
|
|
@@ -59,6 +59,7 @@ for await (const chunk of stream) {
|
|
|
59
59
|
| `zenmux/inclusionai/ring-1t` | 128K | | | | | | $0.56 | $2 |
|
|
60
60
|
| `zenmux/kuaishou/kat-coder-pro-v1` | 256K | | | | | | $0.30 | $1 |
|
|
61
61
|
| `zenmux/kuaishou/kat-coder-pro-v1-free` | 256K | | | | | | — | — |
|
|
62
|
+
| `zenmux/kuaishou/kat-coder-pro-v2` | 256K | | | | | | $0.30 | $1 |
|
|
62
63
|
| `zenmux/minimax/minimax-m2` | 204K | | | | | | $0.30 | $1 |
|
|
63
64
|
| `zenmux/minimax/minimax-m2.1` | 204K | | | | | | $0.30 | $1 |
|
|
64
65
|
| `zenmux/minimax/minimax-m2.5` | 205K | | | | | | $0.30 | $1 |
|
|
@@ -88,6 +89,7 @@ for await (const chunk of stream) {
|
|
|
88
89
|
| `zenmux/qwen/qwen3-max` | 256K | | | | | | $1 | $6 |
|
|
89
90
|
| `zenmux/qwen/qwen3.5-flash` | 1.0M | | | | | | $0.10 | $0.40 |
|
|
90
91
|
| `zenmux/qwen/qwen3.5-plus` | 1.0M | | | | | | $0.80 | $5 |
|
|
92
|
+
| `zenmux/qwen/qwen3.6-plus` | 1.0M | | | | | | $0.50 | $3 |
|
|
91
93
|
| `zenmux/stepfun/step-3` | 66K | | | | | | $0.21 | $0.57 |
|
|
92
94
|
| `zenmux/stepfun/step-3.5-flash` | 256K | | | | | | $0.10 | $0.30 |
|
|
93
95
|
| `zenmux/stepfun/step-3.5-flash-free` | 256K | | | | | | — | — |
|
|
@@ -119,6 +121,7 @@ for await (const chunk of stream) {
|
|
|
119
121
|
| `zenmux/z-ai/glm-4.7-flashx` | 200K | | | | | | $0.07 | $0.42 |
|
|
120
122
|
| `zenmux/z-ai/glm-5` | 200K | | | | | | $0.58 | $3 |
|
|
121
123
|
| `zenmux/z-ai/glm-5-turbo` | 200K | | | | | | $0.88 | $3 |
|
|
124
|
+
| `zenmux/z-ai/glm-5v-turbo` | 200K | | | | | | $0.73 | $3 |
|
|
122
125
|
|
|
123
126
|
## Advanced configuration
|
|
124
127
|
|
|
@@ -148,7 +151,7 @@ const agent = new Agent({
|
|
|
148
151
|
model: ({ requestContext }) => {
|
|
149
152
|
const useAdvanced = requestContext.task === "complex";
|
|
150
153
|
return useAdvanced
|
|
151
|
-
? "zenmux/z-ai/glm-
|
|
154
|
+
? "zenmux/z-ai/glm-5v-turbo"
|
|
152
155
|
: "zenmux/anthropic/claude-3.5-haiku";
|
|
153
156
|
}
|
|
154
157
|
});
|
|
@@ -88,6 +88,9 @@ Direct access to individual AI model providers. Each provider offers unique mode
|
|
|
88
88
|
- [Vultr](https://mastra.ai/models/providers/vultr)
|
|
89
89
|
- [Weights & Biases](https://mastra.ai/models/providers/wandb)
|
|
90
90
|
- [Xiaomi](https://mastra.ai/models/providers/xiaomi)
|
|
91
|
+
- [Xiaomi Token Plan (China)](https://mastra.ai/models/providers/xiaomi-token-plan-cn)
|
|
92
|
+
- [Xiaomi Token Plan (Europe)](https://mastra.ai/models/providers/xiaomi-token-plan-ams)
|
|
93
|
+
- [Xiaomi Token Plan (Singapore)](https://mastra.ai/models/providers/xiaomi-token-plan-sgp)
|
|
91
94
|
- [Z.AI](https://mastra.ai/models/providers/zai)
|
|
92
95
|
- [Z.AI Coding Plan](https://mastra.ai/models/providers/zai-coding-plan)
|
|
93
96
|
- [ZenMux](https://mastra.ai/models/providers/zenmux)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# OpenAI Responses API Conversations
|
|
2
2
|
|
|
3
|
-
The OpenAI Responses API Conversations surface provides methods to create, retrieve, delete, and inspect thread-backed conversations in Mastra.
|
|
3
|
+
The OpenAI Responses API Conversations surface gives you the conversation-management side of Mastra Agents as a Responses API. It provides methods to create, retrieve, delete, and inspect thread-backed conversations in Mastra.
|
|
4
4
|
|
|
5
5
|
This API follows up on the [OpenAI Responses API](https://mastra.ai/reference/client-js/responses). Stored Responses calls return `conversation_id`, and in Mastra that value is the raw memory `threadId`. Use `client.conversations` when you want to work with that thread directly.
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# OpenAI Responses API
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
This OpenAI-compatible, agent-backed interface lets you use Mastra Agents as a Responses API. It provides methods to create, retrieve, stream, and delete responses through Mastra agents.
|
|
4
4
|
|
|
5
5
|
These routes are agent-backed adapters over Mastra agents, memory, and storage. Use `agent_id` to select the Mastra agent that should handle the request. You can pass `model` to override the agent's configured model for a single request, or omit it to use the model already configured on the agent.
|
|
6
6
|
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @mastra/mcp-docs-server
|
|
2
2
|
|
|
3
|
+
## 1.1.22-alpha.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`f32b9e1`](https://github.com/mastra-ai/mastra/commit/f32b9e115a3c754d1c8cfa3f4256fba87b09cfb7)]:
|
|
8
|
+
- @mastra/core@1.23.0-alpha.1
|
|
9
|
+
|
|
10
|
+
## 1.1.22-alpha.0
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [[`ed425d7`](https://github.com/mastra-ai/mastra/commit/ed425d78e7c66cbda8209fee910856f98c6c6b82), [`ba6f7e9`](https://github.com/mastra-ai/mastra/commit/ba6f7e9086d8281393f2acae60fda61de3bff1f9), [`7eb2596`](https://github.com/mastra-ai/mastra/commit/7eb25960d607e07468c9a10c5437abd2deaf1e9a)]:
|
|
15
|
+
- @mastra/core@1.23.0-alpha.0
|
|
16
|
+
|
|
3
17
|
## 1.1.21
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/mcp-docs-server",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.22-alpha.1",
|
|
4
4
|
"description": "MCP server for accessing Mastra.ai documentation, changelogs, and news.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"jsdom": "^26.1.0",
|
|
30
30
|
"local-pkg": "^1.1.2",
|
|
31
31
|
"zod": "^4.3.6",
|
|
32
|
-
"@mastra/core": "1.
|
|
32
|
+
"@mastra/core": "1.23.0-alpha.1",
|
|
33
33
|
"@mastra/mcp": "^1.4.1"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
@@ -47,8 +47,8 @@
|
|
|
47
47
|
"typescript": "^5.9.3",
|
|
48
48
|
"vitest": "4.0.18",
|
|
49
49
|
"@internal/lint": "0.0.79",
|
|
50
|
-
"@
|
|
51
|
-
"@
|
|
50
|
+
"@mastra/core": "1.23.0-alpha.1",
|
|
51
|
+
"@internal/types-builder": "0.0.54"
|
|
52
52
|
},
|
|
53
53
|
"homepage": "https://mastra.ai",
|
|
54
54
|
"repository": {
|