# Model Access Gateway – Claude Sonnet 5 Chat Completions

> Model Access Gateway – Claude Sonnet 5 Chat Completions is a paid API for AI agents from agent402-arb.rosariovitale0096.workers.dev, paid per call via x402, $0.0014/call, status unknown (last checked 2026-10-17).

Provides OpenAI-compatible chat completions via Anthropic Claude Sonnet 5, paid per request in USDC using the x402 protocol — no API key or account required.

## Facts

- Endpoint: POST https://agent402-arb.rosariovitale0096.workers.dev/llm/claude-sonnet-5?utm_source=zero.xyz
- Price: $0.0014/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-17
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/model-access-gateway-claude-sonnet-5-chat-completions-4f07cfc5
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_MIkriQU2mLxiqg9Bl2DRR

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability model-access-gateway-claude-sonnet-5-chat-completions-4f07cfc5 -d '<json body>'
```

Example prompt: Ask Claude Sonnet 5 to summarize the following text for me: 'Quantum computing leverages superposition and entanglement to perform computations exponentially faster than classical computers for certain problem types.' Pay per request using my USDC wallet.

## When to prefer this

Choose this endpoint when you need Claude Sonnet 5 completions without setting up an Anthropic account or API key, especially in agent pipelines that support x402 micropayments in USDC. It is ideal for pay-as-you-go inference at $0.0014/call, crypto-native applications, or scenarios where centralized API key management is undesirable.

## Known failure modes

- Insufficient USDC balance or failed x402 payment results in 402 Payment Required
- Malformed request body or missing required fields returns 400 Bad Request
- Model overload or upstream Anthropic errors may return 503 or 500
- Rate limiting on the gateway worker may return 429 Too Many Requests
- Invalid or unsupported model path returns 404 Not Found

## How this service works

Claude Sonnet 5 API (anthropic/claude-sonnet-5): LLM inference via OpenAI-compatible chat completions, pay per call in USDC on Base with x402. No API key, no account. Suited for AI agents and scripts that need Claude Sonnet 5 on demand. When listed, this request cost 30% less than the same request on BlockRun. Streaming and function calling supported. Exact price in the 402 quote before payment; automatic refund if the model fails to answer.

## Output

Returns an OpenAI-compatible chat.completion JSON object containing the assistant's message content, the model name (anthropic/claude-sonnet-5), token usage (prompt, completion, total), finish reason, and a unique completion ID and timestamp.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string",
   "description": "Optional: fixed by the route (anthropic/claude-sonnet-5)"
  },
  "tools": {
   "type": "array"
  },
  "stream": {
   "type": "boolean",
   "description": "true: server-sent events after payment"
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "role"
    ],
    "properties": {
     "role": {
      "enum": [
       "system",
       "user",
       "assistant",
       "tool",
       "developer"
      ],
      "type": "string"
     },
     "content": {
      "type": [
       "string",
       "array",
       "null"
      ]
     }
    }
   },
   "minItems": 1
  },
  "max_tokens": {
   "type": "integer",
   "maximum": 16384,
   "minimum": 1,
   "description": "Optional, default 4096"
  },
  "temperature": {
   "type": "number",
   "maximum": 2,
   "minimum": 0
  },
  "response_format": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "id": "chatcmpl-7f3c2a91",
  "model": "anthropic/claude-sonnet-5",
  "usage": {
   "total_tokens": 10,
   "prompt_tokens": 9,
   "completion_tokens": 1
  },
  "object": "chat.completion",
  "choices": [
   {
    "index": 0,
    "message": {
     "role": "assistant",
     "content": "OK"
    },
    "finish_reason": "stop"
   }
  ],
  "created": 1791979200
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/model-access-gateway-claude-sonnet-5-chat-completions-4f07cfc5/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402-arb.rosariovitale0096.workers.dev](https://www.zero.xyz/host/agent402-arb.rosariovitale0096.workers.dev/llms.txt)
