This is an example Business A2A Agent that implements UCP Extension. The extension allows the business agent to respond to the client applications with UCP defined data types.
A simple chat client is also provided to interact with the business agent that consumes the A2A interface exposed by the business agent.
The example uses a mock inmemory RetailStore to simulate a business store.
- Python 3.13
- UV
- Gemini API Key (The agent uses Gemini model to generate responses)
- Clone the samples repository.
cd a2a/business_agent- Run
uv sync - Copy the env.example file to .env and then add your Gemini API key to .env
- Run
uv run business_agent - This starts the business agent on port 10999. You can verify by accessing the agent card at http://localhost:10999/.well-known/agent-card.json
- The business agent's UCP Profile can be found at http://localhost:10999/.well-known/ucp
Prerequisites: Node.js
- cd chat-client
- Install dependencies:
npm install - Run the app:
npm run dev - The Chat Client UCP Profile can be found at http://localhost:3000/profile/agent-profile.json
- Launch the browser and navigate to http://localhost:3000/
- In the Chat interface, type "show me cookies available in stock" and press enter.
- The agent will return products available in stock.
- Click 'Add to Checkout' for any product.
- The agent will ask for required information such as email address, shipping address etc.
- Once the required information is provided, click 'Complete Payment'.
- The UI shows available mock payment options.
- Select a payment method and click 'Confirm Purchase'.
- The agent will create an order and return the order response.
This is an example implementation for demonstration purposes and is not intended for production use.