@mastra/mcp-docs-server 1.2.2-alpha.7 → 1.2.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/docs/server/auth/google.md +281 -0
- package/.docs/docs/server/auth.md +2 -1
- package/.docs/models/gateways/openrouter.md +2 -1
- package/.docs/models/gateways/vercel.md +3 -1
- package/.docs/models/index.md +1 -1
- package/.docs/models/providers/baseten.md +1 -1
- package/.docs/models/providers/berget.md +4 -3
- package/.docs/models/providers/evroc.md +19 -17
- package/.docs/models/providers/fireworks-ai.md +2 -1
- package/.docs/models/providers/friendli.md +3 -1
- package/.docs/models/providers/llmgateway.md +22 -22
- package/.docs/models/providers/minimax-cn-coding-plan.md +1 -1
- package/.docs/models/providers/minimax-cn.md +1 -1
- package/.docs/models/providers/minimax-coding-plan.md +1 -1
- package/.docs/models/providers/minimax.md +1 -1
- package/.docs/models/providers/nebius.md +3 -2
- package/.docs/models/providers/neuralwatt.md +2 -1
- package/.docs/models/providers/opencode-go.md +1 -1
- package/.docs/models/providers/ovhcloud.md +1 -2
- package/.docs/models/providers/scaleway.md +2 -1
- package/.docs/models/providers/stepfun.md +3 -2
- package/.docs/models/providers/togetherai.md +3 -2
- package/.docs/models/providers/xiaomi-token-plan-ams.md +4 -6
- package/.docs/models/providers/xiaomi-token-plan-cn.md +4 -6
- package/.docs/models/providers/xiaomi-token-plan-sgp.md +4 -6
- package/.docs/models/providers/xiaomi.md +4 -7
- package/.docs/reference/agents/durable-agent.md +30 -3
- package/.docs/reference/auth/google.md +355 -0
- package/.docs/reference/index.md +1 -0
- package/CHANGELOG.md +28 -0
- package/package.json +5 -5
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
# Google
|
|
2
|
+
|
|
3
|
+
The `@mastra/auth-google` package provides authentication and role-based access control for Mastra using Google Workspace. It supports an OAuth 2.0 / OIDC login flow with encrypted session cookies, verifies Google ID tokens, and maps Google Workspace groups to Mastra permissions.
|
|
4
|
+
|
|
5
|
+
Use it when your Studio users sign in with Google and access should be limited to one or more Google Workspace domains.
|
|
6
|
+
|
|
7
|
+
## Prerequisites
|
|
8
|
+
|
|
9
|
+
This guide uses Google Workspace authentication. Make sure to:
|
|
10
|
+
|
|
11
|
+
1. Create or select a Google Cloud project
|
|
12
|
+
2. Set up an OAuth client for web applications
|
|
13
|
+
3. Add your Mastra SSO callback URL to the authorized redirect URIs
|
|
14
|
+
4. Configure Google Workspace groups if you plan to use RBAC
|
|
15
|
+
|
|
16
|
+
For Google Groups RBAC, also configure a Google Workspace service account with domain-wide delegation and grant it the Directory API read-only group scope:
|
|
17
|
+
|
|
18
|
+
```text
|
|
19
|
+
https://www.googleapis.com/auth/admin.directory.group.readonly
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Make sure your environment variables are set.
|
|
23
|
+
|
|
24
|
+
```env
|
|
25
|
+
GOOGLE_CLIENT_ID=your-client-id.apps.googleusercontent.com
|
|
26
|
+
GOOGLE_CLIENT_SECRET=your-client-secret
|
|
27
|
+
GOOGLE_REDIRECT_URI=http://localhost:4111/api/auth/sso/callback
|
|
28
|
+
GOOGLE_COOKIE_PASSWORD=a-random-string-at-least-32-characters-long
|
|
29
|
+
GOOGLE_ALLOWED_DOMAINS=example.com
|
|
30
|
+
|
|
31
|
+
GOOGLE_SERVICE_ACCOUNT_EMAIL=service-account@project.iam.gserviceaccount.com
|
|
32
|
+
GOOGLE_SERVICE_ACCOUNT_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n"
|
|
33
|
+
GOOGLE_WORKSPACE_ADMIN_EMAIL=admin@example.com
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
> **Note:** `GOOGLE_COOKIE_PASSWORD` encrypts session cookies. If omitted, an auto-generated value is used that doesn't survive server restarts. Set it explicitly for production.
|
|
37
|
+
>
|
|
38
|
+
> `MastraAuthGoogle` reads the `GOOGLE_*` auth variables automatically. The service-account variables shown above are read by the configuration code you pass to `MastraRBACGoogle`.
|
|
39
|
+
|
|
40
|
+
## Installation
|
|
41
|
+
|
|
42
|
+
Before you can use the `MastraAuthGoogle` class, install the `@mastra/auth-google` package.
|
|
43
|
+
|
|
44
|
+
**npm**:
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
npm install @mastra/auth-google
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
**pnpm**:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
pnpm add @mastra/auth-google
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
**Yarn**:
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
yarn add @mastra/auth-google
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
**Bun**:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
bun add @mastra/auth-google
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Usage examples
|
|
69
|
+
|
|
70
|
+
### Basic usage with environment variables
|
|
71
|
+
|
|
72
|
+
With the environment variables above set, all constructor parameters are optional:
|
|
73
|
+
|
|
74
|
+
```typescript
|
|
75
|
+
import { Mastra } from '@mastra/core'
|
|
76
|
+
import { MastraAuthGoogle } from '@mastra/auth-google'
|
|
77
|
+
|
|
78
|
+
export const mastra = new Mastra({
|
|
79
|
+
server: {
|
|
80
|
+
auth: new MastraAuthGoogle(),
|
|
81
|
+
},
|
|
82
|
+
})
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
> **Warning:** Use `allowedDomains` or `GOOGLE_ALLOWED_DOMAINS` to enforce Workspace access. Mastra checks Google's verified `hd` claim, not the email address suffix.
|
|
86
|
+
|
|
87
|
+
### Custom configuration
|
|
88
|
+
|
|
89
|
+
Pass constructor options directly if you don't want to rely on environment variables:
|
|
90
|
+
|
|
91
|
+
```typescript
|
|
92
|
+
import { Mastra } from '@mastra/core'
|
|
93
|
+
import { MastraAuthGoogle } from '@mastra/auth-google'
|
|
94
|
+
|
|
95
|
+
export const mastra = new Mastra({
|
|
96
|
+
server: {
|
|
97
|
+
auth: new MastraAuthGoogle({
|
|
98
|
+
clientId: process.env.GOOGLE_CLIENT_ID,
|
|
99
|
+
clientSecret: process.env.GOOGLE_CLIENT_SECRET,
|
|
100
|
+
redirectUri: process.env.GOOGLE_REDIRECT_URI,
|
|
101
|
+
allowedDomains: ['example.com'],
|
|
102
|
+
}),
|
|
103
|
+
},
|
|
104
|
+
})
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
### Auth with Google Groups RBAC
|
|
108
|
+
|
|
109
|
+
Add `MastraRBACGoogle` to map Google Workspace groups to Mastra permissions:
|
|
110
|
+
|
|
111
|
+
```typescript
|
|
112
|
+
import { Mastra } from '@mastra/core'
|
|
113
|
+
import { MastraAuthGoogle, MastraRBACGoogle } from '@mastra/auth-google'
|
|
114
|
+
|
|
115
|
+
export const mastra = new Mastra({
|
|
116
|
+
server: {
|
|
117
|
+
auth: new MastraAuthGoogle(),
|
|
118
|
+
rbac: new MastraRBACGoogle({
|
|
119
|
+
serviceAccount: {
|
|
120
|
+
clientEmail: process.env.GOOGLE_SERVICE_ACCOUNT_EMAIL!,
|
|
121
|
+
privateKey: process.env.GOOGLE_SERVICE_ACCOUNT_PRIVATE_KEY!,
|
|
122
|
+
subject: process.env.GOOGLE_WORKSPACE_ADMIN_EMAIL!,
|
|
123
|
+
},
|
|
124
|
+
roleMapping: {
|
|
125
|
+
'admins@example.com': ['*'],
|
|
126
|
+
'engineering@example.com': ['agents:*', 'workflows:*', 'tools:*'],
|
|
127
|
+
'viewers@example.com': ['agents:read', 'workflows:read'],
|
|
128
|
+
_default: [], // users with unmapped groups get no permissions
|
|
129
|
+
},
|
|
130
|
+
}),
|
|
131
|
+
},
|
|
132
|
+
})
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
### Cross-provider usage
|
|
136
|
+
|
|
137
|
+
Use a different auth provider (Auth0, Clerk, etc.) for login and Google Workspace groups for RBAC. Pass a `getUserKey` function to resolve the Google Directory API user key from the other provider's user object:
|
|
138
|
+
|
|
139
|
+
```typescript
|
|
140
|
+
import { Mastra } from '@mastra/core'
|
|
141
|
+
import { MastraAuthAuth0 } from '@mastra/auth-auth0'
|
|
142
|
+
import { MastraRBACGoogle } from '@mastra/auth-google'
|
|
143
|
+
|
|
144
|
+
export const mastra = new Mastra({
|
|
145
|
+
server: {
|
|
146
|
+
auth: new MastraAuthAuth0(),
|
|
147
|
+
rbac: new MastraRBACGoogle({
|
|
148
|
+
getUserKey: user => {
|
|
149
|
+
if (!user || typeof user !== 'object') return undefined
|
|
150
|
+
|
|
151
|
+
const { email } = user as { email?: unknown }
|
|
152
|
+
return typeof email === 'string' ? email : undefined
|
|
153
|
+
},
|
|
154
|
+
serviceAccount: {
|
|
155
|
+
clientEmail: process.env.GOOGLE_SERVICE_ACCOUNT_EMAIL!,
|
|
156
|
+
privateKey: process.env.GOOGLE_SERVICE_ACCOUNT_PRIVATE_KEY!,
|
|
157
|
+
subject: process.env.GOOGLE_WORKSPACE_ADMIN_EMAIL!,
|
|
158
|
+
},
|
|
159
|
+
roleMapping: {
|
|
160
|
+
'engineering@example.com': ['agents:*', 'workflows:*'],
|
|
161
|
+
'admins@example.com': ['*'],
|
|
162
|
+
_default: [],
|
|
163
|
+
},
|
|
164
|
+
}),
|
|
165
|
+
},
|
|
166
|
+
})
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
> **Info:** Visit [MastraAuthGoogle](https://mastra.ai/reference/auth/google) for all available configuration options.
|
|
170
|
+
|
|
171
|
+
## Role mapping
|
|
172
|
+
|
|
173
|
+
The `roleMapping` option maps Google Workspace group email addresses to arrays of Mastra permission strings. Permissions follow a `resource:action` pattern and support wildcards:
|
|
174
|
+
|
|
175
|
+
```typescript
|
|
176
|
+
const rbac = new MastraRBACGoogle({
|
|
177
|
+
roleMapping: {
|
|
178
|
+
// full access to everything
|
|
179
|
+
'admins@example.com': ['*'],
|
|
180
|
+
|
|
181
|
+
// full access to agents and workflows
|
|
182
|
+
'engineering@example.com': ['agents:*', 'workflows:*'],
|
|
183
|
+
|
|
184
|
+
// read-only access
|
|
185
|
+
'viewers@example.com': ['agents:read', 'workflows:read'],
|
|
186
|
+
|
|
187
|
+
// users whose groups don't match any key above
|
|
188
|
+
_default: [],
|
|
189
|
+
},
|
|
190
|
+
})
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
Group email addresses are used as role IDs by default. Use `mapGroupToRoles` if you want to map by group name or another property. The `_default` key assigns permissions to users whose Google Workspace groups don't match any other key.
|
|
194
|
+
|
|
195
|
+
## Client-side setup
|
|
196
|
+
|
|
197
|
+
When auth is enabled, requests to Mastra routes require authentication. When SSO is enabled with `GOOGLE_CLIENT_SECRET`, `MastraAuthGoogle` uses Google sign-in and sets an encrypted session cookie after login.
|
|
198
|
+
|
|
199
|
+
### Cookie session (recommended)
|
|
200
|
+
|
|
201
|
+
For cross-origin requests (for example, a frontend on `:3000` calling Mastra on `:4111`), enable CORS credentials on the Mastra server:
|
|
202
|
+
|
|
203
|
+
```typescript
|
|
204
|
+
export const mastra = new Mastra({
|
|
205
|
+
server: {
|
|
206
|
+
auth: new MastraAuthGoogle(),
|
|
207
|
+
cors: {
|
|
208
|
+
origin: 'http://localhost:3000',
|
|
209
|
+
credentials: true,
|
|
210
|
+
},
|
|
211
|
+
},
|
|
212
|
+
})
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
Configure the client to include credentials:
|
|
216
|
+
|
|
217
|
+
```typescript
|
|
218
|
+
import { MastraClient } from '@mastra/client-js'
|
|
219
|
+
|
|
220
|
+
export const mastraClient = new MastraClient({
|
|
221
|
+
baseUrl: 'http://localhost:4111',
|
|
222
|
+
credentials: 'include',
|
|
223
|
+
})
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
### Bearer token
|
|
227
|
+
|
|
228
|
+
You can also pass a Google ID token as a Bearer token. Mastra verifies the token against Google's JSON Web Key Set (JWKS) endpoint:
|
|
229
|
+
|
|
230
|
+
```typescript
|
|
231
|
+
import { MastraClient } from '@mastra/client-js'
|
|
232
|
+
|
|
233
|
+
export const createMastraClient = (idToken: string) => {
|
|
234
|
+
return new MastraClient({
|
|
235
|
+
baseUrl: 'http://localhost:4111',
|
|
236
|
+
headers: {
|
|
237
|
+
Authorization: `Bearer ${idToken}`,
|
|
238
|
+
},
|
|
239
|
+
})
|
|
240
|
+
}
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
> **Info:** Visit [Mastra Client SDK](https://mastra.ai/docs/server/mastra-client) for more configuration options.
|
|
244
|
+
|
|
245
|
+
### Making authenticated requests
|
|
246
|
+
|
|
247
|
+
**MastraClient**:
|
|
248
|
+
|
|
249
|
+
```typescript
|
|
250
|
+
import { mastraClient } from '../lib/mastra-client'
|
|
251
|
+
|
|
252
|
+
const agent = mastraClient.getAgent('weatherAgent')
|
|
253
|
+
const response = await agent.generate('Weather in London')
|
|
254
|
+
console.log(response)
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
**cURL**:
|
|
258
|
+
|
|
259
|
+
```bash
|
|
260
|
+
curl -X POST http://localhost:4111/api/agents/weatherAgent/generate \
|
|
261
|
+
-H "Content-Type: application/json" \
|
|
262
|
+
-H "Authorization: Bearer <your-google-id-token>" \
|
|
263
|
+
-d '{
|
|
264
|
+
"messages": "Weather in London"
|
|
265
|
+
}'
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
## Troubleshooting
|
|
269
|
+
|
|
270
|
+
- **401 after sign-in**: Check that `GOOGLE_CLIENT_ID`, `GOOGLE_CLIENT_SECRET`, and `GOOGLE_REDIRECT_URI` match the Google Cloud OAuth client.
|
|
271
|
+
- **Workspace users are rejected**: Verify `GOOGLE_ALLOWED_DOMAINS` matches the Google ID token `hd` claim.
|
|
272
|
+
- **Consumer Gmail accounts are rejected**: This is expected when `allowedDomains` is configured because Gmail accounts don't have a Workspace `hd` claim.
|
|
273
|
+
- **RBAC returns default permissions**: No roles were resolved for the user. Verify the user email or custom `getUserKey`, Google group membership, and `roleMapping`. If the Directory API lookup fails, the provider throws an error instead of returning `_default`.
|
|
274
|
+
- **Cookies are not sent cross-origin**: Set `credentials: "include"` in `MastraClient` and configure `server.cors` with your frontend origin and `credentials: true`.
|
|
275
|
+
- **Session lost on restart**: Set `GOOGLE_COOKIE_PASSWORD` to a stable value of at least 32 characters. Without it, an auto-generated key is used in development and changes on each restart.
|
|
276
|
+
|
|
277
|
+
## Related
|
|
278
|
+
|
|
279
|
+
- [Auth overview](https://mastra.ai/docs/server/auth)
|
|
280
|
+
- [Composite Auth](https://mastra.ai/docs/server/auth/composite-auth)
|
|
281
|
+
- [MastraAuthGoogle reference](https://mastra.ai/reference/auth/google)
|
|
@@ -15,7 +15,7 @@ Authentication is optional. If no auth is configured, all routes and Studio are
|
|
|
15
15
|
|
|
16
16
|
See [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes) for controlling authentication on custom endpoints. Visit the [Studio Auth docs](https://mastra.ai/docs/studio/auth) for more on securing your Studio deployment.
|
|
17
17
|
|
|
18
|
-
> **Note:** Authentication for Studio is currently supported by the following providers: Simple Auth, JWT, WorkOS,
|
|
18
|
+
> **Note:** Authentication for Studio is currently supported by the following providers: Simple Auth, JWT, WorkOS, Better Auth, and Google.
|
|
19
19
|
|
|
20
20
|
## Available providers
|
|
21
21
|
|
|
@@ -30,6 +30,7 @@ See [Custom API Routes](https://mastra.ai/docs/server/custom-api-routes) for con
|
|
|
30
30
|
- [Better Auth](https://mastra.ai/docs/server/auth/better-auth)
|
|
31
31
|
- [Clerk](https://mastra.ai/docs/server/auth/clerk)
|
|
32
32
|
- [Firebase](https://mastra.ai/docs/server/auth/firebase)
|
|
33
|
+
- [Google](https://mastra.ai/docs/server/auth/google)
|
|
33
34
|
- [Okta](https://mastra.ai/docs/server/auth/okta)
|
|
34
35
|
- [Supabase](https://mastra.ai/docs/server/auth/supabase)
|
|
35
36
|
- [WorkOS](https://mastra.ai/docs/server/auth/workos)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# OpenRouter
|
|
2
2
|
|
|
3
|
-
OpenRouter aggregates models from multiple providers with enhanced features like rate limiting and failover. Access
|
|
3
|
+
OpenRouter aggregates models from multiple providers with enhanced features like rate limiting and failover. Access 337 models through Mastra's model router.
|
|
4
4
|
|
|
5
5
|
Learn more in the [OpenRouter documentation](https://openrouter.ai/models).
|
|
6
6
|
|
|
@@ -336,6 +336,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
336
336
|
| `rekaai/reka-flash-3` |
|
|
337
337
|
| `relace/relace-apply-3` |
|
|
338
338
|
| `relace/relace-search` |
|
|
339
|
+
| `sakana/fugu-ultra` |
|
|
339
340
|
| `sao10k/l3-lunaris-8b` |
|
|
340
341
|
| `sao10k/l3.1-70b-hanami-x1` |
|
|
341
342
|
| `sao10k/l3.1-euryale-70b` |
|
|
@@ -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 292 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
|
|
|
@@ -302,6 +302,7 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
302
302
|
| `xai/grok-build-0.1` |
|
|
303
303
|
| `xai/grok-imagine-image` |
|
|
304
304
|
| `xai/grok-imagine-video` |
|
|
305
|
+
| `xai/grok-imagine-video-1.5` |
|
|
305
306
|
| `xai/grok-imagine-video-1.5-preview` |
|
|
306
307
|
| `xai/grok-stt` |
|
|
307
308
|
| `xai/grok-tts` |
|
|
@@ -323,4 +324,5 @@ ANTHROPIC_API_KEY=ant-...
|
|
|
323
324
|
| `zai/glm-5-turbo` |
|
|
324
325
|
| `zai/glm-5.1` |
|
|
325
326
|
| `zai/glm-5.2` |
|
|
327
|
+
| `zai/glm-5.2-fast` |
|
|
326
328
|
| `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 4540 models from 133 providers through a single API.
|
|
4
4
|
|
|
5
5
|
## Features
|
|
6
6
|
|
|
@@ -34,7 +34,7 @@ for await (const chunk of stream) {
|
|
|
34
34
|
|
|
35
35
|
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
36
|
| -------------------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
-
| `baseten/deepseek-ai/DeepSeek-V4-Pro` |
|
|
37
|
+
| `baseten/deepseek-ai/DeepSeek-V4-Pro` | 262K | | | | | | $2 | $3 |
|
|
38
38
|
| `baseten/moonshotai/Kimi-K2.5` | 262K | | | | | | $0.60 | $3 |
|
|
39
39
|
| `baseten/moonshotai/Kimi-K2.6` | 262K | | | | | | $0.95 | $4 |
|
|
40
40
|
| `baseten/moonshotai/Kimi-K2.7-Code` | 262K | | | | | | $0.95 | $4 |
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Berget.AI
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 8 Berget.AI models through Mastra's model router. Authentication is handled automatically using the `BERGET_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Berget.AI documentation](https://api.berget.ai).
|
|
6
6
|
|
|
@@ -39,8 +39,9 @@ for await (const chunk of stream) {
|
|
|
39
39
|
| `berget/mistralai/Mistral-Medium-3.5-128B` | 262K | | | | | | $2 | $6 |
|
|
40
40
|
| `berget/mistralai/Mistral-Small-3.2-24B-Instruct-2506` | 32K | | | | | | $0.33 | $0.33 |
|
|
41
41
|
| `berget/moonshotai/Kimi-K2.6` | 262K | | | | | | $0.83 | $4 |
|
|
42
|
-
| `berget/openai/gpt-oss-120b` | 128K | | | | | | $0.
|
|
42
|
+
| `berget/openai/gpt-oss-120b` | 128K | | | | | | $0.22 | $0.83 |
|
|
43
43
|
| `berget/zai-org/GLM-4.7` | 128K | | | | | | $0.77 | $3 |
|
|
44
|
+
| `berget/zai-org/GLM-5.2` | 524K | | | | | | $2 | $5 |
|
|
44
45
|
|
|
45
46
|
## Advanced configuration
|
|
46
47
|
|
|
@@ -70,7 +71,7 @@ const agent = new Agent({
|
|
|
70
71
|
model: ({ requestContext }) => {
|
|
71
72
|
const useAdvanced = requestContext.task === "complex";
|
|
72
73
|
return useAdvanced
|
|
73
|
-
? "berget/zai-org/GLM-
|
|
74
|
+
? "berget/zai-org/GLM-5.2"
|
|
74
75
|
: "berget/google/gemma-4-31B-it";
|
|
75
76
|
}
|
|
76
77
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# evroc
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 15 evroc models through Mastra's model router. Authentication is handled automatically using the `EVROC_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [evroc documentation](https://docs.evroc.com/products/think/overview.html).
|
|
6
6
|
|
|
@@ -32,21 +32,23 @@ for await (const chunk of stream) {
|
|
|
32
32
|
|
|
33
33
|
## Models
|
|
34
34
|
|
|
35
|
-
| Model
|
|
36
|
-
|
|
|
37
|
-
| `evroc/
|
|
38
|
-
| `evroc/
|
|
39
|
-
| `evroc/
|
|
40
|
-
| `evroc/
|
|
41
|
-
| `evroc/mistralai/
|
|
42
|
-
| `evroc/mistralai/Voxtral-Small-24B-2507`
|
|
43
|
-
| `evroc/moonshotai/Kimi-K2.
|
|
44
|
-
| `evroc/nvidia/Llama-3.3-70B-Instruct-FP8`
|
|
45
|
-
| `evroc/openai/gpt-oss-120b`
|
|
46
|
-
| `evroc/openai/whisper-large-v3`
|
|
47
|
-
| `evroc/
|
|
48
|
-
| `evroc/Qwen/Qwen3-Embedding-8B`
|
|
49
|
-
| `evroc/Qwen/Qwen3-
|
|
35
|
+
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
|
+
| ----------------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
+
| `evroc/evroc/roc` | 262K | | | | | | $3 | $12 |
|
|
38
|
+
| `evroc/google/gemma-4-26B-A4B-it` | 262K | | | | | | $0.14 | $0.57 |
|
|
39
|
+
| `evroc/intfloat/multilingual-e5-large-instruct` | 512 | | | | | | $0.11 | $0.11 |
|
|
40
|
+
| `evroc/KBLab/kb-whisper-large` | 448 | | | | | | $0.00 | $0.00 |
|
|
41
|
+
| `evroc/mistralai/Mistral-Medium-3.5-128B` | 262K | | | | | | $2 | $7 |
|
|
42
|
+
| `evroc/mistralai/Voxtral-Small-24B-2507` | 32K | | | | | | $0.00 | $0.00 |
|
|
43
|
+
| `evroc/moonshotai/Kimi-K2.6` | 262K | | | | | | $1 | $6 |
|
|
44
|
+
| `evroc/nvidia/Llama-3.3-70B-Instruct-FP8` | 128K | | | | | | $1 | $1 |
|
|
45
|
+
| `evroc/openai/gpt-oss-120b` | 66K | | | | | | $0.23 | $0.92 |
|
|
46
|
+
| `evroc/openai/whisper-large-v3` | 448 | | | | | | $0.00 | $0.00 |
|
|
47
|
+
| `evroc/openai/whisper-large-v3-turbo` | 448 | | | | | | $0.00 | $0.00 |
|
|
48
|
+
| `evroc/Qwen/Qwen3-Embedding-8B` | 41K | | | | | | $0.12 | $0.12 |
|
|
49
|
+
| `evroc/Qwen/Qwen3-Reranker-4B` | 32K | | | | | | $0.06 | — |
|
|
50
|
+
| `evroc/Qwen/Qwen3-VL-30B-A3B-Instruct` | 100K | | | | | | $0.23 | $0.92 |
|
|
51
|
+
| `evroc/Qwen/Qwen3.6-35B-A3B-FP8` | 262K | | | | | | $0.34 | $1 |
|
|
50
52
|
|
|
51
53
|
## Advanced configuration
|
|
52
54
|
|
|
@@ -76,7 +78,7 @@ const agent = new Agent({
|
|
|
76
78
|
model: ({ requestContext }) => {
|
|
77
79
|
const useAdvanced = requestContext.task === "complex";
|
|
78
80
|
return useAdvanced
|
|
79
|
-
? "evroc/openai/whisper-large-v3"
|
|
81
|
+
? "evroc/openai/whisper-large-v3-turbo"
|
|
80
82
|
: "evroc/KBLab/kb-whisper-large";
|
|
81
83
|
}
|
|
82
84
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Fireworks AI
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 16 Fireworks AI models through Mastra's model router. Authentication is handled automatically using the `FIREWORKS_API_KEY` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Fireworks AI documentation](https://fireworks.ai/docs/).
|
|
6
6
|
|
|
@@ -46,6 +46,7 @@ for await (const chunk of stream) {
|
|
|
46
46
|
| `fireworks-ai/accounts/fireworks/models/minimax-m3` | 512K | | | | | | $0.30 | $1 |
|
|
47
47
|
| `fireworks-ai/accounts/fireworks/models/qwen3p7-plus` | 262K | | | | | | $0.40 | $2 |
|
|
48
48
|
| `fireworks-ai/accounts/fireworks/routers/glm-5p1-fast` | 203K | | | | | | $3 | $9 |
|
|
49
|
+
| `fireworks-ai/accounts/fireworks/routers/glm-5p2-fast` | 1.0M | | | | | | $2 | $7 |
|
|
49
50
|
| `fireworks-ai/accounts/fireworks/routers/kimi-k2p6-fast` | 262K | | | | | | $2 | $8 |
|
|
50
51
|
| `fireworks-ai/accounts/fireworks/routers/kimi-k2p6-turbo` | 262K | | | | | | $2 | $8 |
|
|
51
52
|
| `fireworks-ai/accounts/fireworks/routers/kimi-k2p7-code-fast` | 262K | | | | | | $2 | $8 |
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Friendli
|
|
2
2
|
|
|
3
|
-
Access
|
|
3
|
+
Access 9 Friendli models through Mastra's model router. Authentication is handled automatically using the `FRIENDLI_TOKEN` environment variable.
|
|
4
4
|
|
|
5
5
|
Learn more in the [Friendli documentation](https://friendli.ai/docs/guides/serverless_endpoints/introduction).
|
|
6
6
|
|
|
@@ -34,6 +34,8 @@ for await (const chunk of stream) {
|
|
|
34
34
|
|
|
35
35
|
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|
|
36
36
|
| --------------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
|
|
37
|
+
| `friendli/deepseek-ai/DeepSeek-V3.2` | 164K | | | | | | $0.50 | $2 |
|
|
38
|
+
| `friendli/google/gemma-4-31B-it` | 262K | | | | | | $0.14 | $0.40 |
|
|
37
39
|
| `friendli/meta-llama/Llama-3.1-8B-Instruct` | 131K | | | | | | $0.10 | $0.10 |
|
|
38
40
|
| `friendli/meta-llama/Llama-3.3-70B-Instruct` | 131K | | | | | | $0.60 | $0.60 |
|
|
39
41
|
| `friendli/MiniMaxAI/MiniMax-M2.5` | 197K | | | | | | $0.30 | $1 |
|
|
@@ -51,7 +51,7 @@ for await (const chunk of stream) {
|
|
|
51
51
|
| `llmgateway/codestral-2508` | 256K | | | | | | $0.30 | $0.90 |
|
|
52
52
|
| `llmgateway/custom` | 128K | | | | | | — | — |
|
|
53
53
|
| `llmgateway/deepseek-v3.1` | 128K | | | | | | $0.56 | $2 |
|
|
54
|
-
| `llmgateway/deepseek-v3.2` | 164K | | | | | | $0.
|
|
54
|
+
| `llmgateway/deepseek-v3.2` | 164K | | | | | | $0.26 | $0.38 |
|
|
55
55
|
| `llmgateway/deepseek-v4-flash` | 1.1M | | | | | | $0.14 | $0.28 |
|
|
56
56
|
| `llmgateway/deepseek-v4-pro` | 1.1M | | | | | | $0.43 | $0.87 |
|
|
57
57
|
| `llmgateway/fugu-ultra` | 1.0M | | | | | | $5 | $30 |
|
|
@@ -68,21 +68,21 @@ for await (const chunk of stream) {
|
|
|
68
68
|
| `llmgateway/gemma-4-31b-it` | 262K | | | | | | $0.13 | $0.38 |
|
|
69
69
|
| `llmgateway/glm-4-32b-0414-128k` | 128K | | | | | | $0.10 | $0.10 |
|
|
70
70
|
| `llmgateway/glm-4.5` | 131K | | | | | | $0.60 | $2 |
|
|
71
|
-
| `llmgateway/glm-4.5-air` | 131K | | | | | | $0.
|
|
71
|
+
| `llmgateway/glm-4.5-air` | 131K | | | | | | $0.13 | $0.85 |
|
|
72
72
|
| `llmgateway/glm-4.5-airx` | 128K | | | | | | $1 | $5 |
|
|
73
73
|
| `llmgateway/glm-4.5-flash` | 128K | | | | | | — | — |
|
|
74
74
|
| `llmgateway/glm-4.5-x` | 128K | | | | | | $2 | $9 |
|
|
75
75
|
| `llmgateway/glm-4.5v` | 128K | | | | | | $0.60 | $2 |
|
|
76
|
-
| `llmgateway/glm-4.6` | 205K | | | | | | $0.
|
|
76
|
+
| `llmgateway/glm-4.6` | 205K | | | | | | $0.43 | $2 |
|
|
77
77
|
| `llmgateway/glm-4.6v` | 131K | | | | | | $0.30 | $0.90 |
|
|
78
78
|
| `llmgateway/glm-4.6v-flash` | 128K | | | | | | — | — |
|
|
79
79
|
| `llmgateway/glm-4.6v-flashx` | 128K | | | | | | $0.04 | $0.40 |
|
|
80
|
-
| `llmgateway/glm-4.7` | 205K | | | | | | $0.
|
|
80
|
+
| `llmgateway/glm-4.7` | 205K | | | | | | $0.38 | $2 |
|
|
81
81
|
| `llmgateway/glm-4.7-flash` | 200K | | | | | | $0.06 | $0.40 |
|
|
82
82
|
| `llmgateway/glm-4.7-flash-free` | 200K | | | | | | — | — |
|
|
83
83
|
| `llmgateway/glm-4.7-flashx` | 200K | | | | | | $0.07 | $0.40 |
|
|
84
|
-
| `llmgateway/glm-5` | 203K | | | | | | $
|
|
85
|
-
| `llmgateway/glm-5.1` | 205K | | | | | | $
|
|
84
|
+
| `llmgateway/glm-5` | 203K | | | | | | $0.72 | $2 |
|
|
85
|
+
| `llmgateway/glm-5.1` | 205K | | | | | | $0.93 | $3 |
|
|
86
86
|
| `llmgateway/glm-5.2` | 1.0M | | | | | | $1 | $4 |
|
|
87
87
|
| `llmgateway/gpt-3.5-turbo` | 16K | | | | | | $0.50 | $2 |
|
|
88
88
|
| `llmgateway/gpt-4` | 8K | | | | | | $30 | $60 |
|
|
@@ -114,8 +114,8 @@ for await (const chunk of stream) {
|
|
|
114
114
|
| `llmgateway/gpt-5.4-pro` | 1.1M | | | | | | $30 | $180 |
|
|
115
115
|
| `llmgateway/gpt-5.5` | 1.1M | | | | | | $5 | $30 |
|
|
116
116
|
| `llmgateway/gpt-5.5-pro` | 1.1M | | | | | | $30 | $180 |
|
|
117
|
-
| `llmgateway/gpt-oss-120b` | 131K | | | | | | $0.
|
|
118
|
-
| `llmgateway/gpt-oss-20b` | 131K | | | | | | $0.
|
|
117
|
+
| `llmgateway/gpt-oss-120b` | 131K | | | | | | $0.05 | $0.25 |
|
|
118
|
+
| `llmgateway/gpt-oss-20b` | 131K | | | | | | $0.04 | $0.15 |
|
|
119
119
|
| `llmgateway/grok-4` | 256K | | | | | | $3 | $15 |
|
|
120
120
|
| `llmgateway/grok-4-1-fast-non-reasoning` | 2.0M | | | | | | $0.20 | $0.50 |
|
|
121
121
|
| `llmgateway/grok-4-1-fast-reasoning` | 2.0M | | | | | | $0.20 | $0.50 |
|
|
@@ -125,11 +125,11 @@ for await (const chunk of stream) {
|
|
|
125
125
|
| `llmgateway/grok-4-20-reasoning` | 2.0M | | | | | | $2 | $6 |
|
|
126
126
|
| `llmgateway/grok-4-3` | 1.0M | | | | | | $1 | $3 |
|
|
127
127
|
| `llmgateway/grok-build-0-1` | 256K | | | | | | $1 | $2 |
|
|
128
|
-
| `llmgateway/kimi-k2` | 256K | | | | | | $
|
|
129
|
-
| `llmgateway/kimi-k2-thinking` | 262K | | | | | | $0.
|
|
128
|
+
| `llmgateway/kimi-k2` | 256K | | | | | | $0.57 | $2 |
|
|
129
|
+
| `llmgateway/kimi-k2-thinking` | 262K | | | | | | $0.57 | $2 |
|
|
130
130
|
| `llmgateway/kimi-k2-thinking-turbo` | 262K | | | | | | $1 | $8 |
|
|
131
|
-
| `llmgateway/kimi-k2.5` | 262K | | | | | | $0.
|
|
132
|
-
| `llmgateway/kimi-k2.6` | 262K | | | | | | $0.
|
|
131
|
+
| `llmgateway/kimi-k2.5` | 262K | | | | | | $0.41 | $2 |
|
|
132
|
+
| `llmgateway/kimi-k2.6` | 262K | | | | | | $0.50 | $3 |
|
|
133
133
|
| `llmgateway/kimi-k2.7-code` | 262K | | | | | | $0.95 | $4 |
|
|
134
134
|
| `llmgateway/kimi-k2.7-code-highspeed` | 262K | | | | | | $2 | $8 |
|
|
135
135
|
| `llmgateway/llama-3-70b-instruct` | 8K | | | | | | $0.51 | $0.74 |
|
|
@@ -139,8 +139,8 @@ for await (const chunk of stream) {
|
|
|
139
139
|
| `llmgateway/llama-3.2-11b-instruct` | 128K | | | | | | $0.07 | $0.33 |
|
|
140
140
|
| `llmgateway/llama-3.2-3b-instruct` | 33K | | | | | | $0.03 | $0.05 |
|
|
141
141
|
| `llmgateway/llama-3.3-70b-instruct` | 131K | | | | | | $0.13 | $0.40 |
|
|
142
|
-
| `llmgateway/llama-4-maverick-17b-instruct` | 1.0M | | | | | | $0.
|
|
143
|
-
| `llmgateway/llama-4-scout-17b-instruct` | 131K | | | | | | $0.
|
|
142
|
+
| `llmgateway/llama-4-maverick-17b-instruct` | 1.0M | | | | | | $0.27 | $0.85 |
|
|
143
|
+
| `llmgateway/llama-4-scout-17b-instruct` | 131K | | | | | | $0.18 | $0.59 |
|
|
144
144
|
| `llmgateway/mimo-v2-omni` | 256K | | | | | | $0.40 | $2 |
|
|
145
145
|
| `llmgateway/mimo-v2-pro` | 1.0M | | | | | | $1 | $3 |
|
|
146
146
|
| `llmgateway/mimo-v2.5` | 1.0M | | | | | | $0.14 | $0.28 |
|
|
@@ -179,21 +179,21 @@ for await (const chunk of stream) {
|
|
|
179
179
|
| `llmgateway/qwen2-5-vl-32b-instruct` | 131K | | | | | | $1 | $4 |
|
|
180
180
|
| `llmgateway/qwen2-5-vl-72b-instruct` | 33K | | | | | | $0.13 | $0.40 |
|
|
181
181
|
| `llmgateway/qwen3-235b-a22b-fp8` | 41K | | | | | | $0.20 | $0.80 |
|
|
182
|
-
| `llmgateway/qwen3-235b-a22b-instruct-2507` | 262K | | | | | | $0.
|
|
182
|
+
| `llmgateway/qwen3-235b-a22b-instruct-2507` | 262K | | | | | | $0.09 | $0.58 |
|
|
183
183
|
| `llmgateway/qwen3-235b-a22b-thinking-2507` | 262K | | | | | | $0.20 | $0.60 |
|
|
184
184
|
| `llmgateway/qwen3-30b-a3b-instruct-2507` | 262K | | | | | | $0.10 | $0.30 |
|
|
185
185
|
| `llmgateway/qwen3-32b` | 33K | | | | | | $0.10 | $0.30 |
|
|
186
186
|
| `llmgateway/qwen3-4b-fp8` | 128K | | | | | | $0.03 | $0.03 |
|
|
187
|
-
| `llmgateway/qwen3-coder-30b-a3b-instruct` | 262K | | | | | | $0.
|
|
188
|
-
| `llmgateway/qwen3-coder-480b-a35b-instruct` | 262K | | | | | | $0.
|
|
187
|
+
| `llmgateway/qwen3-coder-30b-a3b-instruct` | 262K | | | | | | $0.07 | $0.27 |
|
|
188
|
+
| `llmgateway/qwen3-coder-480b-a35b-instruct` | 262K | | | | | | $0.30 | $1 |
|
|
189
189
|
| `llmgateway/qwen3-coder-flash` | 1.0M | | | | | | $0.30 | $2 |
|
|
190
190
|
| `llmgateway/qwen3-coder-next` | 262K | | | | | | $0.11 | $0.68 |
|
|
191
191
|
| `llmgateway/qwen3-coder-plus` | 1.0M | | | | | | $6 | $60 |
|
|
192
|
-
| `llmgateway/qwen3-max` | 262K | | | | | | $
|
|
192
|
+
| `llmgateway/qwen3-max` | 262K | | | | | | $0.84 | $3 |
|
|
193
193
|
| `llmgateway/qwen3-max-2026-01-23` | 262K | | | | | | $1 | $6 |
|
|
194
|
-
| `llmgateway/qwen3-next-80b-a3b-instruct` | 131K | | | | | | $0.
|
|
195
|
-
| `llmgateway/qwen3-next-80b-a3b-thinking` | 131K | | | | | | $0.
|
|
196
|
-
| `llmgateway/qwen3-vl-235b-a22b-instruct` | 131K | | | | | | $0.
|
|
194
|
+
| `llmgateway/qwen3-next-80b-a3b-instruct` | 131K | | | | | | $0.15 | $2 |
|
|
195
|
+
| `llmgateway/qwen3-next-80b-a3b-thinking` | 131K | | | | | | $0.15 | $1 |
|
|
196
|
+
| `llmgateway/qwen3-vl-235b-a22b-instruct` | 131K | | | | | | $0.30 | $2 |
|
|
197
197
|
| `llmgateway/qwen3-vl-235b-a22b-thinking` | 131K | | | | | | $0.50 | $2 |
|
|
198
198
|
| `llmgateway/qwen3-vl-30b-a3b-instruct` | 131K | | | | | | $0.20 | $0.70 |
|
|
199
199
|
| `llmgateway/qwen3-vl-30b-a3b-thinking` | 131K | | | | | | $0.20 | $1 |
|
|
@@ -204,7 +204,7 @@ for await (const chunk of stream) {
|
|
|
204
204
|
| `llmgateway/qwen3.6-35b-a3b` | 262K | | | | | | $0.25 | $1 |
|
|
205
205
|
| `llmgateway/qwen3.6-max-preview` | 262K | | | | | | $1 | $8 |
|
|
206
206
|
| `llmgateway/qwen3.6-plus` | 262K | | | | | | $0.50 | $3 |
|
|
207
|
-
| `llmgateway/qwen3.7-max` | 1.0M | | | | | | $
|
|
207
|
+
| `llmgateway/qwen3.7-max` | 1.0M | | | | | | $1 | $4 |
|
|
208
208
|
| `llmgateway/qwen3.7-plus` | 1.0M | | | | | | $0.40 | $2 |
|
|
209
209
|
| `llmgateway/qwen35-397b-a17b` | 262K | | | | | | $0.60 | $4 |
|
|
210
210
|
| `llmgateway/qwq-plus` | 131K | | | | | | $0.80 | $2 |
|
|
@@ -40,7 +40,7 @@ for await (const chunk of stream) {
|
|
|
40
40
|
| `minimax-cn-coding-plan/MiniMax-M2.5-highspeed` | 205K | | | | | | — | — |
|
|
41
41
|
| `minimax-cn-coding-plan/MiniMax-M2.7` | 205K | | | | | | — | — |
|
|
42
42
|
| `minimax-cn-coding-plan/MiniMax-M2.7-highspeed` | 205K | | | | | | — | — |
|
|
43
|
-
| `minimax-cn-coding-plan/MiniMax-M3` |
|
|
43
|
+
| `minimax-cn-coding-plan/MiniMax-M3` | 1.0M | | | | | | — | — |
|
|
44
44
|
|
|
45
45
|
## Advanced configuration
|
|
46
46
|
|
|
@@ -40,7 +40,7 @@ for await (const chunk of stream) {
|
|
|
40
40
|
| `minimax-cn/MiniMax-M2.5-highspeed` | 205K | | | | | | $0.60 | $2 |
|
|
41
41
|
| `minimax-cn/MiniMax-M2.7` | 205K | | | | | | $0.30 | $1 |
|
|
42
42
|
| `minimax-cn/MiniMax-M2.7-highspeed` | 205K | | | | | | $0.60 | $2 |
|
|
43
|
-
| `minimax-cn/MiniMax-M3` |
|
|
43
|
+
| `minimax-cn/MiniMax-M3` | 1.0M | | | | | | $0.30 | $1 |
|
|
44
44
|
|
|
45
45
|
## Advanced configuration
|
|
46
46
|
|
|
@@ -40,7 +40,7 @@ for await (const chunk of stream) {
|
|
|
40
40
|
| `minimax-coding-plan/MiniMax-M2.5-highspeed` | 205K | | | | | | — | — |
|
|
41
41
|
| `minimax-coding-plan/MiniMax-M2.7` | 205K | | | | | | — | — |
|
|
42
42
|
| `minimax-coding-plan/MiniMax-M2.7-highspeed` | 205K | | | | | | — | — |
|
|
43
|
-
| `minimax-coding-plan/MiniMax-M3` |
|
|
43
|
+
| `minimax-coding-plan/MiniMax-M3` | 1.0M | | | | | | — | — |
|
|
44
44
|
|
|
45
45
|
## Advanced configuration
|
|
46
46
|
|