Defines shared constants and status types for the Model Context Protocol (MCP) Tasks extension. Use this to maintain protocol compatibility when building task-based AI agent integrations.
// Source: https://github.com/mastra-ai/mastra | License: Apache-2.0 | Copyright 2025 Kepler Software, Inc
// Provided via justclaw.it.com; keep this notice with the code.
/**
* Wire constants for the MCP Tasks extension (SEP-2663, protocol revision 2026-07-28).
*
* @experimental SEP-2663 extension; API may change.
*/
/** Extension identifier used as the key under `capabilities.extensions`. */
export const TASKS_EXTENSION_ID = 'io.modelcontextprotocol/tasks';
export const TASKS_METHODS = {
get: 'tasks/get',
update: 'tasks/update',
cancel: 'tasks/cancel',
} as const;
/** `resultType` of a `tools/call` result that is a task handle instead of a `CallToolResult`. */
export const TASK_RESULT_TYPE = 'task';
export const TASK_STATUSES = ['working', 'input_required', 'completed', 'fa
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key