@mastra/client-js 0.0.0-structured-output-errors-20260409185629 → 0.0.0-structured-output-agent-20260413221909
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/CHANGELOG.md
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
# @mastra/client-js
|
|
2
2
|
|
|
3
|
-
## 0.0.0-structured-output-
|
|
3
|
+
## 0.0.0-structured-output-agent-20260413221909
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
|
-
- Updated dependencies [[`87df955`](https://github.com/mastra-ai/mastra/commit/87df955c028660c075873fd5d74af28233ce32eb), [`
|
|
8
|
-
- @mastra/core@0.0.0-structured-output-
|
|
7
|
+
- Updated dependencies [[`87df955`](https://github.com/mastra-ai/mastra/commit/87df955c028660c075873fd5d74af28233ce32eb), [`5d84914`](https://github.com/mastra-ai/mastra/commit/5d84914e0e520c642a40329b210b413fcd139898), [`fd2f314`](https://github.com/mastra-ai/mastra/commit/fd2f31473d3449b6b97e837ef8641264377f41a7), [`e80fead`](https://github.com/mastra-ai/mastra/commit/e80fead1412cc0d1b2f7d6a1ce5017d9e0098ff7), [`0287b64`](https://github.com/mastra-ai/mastra/commit/0287b644a5c3272755cf3112e71338106664103b), [`5332c00`](https://github.com/mastra-ai/mastra/commit/5332c00ede9a783f0f56000240b8ed68e008d922), [`075e91a`](https://github.com/mastra-ai/mastra/commit/075e91a4549baf46ad7a42a6a8ac8dfa78cc09e6)]:
|
|
8
|
+
- @mastra/core@0.0.0-structured-output-agent-20260413221909
|
|
9
9
|
|
|
10
10
|
## 1.13.4-alpha.0
|
|
11
11
|
|
package/dist/docs/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: mastra-client-js
|
|
|
3
3
|
description: Documentation for @mastra/client-js. Use when working with @mastra/client-js APIs, configuration, or implementation.
|
|
4
4
|
metadata:
|
|
5
5
|
package: "@mastra/client-js"
|
|
6
|
-
version: "0.0.0-structured-output-
|
|
6
|
+
version: "0.0.0-structured-output-agent-20260413221909"
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## When to use
|
|
@@ -6,6 +6,21 @@ This is useful when building custom streaming endpoints outside Mastra's provide
|
|
|
6
6
|
|
|
7
7
|
`toAISdkStream()` keeps the existing AI SDK v5/default behavior. If your app is typed against AI SDK v6, pass `version: 'v6'` in the options object.
|
|
8
8
|
|
|
9
|
+
## Structured output in UI streams
|
|
10
|
+
|
|
11
|
+
When the source agent stream includes a final structured output object, `toAISdkStream()` emits it as a custom AI SDK UI data part:
|
|
12
|
+
|
|
13
|
+
```json
|
|
14
|
+
{
|
|
15
|
+
"type": "data-structured-output",
|
|
16
|
+
"data": {
|
|
17
|
+
"object": {}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
The `object` field contains your full structured output value. This maps Mastra's final structured output chunk into the AI SDK UI stream. Partial structured output chunks are not emitted.
|
|
23
|
+
|
|
9
24
|
## Usage example
|
|
10
25
|
|
|
11
26
|
Next.js App Router example:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/client-js",
|
|
3
|
-
"version": "0.0.0-structured-output-
|
|
3
|
+
"version": "0.0.0-structured-output-agent-20260413221909",
|
|
4
4
|
"description": "The official TypeScript library for the Mastra Client API",
|
|
5
5
|
"author": "",
|
|
6
6
|
"type": "module",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"@ai-sdk/ui-utils": "^1.2.11",
|
|
38
38
|
"@lukeed/uuid": "^2.0.1",
|
|
39
39
|
"json-schema": "^0.4.0",
|
|
40
|
-
"@mastra/core": "0.0.0-structured-output-
|
|
40
|
+
"@mastra/core": "0.0.0-structured-output-agent-20260413221909",
|
|
41
41
|
"@mastra/schema-compat": "1.2.7"
|
|
42
42
|
},
|
|
43
43
|
"peerDependencies": {
|
|
@@ -53,10 +53,10 @@
|
|
|
53
53
|
"typescript": "^5.9.3",
|
|
54
54
|
"vitest": "4.0.18",
|
|
55
55
|
"zod": "^4.3.6",
|
|
56
|
-
"@internal/ai-sdk-v4": "0.0.0-structured-output-
|
|
57
|
-
"@internal/
|
|
58
|
-
"@internal/
|
|
59
|
-
"@internal/
|
|
56
|
+
"@internal/ai-sdk-v4": "0.0.0-structured-output-agent-20260413221909",
|
|
57
|
+
"@internal/ai-sdk-v5": "0.0.0-structured-output-agent-20260413221909",
|
|
58
|
+
"@internal/lint": "0.0.0-structured-output-agent-20260413221909",
|
|
59
|
+
"@internal/types-builder": "0.0.0-structured-output-agent-20260413221909"
|
|
60
60
|
},
|
|
61
61
|
"engines": {
|
|
62
62
|
"node": ">=22.13.0"
|