TigerTag SDK JS

JavaScript / Node.js SDKTigerTag SDK

Read, verify and write TigerTag NFC chips from JavaScript.

The SDK of the open TigerTag protocol for 3D-printing filament and resin: it turns a chip's bytes into material, colour, print settings and quantity, checks its ECDSA-P256 signature offline, and builds new tags byte for byte.

npm install tigertag
quick-start.js
const { TigerTag } = require('tigertag');

const tag = TigerTag.fromPages(uid, payload);   // from your NFC SDK
console.log(tag.pretty());                      // human-readable summary
console.log(String(tag.verify()));              // VALID / NOT SIGNED / INVALID
console.log(tag.toDict());                      // JSON-ready object
The README quick start: it works right after npm install, with no setup.
1.2.1Current version, released 2026-11-06
Node.js 18+Uses the built-in crypto and fetch
0Runtime dependencies for parsing and verification
Apache-2.0Open-source licence, with a patent grant

Get started in three steps

Install the package, read a chip with your NFC library, write a new one. The bundled reference tables make the first run work with no network.

  1. 1

    Install the package

    From the npm registry. pnpm, yarn and bun install the same package.

    npm install tigertag
    pnpm add tigertag
    yarn add tigertag
    bun add tigertag
  2. 2

    Read a chip

    Pass the 7-byte UID and the 144 bytes your NFC library reads. Here with nfc-pcsc and an ACR122U.

    // Node.js — nfc-pcsc (ACR122U / PN532)
    reader.on('card', async (card) => {
      const uid = Buffer.from(card.uid, 'hex');        // 7 bytes
      const payload = await reader.read(4, 144, 4);    // pages 4–39, 144 bytes
      const tag = TigerTag.fromPages(uid, payload);
      console.log(tag.pretty());
      console.log(String(tag.verify()));               // VALID / NOT SIGNED
    });
  3. 3

    Change and write

    Every change returns a new TigerTag; toBytes() gives the bytes to write back. erase() gives a blank chip.

    // Immutable surgical update — returns a new TigerTag, original unchanged
    const patched = tag.patch({ nozzleTempMin: 200, dryTemp: 55 });
    
    // Erase a chip — write the returned 80 bytes to the NFC chip
    const blankBytes = TigerTag.erase();

The full API in the README

What the SDK does

One package for every side of a TigerTag chip: reading, checking, writing, and keeping its data up to date.

Read any dump

fromPages(), fromDump() and fromFile() take a UID with 80 or 144 bytes, or a full 180-byte dump. pretty(), describe(), toDict() and toRawDict() return text, a plain-language paragraph or JSON-ready objects.

Verify authenticity offline

verify() checks the ECDSA-P256 signature that binds the chip UID to its product data, with the public key bundled in the package. The result is valid, invalid, unsigned, no_key or no_uid.

Create and patch tags

create(), asInit(), patch() and erase() build chip bytes. A TigerTag is immutable: patch() returns a new one, and refuses to change idTigertag, idProduct, uid or the signature.

Build from the catalogue

TigerTag.fromCatalog(productId) builds a complete TigerTag+ from the official product catalogue, downloaded on first use and cached in a per-user folder.

Sync with the manufacturer

For TigerTag+ chips, rawApi(), diffApi() and patchFromApi() fetch the brand's current product data, list what differs from the chip and apply it.

Reference data, offline first

The material, brand, aspect, type, diameter and unit tables ship in the package. A background check updates them at most once a day; offline: true or TIGERTAG_OFFLINE=1 means zero network calls.

Three kinds of tag

The SDK reads and writes the three tag types of TigerTag protocol v2.2, on NTAG213, NTAG215 and NTAG216 chips.

idProduct 0xFFFFFFFF

TigerTag (Maker)

Every field on the chip, readable fully offline.

idProduct 0x00000000

TigerTag Init

A blank template, ready to be programmed. TigerTag.asInit() creates one.

ECDSA-P256

TigerTag+

Every field on the chip, plus a product ID that links to the cloud API for updates from the manufacturer. A signed chip can be verified with verify().

From the command line and inside Electron

The package installs a tigertag command, and runs in the main process of an Electron app.

The tigertag command

Parse a dump as text, JSON or raw fields, and update the reference tables on demand.

# Parse a dump file
tigertag dump.bin

# JSON output
tigertag dump.bin --json

# Update the reference tables now (into the data dir)
tigertag update

Inside an Electron app

Parse chips in the main process, with no subprocess to ship.

// main.js — replace parseTigerTag() subprocess dependency
const { TigerTag, TigerTagDB } = require('tigertag');

function parseTigerTag(payload, uid) {
  const tag = TigerTag.fromPages(Buffer.from(uid), Buffer.from(payload));
  const db  = new TigerTagDB();
  return {
    dict: tag.toDict(db),
    raw:  tag.toRawDict(),
    sig:  tag.verify(db).toDict(),
  };
}

Try it without a reader: the playground

A local web page, served by the SDK itself, that builds and decodes TigerTag chips and shows every byte. No NFC hardware is needed.

  • SDK input and output side by side: the create() call, then pretty(), describe(), verify() and toDict().
  • With one or more PC/SC readers such as the ACR122U, chips are read as soon as they are placed, and Burn writes the current payload.
  • The playground never writes a signature: only a certified manufacturer can issue one.
npm run playground
# then open http://localhost:7432/tools/playground.html

# Enable live reader support (one-time install)
npm install ws nfc-pcsc

Part of the TigerTag ecosystem

The SDK implements the open TigerTag specification, next to the other official tools.

TigerTag protocol specification

The open specification the SDK implements: memory layout, tag types, signature scheme and reference database.

Repository: TigerTag-RFID-Guide

TigerTag RFID Connect

The official mobile app: read and write chips with the phone's built-in NFC.

Questions

How do I install the TigerTag JavaScript SDK?

Run npm install tigertag, or pnpm add tigertag, yarn add tigertag or bun add tigertag. It needs Node.js 18 or later and no other package for parsing and verification.

Does it need an internet connection?

No. The reference tables and the signature public key ship in the package, so reading and verifying work offline. The network is only used for the daily table check, the product catalogue and the TigerTag+ cloud methods; offline: true or TIGERTAG_OFFLINE=1 turns it off.

Which NFC chips and readers does it work with?

TigerTag uses NTAG213, NTAG215 and NTAG216 chips (ISO 14443-3). The SDK takes the UID and the bytes your NFC library reads, so it is not tied to one reader; the README shows nfc-pcsc with an ACR122U.

How does it check that a chip is genuine?

verify() checks the chip's ECDSA-P256 signature over its UID and product identifiers, with the public key bundled in the package. It returns valid, invalid, unsigned (a Maker tag), no_key or no_uid, without a server call.

Can it write chips?

It builds the bytes: create(), patch(), asInit(), erase() and fromCatalog() give a TigerTag whose toBytes() is the payload your NFC library writes. The playground's Burn button writes it to the chips on connected readers.

Is there a Python version?

Yes: TigerTag-SDK-Python is the Python port of the same API, and both SDKs serve the same playground page.

Which licence is the SDK under?

Apache-2.0, which carries an express patent grant. Implementing the TigerTag protocol itself requires no licence.

One command to start

npm install tigertag, then TigerTag.fromPages(uid, payload).

View on npm