Skip to content
FlatCryptoPay

Quickstart

Create an account, add a payout address, make an API key and accept your first crypto payment in about five minutes.

This guide takes you from a new account to a paid test invoice and a verified webhook. You need a terminal with curl, and a wallet address for at least one network.

1. Create your account

Open the dashboard and sign up with an email and password. No business documents are needed. Add your business name in Settings; it is shown to customers on the pay page.

2. Add a payout address

In Payout addresses, add where you want to be paid. Each address enables a set of payment methods:

  • EVM address (0x...): USDT/USDC on Ethereum, Base, Polygon and BNB Smart Chain, and card payments (settled in USDC).
  • TRON address (T...): USDT TRC-20.
  • Solana address: USDC and USDT on Solana.
  • Bitcoin: an account zpub/xpub (a fresh address per invoice) or a single address.
  • Litecoin: an account xpub/zpub/Ltub or a single address.

Read Payout addresses and xpubs for validation rules. Always check the derived address preview against your wallet before going live.

3. Create a test API key

In API keys, create a key in test mode. It starts with fcp_test_ and is shown once: store it in your server's secret manager, never in browser code.

4. Create an invoice

curl
curl https://flatcryptopay.com/api/v1/invoices \
  -H "Authorization: Bearer $FCP_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: order-1001" \
  -d '{
    "amount": "25.00",
    "currency": "USD",
    "description": "Order #1001",
    "order_id": "1001",
    "redirect_url": "https://shop.example/thanks"
  }'

The response contains hosted_url. Redirect your customer there; the page lists every method your payout addresses enable, shows a QR code and the exact amount, and watches the blockchain.

201 Created
{
  "id": "inv_8fK2mQ9xLr3TzW1bN0aYc4",
  "object": "invoice",
  "livemode": false,
  "status": "open",
  "amount": "25.00",
  "currency": "USD",
  "hosted_url": "https://flatcryptopay.com/pay/inv_8fK2mQ9xLr3TzW1bN0aYc4/",
  "expires_at": "2026-12-03T10:00:00.000Z",
  "payment": null
}

5. Add a webhook endpoint

In Webhooks, add an HTTPS URL on your server. Copy the signing secret (whsec_..., shown once). Don't have a server yet? Use the webhook inspector URL to see deliveries in your browser.

6. Pay the test invoice

Open the hosted_url. Test invoices show a Simulate payment button: click it and the invoice becomes paid, an invoice.paid webhook is sent to your endpoint, and the customer is redirected to your redirect_url.

7. Verify the webhook

Node.js (Express)
app.post('/webhooks/fcp', express.raw({ type: 'application/json' }), (req, res) => {
  const ts = req.header('X-FCP-Timestamp');
  const sig = req.header('X-FCP-Signature');
  const expected = crypto.createHmac('sha256', process.env.FCP_WEBHOOK_SECRET)
    .update(ts + '.' + req.body.toString('utf8')).digest('hex');
  const fresh = Math.abs(Date.now() / 1000 - Number(ts)) < 300;
  if (!fresh || sig.length !== expected.length ||
      !crypto.timingSafeEqual(Buffer.from(sig), Buffer.from(expected))) return res.sendStatus(400);
  const event = JSON.parse(req.body.toString('utf8'));
  if (event.type === 'invoice.paid') markOrderPaid(event.data.invoice.order_id);
  res.sendStatus(200);
});

8. Go live

  1. Create a live key (fcp_live_) and swap it in.
  2. Send yourself a small real payment on your preferred network and confirm it arrives in your wallet.
  3. Make sure your webhook handler is idempotent (dedupe on X-FCP-Event-Id).
Start free: no fees, no documents