# Delx Commerce — QR Code Generator

> Delx Commerce — QR Code Generator is a paid API for AI agents from commerce.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-01).

Generates a QR code image (PNG or SVG) encoding any text or URL, returned as a base64 data URI, for $0.001 USDC per call via x402.

## Facts

- Endpoint: POST https://commerce.delx.ai/api/v1/x402/qr-code?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-commerce-qr-code-generator-a38df38b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_86h4G0jwHGWEcYObX9Z7B

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 delx-commerce-qr-code-generator-a38df38b -d '<json body>'
```

Example prompt: Generate a QR code for https://myshop.example.com/checkout in PNG format with high error correction and a border of 4 — I need it as an image I can embed on a webpage.

## When to prefer this

Choose this endpoint when you need a verifiable, pay-per-use QR code generation with no account signup, cryptographic proof of delivery (SHA-256), and USDC micropayment settlement on Base or Solana via x402. Ideal for AI agents that need to generate QR codes on-demand without managing API keys or subscriptions. Prefer this over free tier services when auditability and on-chain payment receipts matter.

## Known failure modes

- Empty or missing 'data'/'text' field — returns validation error
- Input text exceeds 2048 characters — returns maxLength validation error
- Invalid 'format' value (not 'png' or 'svg') — returns enum validation error
- Invalid 'error_correction' value — returns enum validation error
- 'box_size' or 'border' out of allowed range — returns range validation error
- Payment failure or insufficient USDC balance via x402 — returns 402 Payment Required

## How this service works

Pay-per-result APIs for agents. No signup. Exact price. Verifiable delivery. USDC on Base + Solana via x402.

## Output

A JSON object containing: a base64-encoded data URI of the QR code image (PNG or SVG), the QR version and module count, SHA-256 hashes of both the output image and the input data, the format and media type, the model used (qrcode-python), the sale price in USDC, and an attribution note. The data URI can be embedded directly in HTML or saved as an image file.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "data": {
   "type": "string",
   "maxLength": 2048,
   "minLength": 1,
   "description": "Text or URL to encode. Delx never fetches or validates the destination."
  },
  "text": {
   "type": "string",
   "maxLength": 2048,
   "minLength": 1,
   "description": "Alias for data."
  },
  "border": {
   "type": "integer",
   "default": 4,
   "maximum": 16,
   "minimum": 0
  },
  "format": {
   "enum": [
    "png",
    "svg"
   ],
   "type": "string",
   "default": "png"
  },
  "box_size": {
   "type": "integer",
   "default": 4,
   "maximum": 8,
   "minimum": 1
  },
  "error_correction": {
   "enum": [
    "L",
    "M",
    "Q",
    "H"
   ],
   "type": "string",
   "default": "M"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "bytes": 438,
  "model": "qrcode-python",
  "qr_id": "qr_8b4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f",
  "scope": "qr_code",
  "format": "png",
  "schema": "delx/qr-code/v1",
  "sha256": "8b4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f901234567890abcdef1234567890ab",
  "modules": 33,
  "version": 2,
  "data_uri": "data:image/png;base64,<bounded-png>",
  "provider": "first-party",
  "media_type": "image/png",
  "attribution": "QR rendered locally by Delx; the encoded destination is supplied by the caller and is not fetched or validated.",
  "input_sha256": "a6e8f7c3d9b2a1e0f6c5d4b3a29180706050403020100ffeeddccbbaa99887766",
  "sale_price_usdc": 0.001,
  "error_correction": "M",
  "gross_margin_usd": 0.001,
  "upstream_cost_usd": 0
 }
}
```

## More

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