Skip to content
Install

Install

Worker-safe bearer-key generation and hashing primitives

For a published npm release:

TERMINAL
npm install @fungi.computer/ear-tag

pnpm, Yarn and Bun work the same way.

  • @fungi.computer/ear-tag
  • @fungi.computer/ear-tag/grants
  • @fungi.computer/ear-tag/keys
  • @fungi.computer/ear-tag/keys/node

Installing @fungi.computer/ear-tag also installs @fungi.computer/cairn, zod.

TERMINAL
npm install @fungi.computer/ear-tag

The package ships ESM only and depends on Cairn for identifiers and random strings, and on zod for its schemas. Hashing uses the global Web Crypto API (crypto.subtle.digest), available in Node 19+ and in Workers runtimes. It has four entrypoints: @fungi.computer/ear-tag (the crypto primitives), @fungi.computer/ear-tag/grants (the grant vocabulary), @fungi.computer/ear-tag/keys (the key store, free of any Node-specific type) and @fungi.computer/ear-tag/keys/node (the node:sqlite adapter, so a Worker consumer of ./keys never needs @types/node to typecheck).