In this article
A successful Activity records a completed operation, while the returned MCP payload determines whether the tool achieved the requested result.
Locate the error in the integration stack
An agent calls a document-conversion tool through Temporal and receives a tool error, but no automatic Activity retry occurs. That can match the documented contract. The current, pre-release MCP integration guide distinguishes a returned tool result with is_error=True from an Activity failure. Treat the integration version as part of the explanation because its APIs and configuration can still change.
Inspect the returned tool result
The guide says a tool-error result completes the Activity successfully. Workflow code must decide whether to retry through an appropriate application path, return an error or fail the workflow. For conversion, an unsupported input format may be a meaningful tool outcome rather than a transient infrastructure failure. Do not convert it into an empty successful document merely because Temporal recorded the Activity as completed.
Separate protocol and transport failures
JSON-RPC error responses fail the Activity with an MCPProtocolError application failure. Invalid requests, invalid arguments and invalid response schemas are nonretryable, while documented transient server, connection and timeout failures can retry. The retry-policy reference explains the failure-driven retry mechanism. Preserve the class and relevant error data rather than reducing every failure to a generic message that loses the distinction needed for recovery.
Keep completion and task success as separate records
The Activity Definition guide records returned results for durable execution. That machinery can preserve a tool’s negative result just as it preserves useful content. A completed Activity therefore answers whether the operation returned a result, while the workflow’s result handling answers whether the requested transformation succeeded. Use distinct status fields or observations when presenting those outcomes to a caller who needs an actionable explanation.
Verify contrasting outcomes with harmless inputs
Use a supported sample, an unsupported document and a controlled connection failure. Inspect the returned error flag, Activity status and whether another attempt occurred. Response-contract guidance separates transport and application meaning; tool observations retain the evidence. A useful adapter makes negative tool results visible and reserves automatic retries for failures where another attempt has a reason to help.
Earn rental income from GPUs
Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.