Skip to content

CAMEL-23063: Add camel-a2a component for Agent-to-Agent (A2A) protoco…#23711

Open
luigidemasi wants to merge 1 commit into
apache:mainfrom
luigidemasi:CAMEL-23063
Open

CAMEL-23063: Add camel-a2a component for Agent-to-Agent (A2A) protoco…#23711
luigidemasi wants to merge 1 commit into
apache:mainfrom
luigidemasi:CAMEL-23063

Conversation

@luigidemasi
Copy link
Copy Markdown
Contributor

…l integration

Adds the camel-a2a component implementing the A2A (Agent-to-Agent) protocol for Apache Camel. The component provides both producer and consumer support, enabling Camel
routes to participate in standardized agent-to-agent communication.

Features

  • Consumer — exposes a Camel route as an A2A server with automatic agent card serving at /.well-known/agent-card.json
  • Producer — sends A2A messages (MESSAGE_SEND, MESSAGE_STREAM, TASK_GET, TASK_CANCEL, etc.) to remote agents
  • Protocol bindings — REST and JSON-RPC 2.0
  • Streaming — Server-Sent Events (SSE) for real-time task updates
  • Authentication — API key, Bearer token, OAuth 2.0, OpenID Connect
  • Task management — in-memory task store with TTL, push notifications, subscriber management
  • Agent card — discovery, resolution (file < bean < URI params), and auto-serving
  • Type converters — Message/Task to String, plus Simple DSL functions (a2aText(), a2aData(), a2aFile())
  • Progress APIA2AProgress.emit() for status updates from any route

Demo

A multi-agent demo showcasing camel-a2a in action is available at:

https://github.com/luigidemasi/camel-a2a-morning-routine

@luigidemasi luigidemasi requested a review from davsclaus June 2, 2026 15:34
"description": "Camel A2A component for Agent-to-Agent protocol communication",
"deprecated": false,
"firstVersion": "4.21.0",
"label": "ai,a2a",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the reason for the a2a label? Plan to have several agent to agents components?

What about ai and agent labels? maybe we will have some components acting as agents or doing agent to something else communication?

return "oauth2";
}
if (configuration.getBearerToken() != null) {
return "http";
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it for both http and https?

Comment on lines +56 to +58
.artifacts(task.artifacts != null ? new ArrayList<>(task.artifacts) : null)
.history(task.history != null ? new ArrayList<>(task.history) : null)
.metadata(task.metadata != null ? new HashMap<>(task.metadata) : null);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about providing empty List or Map instead of null?

it avoids having to check for nullness

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 2, 2026

🌟 Thank you for your contribution to the Apache Camel project! 🌟
🤖 CI automation will test this PR automatically.

🐫 Apache Camel Committers, please review the following items:

  • First-time contributors require MANUAL approval for the GitHub Actions to run
  • You can use the command /component-test (camel-)component-name1 (camel-)component-name2.. to request a test from the test bot although they are normally detected and executed by CI.
  • You can label PRs using skip-tests and test-dependents to fine-tune the checks executed by this PR.
  • Build and test logs are available in the summary page. Only Apache Camel committers have access to the summary.

⚠️ Be careful when sharing logs. Review their contents before sharing them publicly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants