agent2agentGuides

Guides

Getting Started

This guide walks you through installing agent2agent, building a minimal agent, and calling it from both curl and Ruby.

Agent DSL

This guide covers the handler DSL for building agents.

Streaming

This guide covers SSE streaming for real-time task updates and chunked artifact delivery.

Multi-Turn Conversations

This guide covers using TASK_STATE_INPUT_REQUIRED to build confirmation-gated and multi-step conversations.

Async Background Jobs

This guide covers non-blocking background work with returnImmediately and Store::Processor.

Task Stores

This guide covers the in-memory and SQLite task stores and their shared interface.

Schema Validation

This guide covers the 47 A2A protocol types available as validated Ruby objects.

Protocol Operations

This guide covers all 11 A2A operations and task state lifecycle.

Tracing

This guide explains how to add distributed tracing to your A2A agents using the traces gem.

Echo Agent

A minimal A2A agent that echoes messages back. The simplest starting point for understanding the A2A protocol.

Multi-Turn Conversation

Demonstrates the INPUT_REQUIRED state for multi-turn interactions where the agent asks for user confirmation before proceeding.

Async Jobs

Demonstrates non-blocking task processing with background fibers, live progress via SSE, and polling.

Streaming Artifacts

Demonstrates chunked artifact streaming with append/lastChunk semantics, streaming multiple files as separate artifacts over SSE.

Push Notifications

Demonstrates asynchronous task processing with webhook-based push notification delivery for status and artifact updates.

Multi-Agent Orchestration

Three A2A agents communicating via the protocol: an LLM-powered orchestrator discovers remote agents and delegates tasks to the most appropriate one.

Full Echo Agent

Demonstrates all 11 A2A protocol operations in a single agent with Falcon-native SSE streaming and a SQLite-backed persistent task store.