# BlockRun Image Generation

> BlockRun Image Generation is a paid API for AI agents from blockrun.ai, paid per call via x402, $0.04/call, status unknown (last checked 2026-09-13).

Generates AI images from a text prompt via a pay-per-call gateway, settled in USDC on Base or Solana, with no API key required.

## Facts

- Endpoint: POST https://blockrun.ai/api/v1/images/generations
- Price: $0.04/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/blockrun-image-generation-2aba427f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_7B0lLKlD9LAoslJq0V6j7

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-image-generation-2aba427f -d '<json body>'
```

Example prompt: Generate 2 images of a futuristic cyberpunk cityscape at night, 1024x1024, using the openai/gpt-image-1 model.

## When to prefer this

Choose this endpoint when you need AI image generation without managing API keys, want crypto-native pay-per-call billing settled in USDC on Base or Solana, or are building an agent pipeline (OpenClaw, Claude Code, Franklin Agent) that requires a single unified gateway for multiple AI capabilities.

## Known failure modes

- Insufficient USDC balance — payment not settled, 402 Payment Required returned
- Invalid model ID — unrecognized model string causes a 400 Bad Request
- Invalid size format — unsupported dimension string causes a 400 error
- Prompt content policy violation — prompt rejected for unsafe or disallowed content
- Network or gateway timeout — upstream model takes too long, 504 returned

## How this service works

Pay for the outcome. One endpoint for every model, tool and data source an agent needs — each call priced before it runs, at the best value per dollar. 103 models and 100 data and tool APIs.

## Output

Returns one or more AI-generated images (as URLs or base64 data) based on the provided text prompt, using the specified model and dimensions. The call costs $0.04 USDC per invocation, settled on Base or Solana.

## Example request

```json
{
 "n": 1,
 "size": "1024x1024",
 "model": "openai/gpt-image-1",
 "prompt": "A serene landscape with mountains and a clear blue sky"
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "n": {
   "type": "integer",
   "description": "Number of images to generate"
  },
  "size": {
   "type": "string",
   "description": "Image dimensions (e.g., 1024x1024)"
  },
  "model": {
   "type": "string",
   "description": "Image model ID (e.g., openai/gpt-image-1, openai/gpt-image-2)"
  },
  "prompt": {
   "type": "string",
   "description": "Text description of the image to generate"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/blockrun-image-generation-2aba427f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from blockrun.ai](https://www.zero.xyz/host/blockrun.ai/llms.txt)
