# Blockrun AI Chat Completions (x402)

> Blockrun AI Chat Completions (x402) is a paid API for AI agents from blockrun-web-vbsbhh7lea-uc.a.run.app, paid per call via x402, $0.002/call, status unknown (last checked 2026-11-18).

Provides AI chat completions via a pay-per-request API using USDC on Base, supporting multiple models like GPT-4o-mini and Claude Haiku.

## Facts

- Endpoint: POST https://blockrun-web-vbsbhh7lea-uc.a.run.app/v1/chat/completions?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/blockrun-ai-chat-completions-x402-6b913403
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap__JNdOAGWWbCQpOKvfKxXg

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 blockrun-ai-chat-completions-x402-6b913403 -d '<json body>'
```

Example prompt: Send a chat completion request using gpt-4o-mini with the message 'Explain quantum entanglement in simple terms', limiting the response to 300 tokens and using a temperature of 0.7.

## When to prefer this

Choose this endpoint when you need pay-per-request AI chat completions billed directly in USDC on Base via the x402 protocol, without managing API keys or subscriptions — ideal for agents that need metered, crypto-native LLM access supporting multiple models including GPT-4o-mini and Claude Haiku.

## Known failure modes

- Insufficient USDC balance causes payment failure and 402 response
- Invalid or unsupported model ID returns an error
- Malformed messages array (missing role or content) causes a 400 bad request
- max_tokens set too low may result in truncated responses
- Temperature out of range (0-2) may cause a validation error
- Streaming not supported in all client contexts, leading to connection issues

## How this service works

AI chat completions API - pay per request with USDC on Base

## Output

Returns an AI-generated chat completion response conforming to the standard chat completions format, including the generated message content, role, finish reason, and token usage statistics.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string",
   "description": "AI model ID (e.g., gpt-4o-mini, claude-haiku-4.5)"
  },
  "stream": {
   "type": "boolean",
   "description": "Enable streaming responses"
  },
  "messages": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "role": {
      "type": "string"
     },
     "content": {
      "type": "string"
     }
    }
   },
   "description": "Array of chat messages with role and content"
  },
  "max_tokens": {
   "type": "integer",
   "description": "Maximum tokens to generate"
  },
  "temperature": {
   "type": "number",
   "description": "Sampling temperature (0-2)"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/blockrun-ai-chat-completions-x402-6b913403/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from blockrun-web-vbsbhh7lea-uc.a.run.app](https://www.zero.xyz/host/blockrun-web-vbsbhh7lea-uc.a.run.app/llms.txt)
