niiko/developers

Kiipu · invoicing v1 read-only

kiipu.month_result_get

Reads this month's income statement from the ledger: revenue, expenses, net income, the accounts that weigh most and last month to compare. If the ledger does not balance right now it gives no figures; with no entries it says so, never zero.

Last updated

POST /api/v1/reads/kiipu.month_result_get
Token scope
kiipu.month_result_get@1
Workspace permission
api.kiipu.month_result_get off by default
Who reads
The person behind the token, with their role. Someone who leaves the workspace stops reading.
Three permissions

A token with that scope, the workspace owner having switched the read on, and the person's role seeing it in the product. None of them is enough alone. OAuth only →

Request

No fields.

Response — output when status is done

fieldtyperules
currencystringrequired
ledgerBalancedbooleanrequired
monthstring | nullrequired
noActivityThisMonthbooleanrequired
thisMonthobject | nullrequired
previousMonthobject | nullrequired

Example

# Reads take an OAuth access token, not an API key, and no idempotency key: reading changes nothing.
curl -X POST https://niiko.org/api/v1/reads/kiipu.month_result_get \
  -H "Authorization: Bearer $NIIKO_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'
# 200 → done · 4xx → refused, with a named reason

Why it may refuse

Each reason names who can fix it and how; detail.message, when present, says what to do. Refusals & HTTP codes →

invalid_inputrole_forbiddengrant_offreads_need_a_person

In the clients

@vorluno/niiko-sdkniiko.getMonthResult()
niiko (Python)niiko.get_month_result() from 0.3.0 · not on the registry yet
niiko-cliniiko read kiipu.month_result_get
n8n-nodes-niikoNo reads: the node holds a key, and reading needs a person through OAuth.
niiko-mcp-serverkiipu_month_result_get readOnlyHint

History