Quickstart Guide

From zero to accepting Bitcoin in under 10 minutes.

1

Create Your Account

Sign up for a free SatsRail merchant account. No bank approval, no credit checks.

Create Account →
2

Get Your API Keys

From your merchant dashboard, go to API Keys to find your keys:

  • Secret key — starts with sk_live_ or sk_test_ (keep this server-side, never expose to clients)
  • Publishable key — starts with pk_live_ or pk_test_ (safe for client-side, can only create checkout sessions)
⚠️ Start with test keys. Use sk_test_ keys during development. They create isolated test data that never touches real payment providers.
3

Install an SDK

The Ruby SDK is available today. Node.js and Python SDKs are on the roadmap.

# Ruby
gem install satsrail

Working in another language? Use the REST API directly with curl, fetch, requests, or whatever HTTP client your stack provides.

4

Create Your First Order

curl
curl -X POST https://satsrail.com/api/v1/m/orders \
  -H "Authorization: Bearer sk_test_..." \
  -H "Content-Type: application/json" \
  -d '{
    "amount_usd": 50.00,
    "description": "Order #1234"
  }'
Ruby
require "satsrail"

SatsRail.api_key = "sk_test_..."
order = SatsRail::Order.create(
  amount_usd: 50.00,
  description: "Order #1234"
)
puts order.lightning_invoice
5

Listen for Webhooks

Set up a webhook endpoint to get notified when payments complete, orders update, and more. SatsRail signs every webhook with HMAC-SHA256 so you can verify authenticity.

Webhook Guide →
6

Go Live

When you're ready for production, swap your test keys for live keys:

  • Replace sk_test_ with sk_live_
  • Replace pk_test_ with pk_live_

That's it. Same code, real payments.

Ready to build?

Create a free account and start integrating today.

Get Your API Key →