# Relaystation QR Code Generator

> Relaystation QR Code Generator is a paid API for AI agents from api.relaystation.ai, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Generate QR codes as PNG or SVG images with configurable size, error-correction level, and margin

## Facts

- Endpoint: POST https://api.relaystation.ai/v1/qr
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/relaystation-qr-code-generator-4bec8554
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_mrm7jIRyg95Kw-4kuNg7-

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 relaystation-qr-code-generator-4bec8554 -d '<json body>'
```

Example prompt: Generate a QR code for 'https://myshop.example.com/checkout' as a PNG, 400 pixels wide, with high error correction and a margin of 2.

## When to prefer this

Choose this endpoint when you need a quick, cheap, programmatic QR code generation without setting up a dedicated QR library — especially useful in agent workflows where you need PNG or SVG output with fine-grained control over error-correction and margin, billed per call at $0.0002 with a $0.01 minimum via x402 micropayment.

## Known failure modes

- Invalid or empty data string returns an error
- Unsupported output format (not PNG or SVG) returns a format error
- Excessively large data payload may exceed QR code capacity limits
- Invalid size or margin values may return a validation error
- Payment failure or insufficient USDC balance returns a 402 error

## How this service works

$0.0002/call. Generate QR codes as PNG or SVG — size, error-correction, and margin control. 1¢ x402 min; remainder auto-credits — relaystation.ai/penny

## Output

Returns a QR code image file in the requested format (PNG or SVG) encoding the provided data, with the specified size, error-correction level, and margin applied. The image is ready to embed in documents, print, or display digitally.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "properties": {
      "ecc": {
       "enum": [
        "L",
        "M",
        "Q",
        "H"
       ],
       "type": "string",
       "description": "Error-correction level (default M)."
      },
      "data": {
       "type": "string",
       "minLength": 1,
       "description": "The data to encode (≤ cputools.qr.max_data_len)."
      },
      "size": {
       "type": "integer",
       "maximum": 2048,
       "minimum": 64
      },
      "format": {
       "enum": [
        "png",
        "svg"
       ],
       "type": "string"
      },
      "margin": {
       "type": "integer",
       "maximum": 16,
       "minimum": 0
      }
     }
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST",
      "PUT",
      "PATCH"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/relaystation-qr-code-generator-4bec8554/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.relaystation.ai](https://www.zero.xyz/host/api.relaystation.ai/llms.txt)
