# UPCitemdb API

> UPCitemdb returns product details, recorded prices, and store offers by barcode as a workflow and API.

UPCitemdb returns product details, recorded prices, and store offers through Get product by barcode, which needs a 12- or 13-digit barcode.

- Page: https://fous.com/workflows/upcitemdb
- Handle: `@upcitemdb`
- Category: [Commerce](https://fous.com/workflows/category/commerce)
- Source website: https://upcitemdb.com
- Last verified: Sep 29, 2026
- Fous is not affiliated with UPCitemdb.

## Methods

### Get product by barcode

Operation `get_product_by_barcode`, version 1. 1 credit per call.

Identify a product by its 12- or 13-digit barcode and see product details, recorded prices, and store offers. Store prices and links may be outdated; fields missing from the public page are null.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `barcode` | string | yes | `"012000161155"` | The 12- or 13-digit number printed under the barcode, with optional spaces or dashes; for example 012000161155. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "barcode"
  ],
  "properties": {
    "barcode": {
      "type": "string",
      "description": "The 12- or 13-digit number printed under the barcode, with optional spaces or dashes; for example 012000161155.",
      "examples": [
        "012000161155",
        "4006381333931",
        "0120-0016 1155"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "barcode": "012000161155"
    },
    {
      "barcode": "4006381333931"
    },
    {
      "barcode": "0120-0016 1155"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `ean` | string or null | `"0012000161155"` |  |
| `upc` | string or null | `"012000161155"` |  |
| `size` | string or null |  |  |
| `brand` | string or null | `"LIFEWTR"` |  |
| `model` | string or null | `"012000161155"` |  |
| `colour` | string or null | `"Clear"` |  |
| `offers` | array |  |  |
| `offers[].price_usd` | number or null | `3.59` |  |
| `offers[].offer_link` | string or null | `"https://www.upcitemdb.com/norob.php?id=x2x253t213537454t2&tid=1&seq=1790657170&plt=16109f4adcb2dce6b604a9d5320ffd34"` |  |
| `offers[].store_name` | string | `"Walgreens"` |  |
| `offers[].last_updated_date` | string or null | `"2026-09-15"` |  |
| `weight` | string or null | `"1.00lb"` |  |
| `category` | string or null | `"Food, Beverages & Tobacco > Beverages > Water"` |  |
| `page_link` | string | `"https://www.upcitemdb.com/upc/012000161155"` |  |
| `description` | string or null | `"LIFEWTR Premium Purified Bottled Water  pH Balanced with Electrolytes For Taste"` |  |
| `image_links` | array |  |  |
| `product_name` | string or null | `"LIFEWTR Premium Purified Bottled Water  pH Balanced with Electrolytes For Taste"` |  |
| `lowest_price_usd` | number or null | `1.48` |  |
| `highest_price_usd` | number or null | `96` |  |

**Example input**

```json
{
  "barcode": "012000161155"
}
```

**Example output**

```json
{
  "ean": "0012000161155",
  "upc": "012000161155",
  "size": null,
  "brand": "LIFEWTR",
  "model": "012000161155",
  "colour": "Clear",
  "offers": [
    {
      "price_usd": 3.59,
      "offer_link": "https://www.upcitemdb.com/norob.php?id=x2x253t213537454t2&tid=1&seq=1790657170&plt=16109f4adcb2dce6b604a9d5320ffd34",
      "store_name": "Walgreens",
      "last_updated_date": "2026-09-15"
    },
    {
      "price_usd": 1.48,
      "offer_link": "https://www.upcitemdb.com/norob.php?id=v2r253t2x213b444u2&tid=1&seq=1790657170&plt=120341fd6cabeb9792d5e15076f106d5",
      "store_name": "Frys Electronics",
      "last_updated_date": "2018-06-21"
    },
    {
      "price_usd": 1.49,
      "offer_link": "https://www.upcitemdb.com/norob.php?id=x2s263w2y2339464q2&tid=1&seq=1790657170&plt=335bef5f2daa72c2f45089f68da60e39",
      "store_name": "Target",
      "last_updated_date": "2020-09-21"
    }
  ],
  "weight": "1.00lb",
  "category": "Food, Beverages & Tobacco > Beverages > Water",
  "page_link": "https://www.upcitemdb.com/upc/012000161155",
  "description": "LIFEWTR Premium Purified Bottled Water  pH Balanced with Electrolytes For Taste",
  "image_links": [
    "https://i5.walmartimages.com/asr/b29c7d39-72ae-464d-8bb3-1a89fbda40d6.102cd8b37ec485c62739a1f933389b1b.jpeg?odnHeight=450&odnWidth=450&odnBg=ffffff",
    "https://target.scene7.com/is/image/Target/GUEST_46ff2a61-1d87-4887-8a8c-d284dc77bdb1?wid=1000&hei=1000",
    "https://pics.walgreens.com/prodimg/595160/450.jpg"
  ],
  "product_name": "LIFEWTR Premium Purified Bottled Water  pH Balanced with Electrolytes For Taste",
  "lowest_price_usd": 1.48,
  "highest_price_usd": 96
}
```

## Quick start

Call the API with a Fous API key (`FOUS_API_KEY`). To create one, turn on Developer mode in Fous Studio, then open Keys & connections → API keys (https://app.fous.com/keys).

```bash
# First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
: "${FOUS_API_KEY:?Set FOUS_API_KEY before running this example}"

curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 120 \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@upcitemdb",
  "visibility": "public",
  "operation": "get_product_by_barcode",
  "version": 1,
  "input": {
    "barcode": "012000161155"
  },
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
# First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
import json
import os
import urllib.error
import urllib.request

api_key = os.environ.get("FOUS_API_KEY")
if not api_key:
    raise RuntimeError("Set FOUS_API_KEY before running this example")

body = json.loads("{\n  \"api\": \"@upcitemdb\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_product_by_barcode\",\n  \"version\": 1,\n  \"input\": {\n    \"barcode\": \"012000161155\"\n  },\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=120) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
// First set your key: export FOUS_API_KEY='YOUR_FOUS_API_KEY'
const apiKey = process.env.FOUS_API_KEY;
if (!apiKey) throw new Error("Set FOUS_API_KEY before running this example");

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(120_000),
  body: JSON.stringify({
  "api": "@upcitemdb",
  "visibility": "public",
  "operation": "get_product_by_barcode",
  "version": 1,
  "input": {
    "barcode": "012000161155"
  },
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

Or describe the data in plain language: send `{"api":"@upcitemdb","prompt":"Describe the data you need, with every detail"}` to the same URL. Fous fills in the input, runs the method that fits and returns only the fields you asked for; `data.route.calls[].request` is the exact call it made. Routing is free; the run costs the same.

## Use cases

- Identify products from barcode numbers
- Compare recorded product prices
- Review offers from listed stores
- Enrich product records with brand, size, and category

## FAQ

### Is Fous affiliated with UPCitemdb?

No. Fous is not affiliated with UPCitemdb. This workflow reads the public upcitemdb.com website and returns its data.

### How much does it cost?

Each run costs 1 credit. With pay-as-you-go, a credit costs 1¢; monthly plans cost less per credit.

### Do I need a UPCitemdb account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from upcitemdb.com when you run it; repeating the same request within a day may return the saved result. Fous checks this workflow automatically; it last passed a check on Sep 29, 2026.

### What product is identified by this barcode?

Get product by barcode returns product details such as the product name, brand, model, and category.

### What prices are recorded for the product?

Get product by barcode returns recorded offer prices and the lowest and highest recorded prices.

### Which stores have offers for the product?

Get product by barcode returns store offers with store names and offer details.

## Related

- [Best Buy API](https://fous.com/workflows/best-buy.md): Best Buy returns US electronics and appliance listings, prices, deals, specifications, images, reviews, and nearby store pickup and shipping details; prices and availability can change by location and before checkout.
- [Walmart API](https://fous.com/workflows/walmart.md): Walmart helps shoppers find products from Walmart and marketplace sellers, view details, prices, ratings and reviews; availability uses Walmart’s default location, not ZIP codes.
- [Newegg API](https://fous.com/workflows/newegg.md): Newegg provides US computer and electronics listings, with product details and selected public offers whose prices, availability, stock, and shipping can change or may not be displayed.
- [Amazon API](https://fous.com/workflows/amazon.md): Amazon returns publicly shown product listings, prices, details, ratings, reviews, current best sellers, and Today's Deals; availability and content vary by store, location, and access.
- [Ulta Beauty API](https://fous.com/workflows/ulta-beauty.md): Ulta Beauty returns searchable beauty products and product details, including current pricing and availability that may change.
- [Costco API](https://fous.com/workflows/costco.md): Costco returns US product prices/details and warehouse hours/services/gas prices; delivery affects availability, member prices may be hidden, and posted gas and holiday hours may differ.
- [Zara API](https://fous.com/workflows/zara.md): Zara offers fashion and clothing, with product searches and item details including current prices, colours, sizes, materials and images; care instructions may be unavailable.
- [IKEA API](https://fous.com/workflows/ikea.md): IKEA helps shoppers find country-dependent product details, prices, photos, reviews and assembly information, and check store stock where IKEA provides it; some countries are unsupported.
- [All Commerce workflows](https://fous.com/workflows/category/commerce)
