> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trysnapit.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Credits and billing

> How SnapIt credits work: per-invoice cost, checking your balance, buying packages with Stripe checkout, and what happens when credits run out.

SnapIt meters usage with credits. Each accepted invoice upload deducts the current credit cost per invoice from your workspace balance. New workspaces start with a welcome grant of free credits.

Open **Settings → Billing** in the dashboard to see your balance, buy credit packages, and review transactions.

## How credits are consumed

SnapIt debits credits once per invoice, at the moment the invoice file is accepted for processing. The debit is idempotent: retrying the same invoice never charges twice.

The cost per invoice is set by platform settings. The Billing page shows the current rate ("Each invoice upload costs *N* credit(s)").

## Checking your balance

The **Settings → Billing** page shows:

| Area            | Description                                                                    |
| --------------- | ------------------------------------------------------------------------------ |
| Current balance | Credits remaining for the workspace                                            |
| Cost hint       | The current credit cost per invoice upload                                     |
| Buy credits     | Available packages, each with a **Buy now** button that starts Stripe checkout |
| Transactions    | History of every credit movement with the balance after each one               |

Transaction types you may see:

| Type         | Meaning                                       |
| ------------ | --------------------------------------------- |
| Signup grant | Welcome credits when the workspace is created |
| Purchase     | Stripe checkout completed                     |
| Usage        | Debit when an invoice upload is accepted      |
| Adjust       | Platform admin balance change                 |

### Check balance via API

With a programmatic API key, query your balance and the current per-invoice cost:

```bash theme={null}
curl https://api.trysnapit.com/api/v1/credits/balance \
  -H "Authorization: Bearer sk_live_…"
```

```json theme={null}
{
  "balance": 42,
  "creditCostPerInvoice": 1
}
```

## Buying credits

<Steps>
  <Step title="Open Billing">
    Go to **Settings → Billing** in the dashboard.
  </Step>

  <Step title="Choose a package">
    Pick a credit package and select **Buy now**. Package sizes and prices are managed by the SnapIt platform.
  </Step>

  <Step title="Complete Stripe checkout">
    SnapIt redirects you to Stripe checkout. After payment you return to the Billing page.
  </Step>
</Steps>

<Note>
  Credits are applied when Stripe confirms the payment via webhook. If your balance has not updated right after checkout, wait a moment and refresh the Billing page.
</Note>

## When credits run out

Uploads that would overdraw your balance are rejected with HTTP **402 Payment Required** and an insufficient-credits message that includes the required cost and your available balance. This applies to dashboard uploads and to the programmatic API (`POST /api/v1/invoices/upload` and related endpoints).

Existing invoices and data remain accessible. To resume processing, buy a credit package on the Billing page.

When your balance falls to or below the platform low-credit threshold, SnapIt emails the workspace owner. The reminder is rate-limited so you are not emailed on every upload.
