releases.shpreview
Mastra/GitHub Releases/@mastra/core@1.0.0-beta.12

@mastra/core@1.0.0-beta.12

December 17, 2025

$npx -y @buildinternet/releases show rel_4IBJBINJLf9QJyywAp-ef

Changelog

Summary

  • Total packages with changes: 39
  • Packages with major changes: 0
  • Packages with minor changes: 0
  • Packages with patch changes: 26

@mastra/agent-builder@1.0.0-beta.5

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/memory@1.0.0-beta.5

@mastra/ai-sdk@1.0.0-beta.9

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

  • Improve JSDoc comments for toAISdkV5Messages, toAISdkV4Messages functions (#11119)

  • Fixed duplicate assistant messages appearing when using useChat with memory enabled. (#11195)

    What was happening: When using useChat with chatRoute and memory, assistant messages were being duplicated in storage after multiple conversation turns. This occurred because the backend-generated message ID wasn't being sent back to useChat, causing ID mismatches during deduplication.

    What changed:

    • The backend now sends the assistant message ID in the stream's start event, so useChat uses the same ID as storage
    • Custom data-* parts (from writer.custom()) are now preserved when messages contain V5 tool parts

    Fixes #11091

  • add requestContext support to networkRoute (#11164)

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/arize@1.0.0-beta.6

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/otel-exporter@1.0.0-beta.6

@mastra/braintrust@1.0.0-beta.6

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5

@mastra/clickhouse@1.0.0-beta.6

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates
  • fix: make getSqlType consistent across storage adapters (#11112)

    • PostgreSQL: use getSqlType() in createTable instead of toUpperCase()
    • LibSQL: use getSqlType() in createTable, return JSONB for jsonb type (matches SQLite 3.45+ support)
    • ClickHouse: use getSqlType() in createTable instead of COLUMN_TYPES constant, add missing types (uuid, float, boolean)
    • Remove unused getSqlType() and getDefaultValue() from MastraStorage base class (all stores use StoreOperations versions)

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/client-js@1.0.0-beta.12

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

  • Add resourceId to workflow routes (#11166)

  • Add Run instance to client-js. workflow.createRun returns the Run instance which can be used for the different run methods. (#11207) With this change, run methods cannot be called directly on workflow instance anymore

    - const result = await workflow.stream({ runId: '123', inputData: { ... } });
    + const run = await workflow.createRun({ runId: '123' });
    + const stream = await run.stream({ inputData: { ... } });
    
  • Deserialize workflow errors on the client side (#10992)

    When workflows fail, the server sends error data as JSON over HTTP. This change deserializes those errors back to proper Error instances on the client.

    Before:

    const result = await workflow.startAsync({ input });
    if (result.status === 'failed') {
      // result.error was a plain object, couldn't use instanceof
      console.log(result.error.message); // TypeScript error
    }

    After:

    const result = await workflow.startAsync({ input });
    if (result.status === 'failed') {
      // result.error is now a proper Error instance
      if (result.error instanceof MyCustomError) {
        console.log(result.error.statusCode); // Works!
      }
    }

    This enables proper error handling and type checking in client applications, allowing developers to implement error-specific recovery logic based on custom error types and properties.

    Features:

    • instanceof Error checks
    • Access to error.message, error.name, error.stack
    • Preservation of custom error properties (e.g., statusCode, responseHeaders)
    • Nested error tracking via error.cause

    Affected methods:

    • startAsync()
    • resumeAsync()
    • restartAsync()
    • timeTravelAsync()
  • Add missing status parameter to workflow.runs() method (#11095)

    The status parameter was supported by the server API but was missing from the TypeScript types in @mastra/client-js.

    Now you can filter workflow runs by status:

    // Get only running workflows
    const runningRuns = await workflow.runs({ status: 'running' });
    
    // Get completed workflows
    const completedRuns = await workflow.runs({ status: 'success' });

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/schema-compat@1.0.0-beta.3

@mastra/cloudflare@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/cloudflare-d1@1.0.0-beta.6

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/convex@0.1.0-beta.4

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/core@1.0.0-beta.12

Patch Changes

  • Remove redundant toolCalls from network agent finalResult (#11189)

    The network agent's finalResult was storing toolCalls separately even though all tool call information is already present in the messages array (as tool-call and tool-result type messages). This caused significant token waste since the routing agent reads this data from memory on every iteration.

    Before: finalResult: { text, toolCalls, messages } After: finalResult: { text, messages }

    +Migration: If you were accessing finalResult.toolCalls, retrieve tool calls from finalResult.messages by filtering for messages with type: 'tool-call'.

    Updated @mastra/react to extract tool calls directly from the messages array instead of the removed toolCalls field when resolving initial messages from memory.

    Fixes #11059

  • Embed AI types to fix peerdeps mismatches (9650cce)

  • Fix invalid state: Controller is already closed (932d63d)

    Fixes #11005

  • Fix HITL (Human-In-The-Loop) tool execution bug when mixing tools with and without execute functions. (#11178)

    When an agent called multiple tools simultaneously where some had execute functions and others didn't (HITL tools expecting addToolResult from the frontend), the HITL tools would incorrectly receive result: undefined and be marked as "output-available" instead of "input-available". This caused the agent to continue instead of pausing for user input.

  • Add resourceId to workflow routes (#11166)

  • Auto resume suspended tools if autoResumeSuspendedTools: true (#11157)

    The flag can be added to defaultAgentOptions when creating the agent or to options in agent.stream or agent.generate

    const agent = new Agent({
      //...agent information,
      defaultAgentOptions: {
        autoResumeSuspendedTools: true,
      },
    });
  • Preserve error details when thrown from workflow steps (#10992)

    • Errors thrown in workflow steps now preserve full error details including cause chain and custom properties
    • Added SerializedError type with proper cause chain support
    • Added SerializedStepResult and SerializedStepFailure types for handling errors loaded from storage
    • Enhanced addErrorToJSON to recursively serialize error cause chains with max depth protection
    • Added hydrateSerializedStepErrors to convert serialized errors back to Error instances
    • Fixed Inngest workflow error handling to extract original error from NonRetriableError.cause
  • Move @ai-sdk/azure to devDependencies (#10218)

  • Refactor internal event system from Emitter to PubSub abstraction for workflow event handling. This change replaces the EventEmitter-based event system with a pluggable PubSub interface, enabling support for distributed workflow execution backends like Inngest. Adds close() method to PubSub implementations for proper cleanup. (#11052)

  • Add startAsync() method and fix Inngest duplicate workflow execution bug (#11093)

    New Feature: startAsync() for fire-and-forget workflow execution

    • Add Run.startAsync() to base workflow class - starts workflow in background and returns { runId } immediately
    • Add EventedRun.startAsync() - publishes workflow start event without subscribing for completion
    • Add InngestRun.startAsync() - sends Inngest event without polling for result

    Bug Fix: Prevent duplicate Inngest workflow executions

    • Fix getRuns() to properly handle rate limits (429), empty responses, and JSON parse errors with retry logic and exponential backoff
    • Fix getRunOutput() to throw NonRetriableError when polling fails, preventing Inngest from retrying the parent function and re-triggering the workflow
    • Add timeout to getRunOutput() polling (default 5 minutes) with NonRetriableError on timeout

    This fixes a production issue where polling failures after successful workflow completion caused Inngest to retry the parent function, which fired a new workflow event and resulted in duplicate executions (e.g., duplicate Slack messages).

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates
  • Fix Zod 4 compatibility issue with structuredOutput in agent.generate() (#11133)

    Users with Zod 4 installed would see TypeError: undefined is not an object (evaluating 'def.valueType._zod') when using structuredOutput with agent.generate(). This happened because ProcessorStepSchema contains z.custom() fields that hold user-provided Zod schemas, and the workflow validation was trying to deeply validate these schemas causing version conflicts.

    The fix disables input validation for processor workflows since z.custom() fields are meant to pass through arbitrary types without deep validation.

  • Truncate map config when too long (#11175)

  • Add helpful JSDoc comments to BundlerConfig properties (used with bundler option) (#10218)

  • Fixes .network() method ignores MASTRA_RESOURCE_ID_KEY from requestContext (4524734)

  • fix: make getSqlType consistent across storage adapters (#11112)

    • PostgreSQL: use getSqlType() in createTable instead of toUpperCase()
    • LibSQL: use getSqlType() in createTable, return JSONB for jsonb type (matches SQLite 3.45+ support)
    • ClickHouse: use getSqlType() in createTable instead of COLUMN_TYPES constant, add missing types (uuid, float, boolean)
    • Remove unused getSqlType() and getDefaultValue() from MastraStorage base class (all stores use StoreOperations versions)
  • Fix workflow cancel not updating status when workflow is suspended (#11139)

    • Run.cancel() now updates workflow status to 'canceled' in storage, resolving the issue where suspended workflows remained in 'suspended' status after cancellation
    • Cancellation status is immediately persisted and reflected to observers
  • What changed: (#10998)

    Support for sequential tool execution was added. Tool call concurrency is now set conditionally, defaulting to 1 when sequential execution is needed (to avoid race conditions that interfere with human-in-the-loop approval during the workflow) rather than the default of 10 when concurrency is acceptable.

    How it was changed:

    A sequentialExecutionRequired constant was set to a boolean depending on whether any of the tools involved in a returned agentic execution workflow would require approval. If any tool has a 'suspendSchema' property (used for conditionally suspending execution and waiting for human input), or if they have their requireApproval property set to true, then the concurrency property used in the toolCallStep is set to 1, causing sequential execution. The old default of 10 remains otherwise.

  • Fixed duplicate assistant messages appearing when using useChat with memory enabled. (#11195)

    What was happening: When using useChat with chatRoute and memory, assistant messages were being duplicated in storage after multiple conversation turns. This occurred because the backend-generated message ID wasn't being sent back to useChat, causing ID mismatches during deduplication.

    What changed:

    • The backend now sends the assistant message ID in the stream's start event, so useChat uses the same ID as storage
    • Custom data-* parts (from writer.custom()) are now preserved when messages contain V5 tool parts

    Fixes #11091

Dependency Updates

  • @mastra/schema-compat@1.0.0-beta.3
  • @mastra/observability@1.0.0-beta.5

@mastra/dane@1.0.0-beta.12

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/memory@1.0.0-beta.5
  • @mastra/upstash@1.0.0-beta.7
  • @mastra/libsql@1.0.0-beta.8

@mastra/deployer@1.0.0-beta.12

Patch Changes

  • Remove deprecated playground-only prompt generation handler (functionality moved to @mastra/server) (#11074)

    Improve prompt enhancement UX: show toast errors when enhancement fails, disable button when no model has a configured API key, and prevent users from disabling all models in the model list

    Add missing /api/agents/:agentId/instructions/enhance endpoint that was referenced by @mastra/client-js and @mastra/playground-ui

  • Allow for bundler.externals: true to be set. (#10218)

    With this configuration during mastra build all dependencies (except workspace dependencies) will be treated as "external" and not bundled. Instead they will be added to the .mastra/output/package.json file.

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/server@1.0.0-beta.12

@mastra/deployer-cloud@1.0.0-beta.12

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/deployer@1.0.0-beta.12

@mastra/dynamodb@1.0.0-beta.6

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/express@0.0.2-beta.7

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/server@1.0.0-beta.12

@mastra/fastembed@1.0.0-beta.1

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

@mastra/hono@0.0.2-beta.7

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/server@1.0.0-beta.12

@mastra/inngest@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    • Errors thrown in workflow steps now preserve full error details including cause chain and custom properties
    • Added SerializedError type with proper cause chain support
    • Added SerializedStepResult and SerializedStepFailure types for handling errors loaded from storage
    • Enhanced addErrorToJSON to recursively serialize error cause chains with max depth protection
    • Added hydrateSerializedStepErrors to convert serialized errors back to Error instances
    • Fixed Inngest workflow error handling to extract original error from NonRetriableError.cause
  • Refactor internal event system from Emitter to PubSub abstraction for workflow event handling. This change replaces the EventEmitter-based event system with a pluggable PubSub interface, enabling support for distributed workflow execution backends like Inngest. Adds close() method to PubSub implementations for proper cleanup. (#11052)

  • Add startAsync() method and fix Inngest duplicate workflow execution bug (#11093)

    New Feature: startAsync() for fire-and-forget workflow execution

    • Add Run.startAsync() to base workflow class - starts workflow in background and returns { runId } immediately
    • Add EventedRun.startAsync() - publishes workflow start event without subscribing for completion
    • Add InngestRun.startAsync() - sends Inngest event without polling for result

    Bug Fix: Prevent duplicate Inngest workflow executions

    • Fix getRuns() to properly handle rate limits (429), empty responses, and JSON parse errors with retry logic and exponential backoff
    • Fix getRunOutput() to throw NonRetriableError when polling fails, preventing Inngest from retrying the parent function and re-triggering the workflow
    • Add timeout to getRunOutput() polling (default 5 minutes) with NonRetriableError on timeout

    This fixes a production issue where polling failures after successful workflow completion caused Inngest to retry the parent function, which fired a new workflow event and resulted in duplicate executions (e.g., duplicate Slack messages).

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/lance@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/langfuse@1.0.0-beta.5

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5

@mastra/langsmith@1.0.0-beta.6

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5

@mastra/libsql@1.0.0-beta.8

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates
  • fix: make getSqlType consistent across storage adapters (#11112)

    • PostgreSQL: use getSqlType() in createTable instead of toUpperCase()
    • LibSQL: use getSqlType() in createTable, return JSONB for jsonb type (matches SQLite 3.45+ support)
    • ClickHouse: use getSqlType() in createTable instead of COLUMN_TYPES constant, add missing types (uuid, float, boolean)
    • Remove unused getSqlType() and getDefaultValue() from MastraStorage base class (all stores use StoreOperations versions)

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/longmemeval@1.0.0-beta.12

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/fastembed@1.0.0-beta.1
  • @mastra/memory@1.0.0-beta.5
  • @mastra/libsql@1.0.0-beta.8

@mastra/mcp-docs-server@1.0.0-beta.12

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/memory@1.0.0-beta.5

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

  • Fix crash in updateMessageToHideWorkingMemoryV2 when message.content is not a V2 object. Added defensive type guards before spreading content to handle legacy or malformed message formats. (#11180)

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/schema-compat@1.0.0-beta.3

@mastra/mongodb@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/mssql@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/observability@1.0.0-beta.5

Patch Changes

  • Move zod from dependencies to devDependencies as users should install it themselves to avoid version conflicts. (#11114)

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/otel-bridge@1.0.0-beta.5

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5
  • @mastra/otel-exporter@1.0.0-beta.6

@mastra/otel-exporter@1.0.0-beta.6

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5

@mastra/pg@1.0.0-beta.8

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates
  • fix: make getSqlType consistent across storage adapters (#11112)

    • PostgreSQL: use getSqlType() in createTable instead of toUpperCase()
    • LibSQL: use getSqlType() in createTable, return JSONB for jsonb type (matches SQLite 3.45+ support)
    • ClickHouse: use getSqlType() in createTable instead of COLUMN_TYPES constant, add missing types (uuid, float, boolean)
    • Remove unused getSqlType() and getDefaultValue() from MastraStorage base class (all stores use StoreOperations versions)

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/playground-ui@7.0.0-beta.12

Patch Changes

  • Adds tool/workflow error being surfaced to the side panel in the playground (#11099)

  • Auto resume suspended tools if autoResumeSuspendedTools: true (#11157)

    The flag can be added to defaultAgentOptions when creating the agent or to options in agent.stream or agent.generate

    const agent = new Agent({
      //...agent information,
      defaultAgentOptions: {
        autoResumeSuspendedTools: true,
      },
    });
  • Fix trace-span-usage component to handle object values in token usage data. Usage objects can contain nested inputDetails and outputDetails properties which are objects, not numbers. The component now properly type-checks values and renders object properties as nested key-value pairs. (#11141)

  • Add Run instance to client-js. workflow.createRun returns the Run instance which can be used for the different run methods. (#11207) With this change, run methods cannot be called directly on workflow instance anymore

    - const result = await workflow.stream({ runId: '123', inputData: { ... } });
    + const run = await workflow.createRun({ runId: '123' });
    + const stream = await run.stream({ inputData: { ... } });
    
  • Remove deprecated playground-only prompt generation handler (functionality moved to @mastra/server) (#11074)

    Improve prompt enhancement UX: show toast errors when enhancement fails, disable button when no model has a configured API key, and prevent users from disabling all models in the model list

    Add missing /api/agents/:agentId/instructions/enhance endpoint that was referenced by @mastra/client-js and @mastra/playground-ui

  • Focus the textarea when clicking anywhere in the entire chat prompt input box (#11160)

  • Removes redundant "Working Memory" section from memory config panel (already displayed in dedicated working memory component) (#11104) Fixes badge rendering for falsy values by using ?? instead of || (e.g., false was incorrectly displayed as empty string) Adds tooltip on disabled "Edit Working Memory" button explaining that working memory becomes available after the agent calls updateWorkingMemory

  • Workflow step detail panel improvements (#11134)

    • Add step detail panel to view map configs and nested workflows from the workflow graph
    • Enable line wrapping for code display in map config panel and WHEN condition nodes
    • Auto-switch to "Current Run" tab when opening step details
    • Add colored icons matching workflow graph (orange for map, purple for workflow)
    • Simplify step detail context by removing unused parent stack navigation
  • Fix agent default settings not being applied in playground (#11107)

    • Fix settings hook to properly merge agent default options with localStorage values
    • Map maxOutputTokens (AI SDK v5) to maxTokens for UI compatibility
    • Add seed parameter support to model settings
    • Add frequency/presence penalty inputs with sliders
    • Extract and apply agent's defaultOptions.modelSettings on load
  • fix isTopLevelSpan value definition on SpanScoring to properly recognize lack of span?.parentSpanId value (null or empty string) (#11083)

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/react@0.1.0-beta.12
  • @mastra/schema-compat@1.0.0-beta.3
  • @mastra/client-js@1.0.0-beta.12
  • @mastra/ai-sdk@1.0.0-beta.9

@mastra/posthog@1.0.0-beta.5

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/observability@1.0.0-beta.5

@mastra/react-hooks@0.1.0-beta.12

Patch Changes

  • Remove redundant toolCalls from network agent finalResult (#11189)

    The network agent's finalResult was storing toolCalls separately even though all tool call information is already present in the messages array (as tool-call and tool-result type messages). This caused significant token waste since the routing agent reads this data from memory on every iteration.

    Before: finalResult: { text, toolCalls, messages } After: finalResult: { text, messages }

    +Migration: If you were accessing finalResult.toolCalls, retrieve tool calls from finalResult.messages by filtering for messages with type: 'tool-call'.

    Updated @mastra/react to extract tool calls directly from the messages array instead of the removed toolCalls field when resolving initial messages from memory.

    Fixes #11059

  • Auto resume suspended tools if autoResumeSuspendedTools: true (#11157)

    The flag can be added to defaultAgentOptions when creating the agent or to options in agent.stream or agent.generate

    const agent = new Agent({
      //...agent information,
      defaultAgentOptions: {
        autoResumeSuspendedTools: true,
      },
    });

Dependency Updates

  • @mastra/client-js@1.0.0-beta.12

@mastra/schema-compat@1.0.0-beta.3

Patch Changes

  • Embed AI types to fix peerdeps mismatches (9650cce)

@mastra/server@1.0.0-beta.12

Patch Changes

  • Add resourceId to workflow routes (#11166)

  • Fix MastraServer.tools typing to accept tools with input schemas (5118f38)

    Fixes issue #11185 where MastraServer.tools was rejecting tools created with createTool({ inputSchema }). Changed the tools property type from Record<string, Tool> to ToolsInput to accept tools with any schema types (input, output, or none), as well as Vercel AI SDK tools and provider-defined tools.

    Tools created with createTool({ inputSchema: z.object(...) }) now work without TypeScript errors.

  • Remove deprecated playground-only prompt generation handler (functionality moved to @mastra/server) (#11074)

    Improve prompt enhancement UX: show toast errors when enhancement fails, disable button when no model has a configured API key, and prevent users from disabling all models in the model list

    Add missing /api/agents/:agentId/instructions/enhance endpoint that was referenced by @mastra/client-js and @mastra/playground-ui

Dependency Updates

  • @mastra/core@1.0.0-beta.12

@mastra/upstash@1.0.0-beta.7

Patch Changes

  • Preserve error details when thrown from workflow steps (#10992)

    Workflow errors now retain custom properties like statusCode, responseHeaders, and cause chains. This enables error-specific recovery logic in your applications.

    Before:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom error properties were lost
      console.log(result.error); // "Step execution failed" (just a string)
    }

    After:

    const result = await workflow.execute({ input });
    if (result.status === 'failed') {
      // Custom properties are preserved
      console.log(result.error.message); // "Step execution failed"
      console.log(result.error.statusCode); // 429
      console.log(result.error.cause?.name); // "RateLimitError"
    }

    Type change: WorkflowState.error and WorkflowRunState.error types changed from string | Error to SerializedError.

    Other changes:

    • Added UpdateWorkflowStateOptions type for workflow state updates

Dependency Updates

  • @mastra/core@1.0.0-beta.12

create-mastra@1.0.0-beta.10

Patch Changes

  • Auto resume suspended tools if autoResumeSuspendedTools: true (#11157)

    The flag can be added to defaultAgentOptions when creating the agent or to options in agent.stream or agent.generate

    const agent = new Agent({
      //...agent information,
      defaultAgentOptions: {
        autoResumeSuspendedTools: true,
      },
    });
  • Add Run instance to client-js. workflow.createRun returns the Run instance which can be used for the different run methods. (#11207) With this change, run methods cannot be called directly on workflow instance anymore

    - const result = await workflow.stream({ runId: '123', inputData: { ... } });
    + const run = await workflow.createRun({ runId: '123' });
    + const stream = await run.stream({ inputData: { ... } });
    
  • fix isTopLevelSpan value definition on SpanScoring to properly recognize lack of span?.parentSpanId value (null or empty string) (#11083)


mastra@1.0.0-beta.10

Patch Changes

  • Auto resume suspended tools if autoResumeSuspendedTools: true (#11157)

    The flag can be added to defaultAgentOptions when creating the agent or to options in agent.stream or agent.generate

    const agent = new Agent({
      //...agent information,
      defaultAgentOptions: {
        autoResumeSuspendedTools: true,
      },
    });
  • Add Run instance to client-js. workflow.createRun returns the Run instance which can be used for the different run methods. (#11207) With this change, run methods cannot be called directly on workflow instance anymore

    - const result = await workflow.stream({ runId: '123', inputData: { ... } });
    + const run = await workflow.createRun({ runId: '123' });
    + const stream = await run.stream({ inputData: { ... } });
    
  • Fix the development experience of the studio. It was not able to resolve the running instance because the index.html variables were not replaced in the vite dev standalone config (#11085)

  • fix isTopLevelSpan value definition on SpanScoring to properly recognize lack of span?.parentSpanId value (null or empty string) (#11083)

Dependency Updates

  • @mastra/core@1.0.0-beta.12
  • @mastra/deployer@1.0.0-beta.12

Fetched April 7, 2026