---
title: GET /v1/deposits
---

# `GET /v1/deposits`

List deposits

Deposit history, cursor-paginated.

Money, price, rate and count fields cross the wire as decimal strings; units are shown beside each field ([Wire encoding](/api/wire-encoding)). Group: [Deposits](/api/reference/deposits/).

**Auth:** API key (`x-api-key`)

**Scope:** `read`

**Rate limit:** the `read` budget ([Rate limits](/api/rate-limits))

**Effect:** `read`: reads only

## Parameters

- <span id="param-limit"></span>`limit` (query) · string · optional: Page size, 1..200 (default is the endpoint's historical window, not a cap).
- <span id="param-beforeSeq"></span>`beforeSeq` (query) · string · optional: Cursor: return rows strictly before this sequence (decimal). Omit for page one.

## Request

```bash [curl]
curl -fsS "$HB/v1/deposits" \
  -H "x-api-key: $HB_KEY"
```

```python [Python]
import os

import requests

HB = os.environ.get("HB", "https://testnet.hardbasis.com")

resp = requests.get(
    f"{HB}/v1/deposits",
    headers={
        "x-api-key": os.environ["HB_KEY"],
    },
)
resp.raise_for_status()
print(resp.json())
```

```ts [TypeScript]
const HB = process.env.HB ?? "https://testnet.hardbasis.com";

const res = await fetch(`${HB}/v1/deposits`, {
  method: "GET",
  headers: {
    "x-api-key": process.env.HB_KEY!,
  },
});
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
console.log(await res.json());
```

## Responses

- **200**: OK
  - <span id="res-200-deposits"></span>`deposits` · object[] · required
    - <span id="res-200-deposits-accountId"></span>`accountId` · string · required
    - <span id="res-200-deposits-amountMsat"></span>`amountMsat` · string · unit `msat` · required
    - <span id="res-200-deposits-feeMsat"></span>`feeMsat` · string · unit `msat` · required
    - <span id="res-200-deposits-railRef"></span>`railRef` · string · required
    - <span id="res-200-deposits-seq"></span>`seq` · string · unit `seq` · required
    - <span id="res-200-deposits-tsMs"></span>`tsMs` · string · unit `ms` · required
  - <span id="res-200-nextBeforeSeq"></span>`nextBeforeSeq` · string \| null · unit `seq` · required

Example `200` response:

```json
{
  "deposits": [
    {
      "accountId": "string",
      "amountMsat": "100000",
      "feeMsat": "100000",
      "railRef": "string",
      "seq": "100000",
      "tsMs": "100000"
    }
  ],
  "nextBeforeSeq": "100000"
}
```

## Errors

Every refusal carries a stable `code` from [`ErrorCode`](/api/reference/all#errorcode) beside human `error` prose; match on the code. See [Errors](/api/errors).

- **401**: A refusal carrying a stable machine `code` (ErrorCode) beside human `error` prose.
- **403**: A refusal carrying a stable machine `code` (ErrorCode) beside human `error` prose.
- **429**: A token bucket is exhausted.
