POST
/
v1
/
ledgers
{
  "ledger": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "code": "<string>",
    "description": "<string>",
    "type": "asset",
    "currency_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "currency_code": "<string>",
    "balance_current": 123,
    "balance_available": 123,
    "overdraft_enabled": true,
    "overdraft_limit": 123,
    "last_activity_date": "2023-11-07T05:31:56Z",
    "opening_date": "2023-11-07T05:31:56Z",
    "closing_date": "2023-11-07T05:31:56Z",
    "parent_ledger_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "child_ledger_ids": [
      "3c90c3cc-0d44-4b50-8888-8dd25736052a"
    ],
    "created_at": "2023-11-07T05:31:56Z",
    "created_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "modified_at": "2023-11-07T05:31:56Z",
    "modified_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "active": true,
    "metadata": {}
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
code
string
required

Unique ledger code

Example:

"MAIN-USD-001"

description
string
required

Ledger description

Example:

"Main USD Operating Account"

type
enum<string>
required

Type of ledger

Available options:
asset,
liability,
equity,
income,
expense
Example:

"asset"

currency_id
string
required

Currency UUID

Example:

"550e8400-e29b-41d4-a716-446655440000"

currency_code
string
required

ISO currency code

Required string length: 3
Example:

"USD"

balance_current
integer

Current balance in cents

Example:

100000

balance_available
integer

Available balance in cents

Example:

100000

overdraft_enabled
boolean
default:
false

Enable overdraft facility

overdraft_limit
integer
default:
0

Maximum overdraft amount in cents

opening_date
string

Ledger opening date

parent_ledger_id
string

Parent ledger UUID

metadata
object

Additional metadata

Response

201
application/json
Ledger created successfully
ledger
object