@mastra/server 0.10.2-alpha.4 → 0.10.2-alpha.6

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.
@@ -28,6 +28,7 @@ import { Step } from '@mastra/core/workflows';
28
28
  import { StepExecutionContext } from '@mastra/core/workflows/legacy';
29
29
  import { StepGraph } from '@mastra/core/workflows/legacy';
30
30
  import { StorageThreadType } from '@mastra/core/memory';
31
+ import { StreamEvent } from '@mastra/core/workflows';
31
32
  import { Task } from '@mastra/core/a2a';
32
33
  import { TaskAndHistory } from '@mastra/core/a2a';
33
34
  import type { TaskContext } from '@mastra/core/a2a';
@@ -38,7 +39,6 @@ import type { TaskStatus } from '@mastra/core/a2a';
38
39
  import type { ToolAction } from '@mastra/core/tools';
39
40
  import { UIMessage } from 'ai';
40
41
  import type { VercelTool } from '@mastra/core/tools';
41
- import { WatchEvent } from '@mastra/core/workflows';
42
42
  import type { Workflow } from '@mastra/core/workflows';
43
43
  import { WorkflowContext as WorkflowContext_2 } from '@mastra/core/workflows/legacy';
44
44
  import { WorkflowResult } from '@mastra/core/workflows';
@@ -694,7 +694,7 @@ export declare function streamWorkflowHandler({ mastra, runtimeContext, workflow
694
694
  runtimeContext?: RuntimeContext_2;
695
695
  runtimeContextFromRequest?: Record<string, unknown>;
696
696
  }): {
697
- stream: globalThis.ReadableStream<WatchEvent>;
697
+ stream: globalThis.ReadableStream<StreamEvent>;
698
698
  getWorkflowState: () => Promise<WorkflowResult<ZodType<any, ZodTypeDef, any>, Step<string, any, any, any, any>[]>>;
699
699
  };
700
700
 
@@ -28,6 +28,7 @@ import { Step } from '@mastra/core/workflows';
28
28
  import { StepExecutionContext } from '@mastra/core/workflows/legacy';
29
29
  import { StepGraph } from '@mastra/core/workflows/legacy';
30
30
  import { StorageThreadType } from '@mastra/core/memory';
31
+ import { StreamEvent } from '@mastra/core/workflows';
31
32
  import { Task } from '@mastra/core/a2a';
32
33
  import { TaskAndHistory } from '@mastra/core/a2a';
33
34
  import type { TaskContext } from '@mastra/core/a2a';
@@ -38,7 +39,6 @@ import type { TaskStatus } from '@mastra/core/a2a';
38
39
  import type { ToolAction } from '@mastra/core/tools';
39
40
  import { UIMessage } from 'ai';
40
41
  import type { VercelTool } from '@mastra/core/tools';
41
- import { WatchEvent } from '@mastra/core/workflows';
42
42
  import type { Workflow } from '@mastra/core/workflows';
43
43
  import { WorkflowContext as WorkflowContext_2 } from '@mastra/core/workflows/legacy';
44
44
  import { WorkflowResult } from '@mastra/core/workflows';
@@ -694,7 +694,7 @@ export declare function streamWorkflowHandler({ mastra, runtimeContext, workflow
694
694
  runtimeContext?: RuntimeContext_2;
695
695
  runtimeContextFromRequest?: Record<string, unknown>;
696
696
  }): {
697
- stream: globalThis.ReadableStream<WatchEvent>;
697
+ stream: globalThis.ReadableStream<StreamEvent>;
698
698
  getWorkflowState: () => Promise<WorkflowResult<ZodType<any, ZodTypeDef, any>, Step<string, any, any, any, any>[]>>;
699
699
  };
700
700
 
@@ -204,7 +204,7 @@ async function getMessagesHandler({
204
204
  threadId,
205
205
  ...limit && { selectBy: { last: limit } }
206
206
  });
207
- return result;
207
+ return { messages: result.messages, uiMessages: result.uiMessages };
208
208
  } catch (error) {
209
209
  return chunk64U3UDTH_cjs.handleError(error, "Error getting messages");
210
210
  }
@@ -202,7 +202,7 @@ async function getMessagesHandler({
202
202
  threadId,
203
203
  ...limit && { selectBy: { last: limit } }
204
204
  });
205
- return result;
205
+ return { messages: result.messages, uiMessages: result.uiMessages };
206
206
  } catch (error) {
207
207
  return handleError(error, "Error getting messages");
208
208
  }
@@ -1,38 +1,38 @@
1
1
  'use strict';
2
2
 
3
- var chunkY7UWRW5X_cjs = require('../../chunk-Y7UWRW5X.cjs');
3
+ var chunk6TJSHFCJ_cjs = require('../../chunk-6TJSHFCJ.cjs');
4
4
 
5
5
 
6
6
 
7
7
  Object.defineProperty(exports, "createThreadHandler", {
8
8
  enumerable: true,
9
- get: function () { return chunkY7UWRW5X_cjs.createThreadHandler; }
9
+ get: function () { return chunk6TJSHFCJ_cjs.createThreadHandler; }
10
10
  });
