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

# Reconciliation and statements

> Match partner statements, work breaks and export statements.

## Send a statement

A statement covers one partner, currency and day. It needs `recon:write`. `content` is the file, base64 encoded, at most 50 MB, as `CSV` or `JSONL`.

```bash theme={null}
CONTENT=$(base64 < statement.csv)
curl -X POST "$PANOQORE_URL/v1/recon/statements" \
  -H "Authorization: Bearer $PANOQORE_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"partner":"safehaven","currency":"NGN","businessDate":"2026-11-01","format":"CSV","content":"'"$CONTENT"'","closingBalance":"250000"}'
```

```text theme={null}
reference,amount,direction,account_number,narration,date
000013261005091207,2500.00,credit,0123456789,Inbound,2026-11-01
```

Partners write statements their own way, so columns are found under the names banks use, such as `reference` or `session_id`, and `credit` and `debit` columns also work. Amounts in the file are major units, unless the column is `amount_minor`, while `closingBalance` is in minor units.

Matching runs at once.

```json theme={null}
{
  "id": "stm_SHV_NGN_20261101",
  "status": "HAS_BREAKS",
  "lines": 2,
  "matched": 1,
  "breaks": 1,
  "closingBalance": "250000",
  "difference": "250000"
}
```

A day can be sent once, and a repeat gets `ALREADY_REQUESTED`. After more credits arrive, match it again with `POST /v1/recon/runs`, which resolves breaks they explain.

Where PanoQore can read the partner, statements are pulled nightly instead.

## Breaks

A break is a difference that someone has to look at.

| `kind` | Meaning |
| - | - |
| `UNBOUND_CREDIT` | A credit to a number with no active binding. |
| `AMOUNT_MISMATCH` | The partner and the ledger disagree on the amount. |
| `MISSING_AT_PARTNER` | In the ledger, not on the statement. |
| `MISSING_IN_LEDGER` | On the statement, not in the ledger. |
| `DUPLICATE_NOTICE` | The partner reported something twice. |
| `DUPLICATE_POSTING` | The ledger recorded something twice. |

A break is `OPEN`, `PROPOSED` while an adjustment waits for approval, or `RESOLVED`.

```bash theme={null}
curl "$PANOQORE_URL/v1/recon/breaks?status=OPEN" -H "Authorization: Bearer $PANOQORE_API_KEY"
```

A key can read breaks. Assigning, noting and resolving them is console work for people.

## The control equation

```bash theme={null}
curl "$PANOQORE_URL/v1/recon/control/safehaven/NGN?businessDate=2026-11-01" \
  -H "Authorization: Bearer $PANOQORE_API_KEY"
```

It compares what the partner says with the ledger: statement balance, settlement account, bound wallets and suspense. `holds` is `true` when they agree, and is left out when they do not. `businessDate` defaults to yesterday.

## Trial balance

```bash theme={null}
curl "$PANOQORE_URL/v1/trial-balance?currency=NGN&businessDate=2026-11-01" \
  -H "Authorization: Bearer $PANOQORE_API_KEY"
```

## Statements and exports

An export is made at once. `month` is `YYYY-MM`, and defaults to the current one.

| `kind` | Formats | Notes |
| - | - | - |
| `ACCOUNT_STATEMENT` | `CSV`, `PDF` | Needs `accountId`. |
| `CUSTOMER_STATEMENTS` | | Every customer's statement in one zip. |
| `TRIAL_BALANCE` | `CSV` | |
| `JOURNAL` | `CSV` | |
| `BREAK_REPORT` | `CSV` | |

```bash theme={null}
curl -X POST "$PANOQORE_URL/v1/exports" \
  -H "Authorization: Bearer $PANOQORE_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"kind":"ACCOUNT_STATEMENT","accountId":"'"$WALLET"'","format":"PDF"}'
```

Then ask for a link.

```bash theme={null}
curl "$PANOQORE_URL/v1/exports/$EXPORT/download" -H "Authorization: Bearer $PANOQORE_API_KEY"
```

```json theme={null}
{ "url": "https://.../files/exports/...", "expiresAt": "2026-11-02T21:12:45.017734Z" }
```

The link works for five minutes and needs no credential, so treat it as secret. Each download goes on the audit log. A closed month's file never changes. `sha256` on the export is the file's digest.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.