npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

codeclassify

v1.0.1

Published

Offline, zero-dependency checksum & format validators: IBAN, GTIN/EAN/UPC, Luhn, ISIN, CUSIP, SEDOL, LEI, VIN, ISO 6346 container, ABA routing number, BIC. No network calls.

Readme

codeclassify

Offline checksum & format validators for the identifiers you meet in real data: IBAN, GTIN/EAN/UPC, Luhn (cards & IMEI), ISIN, CUSIP, SEDOL, LEI, VIN, ISO 6346 shipping containers, ABA routing numbers and BIC/SWIFT codes.

  • Zero dependencies. Pure JavaScript, CommonJS, works on Node.js >= 14.
  • 100% offline. No network calls, ever. Validate a million rows on a plane.
  • Deterministic. Real check-digit maths (GS1 Mod-10, Luhn, ISO 7064 MOD 97-10, ISO 6346, ISO 13616...), not regex guesses.
  • Honest. This package confirms structure and checksum only — it does not confirm that a code is actually assigned in any registry. For that, see Need more? below.

Battle-tested: these are the same algorithms running the free online validators at code-classify.com.

Install

npm install codeclassify

Note: if the name codeclassify is unavailable on npm, this package is published as @codeclassify/validators instead — npm install @codeclassify/validators and change the require accordingly.

Usage

const cc = require('codeclassify');

cc.validateIBAN('DE89 3704 0044 0532 0130 00');
// { valid: true }

cc.validateIBAN('DE89370400440532013001');
// { valid: false, reason: 'MOD-97 checksum failed (ISO 13616).' }

cc.validateGTIN('4006381333931');   // { valid: true }  (EAN-13)
cc.validateISIN('US0378331005');    // { valid: true }  (Apple)
cc.validateVIN('1HGCM82633A004352');// { valid: true }

Every validator takes a string (spaces and hyphens are stripped, case is ignored) and returns:

{ valid: boolean, reason?: string }  // reason present only when valid === false

Validators

| Function | Identifier | Standard / algorithm | Example (valid) | |---|---|---|---| | validateIBAN(s) | IBAN | ISO 13616, MOD-97 checksum | DE89370400440532013000 | | validateGTIN(s) | GTIN-8 / UPC-A / EAN-13 / GTIN-14 | GS1 Mod-10 check digit | 4006381333931 | | validateLuhn(s) | Card numbers, IMEI, any Luhn-checked number | Luhn (mod 10) | 4111111111111111 | | validateISIN(s) | ISIN (securities) | ISO 6166, Luhn over expanded digits | US0378331005 | | validateCUSIP(s) | CUSIP (US/CA securities) | Modified double-add-double | 037833100 | | validateSEDOL(s) | SEDOL (UK securities) | Weighted mod-10 | B0YBKJ7 | | validateLEI(s) | LEI (legal entities) | ISO 17442, MOD 97-10 | 5493001KJTIIGC8Y1R12 | | validateVIN(s) | VIN (vehicles) | ISO 3779, position-9 check digit | 1HGCM82633A004352 | | validateContainer(s) | Shipping container | ISO 6346 check digit | CSQU3054383 | | validateABA(s) | ABA routing number (US banks) | 3-7-1 weighted checksum | 021000021 | | validateBIC(s) | BIC / SWIFT code | ISO 9362 structure only (BIC has no check digit) | DEUTDEFF |

Testing

npm test

Runs a plain-Node test suite (no framework) with real-world codes for every validator.

Need more?

A passing checksum tells you a code is well-formed — not who it belongs to, or whether it is safe to do business with. When you need the next step, the CodeClassify API picks up where this package stops:

  • Bank name from IBAN — resolve the issuing bank for IBANs from 17 countries.
  • Sanctions screening — check names against the OFAC, EU, UK and UN consolidated lists.
  • KYB enrichment — LEI registry lookups and legal-entity data.
  • Batch validation — up to 100 identifiers per API call, or full-CSV bulk reports on the site.

250 free API calls per month, no credit card. Get a key at code-classify.com/api.

You can also use the free browser tools (IBAN checker, "What is this code?", check-digit fixer and 13 more) at code-classify.com.

License

MIT © CodeClassify