{"uid":"cap_Rf2hbmBf3b-yYWPsqqZh7","slug":"ean-13-upc-a-barcode-svg-generator-9e4da234","name":"EAN-13 / UPC-A Barcode SVG Generator","description":"Draw an EAN-13 or UPC-A barcode SVG: adds or checks the check digit and uses the L/G/R encodings.","url":"https://barcode-qr.x402tookit.com/ean13-svg?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"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":["code"],"properties":{"code":{"type":"string","description":"EAN-13: 12 or 13 digits. UPC-A: 11 or 12 digits (e.g. 4006381333931)"},"type":{"type":"string","description":"ean13 (default) or upca"},"scale":{"type":"integer","description":"Pixels per module, 1 to 8 (default 2)"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"svg":{"type":["null","string"]},"asOf":{"type":["null","string"]},"ean13":{"type":["null","string"]},"digits":{"type":["null","string"]},"source":{"type":["null","string"]},"modules":{"type":["null","number"]},"reasons":{"type":["array","null"],"items":{"type":"string"}},"summary":{"type":["null","string"]},"verdict":{"type":["null","string"]},"degraded":{"type":["boolean","null"]},"svgBytes":{"type":["null","number"]},"checkDigit":{"type":["null","number"]},"disclaimer":{"type":["null","string"]},"notChecked":{"type":["array","null"],"items":{"type":"string"}},"leftParityPattern":{"type":["null","string"]},"leftQuietZoneModules":{"type":["null","number"]},"rightQuietZoneModules":{"type":["null","number"]}}}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_NZmjBWKJ7T8-OzfgBitme","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Generates an SVG barcode image for EAN-13 or UPC-A barcodes, automatically computing or verifying the check digit and applying standard L/G/R module encodings.","exampleAgentPrompt":"Can you generate an EAN-13 barcode SVG for the product code 4006381333931? Use a scale of 3 pixels per module.","exampleUseCases":[{"title":"Product label barcode for e-commerce listing","prompt":"I need to create an EAN-13 barcode SVG for my product with code 501234567890 — make it scale 2 so it fits neatly on a label."},{"title":"UPC-A barcode for retail packaging","prompt":"Generate a UPC-A barcode SVG for item code 01234567890 at scale 4 so I can print it on retail packaging."},{"title":"Verify and render barcode for inventory system","prompt":"Draw an EAN-13 barcode SVG for code 5901234123457 and confirm the check digit is correct — use the default scale."}],"resultDescription":"Returns an SVG string rendering the EAN-13 or UPC-A barcode, along with metadata including the computed check digit, the full digit string, left parity pattern, module count, quiet zone widths, SVG byte size, a verdict on digit validity, a summary message, and any degradation or warning reasons.","failureModes":["Invalid digit count — code has wrong number of digits for the selected barcode type","Non-numeric characters in the code string","Check digit mismatch if 13/12 digits provided and final digit is wrong","Unsupported type value (not ean13 or upca)","Scale out of range (must be 1–8)"],"whenToPreferThis":"Choose this endpoint when you need a standards-compliant EAN-13 or UPC-A barcode rendered as a scalable SVG with automatic check digit computation or verification. It is purpose-built for GS1 retail barcodes and returns rich metadata (parity pattern, module counts, check digit) alongside the SVG, making it superior to generic QR or Code 128 generators when specifically working with product/retail barcodes.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-02T18:32:59.159Z","isFirstParty":false,"canonicalSlug":"ean-13-upc-a-barcode-svg-generator-9e4da234"}