pull down to refresh

SatsAPI — a Bitcoin market intelligence API that uses L402 for pay-per-call access on phoenixd nodes. The idea is simple: you make a request, get a 402 back with a Lightning invoice, pay it, resend with the payment_hash, get your data.

No signup. No monthly plan. No API key to rotate. You pay 2-200 sats depending on the endpoint and that's it.

The endpoints:

  • /v1/price — BTC price + RSI + MAs (3 rate)
  • /v1/mempool — fees + congestion + last block (2 sats)
  • /v1/signal — 9-factor BUY/SELL/HOLD signal with trade setup (150 sats)
  • /v1/summary — everything above combined, structured for AI agents (200 sats)

The L402 implementation uses phoenixd directly. The flow is:

GET /v1/price → 402 + { invoice, payment_hash } pay invoice GET /v1/price?payment_hash=<hash> → 200 + data

Nothing fancy, but it works on mainnet and I've been receiving real payments since I launched it quietly last week.

What I found interesting building this: L402 is genuinely a better auth model for programmatic access than API keys. An AI agent can pay autonomously, there's no credential to leak, and you get natural rate limiting through economics.

Docs: https://satsapi.dev/docs Health endpoint if you want to see it's live: https://satsapi.dev/health

GitHub: https://github.com/Aperezvigoa/satsapi