There are over 4 million industrial robots operating worldwide. Millions more drones, 3D printers, smart locks, and IoT devices. Every single one of them speaks a different language.
An AI agent can browse the web, write code, call APIs, and pay for cloud compute — all autonomously. But ask it to hire a robot to pick an item off a shelf? There's no standard way to do that.
Until now.
What is RTP?
RTP (Robot Task Protocol) is an open standard that defines a common language for AI agents to discover, commission, and pay for physical robot tasks over the internet.
It sits on top of x402 — the HTTP-native payment protocol from Coinbase and Cloudflare — and extends it into the physical world. An agent pays USDC via a standard HTTP request. A robot executes a task. Escrow handles the rest.
No accounts. No API keys. No vendor SDKs. Just HTTP + payment + task.
The Core Idea: Robots as Payable Endpoints
Every x402 service works the same way: you make an HTTP request, get a 402 Payment Required response, pay, and get your resource. RTP applies this exact pattern to physical tasks.
A robot registers its capabilities and price. An agent discovers it via .well-known/x402.json. The agent sends a task + payment. The robot executes. Escrow settles.
The flow takes about 15 seconds and zero manual coordination:
Agent discovers robot via .well-known/x402.json
↓
Agent sends POST /robots/task + x402 USDC payment
↓
Gateway validates payment → holds in escrow
↓
Task dispatched to robot (webhook / XMTP / WiFi / WebSocket)
↓
Robot executes → reports result
↓
Escrow releases to operator → agent gets receipt
What RTP Defines
1. Task Envelope — A universal JSON structure for any task to any robot:
{
"rtp_version": "1.0",
"task_id": "task_xyz789",
"robot_id": "robo_abc123",
"task": "pick",
"parameters": {
"item": "SKU-00421",
"from_location": "bin_A3"
},
"payment": {
"amount": "0.05",
"currency": "USDC",
"chain": "base"
},
"timeout_seconds": 60
}
2. Capability Vocabulary — 15 standard verbs that any robot can declare:
pick · place · scan · sort · deliver · inspect · patrol · capture · weld · assemble · dispense · print · move · transmit · charge
Custom capabilities use reverse-domain notation: com.acmerobotics.palletize
3. Lifecycle State Machine — Every task follows the same path:
PENDING → DISPATCHED → IN_PROGRESS → COMPLETED ✓ (escrow released)
→ FAILED ✗ (payment refunded)
→ TIMEOUT ✗ (payment refunded)
4. Robot Identity — Resolvable URIs for every device:
rtp://gateway.spraay.app/robo_abc123
5. Four Connection Types — webhook, XMTP, WiFi relay, WebSocket. Supports everything from cloud-connected industrial arms to Raspberry Pi hobby projects.
It's Already Live
This isn't a whitepaper. RTP is deployed on Base mainnet today.
Spraay Gateway (v3.4.0) is the reference implementation with 8 RTP endpoints live alongside 63 existing x402 payment endpoints:
| Endpoint | What it does | Price |
|---|---|---|
POST /robots/register |
Register a robot | Free |
POST /robots/task |
Dispatch a paid task | $0.05 USDC |
POST /robots/complete |
Report task result | Free |
GET /robots/list |
Discover robots | $0.005 USDC |
GET /robots/status |
Poll task status | $0.002 USDC |
GET /robots/profile |
Robot capabilities | $0.002 USDC |
The first robot — robo_138fd1f8e0ee51a — is registered and discoverable right now.
The SDK: 15 Minutes to Connect Any Robot
For device operators, connecting a robot to RTP takes one file:
import { RTPDevice } from '@spraay/rtp-sdk'
const robot = new RTPDevice({
name: 'WarehouseBot-01',
capabilities: ['pick', 'place', 'scan'],
pricePerTask: '0.05',
paymentAddress: '0xYourWallet',
apiKey: 'your-key',
connection: {
type: 'webhook',
webhookUrl: 'https://yourserver.com/rtp/task'
}
})
robot.onTask('pick', async (params, task) => {
await myRobotArm.pick(params.item, params.from_location)
await task.complete({ output: 'Done' })
})
await robot.register()
robot.listen(3100)
For AI agents, hiring a robot is three lines:
import { RTPClient } from '@spraay/rtp-sdk'
const client = new RTPClient({ wallet: myX402Wallet })
const robots = await client.discover({ capability: 'pick' })
const result = await client.hire(robots[0], {
task: 'pick',
parameters: { item: 'SKU-421' }
})
What Devices Work?
We published a full compatibility guide covering 7 device categories:
| Device | SDK Direct | Method |
|---|---|---|
| Linux robots (ROS/ROS2) | ✅ | SSH / npm |
| Raspberry Pi | ✅ | SD card, Docker |
| Arduino / ESP32 | Bridge via Pi | Serial |
| Industrial (KUKA/ABB/Fanuc) | External server | Vendor API |
| Drones (ArduPilot) | ✅ | Companion computer |
| IoT / Smart devices | ✅ | SSH / device API |
| 3D Printers, CNC, etc. | ✅ | OctoPrint / native |
Where RTP Fits in the Stack
RTP doesn't compete with machine-identity blockchains or spatial computing platforms. It's a different layer:
| Layer | Role | Example |
|---|---|---|
| Blockchain Infrastructure | Machine identity, on-chain state | peaq |
| Spatial Coordination | Physical-world awareness | Auki |
| Payment + Task Protocol | Agent-to-robot task dispatch & payment | RTP + Spraay |
| Payment Rails | HTTP-native micropayments | x402 |
These are complementary. RTP could use peaq machine IDs for identity and Auki for spatial coordination while handling the payment and task layer.
Why x402?
RTP is built on x402 because it's the only payment protocol designed for exactly this:
- HTTP-native — no custom transport, no WebSocket negotiation, just standard HTTP requests
- Micropayment-ready — $0.05 per robot task is economically viable on Base
- Agent-first — AI agents can discover, understand pricing, and pay autonomously
- Open standard — backed by Coinbase and Cloudflare, not a proprietary token
We've submitted RTP as a proposed extension to the x402 roadmap — the first protocol for extending x402 into the physical world.
What's Next
-
SDK on npm —
@spraay/rtp-sdkfor device operators and agent developers - Python SDK — for Raspberry Pi and robotics communities
- Docker image — one-command deployment for any Linux device
- AgentRank integration — robots build reputation scores over completed tasks
- Task bundles — multi-robot atomic task sequences
Get Involved
- 📄 Spec: github.com/plagtech/rtp-spec
- 🌐 Live Gateway: gateway.spraay.app
- 🔧 x402 Proposal: coinbase/x402 #1569
- 🐦 Twitter: @Spraay_app
RTP is MIT licensed. The spec, SDK, and reference implementation are all open source.
The physical world is about to become programmable and payable. One HTTP request at a time.
Built by Spraay Protocol — the x402 payment gateway for AI agents.
Top comments (0)