Skip to main content

Set up an A2A trigger

To allow external agents to communicate with Retool agents, you can enable the A2A trigger on your agent's configuration page, and copy the endpoint and API key into your A2A client. An API key is provided for each agent, and must be passed to the client via an X-Api-Key header. API keys can be rotated.

The process to use the Agent-to-agent (A2A) protocol with agents is similar to creating a webhook trigger in workflows.

The A2A client then sends messages via common messaging formats like the HTTP+REST or JSON-RPC APIs, and Server-Sent Events (SSE) for long-running streaming updates.

Prior to enabling A2A, you must have all the necessary permissions for Retool AI and AI Agents turned on for your organization. Refer to Permissions for Agents for more information.

Enable the A2A trigger

On your agent's Configuration page:

  1. Click the A2A trigger.
  2. Toggle the A2A switch on.
  3. You can either copy and paste the Endpoint and the API key separately into your A2A client, or you can click Copy next to Endpoint and select Copy as cURL from the dropdown. This copies a cURL command preformatted with your agent's information and API key to your clipboard.

The default endpoint provided is the Get agent card endpoint.

You can cURL to test the agent response to different endpoints, or trigger your agent via an external agent.

Additional resources

To continue learning about A2A, explore the following resources: