littleshop/BTCPAY_SETUP.md
SilverLabs DevTeam 36b393dd2e Update BTCPay integration with production credentials and deployment documentation
- Updated API key and Store ID to production values
- Added comprehensive deployment documentation
- Fixed invoice creation to use GBP (fiat) currency
- Documented successful production deployment status
- Added manual deployment instructions
- Updated CLAUDE.md with latest integration fixes

Production Status:
- BTCPay connection working with v2.2.1
- Store "Shop" configured with ID: CvdvHoncGLM7TdMYRAG6Z15YuxQfxeMWRYwi9gvPhh5R
- Invoice creation functional (wallets need BTCPay-side configuration)

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-19 11:17:43 +01:00

93 lines
2.6 KiB
Markdown

# BTCPay Server Integration Setup
## Current Status
✅ BTCPay Server deployed at: https://thebankofdebbie.giize.com
✅ Admin account created: bankofdebbie
✅ Store created: "Shop"
✅ API Key generated and configured
✅ LittleShop integration working
## Required Configuration Steps
### 1. Get Store ID
1. Login to https://pay.silverlabs.uk
2. Go to **Stores****Settings****General**
3. Copy the Store ID (usually found in URL or displayed on settings page)
### 2. Generate API Key
1. Go to **Account****Manage Account****API Keys**
2. Click **Generate Key**
3. Label: `LittleShop Integration`
4. Required Permissions:
- `btcpay.store.canviewstores`
- `btcpay.store.canmodifyinvoices`
- `btcpay.store.cancreateinvoice`
5. Copy the generated API key
### 3. Configure Webhook
1. Go to **Stores****Settings****Webhooks**
2. Click **Create Webhook**
3. Webhook URL: `https://your-littleshop-domain.com/api/btcpay/webhook`
4. Events to enable:
- Invoice payment settled
- Invoice expired
- Invoice invalid
5. Copy the webhook secret
### 4. Configure Bitcoin Wallet
1. Go to **Stores****Settings****Bitcoin**
2. Click **Set up a wallet**
3. For development: Choose **Use the hot wallet**
4. Generate new wallet or import existing
5. Complete wallet setup
## LittleShop Configuration (Production)
Current working configuration:
```json
{
"BTCPayServer": {
"BaseUrl": "https://thebankofdebbie.giize.com",
"ApiKey": "db920209c0101efdbd1c6b6d1c99a48e3ba9d0de",
"StoreId": "CvdvHoncGLM7TdMYRAG6Z15YuxQfxeMWRYwi9gvPhh5R",
"WebhookSecret": "YOUR_WEBHOOK_SECRET_HERE"
}
}
```
## Supported Cryptocurrencies
The LittleShop integration supports:
- BTC (Bitcoin)
- XMR (Monero) - requires additional setup
- USDT (Tether)
- LTC (Litecoin)
- ETH (Ethereum)
- ZEC (Zcash)
- DASH (Dash)
- DOGE (Dogecoin)
Note: Only Bitcoin is enabled by default. Additional cryptocurrencies require:
1. Enabling them in BTCPay Server store settings
2. Configuring wallets for each currency
## Testing the Integration
After configuration:
1. Start your LittleShop application
2. Create a test order
3. Select cryptocurrency payment
4. Verify invoice creation in BTCPay Server
5. Test payment flow and webhook notifications
## Webhook Endpoint
The webhook endpoint is already implemented in LittleShop:
- URL: `/api/btcpay/webhook`
- Controller: `BTCPayWebhookController.ProcessWebhook`
- Features:
- HMAC-SHA256 signature validation
- Proper BTCPay Server webhook format handling
- Payment status mapping and processing
- Handles: All BTCPay Server webhook events (invoice created, payment settled, expired, etc.)