Skip to main content
POST
/
accounting_new
/
accounts
Create account
curl --request POST \
  --url https://api.zenskar.com/accounting_new/accounts \
  --header 'Content-Type: application/json' \
  --header 'organisation: <api-key>' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "account_category": "Assets",
  "name": "<string>",
  "description": "<string>",
  "custom_data": {}
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "account_category": "Assets",
  "name": "<string>",
  "balance_normality": "credit",
  "is_parent": true,
  "created_at": "2023-11-07T05:31:56Z",
  "description": "<string>",
  "parent_path": "<string>",
  "custom_data": {},
  "updated_at": "2023-11-07T05:31:56Z"
}

Documentation Index

Fetch the complete documentation index at: https://docs2.zenskar.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

x-api-key
string
header
default:<your-api-key>
required
organisation
string
header
default:<your-organisation-id>
required

Body

application/json

not accepting parent_path as of now as we only want to allow the user to create a top-level account. creating a child account is a more involved task. Eg. if an account has journal lines, and no child account initially. Then a new child account is created, we need to update the account_id in all the journal lines of that account. Problems: How do we sync it to connector? Accounting connector currently relies of knowing the account mapping beforehand. Also we don't know if connectors allow us to update the account ID of lines in locked journal entries.

account_category
enum<string>
required
Available options:
Assets,
Liabilities,
Equity,
Income,
Expenses
name
string
required
description
string | null
custom_data
Custom Data · object

Response

Successful Response

id
string<uuid>
required
organisation_id
string<uuid>
required
account_category
enum<string>
required
Available options:
Assets,
Liabilities,
Equity,
Income,
Expenses
name
string
required
balance_normality
enum<string>
required
Available options:
credit,
debit
is_parent
boolean
required
created_at
string<date-time>
required
description
string | null
parent_path
string | null
custom_data
Custom Data · object
updated_at
string<date-time> | null