Overview
The A2A Callback node is designed to send processing results back to an A2A Server for synchronous workflow integration. It supports sending success, error, or fully customized results via HTTP POST requests to a callback URL provided by the A2A Server. This node is useful in scenarios where workflows need to report their status and results back to an external orchestrator or agent system, enabling coordinated task management and real-time feedback.
Practical examples:
- Reporting successful completion of a data transformation task with optional inclusion of input and processed data.
- Sending detailed error information when a workflow fails, including error codes and messages.
- Returning custom status and arbitrary JSON result data for advanced use cases requiring full control over the callback payload.
Properties
| Name | Meaning |
|---|---|
| Custom Status | The status to send back to the A2A Server. Options: Completed, Failed, Partial. |
| Custom Result Data | JSON object containing custom result data to send in the callback. Allows full control over the content sent back. |
| Callback URL Expression | An n8n expression that resolves to the callback URL provided by the A2A Server node. This URL is where the node sends the result data. Required property. |
| Advanced Options | Collection of additional settings: • Callback URL Field: Field name in input JSON containing the callback URL (default: a2a_callback_url).• Task ID Field: Field name for task ID (default: task_id).• Session ID Field: Field name for session ID (default: session_id).• Timeout (seconds): Timeout for the HTTP request (default: 10 seconds). • Include Workflow Metadata: Whether to include metadata about the workflow execution in the callback (default: true). |
Output
The node outputs an array of items corresponding to each input item, each containing the original input JSON extended with callback result metadata:
a2a_callback_success(boolean): Indicates if the callback HTTP request was successful.a2a_callback_status(number): HTTP status code returned by the callback endpoint.a2a_callback_response(object): Parsed JSON response from the callback server.a2a_callback_sent_at(ISO timestamp): When the callback was sent.operation(string): The operation performed (success,error, orcustom).callback_url(string): The URL to which the callback was sent.- If the callback failed:
a2a_callback_error(string): Error message describing the failure.error_timestamp(ISO timestamp): When the error occurred.
No binary data output is produced by this node.
Dependencies
- Requires an accessible callback URL provided by the A2A Server node or available in the input data.
- Uses standard HTTP POST requests with JSON payloads.
- No external API keys or credentials are required by this node itself.
- The node expects the callback URL to follow a specific format to extract task IDs if not explicitly provided.
- The node depends on the presence of certain fields in the input JSON or expressions resolving to the callback URL.
Troubleshooting
Callback URL Not Found:
If the callback URL cannot be resolved from the expression or fallback locations, the node throws an error listing all checked locations.
Resolution: Verify the callback URL expression matches the exact node name in your workflow and that the A2A Server node is correctly configured and connected upstream.Invalid JSON in Custom Result:
When using the "Send Custom Result" operation, the custom result JSON must be valid. Invalid JSON will cause an error.
Resolution: Validate and correct the JSON syntax in the "Custom Result Data" property.HTTP Request Failures:
If the callback endpoint returns an error status, the node marks the callback as unsuccessful and includes the HTTP status and error message in the output.
Resolution: Check network connectivity, callback URL correctness, and server availability.Expression Evaluation Errors:
Errors evaluating the callback URL expression often indicate incorrect node names or syntax in the expression.
Resolution: Double-check the node name used in the expression and try alternative naming conventions suggested in the error message.
Links and References
- n8n Expressions Documentation
- A2A Server Integration Guide (Replace with actual link if available)
- HTTP Request Node Documentation (for understanding HTTP callbacks)