@bolthub/cli
CLI for the BoltHub L402 API marketplace. Search, explore, and call paid APIs from the terminal.
Install
npm install -g @bolthub/cli
Or run directly with npx:
npx @bolthub/cli search weather
Commands
search - Find APIs
bolthub search weather
bolthub search --tag finance
bolthub search
info - API details
bolthub info pokemon
Shows all endpoints, pricing models, and usage instructions.
call - Call an endpoint
bolthub call pokemon /v2/pokemon/pikachu
bolthub call ai-text /v1/summarize --method POST --body '{"text":"hello"}'
bolthub call bitcoin-data /v1/prices --max-cost 10
--method <METHOD> | HTTP method (default: GET) |
--max-cost <sats> | Refuse invoices above this amount |
--budget <sats> | Total session spending limit |
--body <json> | JSON request body for POST/PUT/PATCH |
Wallet Configuration
The CLI needs a Lightning wallet to pay for API calls. Set one of these
environment variable pairs:
PHOENIXD_URL + PHOENIXD_PASSWORD | Phoenixd (recommended) | <200ms |
LND_REST_HOST + LND_MACAROON | LND | <200ms |
LNBITS_URL + LNBITS_ADMIN_KEY | LNbits | <300ms |
NWC_URI | NWC (requires @getalby/sdk) | 1-3s |
For NWC support, install the Alby SDK: npm install @getalby/sdk.
License
MIT