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

@eurovalidate/sdk

v0.1.1

Published

Official Node.js/TypeScript SDK for the EuroValidate API — validate EU VAT, IBAN, EORI, and company data.

Readme

@eurovalidate/sdk

Official Node.js/TypeScript SDK for the EuroValidate API -- validate EU VAT numbers, IBANs, EORI numbers, and look up company data.

  • Zero dependencies (native fetch, Node 18+)
  • TypeScript-first with full type definitions
  • ESM + CommonJS dual package
  • Auto-retry on 429 with Retry-After
  • Typed error classes for every failure mode

Installation

npm install @eurovalidate/sdk

Quick Start

import { EuroValidate } from '@eurovalidate/sdk';

const client = new EuroValidate('ev_live_your_key');

// VAT validation
const vat = await client.validateVat('NL820646660B01');
console.log(vat.valid, vat.companyName);
// true "COOLBLUE B.V."

// IBAN validation
const iban = await client.validateIban('DE89370400440532013000');
console.log(iban.valid, iban.bankName, iban.bic);
// true "Commerzbank" "COBADEFFXXX"

// EORI validation
const eori = await client.validateEori('DE328169180000040');
console.log(eori.valid, eori.companyName);

// Company lookup by LEI
const company = await client.lookupCompanyByLei('724500Y6DUVHQD6OXN27');
console.log(company.companyName, company.countryCode);

// VAT rates
const rates = await client.getVatRates('DE');
console.log(rates.standardRate); // 19

const allRates = await client.getAllVatRates();
console.log(allRates.countries.length); // 27

// Unified validation (multiple checks in one call)
const result = await client.validate({
  vatNumber: 'NL820646660B01',
  iban: 'DE89370400440532013000',
});
console.log(result.vat?.valid, result.iban?.valid);

// Account info
const account = await client.getAccount();
console.log(account.plan, account.callsUsed, account.callsLimit);

Error Handling

import {
  EuroValidate,
  AuthError,
  RateLimitError,
  ValidationError,
  NotFoundError,
  ServerError,
} from '@eurovalidate/sdk';

const client = new EuroValidate('ev_live_your_key');

try {
  const vat = await client.validateVat('INVALID');
} catch (err) {
  if (err instanceof AuthError) {
    // 401 -- invalid API key
  } else if (err instanceof RateLimitError) {
    // 429 -- rate limited (auto-retried 3 times before throwing)
    console.log('Retry after:', err.retryAfter, 'seconds');
  } else if (err instanceof ValidationError) {
    // 400/422 -- bad input
  } else if (err instanceof NotFoundError) {
    // 404
  } else if (err instanceof ServerError) {
    // 5xx -- server error
  }
}

Configuration

const client = new EuroValidate('ev_live_your_key', {
  baseUrl: 'https://api.eurovalidate.com', // default
  timeout: 30000,                           // ms, default 30s
  maxRetries: 3,                            // retries on 429, default 3
});

Requirements

  • Node.js 18+ (uses native fetch)
  • TypeScript 5.0+ (optional, for type checking)

License

MIT