11
11
  Object.defineProperty(exports, "deleteThreadHandler", {
12
12
  enumerable: true,
13
- get: function () { return chunkY7UWRW5X_cjs.deleteThreadHandler; }
13
+ get: function () { return chunk6TJSHFCJ_cjs.deleteThreadHandler; }
14
14
  });
15
15
  Object.defineProperty(exports, "getMemoryStatusHandler", {
16
16
  enumerable: true,
17
- get: function () { return chunkY7UWRW5X_cjs.getMemoryStatusHandler; }
17
+ get: function () { return chunk6TJSHFCJ_cjs.getMemoryStatusHandler; }
18
18
  });
19
19
  Object.defineProperty(exports, "getMessagesHandler", {
20
20
  enumerable: true,
21
- get: function () { return chunkY7UWRW5X_cjs.getMessagesHandler; }
21
+ get: function () { return chunk6TJSHFCJ_cjs.getMessagesHandler; }
22
22
  });
23
23
  Object.defineProperty(exports, "getThreadByIdHandler", {
24
24
  enumerable: true,
25
- get: function () { return chunkY7UWRW5X_cjs.getThreadByIdHandler; }
25
+ get: function () { return chunk6TJSHFCJ_cjs.getThreadByIdHandler; }
26
26
  });
27
27
  Object.defineProperty(exports, "getThreadsHandler", {
28
28
  enumerable: true,
29
- get: function () { return chunkY7UWRW5X_cjs.getThreadsHandler; }
29
+ get: function () { return chunk6TJSHFCJ_cjs.getThreadsHandler; }
30
30
  });
31
31
  Object.defineProperty(exports, "saveMessagesHandler", {
32
32
  enumerable: true,
33
- get: function () { return chunkY7UWRW5X_cjs.saveMessagesHandler; }
33
+ get: function () { return chunk6TJSHFCJ_cjs.saveMessagesHandler; }
34
34
  });
35
35
  Object.defineProperty(exports, "updateThreadHandler", {
36
36
  enumerable: true,
37
- get: function () { return chunkY7UWRW5X_cjs.updateThreadHandler; }
37
+ get: function () { return chunk6TJSHFCJ_cjs.updateThreadHandler; }
38
38
  });
@@ -1 +1 @@
1
- export { createThreadHandler, deleteThreadHandler, getMemoryStatusHandler, getMessagesHandler, getThreadByIdHandler, getThreadsHandler, saveMessagesHandler, updateThreadHandler } from '../../chunk-DJJIUEL2.js';
1
+ export { createThreadHandler, deleteThreadHandler, getMemoryStatusHandler, getMessagesHandler, getThreadByIdHandler, getThreadsHandler, saveMessagesHandler, updateThreadHandler } from '../../chunk-I7KJZNX5.js';
@@ -10,7 +10,7 @@ var chunkSDPGVWQJ_cjs = require('../chunk-SDPGVWQJ.cjs');
10
10
  var chunkA3KDUGS7_cjs = require('../chunk-A3KDUGS7.cjs');
11
11
  var chunkYIOVBYZH_cjs = require('../chunk-YIOVBYZH.cjs');
12
12
  var chunkNEOOQUKW_cjs = require('../chunk-NEOOQUKW.cjs');
13
- var chunkY7UWRW5X_cjs = require('../chunk-Y7UWRW5X.cjs');
13
+ var chunk6TJSHFCJ_cjs = require('../chunk-6TJSHFCJ.cjs');
14
14
 
15
15
 
16
16
 
@@ -56,5 +56,5 @@ Object.defineProperty(exports, "logs", {
56
56
  });
57
57
  Object.defineProperty(exports, "memory", {
58
58
  enumerable: true,
59
- get: function () { return chunkY7UWRW5X_cjs.memory_exports; }
59
+ get: function () { return chunk6TJSHFCJ_cjs.memory_exports; }
60
60
  });
@@ -8,4 +8,4 @@ export { a2a_exports as a2a } from '../chunk-GHC4YV6R.js';
8
8
  export { agents_exports as agents } from '../chunk-J3PKLB3A.js';
9
9
  export { legacyWorkflows_exports as legacyWorkflows } from '../chunk-W7VCKPAD.js';
10
10
  export { logs_exports as logs } from '../chunk-DQLE3DVM.js';
11
- export { memory_exports as memory } from '../chunk-DJJIUEL2.js';
11
+ export { memory_exports as memory } from '../chunk-I7KJZNX5.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mastra/server",
3
- "version": "0.10.2-alpha.4",
3
+ "version": "0.10.2-alpha.6",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "files": [
@@ -61,7 +61,7 @@
61
61
  "zod": "^3.24.3",
62
62
  "zod-to-json-schema": "^3.24.5",
63
63
  "@internal/lint": "0.0.7",
64
- "@mastra/core": "0.10.2-alpha.4"
64
+ "@mastra/core": "0.10.2-alpha.6"
65
65
  },
66
66
  "scripts": {
67
67
  "build": "tsup src/index.ts src/server/handlers.ts src/server/handlers/*.ts !src/server/handlers/*.test.ts --format esm,cjs --clean --experimental-dts --treeshake=smallest --splitting",