---
title: rpk ai agent a2a
latest-operator-version: v26.2.6
latest-console-tag: v3.14.0
latest-connect-version: 4.118.0
latest-redpanda-tag: v26.2.7
docname: rpk/rpk-ai/rpk-ai-agent-a2a
page-component-name: agentic-data-plane
page-version: master
page-component-version: master
page-component-title: Agentic Data Plane
page-relative-src-path: rpk/rpk-ai/rpk-ai-agent-a2a.adoc
page-edit-url: https://github.com/redpanda-data/adp-docs/edit/main/modules/reference/pages/rpk/rpk-ai/rpk-ai-agent-a2a.adoc
description: Interact with an agent over the A2A (Agent-to-Agent) protocol. The AGENT argument is either a registry agent name or a full A2A endpoint URL (anything starting with http:// or https://).
page-git-created-date: "2026-06-25"
page-git-modified-date: "2026-09-22"
page-generated-sources:
  - include: streaming:reference:partial$rpk-ai/rpk-ai-agent-a2a.adoc
    generator: rpk-docs
    version: null
    source: the rpk command help in redpanda-data/streaming-enterprise
page-generated-content: partial
---

# rpk ai agent a2a

> For the complete documentation index, see [llms.txt](https://docs.redpanda.com/llms.txt). Component-specific: [agentic-data-plane-full.txt](https://docs.redpanda.com/agentic-data-plane-full.txt)

<!-- Source: https://docs.redpanda.com/agentic-data-plane/reference/rpk/rpk-ai/rpk-ai-agent-a2a.md -->

Interact with an agent over the A2A (Agent-to-Agent) protocol.

The AGENT argument is either a registry agent name or a full A2A endpoint URL (anything starting with http:// or https://). A registry agent name resolves to the agent’s A2A endpoint via its runtime status.

Authentication: your environment’s bearer token is attached when the target is a registry agent or an explicit URL on the environment’s dataplane host. Explicit URLs on other hosts are called without credentials so your token never leaves the platform (a note on stderr says so when this happens).

Output formats: table (`default`, human-readable) and `-o json` / `-o yaml`. Streams (`--stream`, task watch) emit one JSON event per line under both `json` and `yaml`.

Exit codes: 0 success (including tasks waiting for more input), 4 task ended failed/canceled/rejected, 1 anything else.

## Usage

```bash
rpk ai agent a2a [flags]
```

## Examples

This section provides examples of how to use `rpk ai agent a2a`.

Discover what an agent can do

```bash
rpk ai agent a2a card financial-advisor
```

Ask a question (waits for the reply)

```bash
rpk ai agent a2a send financial-advisor "How did tech stocks do today?"
```

Continue the same conversation

```bash
rpk ai agent a2a send financial-advisor --context-id CTX "And yesterday?"
```

Stream the reply as it is produced

```bash
rpk ai agent a2a send financial-advisor --stream "Summarize the market"
```

Inspect, watch, or cancel a long-running task

```bash
rpk ai agent a2a task get financial-advisor TASK_ID
rpk ai agent a2a task watch financial-advisor TASK_ID
rpk ai agent a2a task cancel financial-advisor TASK_ID
```

## Subcommands

| Command | Description |
| --- | --- |
| [`rpk ai agent a2a card`](https://docs.redpanda.com/agentic-data-plane/reference/rpk/rpk-ai/rpk-ai-agent-a2a-card/) | Fetch the A2A agent card: the JSON discovery document describing the agent’s identity, skills, supported transports and capabilities. Use `-o json` to feed the raw card to other tools. |
| [`rpk ai agent a2a send`](https://docs.redpanda.com/agentic-data-plane/reference/rpk/rpk-ai/rpk-ai-agent-a2a-send/) | Send a text message to an agent over A2A and print the reply. The message comes from the positional argument, or from stdin when the argument is omitted or "-" (so you can pipe a prompt in). |
| [`rpk ai agent a2a task`](https://docs.redpanda.com/agentic-data-plane/reference/rpk/rpk-ai/rpk-ai-agent-a2a-task/) | Manage tasks created by agent-to-agent (A2A) conversations. Task IDs come from `rpk ai agent a2a send` replies. |

## Global flags

| Value | Type | Description |
| --- | --- | --- |
| `--config` | string | Redpanda or `rpk` config file; default search paths are `~/.config/rpk/rpk.yaml`, `$PWD/redpanda.yaml`, and `/etc/redpanda/redpanda.yaml`. |
| `-X, --config-opt` | stringArray | Override `rpk` configuration settings; `-X help` for detail or `-X list` for terser detail. |
| `--ignore-profile` | bool | Ignore `rpk.yaml` and `redpanda.yaml`; use default settings. |
| `--profile` | string | `rpk` profile to use. |
| `-v, --verbose` | bool | Enable verbose logging. |