A2A Interop
MCP lets a model call InterviewForge as a tool. A2A (Agent2Agent) lets another agent discover it and hand it a task. The difference is not protocol trivia but reuse: an ATS that speaks A2A needs a card it can discover and a task it can poll, not a bespoke HTTP API.
Discovery
GET /.well-known/agent-card.json host card: name, version, capabilities, skills
GET /.well-known/agents index of delegatable agents
GET /.well-known/agents/planner.json one agent's cardCards are public — they say what this host can do, not who may call it; the RPC still requires a profile token.
{
"name": "InterviewForge",
"protocolVersion": "0.2.5",
"capabilities": { "streaming": false, "pushNotifications": false },
"skills": [{ "id": "run-interview", "name": "Run an interview", "tags": ["interview", "hiring"] }]
}streaming and pushNotifications are declared false on purpose: do not promise what is not implemented. A card that lies is worse than a plain one — clients write code against it.
Task lifecycle
One A2A task is one interview:
input-requiredmeans it is the candidate's turn; later messages on the samecontextIdare answers.completedcarries a compact report JSON (score, verdict, per-question, improvements) asartifacts[0], not the whole transcript.tasks/cancelaborts the session's in-flight runs and marks the taskcanceled; a finished task returns-32002.
Tasks live in a2a_tasks (migration 18), so tasks/get survives reconnects and restarts — which is what polling semantics need.
Delegation is A2A too
The Director's delegate tool is not a private shortcut: it builds a standard message/send with metadata.agent and gets a real task back.
- RPC logic lives in
server/a2a-handler.tsand knows nothing about transports. - The HTTP route (
server/routes/a2a.ts) and the in-process client (server/a2a-client.ts) both call it. - An agent outside the allowlist gets
-32602rather than being quietly run — naming an agent in a protocol is not authorisation.
Error shapes
| code | meaning |
|---|---|
-32600 | jsonrpc is not "2.0" |
-32601 | unknown method |
-32602 | bad params (no text part, agent not allowlisted, delegation without sessionId) |
-32001 | task not found |
-32002 | task already finished, cannot cancel |
Boundaries
- No streaming: poll the task;
message/streamreturns-32601. - One
contextIdis one interview; use different contexts for concurrency. - The A2A entry point is subject to the same profile auth and concurrency cap as the UI.