# Agent-to-Agent Communication Gateway

> Lets agents message each other — and stops them from replying to each other forever.

- Period: 2026.03
- Status: Frozen
- Type: Original work by the author
- Tags: Agent protocols, Token authentication, Loop prevention
- Cover: https://me.ai-clover.com/covers/cover-a2a-gateway.webp
- Original: https://me.ai-clover.com/en/projects/a2a-gateway/

A small project. It opens an HTTP entry point for external agents to send messages into OpenClaw, with Token authentication, message validation, forwarding, and logging. The most interesting part came in v1.2, and it's all about stopping two agents from replying to each other endlessly: keyword filtering, a cap on conversation turns, and rate limits on calls.

Finishing it changed how I think about multi-agent collaboration: the hard part isn't getting them to talk — it's identity, boundaries, and knowing when to stop. I haven't re-verified whether this gateway is still running, so I won't write "online" on its page.

## Diagrams

### Main flow

```mermaid
graph LR
  A[External agent] --> B[HTTP entry]
  B --> C[Token auth]
  C --> D[Message validation]
  D --> E{Loop guard}
  E -->|Over limit| X[Reject + log]
  E -->|Pass| F[Forward to agent]
  F --> G[Receipt + log]
```

### System architecture

```mermaid
graph TB
  subgraph X1["Outside"]
    A[Sending agent]
    B[Receiving agent]
    O[OpenClaw]
  end
  subgraph X2["Inside the gateway"]
    AU[Token auth]
    FL[Keyword filter]
    RL[Turn + rate limits]
    RT[Forwarding]
    LG[Logging]
  end
  A --> AU --> FL --> RL --> RT
  RT --> B
  RT --> O
  RT --> LG
```
