@mastra/client-js 1.19.0-alpha.3 → 1.19.1-alpha.0

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,5 +1,56 @@
1
1
  # @mastra/client-js
2
2
 
3
+ ## 1.19.1-alpha.0
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`b661349`](https://github.com/mastra-ai/mastra/commit/b661349281514691db78941a9044e6e4f1cde7a7)]:
8
+ - @mastra/core@1.34.1-alpha.0
9
+
10
+ ## 1.19.0
11
+
12
+ ### Minor Changes
13
+
14
+ - Added optional `metadata` to code-defined agents. Pass a `metadata` record to `new Agent({...})`, read it back with `agent.getMetadata()`, and clients can filter on it from the existing `/agents` and `/agents/:agentId` responses without encoding the data into IDs or names. ([#16603](https://github.com/mastra-ai/mastra/pull/16603))
15
+
16
+ Metadata supports the same `DynamicArgument` form as other agent config fields, so it can also be resolved per request from the request context.
17
+
18
+ Stored agents loaded via the editor also expose their metadata through `agent.getMetadata()`, so clients can filter these agents as well. Cloning a runtime agent via `editor.agent.clone()` now carries the source agent's metadata over to the stored clone when the caller does not provide one explicitly.
19
+
20
+ ```ts
21
+ // Static
22
+ const supportAgent = new Agent({
23
+ id: 'support-agent',
24
+ name: 'Support Agent',
25
+ instructions: 'You help customers with support requests.',
26
+ model: 'openai/gpt-5',
27
+ metadata: { type: 'support' },
28
+ });
29
+
30
+ supportAgent.getMetadata(); // { type: 'support' }
31
+
32
+ // Dynamic
33
+ const tenantAgent = new Agent({
34
+ id: 'tenant-agent',
35
+ name: 'Tenant Agent',
36
+ instructions: 'You help customers with tenant-specific tasks.',
37
+ model: 'openai/gpt-5',
38
+ metadata: ({ requestContext }) => ({
39
+ type: 'support',
40
+ tenant: requestContext.get('tenant'),
41
+ }),
42
+ });
43
+
44
+ await tenantAgent.getMetadata({ requestContext }); // { type: 'support', tenant: 'acme' }
45
+ ```
46
+
47
+ ### Patch Changes
48
+
49
+ - Expose `GET /observability/traces/light` and storage support for fetching paginated trace-list rows without span payload data. ([#16608](https://github.com/mastra-ai/mastra/pull/16608))
50
+
51
+ - Updated dependencies [[`20787de`](https://github.com/mastra-ai/mastra/commit/20787de5965234a1af28fe35f49437c537dbfa0d), [`784ad98`](https://github.com/mastra-ai/mastra/commit/784ad989549de91dc5d33ab8ef36caa6f7dcd34e), [`fceae1f`](https://github.com/mastra-ai/mastra/commit/fceae1f5f5db4722cb078a663c6eb4bd22944123), [`090a647`](https://github.com/mastra-ai/mastra/commit/090a647ba5a66d36f203f9f49457e03a1ff4e6fb), [`bf02acb`](https://github.com/mastra-ai/mastra/commit/bf02acbb8a6110f638ac844e89f1ebf04cb7fe74), [`090a647`](https://github.com/mastra-ai/mastra/commit/090a647ba5a66d36f203f9f49457e03a1ff4e6fb), [`bdb4cbf`](https://github.com/mastra-ai/mastra/commit/bdb4cbf8ba4b685d7481f28bb9dc3de6c79c9ed2), [`0fd3fbe`](https://github.com/mastra-ai/mastra/commit/0fd3fbe40fb63657aedd72f6e7b38c8e8ee6940d), [`f84447d`](https://github.com/mastra-ai/mastra/commit/f84447d6c80f3471836a9b300d246b331fb47e0d), [`a1a5b3e`](https://github.com/mastra-ai/mastra/commit/a1a5b3e42ab2ca5161ea21db59ebf28442680fa7), [`af84f57`](https://github.com/mastra-ai/mastra/commit/af84f571ed762e92e8e61c5f9a72363520914274), [`8b3c6f9`](https://github.com/mastra-ai/mastra/commit/8b3c6f90f7879833ba7d1bc70937e1d8f69d0804), [`fed0475`](https://github.com/mastra-ai/mastra/commit/fed0475ccfea31e4fc251469ac05640d0742c1f0), [`0d53730`](https://github.com/mastra-ai/mastra/commit/0d53730c1ed87ef80c87caa5701c4170ea8028e6), [`522f44d`](https://github.com/mastra-ai/mastra/commit/522f44d947214bfc06cff50599bae1ef3494880d)]:
52
+ - @mastra/core@1.34.0
53
+
3
54
  ## 1.19.0-alpha.3
4
55
 
5
56
  ### Minor Changes
@@ -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: "1.19.0-alpha.3"
6
+ version: "1.19.1-alpha.0"
7
7
  ---
8
8
 
9
9
  ## When to use
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.19.0-alpha.3",
2
+ "version": "1.19.1-alpha.0",
3
3
  "package": "@mastra/client-js",
4
4
  "exports": {
5
5
  "RequestContext": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mastra/client-js",
3
- "version": "1.19.0-alpha.3",
3
+ "version": "1.19.1-alpha.0",
4
4
  "description": "The official TypeScript library for the Mastra Client API",
5
5
  "author": "",
6
6
  "type": "module",
@@ -39,8 +39,8 @@
39
39
  "canonicalize": "^1.0.8",
40
40
  "jose": "^6.2.1",
41
41
  "json-schema": "^0.4.0",
42
- "@mastra/schema-compat": "1.2.10",
43
- "@mastra/core": "1.34.0-alpha.3"
42
+ "@mastra/core": "1.34.1-alpha.0",
43
+ "@mastra/schema-compat": "1.2.10"
44
44
  },
45
45
  "peerDependencies": {
46
46
  "zod": "^3.25.0 || ^4.0.0"
@@ -55,10 +55,10 @@
55
55
  "typescript": "^6.0.3",
56
56
  "vitest": "4.1.5",
57
57
  "zod": "^4.3.6",
58
- "@internal/ai-sdk-v4": "0.0.41",
59
- "@internal/lint": "0.0.94",
60
- "@internal/types-builder": "0.0.69",
61
- "@internal/ai-sdk-v5": "0.0.41"
58
+ "@internal/ai-sdk-v4": "0.0.42",
59
+ "@internal/lint": "0.0.95",
60
+ "@internal/types-builder": "0.0.70",
61
+ "@internal/ai-sdk-v5": "0.0.42"
62
62
  },
63
63
  "engines": {
64
64
  "node": ">=22.13.0"