Developer API
Integrate Bitcoin payments into your application with our simple REST API
Your API Key
YOUR_API_KEY
Keep your API key secure! Never share it publicly or commit it to version control.
Base URL
http://bitcoincheckout.io/api/
Authentication
Bearer Token
Format
JSON REST API
API Endpoints
http://bitcoincheckout.io/api/payments/create/
Fields
- amount_usd Required (number)
- order_id Required (string, unique per shop)
- shop_id Conditionally required (UUID; required if you have multiple active shops; optional if you have exactly one)
- customer_email Optional (email)
- customer_name Optional (string)
- expires_minutes Optional Default: 60 (int)
- on_confirm_url Optional (URL)
- items Optional (array of objects; e.g., [{name, quantity, amount_usd}])
- shop_id required (UUID)
- amount_usd required (number)
- customer_email required (email)
- order_id required (string, unique per shop)
- customer_name optional (string)
- expires_minutes optional (int, default 60)
- on_confirm_url optional (URL)
- items optional (array of objects; e.g., [{name, quantity, amount_usd}])
import requests
# Create Payment
def create_payment(amount_usd, customer_email, shop_id, order_id, customer_name=None, on_confirm_url=None, items=None):
url = "http://bitcoincheckout.io/api/payments/create/"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
}
data = {
"amount_usd": amount_usd,
"customer_email": customer_email,
"shop_id": shop_id,
"order_id": order_id,
}
if customer_name: data["customer_name"] = customer_name
if on_confirm_url: data["on_confirm_url"] = on_confirm_url
if items: data["items"] = items
response = requests.post(url, json=data, headers=headers)
return response.json()
# Example usage
payment = create_payment(50.00, "customer@example.com", "your-shop-id", "ORD-2025-0001")
print(f"Payment URL: {payment['checkout_url']}")
http://bitcoincheckout.io/api/payments/{payment_id}/
import requests
# Check Payment Status
def check_payment(payment_id):
url = f"http://bitcoincheckout.io/api/payments/{payment_id}/"
headers = {"Authorization": "Bearer YOUR_API_KEY"}
response = requests.get(url, headers=headers)
return response.json()
# Example usage
status = check_payment("payment-id-here")
print(f"Status: {status['status']}")
print(f"Received: {status['received_btc']} BTC")
print(f"Confirmations: {status['confirmations']}")
http://bitcoincheckout.io/api/shops/
import requests
# Get Shops
def get_shops():
url = "http://bitcoincheckout.io/api/shops/"
headers = {"Authorization": "Bearer YOUR_API_KEY"}
response = requests.get(url, headers=headers)
return response.json()
# Example usage
shops_data = get_shops()
print(f"Total shops: {shops_data['total_shops']}")
for shop in shops_data['shops']:
print(f"Shop: {shop['name']} (ID: {shop['id']})")
E-commerce Integrations
Ready-to-use plugins for popular platforms
WooCommerce
WordPress Plugin
Complete payment gateway plugin for WooCommerce stores. Easy installation and configuration.
Shopify
App Integration
Full Shopify app with webhook integration and order management. Deploy to your store.
API Response Examples
200 Create Payment Response
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"order_id": "ORD-2025-0001",
"status": "pending",
"amount_state": "none",
"amount_usd": 50.00,
"amount_btc": "0.0010000",
"bitcoin_address": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh",
"checkout_url": "http://bitcoincheckout.io/payments/pay/550e8400-e29b-41d4-a716-446655440000/",
"success_url": "https://yourapp.com/thank-you?order=ORD-2025-0001",
"expires_at": "2024-01-01T12:00:00Z",
"created_at": "2024-01-01T11:00:00Z"
}
200 Payment Status Response
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"status": "confirmed",
"amount_state": "full",
"amount_usd": 50.00,
"amount_btc": "0.0010000",
"received_btc": "0.0010000",
"confirmations": 3,
"bitcoin_address": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh",
"txid": "a1b2c3d4e5f6789012345678901234567890abcdef",
"expires_at": "2024-01-01T12:00:00Z",
"confirmed_at": "2024-01-01T11:45:00Z"
}
200 Get Shops Response
{
"shops": [
{
"id": "1d9673c8-1cd6-4cfd-8a87-7cc09f0e26c6",
"name": "My Online Store",
"created_at": "2024-01-01T10:00:00Z"
},
{
"id": "2e8784d9-2de7-5ced-9b98-8dd1af1f37d7",
"name": "Mobile App Store",
"created_at": "2024-01-02T14:30:00Z"
}
],
"total_shops": 2
}