@mastra/mcp-docs-server 1.2.24-alpha.9 → 1.2.25-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/agents/processors.md +3 -2
- package/.docs/docs/auth/fga.md +1 -1
- package/.docs/docs/channels.md +1 -1
- package/.docs/docs/evals/custom-scorers.md +2 -2
- package/.docs/docs/evals/datasets.md +13 -3
- package/.docs/docs/evals/experiments.md +11 -3
- package/.docs/docs/evals/multi-turn.md +1 -1
- package/.docs/docs/guides/agent-lifecycle.md +161 -0
- package/.docs/docs/guides/streaming.md +1 -1
- package/.docs/docs/harness/agent-controller.md +1 -1
- package/.docs/docs/harness/durable-agents.md +11 -0
- package/.docs/docs/index.md +7 -7
- package/.docs/docs/mastra-platform/database.md +3 -1
- package/.docs/docs/memory/message-history.md +1 -1
- package/.docs/docs/memory/multi-user-threads.md +1 -1
- package/.docs/docs/memory/observational-memory.md +41 -1
- package/.docs/docs/memory/overview.md +4 -4
- package/.docs/docs/observability/tracing/overview.md +2 -2
- package/.docs/docs/server/middleware.md +17 -7
- package/.docs/docs/server/pubsub.md +1 -1
- package/.docs/docs/server/request-context.md +7 -5
- package/.docs/docs/studio/overview.md +1 -1
- package/.docs/docs/workflows/control-flow.md +0 -8
- package/.docs/integrations/browsers/browser-viewer.md +10 -2
- package/.docs/integrations/deploy/kubernetes-helm.md +13 -2
- package/.docs/integrations/frameworks/tanstack-start.md +3 -3
- package/.docs/integrations/observability/langfuse.md +3 -0
- package/.docs/integrations/tools/parallel.md +2 -2
- package/.docs/models/gateways/merge-gateway.md +2 -1
- package/.docs/models/gateways/neon.md +5 -1
- package/.docs/models/gateways/netlify.md +2 -3
- package/.docs/models/gateways/openrouter.md +5 -8
- package/.docs/models/gateways/vercel.md +4 -4
- package/.docs/models/index.md +1 -1
- package/.docs/models/providers/302ai.md +52 -33
- package/.docs/models/providers/anthropic.md +1 -31
- package/.docs/models/providers/cerebras.md +6 -36
- package/.docs/models/providers/cortecs.md +2 -5
- package/.docs/models/providers/crof.md +27 -26
- package/.docs/models/providers/crossmodel.md +2 -2
- package/.docs/models/providers/deepinfra.md +2 -33
- package/.docs/models/providers/digitalocean.md +2 -1
- package/.docs/models/providers/edenai.md +25 -14
- package/.docs/models/providers/fireworks-ai.md +2 -1
- package/.docs/models/providers/freemodel.md +0 -28
- package/.docs/models/providers/google.md +1 -31
- package/.docs/models/providers/groq.md +1 -31
- package/.docs/models/providers/hyper.md +5 -4
- package/.docs/models/providers/kilo.md +17 -19
- package/.docs/models/providers/kimi-for-coding.md +0 -28
- package/.docs/models/providers/llmgateway-providers.md +5 -5
- package/.docs/models/providers/llmgateway.md +3 -3
- package/.docs/models/providers/meta.md +0 -28
- package/.docs/models/providers/minimax-cn-coding-plan.md +0 -28
- package/.docs/models/providers/minimax-cn.md +0 -28
- package/.docs/models/providers/minimax-coding-plan.md +0 -28
- package/.docs/models/providers/minimax.md +1 -31
- package/.docs/models/providers/mistral.md +1 -31
- package/.docs/models/providers/moonshotai-cn.md +4 -10
- package/.docs/models/providers/moonshotai.md +4 -10
- package/.docs/models/providers/nano-gpt.md +13 -21
- package/.docs/models/providers/neosmith.md +0 -28
- package/.docs/models/providers/ofox.md +2 -1
- package/.docs/models/providers/openai.md +1 -31
- package/.docs/models/providers/opencode.md +6 -1
- package/.docs/models/providers/orcarouter.md +2 -2
- package/.docs/models/providers/perplexity-agent.md +0 -28
- package/.docs/models/providers/perplexity.md +1 -31
- package/.docs/models/providers/privatemode-ai.md +3 -1
- package/.docs/models/providers/requesty.md +9 -8
- package/.docs/models/providers/sensenova.md +3 -1
- package/.docs/models/providers/subconscious.md +0 -28
- package/.docs/models/providers/thinkingmachines.md +0 -28
- package/.docs/models/providers/togetherai.md +1 -31
- package/.docs/models/providers/vivgrid.md +9 -32
- package/.docs/models/providers/xai.md +1 -31
- package/.docs/reference/agent-controller/session.md +2 -0
- package/.docs/reference/agents/durable-agent.md +7 -1
- package/.docs/reference/agents/generate.md +1 -1
- package/.docs/reference/agents/network.md +1 -1
- package/.docs/reference/build-with-ai.md +8 -24
- package/.docs/reference/cli/mastra.md +30 -0
- package/.docs/reference/client-js/datasets.md +56 -1
- package/.docs/reference/coding-agent/build-base-prompt.md +4 -4
- package/.docs/reference/datasets/dataset.md +1 -0
- package/.docs/reference/datasets/datasets-manager.md +14 -0
- package/.docs/reference/datasets/deleteExperiment.md +47 -9
- package/.docs/reference/datasets/purgeItem.md +41 -0
- package/.docs/reference/editor/versioning.md +1 -1
- package/.docs/reference/evals/completeness.md +1 -1
- package/.docs/reference/evals/faithfulness.md +1 -1
- package/.docs/reference/evals/noise-sensitivity.md +1 -1
- package/.docs/reference/evals/prompt-alignment.md +2 -4
- package/.docs/reference/index.md +1 -0
- package/.docs/reference/memory/observational-memory.md +1 -1
- package/.docs/reference/migrations/upgrade-to-v1/workflows.md +1 -1
- package/.docs/reference/processors/processor-interface.md +21 -83
- package/.docs/reference/processors/regex-filter-processor.md +1 -1
- package/.docs/reference/rag/vector-databases.md +1 -1
- package/.docs/reference/server/routes.md +44 -19
- package/.docs/reference/streaming/agents/stream.md +7 -3
- package/.docs/reference/tools/graph-rag-tool.md +3 -1
- package/.docs/reference/tools/mcp-server.md +1 -1
- package/.docs/reference/tools/vector-query-tool.md +4 -2
- package/.docs/reference/workspace/sandbox.md +2 -2
- package/package.json +5 -5
|
@@ -131,7 +131,11 @@ export const mastra = new Mastra({
|
|
|
131
131
|
|
|
132
132
|
### Authorization (User Isolation)
|
|
133
133
|
|
|
134
|
-
Authentication verifies who the user is
|
|
134
|
+
Authentication verifies who the user is, while authorization controls what they can access.
|
|
135
|
+
|
|
136
|
+
Without server-enforced resource scoping or another authorization policy, authenticated callers can list threads across resources and access their messages and working memory. Callers don't need to guess thread IDs: an unscoped listing can expose them. For private per-user or per-tenant memory, configure `mapUserToResourceId` or set a trusted resource ID in middleware.
|
|
137
|
+
|
|
138
|
+
Cross-resource access can be intentional in shared applications. A resource ID can identify a user, tenant, project, or another grouping. Choose an authorization policy that matches who can access those resources.
|
|
135
139
|
|
|
136
140
|
The simplest way to scope memory and threads to the authenticated user is the `mapUserToResourceId` callback in the auth config:
|
|
137
141
|
|
|
@@ -152,10 +156,16 @@ export const mastra = new Mastra({
|
|
|
152
156
|
|
|
153
157
|
After successful authentication, `mapUserToResourceId` is called with the authenticated user object. The returned value is set as `MASTRA_RESOURCE_ID_KEY` on the request context, which works across all server adapters (Hono, Express, Next.js, etc.).
|
|
154
158
|
|
|
159
|
+
When configured, the callback must return a non-empty string. If it throws or returns `null`, `undefined`, an empty or whitespace-only string, or a non-string value, authentication middleware rejects the request with a 500 error before the route runs. This applies to all requests that run authentication, including non-memory routes. A client-provided resource ID can't override a failed mapping.
|
|
160
|
+
|
|
161
|
+
With `CompositeAuth`, this requirement applies to the provider that authenticated the request. A provider without a mapper keeps its existing behavior, even if another provider in the composite has one. The same validation applies to configured Studio auth mappers.
|
|
162
|
+
|
|
163
|
+
Without a mapper, authentication doesn't enable user isolation: you're responsible for setting a trusted resource ID in middleware or otherwise enforcing authorization.
|
|
164
|
+
|
|
155
165
|
The resource ID doesn't have to be `user.id`. Common patterns:
|
|
156
166
|
|
|
157
167
|
```typescript
|
|
158
|
-
//
|
|
168
|
+
// Per-user within an organization
|
|
159
169
|
mapUserToResourceId: user => `${user.orgId}:${user.id}`
|
|
160
170
|
|
|
161
171
|
// From a JWT claim
|
|
@@ -167,12 +177,12 @@ mapUserToResourceId: user => `${user.workspaceId}:${user.projectId}:${user.id}`
|
|
|
167
177
|
|
|
168
178
|
With a resource ID set, the server automatically:
|
|
169
179
|
|
|
170
|
-
- **Filters thread listing** to only return threads
|
|
171
|
-
- **Validates thread access** and returns 403 if accessing
|
|
172
|
-
- **Forces thread creation** to use the
|
|
173
|
-
- **Validates message operations** including deletion, ensuring messages belong to
|
|
180
|
+
- **Filters thread listing** to only return threads in the configured resource scope
|
|
181
|
+
- **Validates thread access** and returns 403 if accessing a thread belonging to a different resource
|
|
182
|
+
- **Forces thread creation** to use the configured resource ID
|
|
183
|
+
- **Validates message operations** including deletion, ensuring messages belong to threads in the configured resource scope
|
|
174
184
|
|
|
175
|
-
Even if a client passes `?resourceId=other-
|
|
185
|
+
Even if a client passes `?resourceId=other-resource-id`, the server-set value takes precedence. Attempts to access threads or messages belonging to a different resource return a 403 error. Users mapped to the same resource ID share that resource scope.
|
|
176
186
|
|
|
177
187
|
#### Advanced: Setting resource ID in middleware
|
|
178
188
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# PubSub
|
|
6
6
|
|
|
7
|
-
Mastra uses a publish/subscribe (pub/sub) system as its internal event bus. Components publish events to topics, and other components subscribe to those topics to react. The backend
|
|
7
|
+
Mastra uses a publish/subscribe (pub/sub) system as its internal event bus. Components publish events to topics, and other components subscribe to those topics to react. The backend determines whether events are delivered within a single process, between processes on one host, or across separate instances.
|
|
8
8
|
|
|
9
9
|
Set the backend once on the `Mastra` instance for use throughout the system. The default is an in-process backend that requires no setup.
|
|
10
10
|
|
|
@@ -259,7 +259,7 @@ Visit [createTool()](https://mastra.ai/reference/tools/create-tool) for a full l
|
|
|
259
259
|
|
|
260
260
|
## Reserved keys
|
|
261
261
|
|
|
262
|
-
Mastra reserves special context keys for
|
|
262
|
+
Mastra reserves special context keys for the server to read. The resource and thread keys take precedence over client-provided values: the server validates ownership and returns 403 errors when users attempt to access resources they don't own.
|
|
263
263
|
|
|
264
264
|
The easiest way to set `MASTRA_RESOURCE_ID_KEY` is via the `mapUserToResourceId` callback in auth config:
|
|
265
265
|
|
|
@@ -284,10 +284,11 @@ requestContext.set(MASTRA_RESOURCE_ID_KEY, user.id)
|
|
|
284
284
|
requestContext.set(MASTRA_THREAD_ID_KEY, threadId)
|
|
285
285
|
```
|
|
286
286
|
|
|
287
|
-
| Key
|
|
288
|
-
|
|
|
289
|
-
| `MASTRA_RESOURCE_ID_KEY`
|
|
290
|
-
| `MASTRA_THREAD_ID_KEY`
|
|
287
|
+
| Key | Purpose |
|
|
288
|
+
| --------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
289
|
+
| `MASTRA_RESOURCE_ID_KEY` | Forces all memory operations to use this resource ID. The server validates that accessed threads belong to this resource and returns 403 if not. |
|
|
290
|
+
| `MASTRA_THREAD_ID_KEY` | Forces thread operations to use this thread ID, overriding client-provided values |
|
|
291
|
+
| `MASTRA_MESSAGE_AUTHOR_KEY` | Names who sent a user message as `{ id, name?, avatarUrl? }`. Agent-controller sessions copy it onto every message the request sends as `providerMetadata.mastra.author`, so a thread shared by several people can show who wrote what. |
|
|
291
292
|
|
|
292
293
|
These keys are used to implement user isolation in multi-tenant applications. See [Authorization middleware](https://mastra.ai/docs/server/middleware) for usage examples.
|
|
293
294
|
|
|
@@ -503,6 +504,7 @@ requestContextSchema: z.object({
|
|
|
503
504
|
|
|
504
505
|
## Related
|
|
505
506
|
|
|
507
|
+
- [Agent lifecycle](https://mastra.ai/docs/guides/agent-lifecycle): Understand when context values become visible during an agent run
|
|
506
508
|
- [Agent Request Context](https://mastra.ai/docs/memory/overview)
|
|
507
509
|
- [Workflow Request Context](https://mastra.ai/docs/workflows/overview)
|
|
508
510
|
- [Server Middleware](https://mastra.ai/docs/server/middleware)
|
|
@@ -67,7 +67,7 @@ Use [Agent Builder](https://agent-builder.mastra.ai) to create and manage fully
|
|
|
67
67
|
|
|
68
68
|
Visualize your workflow as a graph and run it step by step with a custom input. During execution, the interface updates in real time to show the active step and the path taken.
|
|
69
69
|
|
|
70
|
-
|
|
70
|
+
Workflow traces show tool calls and raw JSON outputs, along with any execution errors.
|
|
71
71
|
|
|
72
72
|
### Processors
|
|
73
73
|
|
|
@@ -332,8 +332,6 @@ export const testWorkflow = createWorkflow({
|
|
|
332
332
|
|
|
333
333
|
When using `.then()`, `.parallel()`, or `.branch()`, it's sometimes necessary to transform the output of a previous step to match the input of the next. In these cases you can use `.map()` to access the `inputData` and transform it to create a suitable data shape for the next step.
|
|
334
334
|
|
|
335
|
-

|
|
336
|
-
|
|
337
335
|
```typescript
|
|
338
336
|
const step1 = createStep({...});
|
|
339
337
|
const step2 = createStep({...});
|
|
@@ -439,8 +437,6 @@ Workflows support different looping methods that let you repeat steps until or w
|
|
|
439
437
|
|
|
440
438
|
Use `.dountil()` to run a step repeatedly until a condition becomes true.
|
|
441
439
|
|
|
442
|
-

|
|
443
|
-
|
|
444
440
|
```typescript
|
|
445
441
|
const step1 = createStep({...});
|
|
446
442
|
|
|
@@ -463,8 +459,6 @@ export const testWorkflow = createWorkflow({})
|
|
|
463
459
|
|
|
464
460
|
Use `.dowhile()` to run a step repeatedly while a condition remains true.
|
|
465
461
|
|
|
466
|
-

|
|
467
|
-
|
|
468
462
|
```typescript
|
|
469
463
|
const step1 = createStep({...});
|
|
470
464
|
|
|
@@ -487,8 +481,6 @@ export const testWorkflow = createWorkflow({})
|
|
|
487
481
|
|
|
488
482
|
Use `.foreach()` to run the same step for each item in an array. The input must be of type `array` so the loop can iterate over its values, applying the step's logic to each one. See [Choosing the right pattern](#choosing-the-right-pattern) for guidance on when to use `.foreach()` vs other methods.
|
|
489
483
|
|
|
490
|
-

|
|
491
|
-
|
|
492
484
|
```typescript
|
|
493
485
|
const step1 = createStep({
|
|
494
486
|
inputSchema: z.string(),
|
|
@@ -95,7 +95,13 @@ export const mastra = new Mastra({
|
|
|
95
95
|
})
|
|
96
96
|
```
|
|
97
97
|
|
|
98
|
-
When the agent runs a CLI command
|
|
98
|
+
When the agent runs a browser CLI command, Mastra automatically launches Chrome, passes the CDP connection to the CLI, and starts streaming the screencast to Studio. For Browser Use, the agent can pass Python through stdin:
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
browser-use <<'PY'
|
|
102
|
+
print("Connected to the managed browser")
|
|
103
|
+
PY
|
|
104
|
+
```
|
|
99
105
|
|
|
100
106
|
## How it works
|
|
101
107
|
|
|
@@ -133,7 +139,9 @@ pip install browser-use
|
|
|
133
139
|
npx skills add browser-use/browser-use --skill browser-use
|
|
134
140
|
```
|
|
135
141
|
|
|
136
|
-
|
|
142
|
+
For direct stdin invocations (`browser-use`, `browseruse`, `browser`, or `bu`, optionally followed by `<` redirection or a heredoc), Mastra sets `BU_CDP_WS` to the managed browser's CDP URL and `BU_NAME` to a stable daemon name. The name is unique to the thread and browser endpoint, so repeated calls reuse the same daemon while different threads or endpoints stay isolated. Mastra preserves the stdin script without adding CLI arguments.
|
|
143
|
+
|
|
144
|
+
Legacy subcommands retain `--cdp-url` and `--session` injection for compatibility. These flags aren't added to stdin invocations.
|
|
137
145
|
|
|
138
146
|
### `browse`
|
|
139
147
|
|
|
@@ -72,10 +72,13 @@ You'll need:
|
|
|
72
72
|
kubectl create secret generic mastra-app-env -n mastra \
|
|
73
73
|
--from-literal=DATABASE_URL='postgresql://user:pass@host:5432/mastra' \
|
|
74
74
|
--from-literal=MASTRA_EE_LICENSE='<your-license-key>' \
|
|
75
|
-
--from-literal=OPENAI_API_KEY='<provider-key>'
|
|
75
|
+
--from-literal=OPENAI_API_KEY='<provider-key>' \
|
|
76
|
+
--from-literal=CLICKHOUSE_URL='https://your-instance.clickhouse.cloud:8443' \
|
|
77
|
+
--from-literal=CLICKHOUSE_USERNAME='<clickhouse-username>' \
|
|
78
|
+
--from-literal=CLICKHOUSE_PASSWORD='<clickhouse-password>'
|
|
76
79
|
```
|
|
77
80
|
|
|
78
|
-
Include any other environment variables your agents need, such as model provider API keys.
|
|
81
|
+
Include any other environment variables your agents need, such as model provider API keys. Omit the `CLICKHOUSE_*` variables unless you use ClickHouse for observability.
|
|
79
82
|
|
|
80
83
|
3. Create a values file pointing the chart at your image and secret:
|
|
81
84
|
|
|
@@ -259,6 +262,14 @@ mastra-server:
|
|
|
259
262
|
|
|
260
263
|
Put `S3_ACCESS_KEY_ID` and `S3_SECRET_ACCESS_KEY` in your existing Secret rather than in values. On EKS and GKE, prefer IRSA or Workload Identity over static keys.
|
|
261
264
|
|
|
265
|
+
## ClickHouse observability
|
|
266
|
+
|
|
267
|
+
To persist traces, logs, metrics, scores, and feedback in ClickHouse, add `CLICKHOUSE_URL`, `CLICKHOUSE_USERNAME`, and `CLICKHOUSE_PASSWORD` to the Secret that `mastra-server.existingSecret` references. The Secret example above includes those variables for ClickHouse Cloud.
|
|
268
|
+
|
|
269
|
+
The chart makes the variables available to your application. It doesn't configure observability or send telemetry by itself. Configure `ObservabilityStorageClickhouseVNext` for the `observability` storage domain and add `MastraStorageExporter` to your Mastra application. See [ClickHouse](https://mastra.ai/integrations/databases/clickhouse) for the complete application configuration.
|
|
270
|
+
|
|
271
|
+
When you enable `mastra-workers`, worker pods mount the Server's Secret. If you install the `mastra-workers` chart separately, set `mastra-workers.server.existingSecret` to the same Secret name. The `mastra-projects` chart verifies that the names match.
|
|
272
|
+
|
|
262
273
|
## Scale server replicas
|
|
263
274
|
|
|
264
275
|
The chart starts one Server replica by default. A HorizontalPodAutoscaler can add pods, but it doesn't make Mastra's in-process state available across them.
|
|
@@ -53,13 +53,13 @@ You'll pass the Mastra instance exported from `src/mastra/index.ts` to the serve
|
|
|
53
53
|
|
|
54
54
|
## Configure Vite and Nitro
|
|
55
55
|
|
|
56
|
-
Update `vite.config.ts` so Vite and Nitro leave DuckDB's
|
|
56
|
+
Update `vite.config.ts` so Vite and Nitro leave DuckDB's and `@mastra/core`'s Node-only dependencies out of their processing pipelines:
|
|
57
57
|
|
|
58
58
|
```diff
|
|
59
59
|
const config = defineConfig({
|
|
60
60
|
resolve: { tsconfigPaths: true },
|
|
61
61
|
+ optimizeDeps: {
|
|
62
|
-
+ exclude: ['@mastra/duckdb'],
|
|
62
|
+
+ exclude: ['@mastra/duckdb', 'execa'],
|
|
63
63
|
+ },
|
|
64
64
|
plugins: [
|
|
65
65
|
devtools(),
|
|
@@ -71,7 +71,7 @@ const config = defineConfig({
|
|
|
71
71
|
+ }),
|
|
72
72
|
```
|
|
73
73
|
|
|
74
|
-
The `optimizeDeps.exclude` setting prevents Vite's development optimizer from opening DuckDB's native `.node` binary as JavaScript. Adding `/^@duckdb\//` to Nitro's `rollupConfig.external` keeps DuckDB's native Node packages out of the production bundle so Node.js can load them at runtime.
|
|
74
|
+
The `optimizeDeps.exclude` setting prevents Vite's development optimizer from opening DuckDB's native `.node` binary as JavaScript. Excluding `execa` stops the optimizer from pre-bundling the server-only dependency `@mastra/core` uses for local process execution; its transitive `npm-run-path` and `unicorn-magic` packages use Node-only conditional exports that the optimizer cannot resolve in the browser build. Adding `/^@duckdb\//` to Nitro's `rollupConfig.external` keeps DuckDB's native Node packages out of the production bundle so Node.js can load them at runtime.
|
|
75
75
|
|
|
76
76
|
These changes apply only to `vite.config.ts`; you don't need to change your application or Mastra source files.
|
|
77
77
|
|
|
@@ -216,10 +216,13 @@ const tracingOptions = {
|
|
|
216
216
|
|
|
217
217
|
This example produces `langfuse.trace.metadata.customerId` and `langfuse.trace.metadata.tier`.
|
|
218
218
|
|
|
219
|
+
Metadata on the root span is also forwarded. Mastra sets `runId` and `resourceId` on every agent and workflow root span, and you can add your own keys through `tracingOptions.metadata`. The exporter forwards each of these root span keys to `langfuse.trace.metadata.<key>`. Keys that map to a dedicated Langfuse field (`userId`, `sessionId`, `threadId`, `traceName`, and `version`) are not duplicated as trace metadata. Metadata on child spans stays on the observation and never changes the trace.
|
|
220
|
+
|
|
219
221
|
Notes:
|
|
220
222
|
|
|
221
223
|
- The reserved `prompt` key is used for [prompt linking](#prompt-linking) and isn't forwarded as trace metadata.
|
|
222
224
|
- The reserved identity keys `agentId`, `agentName`, `workflowId`, and `workflowName` are set from the root span and take precedence over custom values with the same name.
|
|
225
|
+
- Keys under `langfuse` take precedence over root span metadata with the same name.
|
|
223
226
|
- Values are sent as strings, because Langfuse maps trace metadata attributes as strings. Numbers, booleans, and objects are serialized with JSON. Langfuse Cloud restores them to their original types on ingestion.
|
|
224
227
|
|
|
225
228
|
## Prompt linking
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Parallel
|
|
6
6
|
|
|
7
|
-
The `@mastra/parallel` package exposes [Parallel Search](https://docs.parallel.ai/search/search-quickstart) and [Extract](https://docs.parallel.ai/
|
|
7
|
+
The `@mastra/parallel` package exposes [Parallel Search](https://docs.parallel.ai/search/search-quickstart) and [Extract](https://docs.parallel.ai/extract/extract-quickstart) as Mastra-compatible tools. Each factory returns a tool created with [`createTool()`](https://mastra.ai/reference/tools/create-tool) and a typed Zod input and output schema.
|
|
8
8
|
|
|
9
9
|
## Installation
|
|
10
10
|
|
|
@@ -238,5 +238,5 @@ export const researchAgent = new Agent({
|
|
|
238
238
|
## Related
|
|
239
239
|
|
|
240
240
|
- [Parallel Search documentation](https://docs.parallel.ai/search/search-quickstart)
|
|
241
|
-
- [Parallel Extract documentation](https://docs.parallel.ai/
|
|
241
|
+
- [Parallel Extract documentation](https://docs.parallel.ai/extract/extract-quickstart)
|
|
242
242
|
- [`createTool()` reference](https://mastra.ai/reference/tools/create-tool)
|
|
@@ -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 181 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
|
|
|
@@ -95,6 +95,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
95
95
|
| `google/gemini-flash-lite-latest` |
|
|
96
96
|
| `google/gemma-4-26b-a4b-it` |
|
|
97
97
|
| `google/gemma-4-31b-it` |
|
|
98
|
+
| `meta/llama-3.1-70b-instruct` |
|
|
98
99
|
| `meta/llama-3.1-8b-instruct` |
|
|
99
100
|
| `meta/llama-3.3-70b-instruct` |
|
|
100
101
|
| `meta/muse-spark-1.1` |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
# Neon
|
|
6
6
|
|
|
7
|
-
Neon aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
7
|
+
Neon aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 46 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [Neon documentation](https://neon.com/docs).
|
|
10
10
|
|
|
@@ -36,6 +36,7 @@ NEON_AI_GATEWAY_TOKEN=your-gateway-key
|
|
|
36
36
|
| Model |
|
|
37
37
|
| ----------------------------- |
|
|
38
38
|
| `claude-fable-5` |
|
|
39
|
+
| `claude-fable-5-1` |
|
|
39
40
|
| `claude-haiku-4-5` |
|
|
40
41
|
| `claude-opus-4-1` |
|
|
41
42
|
| `claude-opus-4-5` |
|
|
@@ -54,6 +55,7 @@ NEON_AI_GATEWAY_TOKEN=your-gateway-key
|
|
|
54
55
|
| `gemini-3-flash` |
|
|
55
56
|
| `gemma-3-12b` |
|
|
56
57
|
| `glm-5-2` |
|
|
58
|
+
| `glm-5-3-flash` |
|
|
57
59
|
| `gpt-5` |
|
|
58
60
|
| `gpt-5-1` |
|
|
59
61
|
| `gpt-5-2` |
|
|
@@ -68,8 +70,10 @@ NEON_AI_GATEWAY_TOKEN=your-gateway-key
|
|
|
68
70
|
| `gpt-5-6-terra` |
|
|
69
71
|
| `gpt-5-mini` |
|
|
70
72
|
| `gpt-5-nano` |
|
|
73
|
+
| `gpt-6-astra` |
|
|
71
74
|
| `gpt-oss-120b` |
|
|
72
75
|
| `gpt-oss-20b` |
|
|
76
|
+
| `grok-4-6` |
|
|
73
77
|
| `inkling` |
|
|
74
78
|
| `kimi-k3` |
|
|
75
79
|
| `llama-4-maverick` |
|
|
@@ -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 242 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
|
|
|
@@ -147,7 +147,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
147
147
|
| `openrouter/gryphe/mythomax-l2-13b` |
|
|
148
148
|
| `openrouter/ibm-granite/granite-4.2-8b` |
|
|
149
149
|
| `openrouter/inception/mercury-2` |
|
|
150
|
-
| `openrouter/inception/mercury-2.5
|
|
150
|
+
| `openrouter/inception/mercury-2.5` |
|
|
151
151
|
| `openrouter/inclusionai/ling-3.0-flash` |
|
|
152
152
|
| `openrouter/inclusionai/ling-3.0-flash-fin` |
|
|
153
153
|
| `openrouter/inclusionai/ling-3.0-flash-fin:free` |
|
|
@@ -279,6 +279,5 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
279
279
|
| `openrouter/z-ai/glm-5` |
|
|
280
280
|
| `openrouter/z-ai/glm-5.1` |
|
|
281
281
|
| `openrouter/z-ai/glm-5.2` |
|
|
282
|
-
| `openrouter/z-ai/glm-5.2:free` |
|
|
283
282
|
| `openrouter/z-ai/glm-5.3` |
|
|
284
283
|
| `openrouter/z-ai/glm-5.3-flash` |
|
|
@@ -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 358 models through Mastra's model router.
|
|
8
8
|
|
|
9
9
|
Learn more in the [OpenRouter documentation](https://openrouter.ai/models).
|
|
10
10
|
|
|
@@ -141,7 +141,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
141
141
|
| `ibm-granite/granite-4.0-h-micro` |
|
|
142
142
|
| `ibm-granite/granite-4.2-8b` |
|
|
143
143
|
| `inception/mercury-2` |
|
|
144
|
-
| `inception/mercury-2.5
|
|
144
|
+
| `inception/mercury-2.5` |
|
|
145
145
|
| `inclusionai/ling-3.0-flash` |
|
|
146
146
|
| `inclusionai/ling-3.0-flash-fin` |
|
|
147
147
|
| `inclusionai/ling-3.0-flash-fin:free` |
|
|
@@ -174,9 +174,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
174
174
|
| `minimax/minimax-m2.1` |
|
|
175
175
|
| `minimax/minimax-m2.5` |
|
|
176
176
|
| `minimax/minimax-m2.7` |
|
|
177
|
-
| `minimax/minimax-m2.7:free` |
|
|
178
177
|
| `minimax/minimax-m3` |
|
|
179
|
-
| `minimax/minimax-m3:free` |
|
|
180
178
|
| `mistralai/codestral-2508` |
|
|
181
179
|
| `mistralai/devstral-2512` |
|
|
182
180
|
| `mistralai/ministral-14b-2512` |
|
|
@@ -205,8 +203,8 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
205
203
|
| `moonshotai/kimi-k3` |
|
|
206
204
|
| `morph/morph-v3-fast` |
|
|
207
205
|
| `morph/morph-v3-large` |
|
|
208
|
-
| `nex-agi/nex-n2-mini`
|
|
209
|
-
| `nex-agi/nex-n2-pro`
|
|
206
|
+
| `nex-agi/nex-n2.5-mini:free` |
|
|
207
|
+
| `nex-agi/nex-n2.5-pro:free` |
|
|
210
208
|
| `nousresearch/hermes-3-llama-3.1-405b` |
|
|
211
209
|
| `nousresearch/hermes-3-llama-3.1-70b` |
|
|
212
210
|
| `nousresearch/hermes-4-405b` |
|
|
@@ -346,7 +344,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
346
344
|
| `qwen/qwen3.8-2.4t-a95b` |
|
|
347
345
|
| `qwen/qwen3.8-27b` |
|
|
348
346
|
| `qwen/qwen3.8-flash` |
|
|
349
|
-
| `qwen/qwen3.8-max`
|
|
347
|
+
| `qwen/qwen3.8-max-0902` |
|
|
350
348
|
| `rekaai/reka-edge` |
|
|
351
349
|
| `rekaai/reka-flash-3` |
|
|
352
350
|
| `relace/relace-apply-3` |
|
|
@@ -395,7 +393,6 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
395
393
|
| `z-ai/glm-5-turbo` |
|
|
396
394
|
| `z-ai/glm-5.1` |
|
|
397
395
|
| `z-ai/glm-5.2` |
|
|
398
|
-
| `z-ai/glm-5.2:free` |
|
|
399
396
|
| `z-ai/glm-5.3` |
|
|
400
397
|
| `z-ai/glm-5.3-flash` |
|
|
401
398
|
| `z-ai/glm-5v-turbo` |
|
|
@@ -143,6 +143,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
143
143
|
| `deepseek/deepseek-v4-flash-vision-exp` |
|
|
144
144
|
| `deepseek/deepseek-v4-pro` |
|
|
145
145
|
| `deepseek/deepseek-v4-pro-0813` |
|
|
146
|
+
| `deepseek/deepseek-v4.1-flash-beta` |
|
|
146
147
|
| `fish-audio/s1` |
|
|
147
148
|
| `fish-audio/s1-free` |
|
|
148
149
|
| `fish-audio/s2-pro` |
|
|
@@ -182,6 +183,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
182
183
|
| `google/veo-3.1-generate-001` |
|
|
183
184
|
| `google/veo-3.1-lite-generate-001` |
|
|
184
185
|
| `inception/mercury-2` |
|
|
186
|
+
| `inception/mercury-2.5` |
|
|
185
187
|
| `inception/mercury-coder-small` |
|
|
186
188
|
| `inclusionai/ling-3.0-flash` |
|
|
187
189
|
| `inclusionai/ling-3.0-flash-fin` |
|
|
@@ -221,10 +223,8 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
221
223
|
| `minimax/minimax-m2.5` |
|
|
222
224
|
| `minimax/minimax-m2.5-highspeed` |
|
|
223
225
|
| `minimax/minimax-m2.7` |
|
|
224
|
-
| `minimax/minimax-m2.7-free` |
|
|
225
226
|
| `minimax/minimax-m2.7-highspeed` |
|
|
226
227
|
| `minimax/minimax-m3` |
|
|
227
|
-
| `minimax/minimax-m3-free` |
|
|
228
228
|
| `mistral/codestral` |
|
|
229
229
|
| `mistral/codestral-embed` |
|
|
230
230
|
| `mistral/devstral-2` |
|
|
@@ -308,6 +308,8 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
308
308
|
| `openai/gpt-image-1-mini` |
|
|
309
309
|
| `openai/gpt-image-1.5` |
|
|
310
310
|
| `openai/gpt-image-2` |
|
|
311
|
+
| `openai/gpt-image-2.5-flare` |
|
|
312
|
+
| `openai/gpt-image-2.5-sunburst` |
|
|
311
313
|
| `openai/gpt-oss-120b` |
|
|
312
314
|
| `openai/gpt-oss-20b` |
|
|
313
315
|
| `openai/gpt-oss-safeguard-120b` |
|
|
@@ -393,7 +395,6 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
393
395
|
| `voyage/voyage-law-2` |
|
|
394
396
|
| `xiaomi/mimo-v2.5` |
|
|
395
397
|
| `xiaomi/mimo-v2.5-pro` |
|
|
396
|
-
| `xiaomi/mimo-v2.5-pro-ultraspeed` |
|
|
397
398
|
| `zai/glm-4.5` |
|
|
398
399
|
| `zai/glm-4.5-air` |
|
|
399
400
|
| `zai/glm-4.5v` |
|
|
@@ -409,5 +410,4 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
409
410
|
| `zai/glm-5.3` |
|
|
410
411
|
| `zai/glm-5.3-fast` |
|
|
411
412
|
| `zai/glm-5.3-flash` |
|
|
412
|
-
| `zai/glm-5.3-promo-50` |
|
|
413
413
|
| `zai/glm-5v-turbo` |
|
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 7122 models from 200 providers through a single API.
|
|
8
8
|
|
|
9
9
|
## Features
|
|
10
10
|
|