submitted, input-required, and completed. This guide explains the technical architecture that makes it possible—from protocol layers to storage backends.
What You’ll Learn:
- How requests flow through Bindu’s layered architecture
- Why TaskManager coordinates everything (the “restaurant manager”)
- How workers execute your agent asynchronously
- Storage, caching, and scaling strategies
System Overview
Core Components
1. Protocol Layer
A2A Protocol - Agent-to-agent communication (task lifecycle, context management)AP2 Protocol - Commerce extensions (payment mandates, cart management)
X402 Protocol - Micropayments (cryptographic signatures, multi-currency) All use JSON-RPC 2.0 for request/response handling.
2. Security & Identity Layer
Authentication - Auth0, OAuth2, API Keys, Mutual TLSDID (Decentralized Identity) - Unique, verifiable agent identity
PKI - RSA/ECDSA key generation, signature verification
3. Application Layer
BinduApplication - Starlette-based web server with async/await, WebSocket supportRequest Router - Routes to
/agent/card, /agent/skills, /tasks/*, /contexts/*Schema Validator - Validates request structure and types
4. Orchestration Layer
TaskManager - Central coordinator that creates tasks, manages state, coordinates workersTask Queue - Memory (dev) or Redis (prod) for distributed task scheduling
Worker Pool - Executes tasks asynchronously, handles retries and timeouts
5. Storage Layer
Memory Storage (dev) - In-memory dictionaries for tasks, contexts, artifactsPostgreSQL (prod) - ACID compliance, relational queries, JSON support
Redis Cache - Session storage, rate limiting, pub/sub notifications
6. Agent Layer
Framework Agnostic - Works with Agno, LangChain, CrewAI, LlamaIndexSkills Registry - Defines agent capabilities via
/agent/skills endpointTool Integrations - 113+ built-in toolkits for data, code, web, APIs
7. Observability Layer
Distributed Tracing - Jaeger/OTLP tracks requests across all componentsLLM Observability - Phoenix/Langfuse monitors token usage, latency, cost
Metrics - Request rate, task duration, error rate, queue depth, worker utilization
Data Flow
Complete Request Lifecycle
Let’s trace a complete request through the system:Request Flow Summary
Phase 1: Submit (0-50ms) - Client sendsmessage/send → Auth validates → TaskManager creates task → Returns task_id immediately
Phase 2: Execute (async) - Worker dequeues → Runs your agent → Updates state (working → input-required or completed)
Phase 3: Retrieve (anytime) - Client polls with tasks/get → Gets current state + artifacts
Summary
Bindu’s architecture is designed for:- Simplicity: Wrap any agent with minimal code
- Scalability: From localhost to distributed cloud
- Reliability: Built-in error handling and recovery
- Observability: Complete visibility into operations
- Security: Authentication and identity built-in
- Standards: Protocol-first design (A2A, AP2, X402)
Connecting the Dots
You’ve now seen three perspectives:- Key Concepts - How task states enable interactive conversations
- This Page (Architecture) - The technical layers that power those states
- Task-First Pattern - Why this design enables multi-agent orchestration
- Your message hits the Protocol Layer → authenticated by Security Layer
- TaskManager creates a task in “submitted” state → stored in Storage Layer
- Worker executes your agent → agent returns structured response requesting input
- TaskManager updates state to “input-required” → you see the question
- You respond “Instagram” → same task continues → completes with artifact