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

# Billing

> How calls draw from your balance.

The API is pay-per-use, drawn from the balance of the account that owns the
credential. Balance is in **coins** (`1 coin = R$ 1.00`).

## Flat fee + pass-through

Every call has up to two cost components:

<Steps>
  <Step title="Flat platform fee">
    A small amount per request, drawn from the account. **Only API-key calls pay
    it** — session-JWT calls (the app) don't.
  </Step>

  <Step title="Pass-through (when applicable)">
    If the call triggers an external provider (transcription, AI, YouTube), its
    real cost is also drawn — from the **owner of the resource**. Plain reads
    serve from the database and have no pass-through.
  </Step>
</Steps>

## Flat fee per route

| Route                                                                                    | Fee          |
| ---------------------------------------------------------------------------------------- | ------------ |
| Most reads (`accounts/me`, `items`, `collections`, `reporters`, `videos`, `discover`, …) | `0.001 coin` |
| `GET /search`                                                                            | `0.005 coin` |
| `GET /items/{id}/transcript`                                                             | `0.005 coin` |
| `POST /items` · `POST /collections/{id}/items`                                           | `0.005 coin` |
| `POST /items/{id}/transcript` (runs the transcriber)                                     | `0.01 coin`  |

<Note>
  The fee is drawn **after** the response, best-effort — a billing failure never
  drops your call. Prices may change as the platform evolves.
</Note>

## Insufficient balance

Before processing an API-key call, the API checks the balance. Zero or negative →
the call is rejected up front:

```json theme={null}
// HTTP 402 Payment Required
{ "erro": "saldo insuficiente — adicione coins na conta" }
```

A long-running job can also fail mid-flight with `402` if a pass-through provider
call would overdraw the resource owner.

## Top up via Pix

Coins are bought with **Pix** (`1 coin = R$ 1.00`):

<Steps>
  <Step title="Create the charge">
    `POST /v1/accounts/me/deposit/pix` with `{ amount_coins, cpf }` → returns the
    QR Code (base64) and the copy-and-paste code. Minimum **5 coins**.

    ```json theme={null}
    {
      "deposit_id": "…",
      "status": "pending",
      "amount_coins": 50,
      "fee_brl": 1.99,
      "pix": { "qr_code_base64": "iVBORw0KGgo…", "copia_e_cola": "00020101…" }
    }
    ```
  </Step>

  <Step title="Pay">
    Pay the Pix from your bank app. (InfinitePay is also available, fee-free, via
    `POST /v1/accounts/me/deposit/infinitepay`, which returns a checkout link.)
  </Step>

  <Step title="Automatic credit">
    On confirmation, the provider notifies the API and the coins are credited —
    you get a `deposit_credited` event in real time.
  </Step>
</Steps>

## Track usage & withdraw

* Balance: `GET /v1/accounts/me`.
* Ledger: `GET /v1/accounts/me/transactions` (filter by `kind`, `ref_type`).
* Withdraw the deposited pool back to BRL: `POST /v1/accounts/me/withdraw`
  (bonus credit isn't withdrawable).
