@sewdn/signed-license-cli
v0.1.0
Published
CLI to generate Ed25519 keys, mint signed tokens, and verify tokens (companion to @sewdn/signed-license).
Maintainers
Readme
signed-license CLI
Small command-line tool for signed tokens (same algorithms as the SDK) used with the Signed License SDK: generate a keypair, mint tokens with the private key, and verify tokens with the public key (via environment variables).
Names: monorepo vs npm
| Context | Package name | Install |
| ---------------- | --------------------------- | ------------------------------------------ |
| This monorepo | @signed-license/cli | (workspace) |
| npm (your scope) | @sewdn/signed-license-cli | npm install -g @sewdn/signed-license-cli |
Published tarballs are produced by bun run build:npm (see root README.md). The global command is signed-license.
Prerequisites
- Bun ≥ 1.2 (the
signed-licensebinary is executed with Bun; seebin/run.js).
Install (registry)
npm install -g @sewdn/signed-license-cli
# or
bun add -g @sewdn/signed-license-cliCommands
| Command | Description |
| ----------------------- | ----------------------------------------------------------------------------------------------------------------------------- |
| signed-license decode | Decode the first segment and print the v1 payload as a table (no signature check). |
| signed-license keygen | Print a new PEM public and private key pair (default Ed25519; --preset or interactive prompt for other algorithms). |
| signed-license mint | Sign a payload and print a token (needs private key; see below). |
| signed-license verify | Verify the signature with SIGNED_LICENSE_PUBLIC_KEY_PEM, then print the payload table. |
Run signed-license --help and signed-license <command> --help for flags and completions.
Environment variables
- Private key: set
SIGNED_LICENSE_PRIVATE_KEY, or pass--private-keywith an inline PKCS#8 PEM. - Public key: set
SIGNED_LICENSE_PUBLIC_KEY_PEMto the PEM used to verify tokens.
Disable interactive prompts (e.g. in CI): set SIGNED_LICENSE_NO_CLACK=1 (or legacy BASIC_AUTH_NO_CLACK=1).
Relationship to the SDK
Published CLI depends on @sewdn/signed-license. Applications should use that package to validate tokens, parse payloads, and implement authorization, delivery, or bulk workflows.
Development
- The published
signed-licensebinary loadsdist/index.js; runbun run buildin this package beforebun linkor testingbin/run.js. - Registry releases use
.npm-publish/signed-license-clifrombun run build:npm, notnpm publishonapps/cli.
