Alladdin

Work in progress

Site en construction

الموقع قيد الإنشاء

Alladdin
POST

Create a ledger entry

Scope: accounting:daily-ledger.write https://api.alladdin.com/api/v2/ledger-entries

Creates a new ledger entry (journal entry) in your accounting books. Each entry records a debit and credit for double-entry bookkeeping.
Ledger entries are the foundation of your accounting — every financial transaction ultimately maps to one or more entries. The response returns the new entry identifier.

Request body

object date string<date> required

Ledger entry date in ISO 8601 format

notes string | null optional

Free-text notes for the ledger entry

contact_id string | null optional

Contact identifier linked to this entry

lines[] object[] required account integer required

Full account number from the chart of accounts — the number field, not the prefix

description string | null optional

Line description

debit string required

Debit amount as decimal string

credit string required

Credit amount as decimal string

tags[] string[] optional

List of tags to categorize this line

Request

python
import requests

url = "https://api.alladdin.com/api/v2/ledger-entries"
headers = {
    "Authorization": "Bearer YOUR_API_KEY",
    "Accept": "application/json",
}

payload = {
    "date": "2024-01-15",
    "notes": "string",
    "contact_id": "string",
    "lines": [
        {
            "account": 43000001,
            "description": "string",
            "debit": "100.00",
            "credit": "0.00",
            "tags": [
                "string"
            ]
        }
    ]
}
response = requests.post(url, headers=headers, json=payload)
print(response.json())

Responses

Response

json
{
  "id": "507f1f77bcf86cd799439011"
}

Success responses

201 Ledger entry created application/json object id string

Error responses

400 Bad request application/json 401 Invalid or missing API key application/json 403 Insufficient permissions application/json 422 Validation error application/json 429 Rate limit exceeded application/json

← PreviousCreate an accounting account →

Next →List chart of accounts →