---
title: "Post opening balances"
method: POST
path: "/opening-balances"
tags: ["Accounting"]
---

# Post opening balances

`POST /opening-balances`

## Request

- Base URL: `https://ledgerhq.pro/api/v1`
- URL: `https://ledgerhq.pro/api/v1/opening-balances`
- Auth: one of:
  - HTTP bearer and API key in header `x-organization-id`
  - HTTP bearer and API key in header `x-organization-id`

Creates the opening-balance journal entry for the organization as of a date. Amounts are integer cents; each line carries a debit or credit against a chart account.

## Request body

- object
  - `date` string, date, required
  - `balances` object[], required
    - `accountId` string, uuid, required
    - `debitAmount` integer
    - `creditAmount` integer

## Response `200`

Opening balances posted

## Other responses

- `default`: Error response

---

[API](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api.md) · [All operations](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ledgerhq-pro/apis/ledgerhq-bookkeeping-api/revisions/9a8269f0a586?raw)
