@mastra/mcp-docs-server 1.3.13-alpha.7 → 1.3.13-alpha.8
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/models/gateways/merge-gateway.md +2 -1
- package/.docs/models/gateways/netlify.md +2 -1
- package/.docs/models/gateways/openrouter.md +2 -1
- package/.docs/models/gateways/vercel.md +2 -1
- package/.docs/models/index.md +1 -1
- package/.docs/models/providers/edenai.md +6 -2
- package/.docs/models/providers/google.md +2 -1
- package/.docs/models/providers/hyper.md +1 -1
- package/.docs/models/providers/kilo.md +7 -6
- package/.docs/models/providers/llmgateway-providers.md +10 -2
- package/.docs/models/providers/llmgateway.md +1 -1
- package/.docs/models/providers/nano-gpt.md +8 -8
- package/.docs/models/providers/opencode.md +2 -1
- package/.docs/reference/agent-controller/agent-controller-class.md +4 -2
- package/.docs/reference/tools/mcp-client.md +15 -6
- package/package.json +3 -3
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Merge Gateway
|
|
6
6
|
|
|
7
|
-
Merge Gateway aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
7
|
+
Merge Gateway aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 205 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Merge Gateway documentation](https://docs.merge.dev/merge-gateway).
|
|
10
10
|
|
|
@@ -94,6 +94,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
94
94
|
| `google/gemini-3.7-flash` |
|
|
95
95
|
| `google/gemini-3.8-flash` |
|
|
96
96
|
| `google/gemini-4-argon` |
|
|
97
|
+
| `google/gemini-4-carbon` |
|
|
97
98
|
| `google/gemini-embedding-001` |
|
|
98
99
|
| `google/gemini-embedding-2` |
|
|
99
100
|
| `google/gemini-flash-latest` |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Netlify
|
|
6
6
|
|
|
7
|
-
Netlify AI Gateway provides unified access to multiple providers with built-in caching and observability. Access
|
|
7
|
+
Netlify AI Gateway provides unified access to multiple providers with built-in caching and observability. Access 286 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Netlify documentation](https://docs.netlify.com/build/ai-gateway/overview/).
|
|
10
10
|
|
|
@@ -71,6 +71,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
71
71
|
| `gemini/gemini-3.7-flash` |
|
|
72
72
|
| `gemini/gemini-3.8-flash` |
|
|
73
73
|
| `gemini/gemini-4-argon` |
|
|
74
|
+
| `gemini/gemini-4-carbon` |
|
|
74
75
|
| `gemini/gemini-flash-latest` |
|
|
75
76
|
| `gemini/gemini-flash-lite-latest` |
|
|
76
77
|
| `gemini/gemini-nano-banana-2.1` |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# OpenRouter
|
|
6
6
|
|
|
7
|
-
OpenRouter aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
7
|
+
OpenRouter aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 377 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [OpenRouter documentation](https://openrouter.ai/models).
|
|
10
10
|
|
|
@@ -137,6 +137,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
137
137
|
| `google/gemini-3.7-flash` |
|
|
138
138
|
| `google/gemini-3.8-flash` |
|
|
139
139
|
| `google/gemini-4-argon` |
|
|
140
|
+
| `google/gemini-4-carbon` |
|
|
140
141
|
| `google/gemini-nano-banana-2.1` |
|
|
141
142
|
| `google/gemini-omni-1.1-flash` |
|
|
142
143
|
| `google/gemini-omni-1.2-flash` |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Vercel
|
|
6
6
|
|
|
7
|
-
Vercel aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
7
|
+
Vercel aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 420 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Vercel documentation](https://ai-sdk.dev/providers/ai-sdk-providers).
|
|
10
10
|
|
|
@@ -180,6 +180,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
180
180
|
| `google/gemini-3.8-live` |
|
|
181
181
|
| `google/gemini-3.8-live-extended-thinking` |
|
|
182
182
|
| `google/gemini-4-argon` |
|
|
183
|
+
| `google/gemini-4-carbon` |
|
|
183
184
|
| `google/gemini-embedding-001` |
|
|
184
185
|
| `google/gemini-embedding-2` |
|
|
185
186
|
| `google/gemini-nano-banana-2.1` |
|
package/.docs/models/index.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Model Providers
|
|
6
6
|
|
|
7
|
-
Mastra provides a unified interface for working with LLMs across multiple providers, giving you access to
|
|
7
|
+
Mastra provides a unified interface for working with LLMs across multiple providers, giving you access to 8285 models from 223 providers through a single API.
|
|
8
8
|
|
|
9
9
|
## Features
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Eden AI
|
|
6
6
|
|
|
7
|
-
Access
|
|
7
|
+
Access 387 Eden AI models through Mastra's model router. Authentication is handled automatically using the `EDENAI_API_KEY` environment variable.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Eden AI documentation](https://docs.edenai.co).
|
|
10
10
|
|
|
@@ -205,6 +205,7 @@ for await (const chunk of stream) {
|
|
|
205
205
|
| `edenai/google/gemini-3.7-flash` | 1.0M | | | | | | $2 | $8 |
|
|
206
206
|
| `edenai/google/gemini-3.8-flash` | 1.0M | | | | | | $2 | $8 |
|
|
207
207
|
| `edenai/google/gemini-4-argon` | 1.0M | | | | | | $4 | $20 |
|
|
208
|
+
| `edenai/google/gemini-4-carbon` | 1.0M | | | | | | $2 | $10 |
|
|
208
209
|
| `edenai/google/gemini-flash-latest` | 1.0M | | | | | | $2 | $8 |
|
|
209
210
|
| `edenai/google/gemini-nano-banana-2.1` | 66K | | | | | | $2 | $8 |
|
|
210
211
|
| `edenai/google/gemini-pro-latest` | 1.0M | | | | | | $4 | $20 |
|
|
@@ -235,7 +236,7 @@ for await (const chunk of stream) {
|
|
|
235
236
|
| `edenai/minimax/MiniMax-M2.5` | 205K | | | | | | $0.30 | $1 |
|
|
236
237
|
| `edenai/minimax/MiniMax-M2.7` | 205K | | | | | | $0.30 | $1 |
|
|
237
238
|
| `edenai/minimax/MiniMax-M3` | 524K | | | | | | $0.30 | $1 |
|
|
238
|
-
| `edenai/minimax/MiniMax-M3.1-Flash` | 1.0M | | | | | | $0.
|
|
239
|
+
| `edenai/minimax/MiniMax-M3.1-Flash` | 1.0M | | | | | | $0.07 | $0.30 |
|
|
239
240
|
| `edenai/mistral/codestral-2508` | 256K | | | | | | $0.30 | $0.90 |
|
|
240
241
|
| `edenai/mistral/codestral-2508@eu` | 256K | | | | | | $0.33 | $0.99 |
|
|
241
242
|
| `edenai/mistral/codestral-latest` | 256K | | | | | | $0.30 | $0.90 |
|
|
@@ -399,6 +400,9 @@ for await (const chunk of stream) {
|
|
|
399
400
|
| `edenai/vertex/gemini-4-argon` | 1.0M | | | | | | $4 | $20 |
|
|
400
401
|
| `edenai/vertex/gemini-4-argon@eu` | 1.0M | | | | | | $4 | $20 |
|
|
401
402
|
| `edenai/vertex/gemini-4-argon@us` | 1.0M | | | | | | $4 | $20 |
|
|
403
|
+
| `edenai/vertex/gemini-4-carbon` | 1.0M | | | | | | $4 | $20 |
|
|
404
|
+
| `edenai/vertex/gemini-4-carbon@eu` | 1.0M | | | | | | $4 | $20 |
|
|
405
|
+
| `edenai/vertex/gemini-4-carbon@us` | 1.0M | | | | | | $4 | $20 |
|
|
402
406
|
| `edenai/vertex/gemini-flash-latest` | 1.0M | | | | | | $2 | $8 |
|
|
403
407
|
| `edenai/vertex/gemini-nano-banana-2.1` | 131K | | | | | | $2 | $8 |
|
|
404
408
|
| `edenai/vertex/gemini-pro-latest` | 1.0M | | | | | | $4 | $20 |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Google
|
|
6
6
|
|
|
7
|
-
Access
|
|
7
|
+
Access 37 Google models through Mastra's model router. Authentication is handled automatically using one of the following environment variables: `GOOGLE_API_KEY`, `GOOGLE_GENERATIVE_AI_API_KEY`.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Google documentation](https://ai.google.dev/gemini-api/docs/models).
|
|
10
10
|
|
|
@@ -61,6 +61,7 @@ for await (const chunk of stream) {
|
|
|
61
61
|
| `google/gemini-3.7-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
62
62
|
| `google/gemini-3.8-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
63
63
|
| `google/gemini-4-argon` | 1.0M | | | | | | $2 | $10 |
|
|
64
|
+
| `google/gemini-4-carbon` | 1.0M | | | | | | $2 | $10 |
|
|
64
65
|
| `google/gemini-embedding-001` | 2K | | | | | | $0.15 | — |
|
|
65
66
|
| `google/gemini-embedding-2` | 8K | | | | | | $0.20 | — |
|
|
66
67
|
| `google/gemini-flash-latest` | 1.0M | | | | | | $0.75 | $4 |
|
|
@@ -49,7 +49,7 @@ for await (const chunk of stream) {
|
|
|
49
49
|
| `hyper/kimi-k3.1-pro` | 1.0M | | | | | | $2 | $11 |
|
|
50
50
|
| `hyper/minimax-m3` | 512K | | | | | | $0.33 | $1 |
|
|
51
51
|
| `hyper/muse-spark-open` | 1.0M | | | | | | $1 | $5 |
|
|
52
|
-
| `hyper/prism` | 1.0M | | | | | | $
|
|
52
|
+
| `hyper/prism` | 1.0M | | | | | | $2 | $11 |
|
|
53
53
|
| `hyper/prism-core` | 1.0M | | | | | | $2 | $5 |
|
|
54
54
|
| `hyper/prism-flash` | 1.0M | | | | | | $0.33 | $1 |
|
|
55
55
|
| `hyper/qwen3.8-2.4t-a95b` | 1.0M | | | | | | $2 | $6 |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Kilo Gateway
|
|
6
6
|
|
|
7
|
-
Access
|
|
7
|
+
Access 377 Kilo Gateway models through Mastra's model router. Authentication is handled automatically using the `KILO_API_KEY` environment variable.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Kilo Gateway documentation](https://kilo.ai).
|
|
10
10
|
|
|
@@ -47,7 +47,7 @@ for await (const chunk of stream) {
|
|
|
47
47
|
| `kilo/~deepseek/deepseek-v4-flash-latest` | 1.0M | | | | | | $0.04 | $0.30 |
|
|
48
48
|
| `kilo/~google/gemini-flash-latest` | 1.0M | | | | | | $0.75 | $4 |
|
|
49
49
|
| `kilo/~google/gemini-pro-latest` | 1.0M | | | | | | $2 | $10 |
|
|
50
|
-
| `kilo/~moonshotai/kimi-latest` | 1.0M | | | | | | $0.18 | $
|
|
50
|
+
| `kilo/~moonshotai/kimi-latest` | 1.0M | | | | | | $0.18 | $9 |
|
|
51
51
|
| `kilo/~openai/gpt-astra-latest` | 1.1M | | | | | | $10 | $50 |
|
|
52
52
|
| `kilo/~openai/gpt-luna-latest` | 1.1M | | | | | | $0.10 | $0.50 |
|
|
53
53
|
| `kilo/~openai/gpt-mini-latest` | 400K | | | | | | $0.75 | $5 |
|
|
@@ -55,7 +55,7 @@ for await (const chunk of stream) {
|
|
|
55
55
|
| `kilo/~openai/gpt-terra-latest` | 1.1M | | | | | | $1 | $5 |
|
|
56
56
|
| `kilo/~unbiased/pareto-latest` | 1.0M | | | | | | $0.80 | $3 |
|
|
57
57
|
| `kilo/~x-ai/grok-latest` | 500K | | | | | | $2 | $6 |
|
|
58
|
-
| `kilo/~z-ai/glm-flash-latest` | 1.0M | | | | | | $0.
|
|
58
|
+
| `kilo/~z-ai/glm-flash-latest` | 1.0M | | | | | | $0.04 | $0.08 |
|
|
59
59
|
| `kilo/~z-ai/glm-latest` | 1.0M | | | | | | $0.07 | $1 |
|
|
60
60
|
| `kilo/aion-labs/aion-2.0` | 131K | | | | | | $0.80 | $2 |
|
|
61
61
|
| `kilo/aion-labs/aion-3.0` | 131K | | | | | | $3 | $6 |
|
|
@@ -130,6 +130,7 @@ for await (const chunk of stream) {
|
|
|
130
130
|
| `kilo/google/gemini-3.7-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
131
131
|
| `kilo/google/gemini-3.8-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
132
132
|
| `kilo/google/gemini-4-argon` | 1.0M | | | | | | $2 | $10 |
|
|
133
|
+
| `kilo/google/gemini-4-carbon` | 1.0M | | | | | | $4 | $20 |
|
|
133
134
|
| `kilo/google/gemini-nano-banana-2.1` | 66K | | | | | | $2 | $8 |
|
|
134
135
|
| `kilo/google/gemini-omni-1.1-flash` | 131K | | | | | | $2 | $9 |
|
|
135
136
|
| `kilo/google/gemini-omni-1.2-flash` | 131K | | | | | | $2 | $9 |
|
|
@@ -137,7 +138,7 @@ for await (const chunk of stream) {
|
|
|
137
138
|
| `kilo/google/gemma-3-12b-it` | 131K | | | | | | $0.04 | $0.12 |
|
|
138
139
|
| `kilo/google/gemma-3-27b-it` | 131K | | | | | | $0.08 | $0.16 |
|
|
139
140
|
| `kilo/google/gemma-3-4b-it` | 131K | | | | | | $0.04 | $0.05 |
|
|
140
|
-
| `kilo/google/gemma-4-26b-a4b-it` | 256K | | | | | | $0.
|
|
141
|
+
| `kilo/google/gemma-4-26b-a4b-it` | 256K | | | | | | $0.04 | $0.11 |
|
|
141
142
|
| `kilo/google/gemma-4-31b-it` | 262K | | | | | | $0.10 | $0.34 |
|
|
142
143
|
| `kilo/google/lyria-3-clip-preview` | 1.0M | | | | | | — | — |
|
|
143
144
|
| `kilo/google/lyria-3-pro-preview` | 1.0M | | | | | | — | — |
|
|
@@ -361,10 +362,10 @@ for await (const chunk of stream) {
|
|
|
361
362
|
| `kilo/tencent/hy-mt2-1.8b` | 8K | | | | | | $0.04 | $0.18 |
|
|
362
363
|
| `kilo/tencent/hy-mt2-30b-a3b` | 8K | | | | | | $0.07 | $0.29 |
|
|
363
364
|
| `kilo/tencent/hy-mt2-7b` | 8K | | | | | | $0.07 | $0.29 |
|
|
364
|
-
| `kilo/tencent/hy3` | 262K | | | | | | $0.
|
|
365
|
+
| `kilo/tencent/hy3` | 262K | | | | | | $0.08 | $0.33 |
|
|
365
366
|
| `kilo/tencent/hy3-preview` | 262K | | | | | | $0.18 | $0.60 |
|
|
366
367
|
| `kilo/tencent/hy4` | 1.0M | | | | | | $0.83 | $3 |
|
|
367
|
-
| `kilo/tencent/hy4-preview` | 1.0M | | | | | | $0.
|
|
368
|
+
| `kilo/tencent/hy4-preview` | 1.0M | | | | | | $0.75 | $2 |
|
|
368
369
|
| `kilo/thedrummer/cydonia-24b-v4.1` | 131K | | | | | | $0.30 | $0.50 |
|
|
369
370
|
| `kilo/thedrummer/skyfall-36b-v2` | 33K | | | | | | $0.55 | $0.80 |
|
|
370
371
|
| `kilo/thedrummer/unslopnemo-12b` | 1.0M | | | | | | $0.40 | $0.40 |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# LLM Gateway
|
|
6
6
|
|
|
7
|
-
Access
|
|
7
|
+
Access 448 LLM Gateway models through Mastra's model router. Authentication is handled automatically using the `LLMGATEWAY_API_KEY` environment variable.
|
|
8
8
|
|
|
9
9
|
Learn more in the [LLM Gateway documentation](https://llmgateway.io/docs).
|
|
10
10
|
|
|
@@ -39,6 +39,7 @@ for await (const chunk of stream) {
|
|
|
39
39
|
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
40
40
|
| ----------------------------------------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
41
41
|
| `llmgateway-providers/alibaba/deepseek-v4-flash` | 1.0M | | | | | | $0.20 | $0.40 |
|
|
42
|
+
| `llmgateway-providers/alibaba/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.20 | $0.40 |
|
|
42
43
|
| `llmgateway-providers/alibaba/deepseek-v4-pro` | 1.0M | | | | | | $2 | $5 |
|
|
43
44
|
| `llmgateway-providers/alibaba/deepseek-v4.1-flash` | 1.0M | | | | | | $0.30 | $1 |
|
|
44
45
|
| `llmgateway-providers/alibaba/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.30 | $1 |
|
|
@@ -152,6 +153,7 @@ for await (const chunk of stream) {
|
|
|
152
153
|
| `llmgateway-providers/azure/grok-4-1-fast-reasoning` | 128K | | | | | | $0.20 | $0.50 |
|
|
153
154
|
| `llmgateway-providers/azure/grok-4-3` | 200K | | | | | | $1 | $3 |
|
|
154
155
|
| `llmgateway-providers/baidu/deepseek-v4-flash` | 1.0M | | | | | | $0.44 | $1 |
|
|
156
|
+
| `llmgateway-providers/baidu/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.44 | $1 |
|
|
155
157
|
| `llmgateway-providers/baidu/deepseek-v4-pro` | 1.0M | | | | | | $1 | $4 |
|
|
156
158
|
| `llmgateway-providers/baidu/deepseek-v4.1-flash` | 1.0M | | | | | | $0.30 | $1 |
|
|
157
159
|
| `llmgateway-providers/baidu/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.28 | $1 |
|
|
@@ -162,6 +164,7 @@ for await (const chunk of stream) {
|
|
|
162
164
|
| `llmgateway-providers/baidu/kimi-k3` | 1.0M | | | | | | $3 | $15 |
|
|
163
165
|
| `llmgateway-providers/bytedance/deepseek-v3.2` | 131K | | | | | | $0.28 | $0.42 |
|
|
164
166
|
| `llmgateway-providers/bytedance/deepseek-v4-flash` | 1.0M | | | | | | $0.44 | $1 |
|
|
167
|
+
| `llmgateway-providers/bytedance/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.44 | $1 |
|
|
165
168
|
| `llmgateway-providers/bytedance/deepseek-v4-pro` | 1.0M | | | | | | $1 | $4 |
|
|
166
169
|
| `llmgateway-providers/bytedance/glm-4.7` | 200K | | | | | | $0.60 | $2 |
|
|
167
170
|
| `llmgateway-providers/bytedance/glm-5.2` | 1.0M | | | | | | $1 | $4 |
|
|
@@ -183,6 +186,7 @@ for await (const chunk of stream) {
|
|
|
183
186
|
| `llmgateway-providers/canopywave/qwen3.8-flash` | 1.0M | | | | | | $0.15 | $0.50 |
|
|
184
187
|
| `llmgateway-providers/cerebras/gpt-oss-120b` | 131K | | | | | | $0.35 | $0.75 |
|
|
185
188
|
| `llmgateway-providers/cloudflare/deepseek-v4-flash` | 1.0M | | | | | | $0.44 | $1 |
|
|
189
|
+
| `llmgateway-providers/cloudflare/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.44 | $1 |
|
|
186
190
|
| `llmgateway-providers/cloudflare/deepseek-v4-pro` | 1.0M | | | | | | $1 | $4 |
|
|
187
191
|
| `llmgateway-providers/cloudflare/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.30 | $1 |
|
|
188
192
|
| `llmgateway-providers/cloudflare/glm-5.3` | 1.0M | | | | | | $1 | $4 |
|
|
@@ -195,7 +199,8 @@ for await (const chunk of stream) {
|
|
|
195
199
|
| `llmgateway-providers/consensusprotocol/gpt-oss-20b` | 128K | | | | | | $0.04 | $0.19 |
|
|
196
200
|
| `llmgateway-providers/consensusprotocol/Qwen3.8-27B` | 262K | | | | | | $0.08 | $0.35 |
|
|
197
201
|
| `llmgateway-providers/deepinfra/deepseek-v3.2` | 160K | | | | | | $0.26 | $0.38 |
|
|
198
|
-
| `llmgateway-providers/deepinfra/deepseek-v4-flash` | 1.0M | | | | | | $0.
|
|
202
|
+
| `llmgateway-providers/deepinfra/deepseek-v4-flash` | 1.0M | | | | | | $0.09 | $0.18 |
|
|
203
|
+
| `llmgateway-providers/deepinfra/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.08 | $0.18 |
|
|
199
204
|
| `llmgateway-providers/deepinfra/deepseek-v4-pro` | 1.0M | | | | | | $1 | $3 |
|
|
200
205
|
| `llmgateway-providers/deepinfra/deepseek-v4.1-flash` | 1.0M | | | | | | $0.20 | $0.60 |
|
|
201
206
|
| `llmgateway-providers/deepinfra/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.20 | $0.60 |
|
|
@@ -250,6 +255,7 @@ for await (const chunk of stream) {
|
|
|
250
255
|
| `llmgateway-providers/greenference/qwen3.6-27b` | 16K | | | | | | $0.15 | $1 |
|
|
251
256
|
| `llmgateway-providers/groq/gpt-oss-120b` | 131K | | | | | | $0.15 | $0.75 |
|
|
252
257
|
| `llmgateway-providers/groq/gpt-oss-20b` | 131K | | | | | | $0.10 | $0.50 |
|
|
258
|
+
| `llmgateway-providers/inference.net/deepseek-v4-flash` | 1.0M | | | | | | $0.23 | $0.62 |
|
|
253
259
|
| `llmgateway-providers/inference.net/deepseek-v4.1-flash-1017` | 262K | | | | | | $0.30 | $1 |
|
|
254
260
|
| `llmgateway-providers/inference.net/deepseek-v4.1-flash-cyber` | 1.0M | | | | | | $0.30 | $1 |
|
|
255
261
|
| `llmgateway-providers/inference.net/glm-5.3` | 1.0M | | | | | | $0.90 | $3 |
|
|
@@ -296,6 +302,7 @@ for await (const chunk of stream) {
|
|
|
296
302
|
| `llmgateway-providers/moonshot/kimi-k3.1-pro-highspeed` | 1.0M | | | | | | $4 | $20 |
|
|
297
303
|
| `llmgateway-providers/nebius/minimax-m3.1-flash` | 1.0M | | | | | | $0.15 | $0.60 |
|
|
298
304
|
| `llmgateway-providers/novita/deepseek-v4-flash` | 1.1M | | | | | | $0.14 | $0.28 |
|
|
305
|
+
| `llmgateway-providers/novita/deepseek-v4-flash-0731` | 1.1M | | | | | | $0.14 | $0.28 |
|
|
299
306
|
| `llmgateway-providers/novita/deepseek-v4.1-flash` | 1.0M | | | | | | $0.30 | $1 |
|
|
300
307
|
| `llmgateway-providers/novita/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.30 | $1 |
|
|
301
308
|
| `llmgateway-providers/novita/gemma-4-26b-a4b-it` | 262K | | | | | | $0.13 | $0.40 |
|
|
@@ -404,6 +411,7 @@ for await (const chunk of stream) {
|
|
|
404
411
|
| `llmgateway-providers/scx-ai/minimax-m2.7` | 197K | | | | | | $0.48 | $2 |
|
|
405
412
|
| `llmgateway-providers/scx-ai/qwen3-32b` | 33K | | | | | | $0.36 | $0.87 |
|
|
406
413
|
| `llmgateway-providers/tencent/deepseek-v4-flash` | 1.0M | | | | | | $0.15 | $0.60 |
|
|
414
|
+
| `llmgateway-providers/tencent/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.15 | $0.60 |
|
|
407
415
|
| `llmgateway-providers/tencent/deepseek-v4-pro` | 1.0M | | | | | | $0.66 | $2 |
|
|
408
416
|
| `llmgateway-providers/tencent/deepseek-v4.1-flash` | 1.0M | | | | | | $0.15 | $0.60 |
|
|
409
417
|
| `llmgateway-providers/tencent/deepseek-v4.1-flash-1017` | 1.0M | | | | | | $0.15 | $0.60 |
|
|
@@ -60,7 +60,7 @@ for await (const chunk of stream) {
|
|
|
60
60
|
| `llmgateway/custom` | 128K | | | | | | — | — |
|
|
61
61
|
| `llmgateway/deepseek-v3.2` | 164K | | | | | | $0.26 | $0.38 |
|
|
62
62
|
| `llmgateway/deepseek-v4-flash` | 1.1M | | | | | | $0.08 | $0.15 |
|
|
63
|
-
| `llmgateway/deepseek-v4-flash-0731` | 1.
|
|
63
|
+
| `llmgateway/deepseek-v4-flash-0731` | 1.1M | | | | | | $0.08 | $0.18 |
|
|
64
64
|
| `llmgateway/deepseek-v4-pro` | 1.1M | | | | | | $0.66 | $2 |
|
|
65
65
|
| `llmgateway/deepseek-v4.1-flash` | 1.1M | | | | | | $0.14 | $0.54 |
|
|
66
66
|
| `llmgateway/deepseek-v4.1-flash-1017` | 1.1M | | | | | | $0.14 | $0.54 |
|
|
@@ -56,7 +56,7 @@ for await (const chunk of stream) {
|
|
|
56
56
|
| `nano-gpt/amazon/nova-lite-v1` | 300K | | | | | | $0.06 | $0.24 |
|
|
57
57
|
| `nano-gpt/amazon/nova-pro-v1` | 300K | | | | | | $0.80 | $3 |
|
|
58
58
|
| `nano-gpt/anthracite-org/magnum-v2-72b` | 16K | | | | | | $2 | $3 |
|
|
59
|
-
| `nano-gpt/anthracite-org/magnum-v4-72b` | 16K | | | | | | $
|
|
59
|
+
| `nano-gpt/anthracite-org/magnum-v4-72b` | 16K | | | | | | $3 | $5 |
|
|
60
60
|
| `nano-gpt/anthropic/claude-fable-5` | 1.0M | | | | | | $10 | $50 |
|
|
61
61
|
| `nano-gpt/anthropic/claude-fable-5.1` | 1.0M | | | | | | $10 | $50 |
|
|
62
62
|
| `nano-gpt/anthropic/claude-fable-5.2` | 1.0M | | | | | | $10 | $50 |
|
|
@@ -231,9 +231,9 @@ for await (const chunk of stream) {
|
|
|
231
231
|
| `nano-gpt/google/gemini-flash-latest` | 1.0M | | | | | | $0.75 | $4 |
|
|
232
232
|
| `nano-gpt/google/gemini-flash-lite-latest` | 1.0M | | | | | | $0.30 | $3 |
|
|
233
233
|
| `nano-gpt/google/gemini-pro-latest` | 1.0M | | | | | | $2 | $12 |
|
|
234
|
-
| `nano-gpt/google/gemma-4-26b-a4b-it` | 262K | | | | | | $0.
|
|
234
|
+
| `nano-gpt/google/gemma-4-26b-a4b-it` | 262K | | | | | | $0.03 | $0.10 |
|
|
235
235
|
| `nano-gpt/google/gemma-4-26b-a4b-it-cybersecurity` | 262K | | | | | | $0.11 | $0.33 |
|
|
236
|
-
| `nano-gpt/google/gemma-4-26b-a4b-it:thinking` | 262K | | | | | | $0.
|
|
236
|
+
| `nano-gpt/google/gemma-4-26b-a4b-it:thinking` | 262K | | | | | | $0.03 | $0.10 |
|
|
237
237
|
| `nano-gpt/google/gemma-4-31b-it` | 262K | | | | | | $0.14 | $0.40 |
|
|
238
238
|
| `nano-gpt/google/gemma-4-31b-it:thinking` | 262K | | | | | | $0.10 | $0.34 |
|
|
239
239
|
| `nano-gpt/google/gemma4-31b-splituntied` | 262K | | | | | | $0.10 | $0.30 |
|
|
@@ -447,8 +447,8 @@ for await (const chunk of stream) {
|
|
|
447
447
|
| `nano-gpt/qwen/qwen2.5-coder-32b-instruct` | 32K | | | | | | $0.20 | $0.20 |
|
|
448
448
|
| `nano-gpt/qwen/qwen2.5-vl-72b-instruct` | 32K | | | | | | $0.70 | $0.70 |
|
|
449
449
|
| `nano-gpt/qwen/qwen3-14b` | 41K | | | | | | $0.08 | $0.24 |
|
|
450
|
-
| `nano-gpt/qwen/qwen3-235b-a22b` | 262K | | | | | | $0.09 | $0.
|
|
451
|
-
| `nano-gpt/qwen/qwen3-235b-a22b-instruct-2507` | 262K | | | | | | $0.09 | $0.
|
|
450
|
+
| `nano-gpt/qwen/qwen3-235b-a22b` | 262K | | | | | | $0.09 | $0.55 |
|
|
451
|
+
| `nano-gpt/qwen/qwen3-235b-a22b-instruct-2507` | 262K | | | | | | $0.09 | $0.55 |
|
|
452
452
|
| `nano-gpt/qwen/qwen3-235b-a22b-thinking-2507` | 131K | | | | | | $0.30 | $0.50 |
|
|
453
453
|
| `nano-gpt/qwen/qwen3-30b-a3b` | 41K | | | | | | $0.10 | $0.30 |
|
|
454
454
|
| `nano-gpt/qwen/qwen3-30b-a3b-instruct-2507` | 256K | | | | | | $0.20 | $0.50 |
|
|
@@ -571,15 +571,15 @@ for await (const chunk of stream) {
|
|
|
571
571
|
| `nano-gpt/TEE/qwen3.8-27b` | 262K | | | | | | $0.20 | $3 |
|
|
572
572
|
| `nano-gpt/tencent/hy3` | 262K | | | | | | $0.07 | $0.26 |
|
|
573
573
|
| `nano-gpt/tencent/hy4` | 1.0M | | | | | | $0.46 | $1 |
|
|
574
|
-
| `nano-gpt/tencent/hy4-preview` | 1.0M | | | | | | $0.
|
|
574
|
+
| `nano-gpt/tencent/hy4-preview` | 1.0M | | | | | | $0.75 | $2 |
|
|
575
575
|
| `nano-gpt/TheDrummer/Anubis-70B-v1` | 66K | | | | | | $0.31 | $0.31 |
|
|
576
|
-
| `nano-gpt/TheDrummer/Anubis-70B-v1.1` |
|
|
576
|
+
| `nano-gpt/TheDrummer/Anubis-70B-v1.1` | 33K | | | | | | $0.31 | $0.31 |
|
|
577
577
|
| `nano-gpt/TheDrummer/artemis-31b-v1.2` | 66K | | | | | | $0.10 | $0.45 |
|
|
578
578
|
| `nano-gpt/TheDrummer/Artemis-v1.1` | 262K | | | | | | $0.10 | $0.45 |
|
|
579
579
|
| `nano-gpt/TheDrummer/Cydonia-24B-v2` | 33K | | | | | | $0.10 | $0.12 |
|
|
580
580
|
| `nano-gpt/TheDrummer/Cydonia-24B-v4` | 33K | | | | | | $0.20 | $0.24 |
|
|
581
581
|
| `nano-gpt/TheDrummer/Cydonia-24B-v4.1` | 131K | | | | | | $0.30 | $0.50 |
|
|
582
|
-
| `nano-gpt/TheDrummer/Cydonia-24B-v4.3` |
|
|
582
|
+
| `nano-gpt/TheDrummer/Cydonia-24B-v4.3` | 66K | | | | | | $0.12 | $0.15 |
|
|
583
583
|
| `nano-gpt/TheDrummer/Magidonia-24B-v4.3` | 33K | | | | | | $0.10 | $0.12 |
|
|
584
584
|
| `nano-gpt/TheDrummer/Rocinante-12B-v1.1` | 16K | | | | | | $0.41 | $0.59 |
|
|
585
585
|
| `nano-gpt/TheDrummer/skyfall-36b-v2` | 33K | | | | | | $0.55 | $0.80 |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# OpenCode
|
|
6
6
|
|
|
7
|
-
Access
|
|
7
|
+
Access 138 OpenCode models through Mastra's model router. Authentication is handled automatically using the `OPENCODE_API_KEY` environment variable.
|
|
8
8
|
|
|
9
9
|
Learn more in the [OpenCode documentation](https://opencode.ai/v2/docs/console/models/).
|
|
10
10
|
|
|
@@ -67,6 +67,7 @@ for await (const chunk of stream) {
|
|
|
67
67
|
| `opencode/gemini-3.7-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
68
68
|
| `opencode/gemini-3.8-flash` | 1.0M | | | | | | $0.75 | $4 |
|
|
69
69
|
| `opencode/gemini-4-argon` | 1.0M | | | | | | $2 | $10 |
|
|
70
|
+
| `opencode/gemini-4-carbon` | 1.0M | | | | | | $2 | $10 |
|
|
70
71
|
| `opencode/glm-5` | 205K | | | | | | $1 | $3 |
|
|
71
72
|
| `opencode/glm-5.1` | 205K | | | | | | $1 | $4 |
|
|
72
73
|
| `opencode/glm-5.2` | 1.0M | | | | | | $1 | $4 |
|
|
@@ -507,7 +507,9 @@ Returns: `Promise<ModelAuthStatus>`
|
|
|
507
507
|
|
|
508
508
|
#### `listAvailableModels()`
|
|
509
509
|
|
|
510
|
-
List models from the configured and built-in gateways.
|
|
510
|
+
List models from the configured and built-in gateways. Each model's `useCount` comes from `modelUseCountProvider` when you configure one.
|
|
511
|
+
|
|
512
|
+
The built-in gateways download public catalogs (models.dev and Netlify). A call waits for a catalog only while none has downloaded yet. After that, calls return the last downloaded catalog, including when a download fails. Once it's 5 minutes old, the next call downloads a new one in the background without waiting for it. Configured gateways and API key availability are checked again after 10 seconds.
|
|
511
513
|
|
|
512
514
|
```typescript
|
|
513
515
|
const models = await controller.listAvailableModels()
|
|
@@ -517,7 +519,7 @@ Returns: `Promise<AvailableModel[]>`
|
|
|
517
519
|
|
|
518
520
|
#### `invalidateAvailableModelsCache()`
|
|
519
521
|
|
|
520
|
-
|
|
522
|
+
Make the next `listAvailableModels()` call check configured gateways and API key availability again, and download the models.dev and Netlify catalogs again in the background. Call it after your app stores or removes a credential or changes a custom provider.
|
|
521
523
|
|
|
522
524
|
```typescript
|
|
523
525
|
controller.invalidateAvailableModelsCache()
|
|
@@ -1764,7 +1764,9 @@ With hooks disabled, your application is responsible for closing MCP connections
|
|
|
1764
1764
|
|
|
1765
1765
|
For HTTP servers, you can provide a custom `fetch` function to handle runtime-defined authentication or request interception. It can also handle other custom behavior. This is particularly useful when you need to refresh tokens on each request or forward user credentials from the incoming request to the MCP server.
|
|
1766
1766
|
|
|
1767
|
-
The custom `fetch` function receives an optional third `requestContext` parameter, which provides access to request-scoped data (e.g., authentication cookies, bearer tokens) set by middleware or passed during agent/tool execution. The `requestContext` is `null`
|
|
1767
|
+
The custom `fetch` function receives an optional third `requestContext` parameter, which provides access to request-scoped data (e.g., authentication cookies, bearer tokens) set by middleware or passed during agent/tool execution. The `requestContext` is `null` for requests that no tool call sends, such as `listTools()` and the connection handshake it opens. When a tool call opens the connection, either because a tool rebuilt with `toolsFromDefinitions()` or `toolFromDefinition()` connects on its first execution or because the call reconnects, the handshake receives that call's `requestContext`. Streams the connection keeps open afterward, such as the server-to-client event stream, keep using that same `requestContext`, and so do the client's replies to server requests on them, such as an answer to an input request. A request your own code starts from a server log or notification on those streams gets `null`.
|
|
1768
|
+
|
|
1769
|
+
A server that authenticates every request therefore needs a credential for discovery as well as for tool calls. The following example forwards the user's cookie when a tool call provides a `requestContext`, and sends the app's own token when there's none, as in `listTools()`. Any request without a `requestContext` gets that token, so have the server limit it to discovery, for example listing tools but not calling them.
|
|
1768
1770
|
|
|
1769
1771
|
When `fetch` is provided, `requestInit` and `authProvider` become optional, as you can handle these concerns within your custom fetch function.
|
|
1770
1772
|
|
|
@@ -1775,10 +1777,15 @@ const mcpClient = new MCPClient({
|
|
|
1775
1777
|
url: new URL('https://api.example.com/mcp'),
|
|
1776
1778
|
fetch: async (url, init, requestContext) => {
|
|
1777
1779
|
const headers = new Headers(init?.headers)
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1780
|
+
if (requestContext) {
|
|
1781
|
+
// A tool call: forward the auth cookie from the incoming request
|
|
1782
|
+
const cookie = requestContext.get('cookie')
|
|
1783
|
+
if (cookie) {
|
|
1784
|
+
headers.set('cookie', cookie)
|
|
1785
|
+
}
|
|
1786
|
+
} else {
|
|
1787
|
+
// No requestContext, as in listTools(): a token the server only accepts for discovery
|
|
1788
|
+
headers.set('authorization', `Bearer ${process.env.MCP_DISCOVERY_TOKEN}`)
|
|
1782
1789
|
}
|
|
1783
1790
|
return fetch(url, { ...init, headers })
|
|
1784
1791
|
},
|
|
@@ -1800,9 +1807,11 @@ await agent.generate('Hello!', {
|
|
|
1800
1807
|
})
|
|
1801
1808
|
```
|
|
1802
1809
|
|
|
1810
|
+
If the server accepts only per-user credentials, skip `listTools()` at startup. Build the catalog with [`listToolDefinitions()`](#listtooldefinitions) from a client that has a credential of its own, for example in a build step with a static `requestInit` header, and store it. At runtime, rebuild the tools with [`toolsFromDefinitions()`](#toolsfromdefinitions). Each rebuilt tool opens the connection on its first call, so the handshake carries that call's `requestContext`.
|
|
1811
|
+
|
|
1803
1812
|
## Handling auth failures inside custom fetch
|
|
1804
1813
|
|
|
1805
|
-
A custom `fetch` shouldn't `throw` when authentication is unavailable.
|
|
1814
|
+
A custom `fetch` shouldn't `throw` when authentication is unavailable. JSON-RPC requests such as `tools/call` are `POST`s, and the SDK surfaces a non-2xx response as an error to the caller of `listTools()`, `tools/call` and so on, which is the behavior you want. A thrown `fetch` is reported the same way but loses the server's status and body. On a 2025-11-25 server, the client also sends a `GET` with no body after the handshake to open the server-to-client event stream, so check `init.method` rather than assuming a `POST` body. Long-lived streams are reopened after a failure: the `subscriptions/listen` `POST` the client opens for `resources.subscribe()` and the `GET` event stream if it drops. An unauthenticated `subscriptions/listen` stream can loop. Wait for the token, then forward the request:
|
|
1806
1815
|
|
|
1807
1816
|
```typescript
|
|
1808
1817
|
async function waitForToken(timeoutMs = 5000): Promise<string | null> {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/mcp-docs-server",
|
|
3
|
-
"version": "1.3.13-alpha.
|
|
3
|
+
"version": "1.3.13-alpha.8",
|
|
4
4
|
"description": "MCP server for accessing Mastra.ai documentation, changelogs, and news.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"@mastra/mcp-legacy": "npm:@mastra/mcp@^1.18.0",
|
|
27
27
|
"local-pkg": "^1.2.1",
|
|
28
28
|
"zod": "^4.6.7",
|
|
29
|
-
"@mastra/core": "1.83.0-alpha.
|
|
30
|
-
"@mastra/mcp": "^2.9.0-alpha.
|
|
29
|
+
"@mastra/core": "1.83.0-alpha.5",
|
|
30
|
+
"@mastra/mcp": "^2.9.0-alpha.2"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@hono/node-server": "^2.1.3",
|