# Duo Data Utilities – GS1 Identifier Validation & Conversion

> Duo Data Utilities – GS1 Identifier Validation & Conversion is a paid API for AI agents from api.duoleads.com, paid per call via x402, $0.05/call, status unknown (last checked 2026-10-02).

Validates GS1 identifiers (GTIN-8/12/13/14, GLN, SSCC), verifies check digits, computes missing check digits, and converts between GTIN formats

## Facts

- Endpoint: GET https://api.duoleads.com/v1/id/gs1?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/duo-data-utilities-gs1-identifier-validation-conversion-b123ed3e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_o6TX72ZOo4YZO19vFbNG5

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 duo-data-utilities-gs1-identifier-validation-conversion-b123ed3e
```

Example prompt: Can you validate the EAN-13 barcode 5901234123457 and tell me if the check digit is correct, and also give me its GTIN-14 equivalent?

## When to prefer this

Choose this endpoint when you need purely structural/mathematical GS1 validation or format conversion without consulting a product database. It is ideal for data-pipeline validation, EDI preprocessing, label-printing workflows, or any scenario where you need to verify or compute check digits programmatically at low cost ($0.05/call). It does not look up product information — for that, use a product database API instead.

## Known failure modes

- Missing 'value' query parameter returns an error
- Non-numeric or malformed input (letters, wrong length) returns an invalid result or error
- op=convert without a 'to' parameter returns an error
- op=convert targeting a shorter format than the input (e.g. GTIN-8 from a GTIN-14) may be unsupported
- Network or payment errors (402 payment required if x402 payment is not completed)

## How this service works

Validate and convert GS1 identifiers: GTIN-8, GTIN-12 (UPC-A), GTIN-13 (EAN-13), GTIN-14, GLN and SSCC. Returns the check-digit verdict, the computed correct check digit, the GS1 company-prefix boundary where it is derivable, and conversion to GTIN-14. Also computes a missing check digit from a partial code. Structure only, no product database.

## Output

Returns a JSON object with: whether the code is valid, the identifier type (e.g. gtin13, gln), the normalised code, the check digit and whether it is correct, the equivalent GTIN-14, any alternative valid interpretations (e.g. also_valid_as GLN), the reason for invalidity if applicable, and metadata including request ID, timestamp, price, and a determinism flag.

## 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"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "value"
     ],
     "properties": {
      "op": {
       "enum": [
        "validate",
        "checkdigit",
        "convert"
       ],
       "type": "string",
       "default": "validate",
       "maxLength": 64,
       "description": "validate (default), checkdigit (compute the missing final digit) or convert."
      },
      "to": {
       "enum": [
        "gtin8",
        "gtin12",
        "gtin13",
        "gtin14"
       ],
       "type": "string",
       "maxLength": 64,
       "description": "Target format. Required when op=convert."
      },
      "value": {
       "type": "string",
       "maxLength": 32,
       "description": "GS1 code, digits with optional spaces or hyphens. For op=checkdigit, omit the final digit."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "ok",
      "route",
      "version",
      "data",
      "meta"
     ],
     "properties": {
      "ok": {
       "const": true
      },
      "data": {
       "type": "object",
       "properties": {
        "type": {
         "type": "string"
        },
        "valid": {
         "type": "boolean"
        },
        "gtin14": {
         "type": [
          "string",
          "null"
         ]
        },
        "reason": {
         "type": [
          "string",
          "null"
         ]
        },
        "converted": {
         "type": [
          "string",
          "null"
         ]
        },
        "indicator": {
         "type": [
          "string",
          "null"
         ]
        },
        "normalised": {
         "type": "string"
        },
        "check_digit": {
         "type": [
          "string",
          "null"
         ]
        },
        "also_valid_as": {
         "type": "array",
         "items": {
          "type": "string"
         }
        },
        "check_digit_ok": {
         "type": "boolean"
  
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "type": "gtin13",
   "valid": true,
   "gtin14": "05901234123457",
   "reason": null,
   "indicator": "0",
   "normalised": "5901234123457",
   "check_digit": "7",
   "also_valid_as": [
    "gln"
   ],
   "check_digit_ok": true
  },
  "meta": {
   "price_usd": "0.05",
   "disclaimer": "Factual output of a deterministic computation over public data. Provided as is, with no warranty of accuracy, completeness or availability. Not investment, financial, legal, tax, medical or any other professional advice, and not a recommendation. Verify before relying on it. Terms: https://api.duoleads.com/terms",
   "request_id": "01K6B7Q4ZC8H3F2M9WXR5TYN0D",
   "computed_at": "2026-09-28T12:00:00.000Z",
   "deterministic": true
  },
  "route": "/v1/id/gs1",
  "version": "1.0.0"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/duo-data-utilities-gs1-identifier-validation-conversion-b123ed3e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.duoleads.com](https://www.zero.xyz/host/api.duoleads.com/llms.txt)
