---
title: "Barcode generator for product, shipping, and inventory labels"
method: GET
path: "/api/barcode"
tags: ["Design & Assets"]
---

# Barcode generator for product, shipping, and inventory labels

`GET /api/barcode`

## Request

- Base URL: `https://api.webbersites.com`
- URL: `https://api.webbersites.com/api/barcode`
- Auth: API key in header `X-PAYMENT`

Barcode generator for product, shipping, and inventory labels: GET ?data=&type= and receive a print-ready SVG plus PNG (base64) and a data: URI. Types: code128 (default), ean13, ean8, upca, upce, code39, itf14, gs1-128, codabar, datamatrix, pdf417, aztec. Check digits, quiet zones, and the human-readable line are handled per spec; invalid input for a symbology returns a clear 400. Deterministic, no network. QR codes live at /api/qr.

Price: $0.01 per call, paid in USDC via the x402 protocol (see the x402 security scheme).

## Query parameters

- `data` string, required
- `type` string
- `scale` number
- `height` number
- `text_line` string
- `dark` string
- `light` string

## Response `200`

Success

- object
  - `data` string
  - `type` string
  - `svg` string
  - `png_base64` string
  - `data_uri` string

## Other responses

- `402`: Payment required — the response body lists accepted payment methods (amount, asset, network, pay-to address). Retry the request with a signed X-PAYMENT header.

---

[API](https://skmtc.dev/webbersites/apis/webbersites-x402-data-api.md) · [All operations](https://skmtc.dev/webbersites/apis/webbersites-x402-data-api/llms.txt) · [OpenAPI document](https://skmtc.dev/webbersites/apis/webbersites-x402-data-api/revisions/c14a76c67a94?raw)
