# Security

## Non-custodial by design
Customers pay directly into your wallet. We never receive, hold or move your funds and never ask for
private keys or seed phrases. There is no balance with us that can be frozen or stolen.

## Your integration
- **Secret keys** (`sk_…`) belong on your server only. We store them as hashes and can never show them
  again; if one leaks, roll it in the dashboard.
- **Publishable keys** (`pk_…`) are safe in the browser: they can only open checkout for payments you created.
- **Verify every webhook** with the `webhook-signature` header (Standard Webhooks, HMAC-SHA256) and reject
  timestamps older than 5 minutes. Code in [Webhooks](/docs/webhooks).
- **Verify the checkout result** (`signature` on the redirect or in `onSuccess`) on your server before
  unlocking anything; for certainty also fetch `GET /v1/payments/{id}`.
- **Idempotency**: send `Idempotency-Key` on every `POST` and make your webhook handler idempotent.
- **Payment buttons**: the price lives in your dashboard, so it cannot be changed in the browser. Still
  confirm orders from the webhook, not from the browser.

## Your account
- Turn on **2FA** (authenticator app). Recovery codes are shown once — store them safely.
- Adding or removing a **live wallet** needs your password or 2FA code, sends an email alert, and new
  addresses may need a 24-hour cool-down.
- Review **active sessions** (Settings → Security) and log out devices you do not recognise.

## Payment detection
A payment is marked `paid` only after the transfer is final on the blockchain (a number of
confirmations or the chain's finalized block). Chain reorganisations are handled: a transfer that
disappears sends the payment back to `pending`. A reconciler re-reads the chain to catch anything a
provider missed.

## Reporting a vulnerability
Email the security contact listed on the [contact page](/contact) with details and steps to reproduce.
Please do not test against other customers' accounts.
