> For the complete documentation index, see [llms.txt](https://tri.gitbook.io/tri-doc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tri.gitbook.io/tri-doc/liquidity-pool/balance/add-balance.md).

# Add Balance

### Liquidity Pool

<mark style="color:green;">`POST`</mark> <https://sandbox.triangle.digital/api/v2/liquidity\\_pool/clients/{client\\_id}/balance/deposits>

Adds money to a Spending Capacity balance by charging the holder's saved card, and creates a deposit that can be read back with [Get Deposit](/tri-doc/liquidity-pool/balance/get-deposit.md). The holder is part of the address:

<table data-full-width="true"><thead><tr><th width="460">URL</th><th>Holder</th></tr></thead><tbody><tr><td><code>/clients/{client_id}/balance/deposits</code></td><td>The client itself</td></tr><tr><td><code>/clients/{client_id}/employees/{employee_id}/balance/deposits</code></td><td>One employee</td></tr><tr><td><code>/clients/{client_id}/individual_consumptions/{individual_consumption_id}/balance/deposits</code></td><td>One Individual Consumption</td></tr></tbody></table>

The answer carries the created deposit, and the `Location` header its address. Reading the balance itself is a separate call (see [Get Balance](/tri-doc/liquidity-pool/balance/get-balance.md)). Money, time and error formats follow the [conventions of the balance endpoints](/tri-doc/liquidity-pool/balance.md).

**Idempotency.** The `Idempotency-Key` header is required: a retry after a lost response must not charge the card twice. Repeating a request with the same key returns the deposit created by the first call, unchanged, with `Idempotent-Replay: true`. Using the same key for a different amount or a different holder is refused with `409`.

**Path parameters**

<table data-full-width="true" data-search="false"><thead><tr><th width="230">Name</th><th width="110">Type</th><th>Description</th><th width="210">Where to take it from</th></tr></thead><tbody><tr><td><code>client_id</code></td><td>integer</td><td><strong>Required.</strong> The client whose balance is topped up.</td><td><a href="/tri-doc/liquidity-pool/get-clients.md">Get Clients</a> — <code>client_id</code></td></tr><tr><td><code>employee_id</code></td><td>integer</td><td>Employee address only.</td><td><a href="/tri-doc/liquidity-pool/get-employees.md">Get Employees</a> — <code>employee_id</code></td></tr><tr><td><code>individual_consumption_id</code></td><td>uuid</td><td>Individual Consumption address only.</td><td><a href="/tri-doc/liquidity-pool/get-individual-consumptions.md">Get Individual Consumptions</a> — <code>individual_consumption_id</code></td></tr></tbody></table>

**Headers**

<table data-full-width="true"><thead><tr><th>Name</th><th>Value</th></tr></thead><tbody><tr><td>Content-Type</td><td><code>application/json</code></td></tr><tr><td>Idempotency-Key</td><td><strong>Required.</strong> Value unique to this attempt, up to 48 characters.</td></tr></tbody></table>

**Query parameters**

<table data-full-width="true" data-search="false"><thead><tr><th width="159.800048828125">Name</th><th width="149">Type</th><th>Description</th><th width="160.796875">Example</th></tr></thead><tbody><tr><td><code>hash</code></td><td>string</td><td><strong>Required.</strong> API key.</td><td>fk5f0iuy-rr06-j4x3-i75b-fy2s67s4ilo1</td></tr></tbody></table>

**Body**

<table data-full-width="true" data-search="false"><thead><tr><th width="159.800048828125">Name</th><th width="149">Type</th><th>Description</th><th width="160.796875">Example</th></tr></thead><tbody><tr><td><code>amount.currency</code></td><td>string</td><td><strong>Required.</strong> ISO 4217 code. Only USD is supported.</td><td>USD</td></tr><tr><td><code>amount.amount</code></td><td>string</td><td><strong>Required.</strong> Decimal string with at most two decimals, from 0.01 to 9999.00.</td><td>100.00</td></tr></tbody></table>

```json
{
    "amount": {
        "currency": "USD",
        "amount": "100.00"
    }
}
```

**Response fields**

<table data-full-width="true" data-search="false"><thead><tr><th width="230">Field</th><th width="110">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>id</code></td><td>uuid</td><td>The created deposit. Use it with <a href="/tri-doc/liquidity-pool/balance/get-deposit.md">Get Deposit</a>.</td></tr><tr><td><code>status</code></td><td>string</td><td>One of settled, failed, needs_reconciliation, pending — see <a href="/tri-doc/liquidity-pool/balance/get-deposit.md">Get Deposit</a>.</td></tr><tr><td><code>amount.currency</code></td><td>string</td><td>ISO 4217 code. Always USD.</td></tr><tr><td><code>amount.amount</code></td><td>string</td><td>Amount charged, as a decimal string.</td></tr><tr><td><code>created_at</code></td><td>string</td><td>When the deposit was created, ISO 8601 in UTC.</td></tr><tr><td><code>payment_intent_id</code></td><td>string</td><td>Identifier of the payment at the provider; <code>null</code> when the card was never charged.</td></tr></tbody></table>

The balance is not part of the answer — read it with [Get Balance](/tri-doc/liquidity-pool/balance/get-balance.md).

**Response**

{% tabs %}
{% tab title="201" %}
{% code fullWidth="false" %}

```json
{
    "id": "3f7a1c9e-8b02-4d51-9a6e-2c14f0d7b9aa",
    "status": "settled",
    "amount": {
        "currency": "USD",
        "amount": "100.00"
    },
    "created_at": "2026-08-04T11:20:05Z",
    "payment_intent_id": "pi_3QxJ8kL2eZvKYlo2C1r4Xy9T"
}
```

{% endcode %}
{% endtab %}

{% tab title="200" %}
A repeat of the same `Idempotency-Key`. The body is the deposit created by the first call and the answer carries `Idempotent-Replay: true`.

```json
{
    "id": "3f7a1c9e-8b02-4d51-9a6e-2c14f0d7b9aa",
    "status": "settled",
    "amount": {
        "currency": "USD",
        "amount": "100.00"
    },
    "created_at": "2026-08-04T11:20:05Z",
    "payment_intent_id": "pi_3QxJ8kL2eZvKYlo2C1r4Xy9T"
}
```

{% endtab %}

{% tab title="402" %}
The card was declined. The deposit still exists and its id is in the answer.

```json
{
    "title": "The card was declined",
    "status": 402,
    "detail": "Your card was declined. Try another card.",
    "code": "card_declined",
    "deposit_id": "3f7a1c9e-8b02-4d51-9a6e-2c14f0d7b9aa"
}
```

{% endtab %}

{% tab title="409" %}

```json
{
    "title": "Deposit result is unknown",
    "status": 409,
    "detail": "The payment may have gone through; the operation is recorded. Contact support before retrying.",
    "code": "needs_reconciliation",
    "deposit_id": "3f7a1c9e-8b02-4d51-9a6e-2c14f0d7b9aa"
}
```

{% endtab %}

{% tab title="422" %}

```json
{
    "title": "Amount is not valid",
    "status": 422,
    "detail": "amount must be a decimal string with at most 2 decimals, e.g. \"10.00\".",
    "code": "invalid_amount",
    "param": "amount.amount"
}
```

{% endtab %}
{% endtabs %}
