JAN codes (Japan Article Number) are the Japanese variant of EAN-13. Torify validates the format, country prefix, and check digit in one call.
https://torify.dev/v1/barcode/validate
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
code |
string | Yes | 13-digit JAN or ISBN | 4901234567894 |
{ "ok": true, "data": { "valid": true, "type": "jan", "country": "JP" } }
curl "https://torify.dev/v1/barcode/validate?code=4901234567894"
import { wrapFetchWithPayment } from 'x402-fetch';
import { privateKeyToAccount } from 'viem/accounts';
const account = privateKeyToAccount(process.env.PRIVATE_KEY as `0x${string}`);
const fetchWithPayment = wrapFetchWithPayment(fetch, account);
const res = await fetchWithPayment(
'https://torify.dev/v1/barcode/validate?code=4901234567894'
);
const data = await res.json();
console.log(data); // { ok: true, data: { ... } }
import requests
# Free MCP tier (no auth) or API key (X-API-Key header)
res = requests.get(
"https://torify.dev/v1/barcode/validate?code=4901234567894",
headers={"X-API-Key": "your_torify_pro_key"}
)
print(res.json())
/v1/mynumber/validate — Japan My Number Validation API
/v1/passport/validate — Japan Passport Number Validation API
/v1/insurance/validate — Japan Social Insurance Number Validation API
/v1/plate/validate — Japan License Plate Validation API