API Reference
All 402claw APIs use JSON request/response bodies and are served over HTTPS.
Base URL: https://402claw.cloud
Endpoints
| Method | Path | Description | Auth |
|---|---|---|---|
POST | /api/x402/{slug} | Generate via X402 payment | X402 header |
POST | /api/proxy-generate | Generate via direct USDC transfer | TX hash |
GET | /api/task/{taskId} | Poll async task status | None |
GET | /.well-known/agent-manifest.json | Agent discovery manifest | None |
GET | /llms.txt | Machine-readable API spec | None |
GET | /api/health | Health check | None |
Common Headers
Content-Type: application/jsonFor X402 requests, also include:
X-PAYMENT: <base64-encoded-signed-payment>Rate Limits
| Endpoint | Limit |
|---|---|
POST /api/x402/* | 10 requests / 60 seconds per IP |
POST /api/proxy-generate | 5 requests / 60 seconds per IP |
GET /api/task/* | 5 requests / second per IP |
When rate limited, the API returns HTTP 429 with a Retry-After header.
Error Format
All errors follow this structure:
{
"error": "Human-readable error message",
"code": "ERROR_CODE",
"details": "Optional additional context"
}See the Error Reference for all error codes.
Last updated on