# StatePulse API - Barcode Product Lookup

> StatePulse API - Barcode Product Lookup is a paid API for AI agents from statepulse-api.hahavoid0.workers.dev, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-15).

Looks up product information (brand, title, category, metadata) from a barcode identifier, returning structured product details with confidence scoring.

## Facts

- Endpoint: POST https://statepulse-api.hahavoid0.workers.dev/product/barcode
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/statepulse-api-barcode-product-lookup-90e5bc7c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_x29-SrnI_n1a5RXJxs7eJ

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 statepulse-api-barcode-product-lookup-90e5bc7c -d '<json body>'
```

Example prompt: I just scanned the barcode 9780143107996 on a book I found — can you look it up and tell me the title, author, and category?

## When to prefer this

Use this endpoint when an agent needs to identify a physical product from its barcode or UPC/EAN/ISBN number, especially to retrieve structured product metadata like brand, title, category, and images. Ideal for shopping assistants, inventory tools, book lookup, or receipt parsing where a barcode is available as the primary identifier.

## Known failure modes

- Barcode not found in database — supported may be false or result may be empty
- Unknown barcode format — unsupported type returns supported: false
- Low confidence match — confidence field may return 'low' indicating uncertain result
- Payment failure — x402 USDC payment not completed, request rejected
- Malformed barcode input — invalid format returns error response

## How this service works

Resolves a UPC/EAN or ISBN barcode into detailed product metadata using OpenLibrary and UPCitemdb free search endpoints.

## Output

Returns a JSON object with: brand name, product title, category, image URL, extended metadata (e.g. author and page count for books), a 'supported' boolean indicating whether the barcode type is recognized, and a confidence level (e.g. 'high') for the match.

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "result": {
   "brand": "Penguin Classics",
   "image": "https://covers.openlibrary.org/b/id/8240502-M.jpg",
   "title": "The Odyssey",
   "category": "Books",
   "metadata": {
    "author": "Homer",
    "page_count": 560
   }
  },
  "supported": true,
  "confidence": "high"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/statepulse-api-barcode-product-lookup-90e5bc7c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from statepulse-api.hahavoid0.workers.dev](https://www.zero.xyz/host/statepulse-api.hahavoid0.workers.dev/llms.txt)
