Accounting

General-ledger overlay — authored journal entries (opening balances, adjustments) and accounting periods with close/lock. Statements (trial balance, balance sheet) are served as reports.

7 endpoints·Scopes: accounting:read, accounting:write
GET/api/journal-entries#

List journal entries

scope · accounting:read

Lists journal entries the caller can see. Results are filtered by the caller's accessible organizations; many routes paginate via page and limit.

Scope: accounting:read
Endpoint: GET /api/journal-entries

Example request

curl "https://app.guliel.com/api/journal-entries?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • from
    string
  • to
    string

Response (200/201)

  • journalEntriesreq
    array<object>
    • idreq
      string
    • organizationIdreq
      string
    • datereq
      string
    • memoreq
      string | null
    • createdAtreq
      string
    • postingsreq
      array<object>
      • idreq
        string
      • accountreq
        enum<15>
        CASH · AR · AP · REVENUE · EXPENSE · TAX_PAYABLE · TAX_RECEIVABLE · EQUITY · PREPAID_EXPENSE · DEFERRED_REVENUE · SALARY_EXPENSE · STATUTORY_EXPENSE · +3 more
      • debitreq
        number
      • creditreq
        number

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
POST/api/journal-entries#

Create a journal entry

scope · accounting:writerole · CONTRIBUTOR+

Creates a new journal entry in the target organization. Returns the created record on success.

Scope: accounting:write
Min role: CONTRIBUTOR or higher
Endpoint: POST /api/journal-entries

Example request

curl -X POST "https://app.guliel.com/api/journal-entries" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "date": "string",
  "legs": [
    {
      "account": "CASH",
      "debit": 0,
      "credit": 0
    }
  ]
}'

Request body

  • organizationIdreq
    string
  • datereq
    string
  • memo
    string | null
  • legsreq
    array<object>
    • accountreq
      enum<15>
      CASH · AR · AP · REVENUE · EXPENSE · TAX_PAYABLE · TAX_RECEIVABLE · EQUITY · PREPAID_EXPENSE · DEFERRED_REVENUE · SALARY_EXPENSE · STATUTORY_EXPENSE · +3 more
    • debitreq
      number
    • creditreq
      number

Response (200/201)

  • idreq
    string
  • organizationIdreq
    string
  • datereq
    string
  • memoreq
    string | null
  • createdAtreq
    string
  • postingsreq
    array<object>
    • idreq
      string
    • accountreq
      enum<15>
      CASH · AR · AP · REVENUE · EXPENSE · TAX_PAYABLE · TAX_RECEIVABLE · EQUITY · PREPAID_EXPENSE · DEFERRED_REVENUE · SALARY_EXPENSE · STATUTORY_EXPENSE · +3 more
    • debitreq
      number
    • creditreq
      number

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
DELETE/api/journal-entries/{id}#

Delete a journal entry

scope · accounting:writerole · CONTRIBUTOR+

Deletes the journal entry. Some endpoints hard-delete the row, others soft-revoke (set revokedAt). Check the response shape.

Scope: accounting:write
Min role: CONTRIBUTOR or higher
Endpoint: DELETE /api/journal-entries/{id}

Example request

curl -X DELETE "https://app.guliel.com/api/journal-entries/abc123?id=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • idreq
    string
  • organizationIdreq
    string

Response (200/201)

  • successreq
    boolean

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
GET/api/ledger/export#

Export ledgers as CSV

scope · accounting:read

Streams the caller's ledgers as a CSV file. Filter parameters scope the export the same way the list endpoint does.

Scope: accounting:read
Endpoint: GET /api/ledger/export

Example request

curl "https://app.guliel.com/api/ledger/export?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • from
    string
  • to
    string

Response (200/201)

JSON object. The exact response shape is being progressively documented — call the endpoint with a real access token to see the live structure, or check the type definitions exposed by the official client libraries.

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
PATCH/api/ledger/lock#

Update lock (ledgers)

scope · accounting:writerole · MANAGER+

Mutates the lock configuration for the ledgers feature.

Scope: accounting:write
Min role: MANAGER or higher
Endpoint: PATCH /api/ledger/lock

Example request

curl -X PATCH "https://app.guliel.com/api/ledger/lock" \
  -H "Authorization: Bearer $GULIEL_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "organizationId": "abc123",
  "lockedThrough": "string"
}'

Request body

  • organizationIdreq
    string
  • lockedThroughreq
    string | null

Response (200/201)

  • lockedThroughreq
    string | null

Error responses

400Validation
401Unauthenticated
403Forbidden
429RateLimit
500Internal
GET/api/ledger/postings#

Get postings (ledgers)

scope · accounting:read

Returns the postings data for the ledgers feature.

Scope: accounting:read
Endpoint: GET /api/ledger/postings

Example request

curl "https://app.guliel.com/api/ledger/postings?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string
  • from
    string
  • to
    string
  • limitreq
    integer

Response (200/201)

  • postingsreq
    array<object>
    • datereq
      string
    • kindreq
      enum<4>
      document · payment · recognition · journal
    • sourcereq
      string
    • accountreq
      string
    • accountNamereq
      string
    • debitreq
      number
    • creditreq
      number
  • totalreq
    integer
  • totalDebitreq
    number
  • totalCreditreq
    number

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal
GET/api/ledger/summary#

Get summary (ledgers)

scope · accounting:read

Returns the summary data for the ledgers feature.

Scope: accounting:read
Endpoint: GET /api/ledger/summary

Example request

curl "https://app.guliel.com/api/ledger/summary?organizationId=value" \
  -H "Authorization: Bearer $GULIEL_API_KEY"

Query parameters

  • organizationIdreq
    string

Response (200/201)

  • autoObligationsreq
    integer
  • autoSettlementsreq
    integer
  • manualEntriesreq
    integer
  • totalDebitreq
    number
  • totalCreditreq
    number
  • lockedThroughreq
    string | null

Error responses

400Validation
401Unauthenticated
403Forbidden
500Internal