@bolthub/cli
v0.1.2
Published
CLI for the bolthub L402 API marketplace — search, discover, and call paid APIs from the terminal
Maintainers
Readme
@bolthub/cli
CLI for the BoltHub L402 API marketplace. Search, explore, and call paid APIs from the terminal.
Install
npm install -g @bolthub/cliOr run directly with npx:
npx @bolthub/cli search weatherCommands
search - Find APIs
bolthub search weather
bolthub search --tag finance
bolthub search # list allinfo - API details
bolthub info pokemonShows 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| Option | Description |
|--------|-------------|
| --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:
| Variables | Wallet | Speed |
|-----------|--------|-------|
| 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
