Skip to main content
Glama

a2a_get_task

Retrieve the current status and details of a specific task in the A2A Client MCP Server by providing the task ID and agent ID for tracking and monitoring purposes.

Instructions

Get the current state of a task

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskIdYesID of the task to retrieve
agentIdYesID of the agent that handled the task

Implementation Reference

  • MCP tool handler for 'a2a_get_task': destructures taskId and agentId from arguments, retrieves the A2AClient via agentManager, calls client.getTask(), and returns the result as JSON text content.
    case "a2a_get_task": { const { taskId, agentId } = args as { taskId: string; agentId: string }; const client = agentManager.getClientById(agentId); if (!client) { throw new Error(`No agent found with ID ${agentId}`); } const result = await client.getTask({ id: taskId }); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }
  • Input schema for 'a2a_get_task' tool defining required taskId and agentId parameters.
    inputSchema: { type: "object", properties: { taskId: { type: "string", description: "ID of the task to retrieve", }, agentId: { type: "string", description: "ID of the agent that handled the task", }, }, required: ["taskId", "agentId"], },
  • index.ts:55-72 (registration)
    Registration of 'a2a_get_task' tool in the ListTools response, including name, description, and input schema.
    { name: "a2a_get_task", description: "Get the current state of a task", inputSchema: { type: "object", properties: { taskId: { type: "string", description: "ID of the task to retrieve", }, agentId: { type: "string", description: "ID of the agent that handled the task", }, }, required: ["taskId", "agentId"], }, },

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tesla0225/mcp-a2a'

If you have feedback or need assistance with the MCP directory API, please join our Discord server