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

@unisat/openapi-cli

v1.0.0

Published

UniSat AI Kit CLI capability layer

Readme

@unisat/openapi-cli

This package owns the stable external CLI command surface for direct UniSat OpenAPI HTTPS calls.

Requires Node.js ^22.23.4 || ^24.22.1 || ^26.12.1 and npm. Install globally:

npm install -g @unisat/openapi-cli

First query (replace the key placeholder locally):

unisat-openapi-cli config bitcoin-key --api-key YOUR_BITCOIN_API_KEY
unisat-openapi-cli config status --env bitcoin --format json
unisat-openapi-cli getBlockchainInfo --env bitcoin --format json

Obtain a key at https://developer.unisat.io/. Read the latest indexed height from response.body.data.blocks. Success requires exit code 0, response.ok: true and business code: 0; HTTP 200 alone is insufficient. No wallet or address is needed.

Supported commands include:

  • config bitcoin-key
  • config fractal-key
  • api call
  • commands domains and commands --domain blockchain
  • Named API commands such as getBlockchainInfo
  • <command> --help and <command> --dry-run

Use built-in discovery and per-command help to choose an API; no Agent Skill or source checkout is required. Domains are business categories, not networks. commands --all can produce very large output. Use text for discovery and JSON for structured results. Top-level --help explains quota lookup and safety limits.

Environments:

  • bitcoin -> https://open-api.unisat.io -> UNISAT_BITCOIN_API_KEY
  • fractal -> https://open-api-fractal.unisat.io -> UNISAT_FRACTAL_API_KEY

Recommended CLI flow:

node bin/unisat-ai.js config bitcoin-key --api-key YOUR_BITCOIN_KEY
node bin/unisat-ai.js api call --env bitcoin --path "/v1/indexer/address/{address}/balance" --path-param address=YOUR_ADDRESS --format json

Fractal example:

node bin/unisat-ai.js config fractal-key --api-key YOUR_FRACTAL_KEY
node bin/unisat-ai.js api call --env fractal --path "/v1/public/fractal/supply" --format json

Use node bin/unisat-ai.js --help for command usage.

API keys are stored in a user config .env file by the config commands. api call reads keys in this order: --api-key, process environment, user config .env.

Swagger is downloaded on demand and cached locally. Use unisat-openapi-cli swagger status to inspect the cache or swagger refresh to update it. OPENAPI_SWAGGER_DIR supplies a local override.

Website Download Package

The repository can also build single-executable CLI archives for users who do not have Node.js or npm installed:

npm run package:cli

Each archive contains:

  • unisat-openapi-cli.exe on Windows, or unisat-openapi-cli on macOS/Linux
  • bundled CLI code
  • remote Swagger download and local cache support

Users configure keys the same way:

unisat-openapi-cli config bitcoin-key --api-key YOUR_BITCOIN_KEY
unisat-openapi-cli config fractal-key --api-key YOUR_FRACTAL_KEY