A2A Agent Card Builder
Define agent name, description, provider, capabilities, and skills, then export a JSON document for the A2A agent card discovery endpoint at /.well-known/agent-card.json.
Identity
Capabilities
Skills
agent-card.json
json · 38 lines · 805 B
{
"name": "Acme Support Agent",
"description": "Answers product questions and creates support tickets.",
"url": "https://example.com/a2a",
"version": "1.0.0",
"provider": {
"organization": "Acme Inc",
"url": "https://example.com"
},
"capabilities": {
"streaming": true,
"pushNotifications": false,
"stateTransitionHistory": false
},
"defaultInputModes": [
"text/plain"
],
"defaultOutputModes": [
"text/plain"
],
"authentication": {
"schemes": [
"bearer"
]
},
"skills": [
{
"id": "answer_question",
"name": "answer_question",
"description": "Answer a question about Acme products."
},
{
"id": "create_ticket",
"name": "create_ticket",
"description": "Open a support ticket."
}
]
}Next.js route handler
typescript · 51 lines · 1.1 KB
// app/.well-known/agent-card.json/route.ts
import { NextResponse } from "next/server";
const CARD = {
"name": "Acme Support Agent",
"description": "Answers product questions and creates support tickets.",
"url": "https://example.com/a2a",
"version": "1.0.0",
"provider": {
"organization": "Acme Inc",
"url": "https://example.com"
},
"capabilities": {
"streaming": true,
"pushNotifications": false,
"stateTransitionHistory": false
},
"defaultInputModes": [
"text/plain"
],
"defaultOutputModes": [
"text/plain"
],
"authentication": {
"schemes": [
"bearer"
]
},
"skills": [
{
"id": "answer_question",
"name": "answer_question",
"description": "Answer a question about Acme products."
},
{
"id": "create_ticket",
"name": "create_ticket",
"description": "Open a support ticket."
}
]
};
export async function GET() {
return NextResponse.json(CARD, {
headers: {
"content-type": "application/json; charset=utf-8",
"cache-control": "public, max-age=300",
},
});
}
Apply this with your coding agent
Get a ready-made prompt that wraps the output above with implementation steps. Paste it into your AI assistant and let it ship the change.
Validate with
About the agent card
An agent card is a JSON document that describes an agent so other agents and clients can discover and call it. The current A2A convention is to host it at /.well-known/agent-card.json.
The card is a description, not a runtime. Implement the actual A2A endpoints separately and reference them from the url field.
Verify on a real URL
Run a full agent readiness scan to see how your live site responds end to end.