Skip to content

Overview

Haddon: an open-source double-entry ledger for AI agents. It comes with an optional web interface for people. One database file is one entity; every path below /v1/entities/{entity_id} is resolved inside that file, so an id that exists for another entity is simply not found here.

Amounts cross the wire as base-10 integer strings of micro-units (millionths), in both directions. "amount_micros": "-12000000" is -12.00 of a two-decimal commodity. JSON numbers are refused.

Dates are inclusive from/to over one continuous journal. Either bound may be omitted (from means “from the beginning”, to means “through the latest posting”), and any valid range is accepted; trial-balance and balance-sheet take a point as_of instead. A range that merely ends in the future is fine; one that has not begun is refused.

Pagination returns {items, next_cursor, snapshot_seq}. Cursors are opaque, signed and bind the entity, the filters, the ordering and the snapshot; pass them back unchanged. Default 50 per page, maximum 200; events default 100, maximum 500. A cursor whose snapshot is gone is 409 cursor_expired with a resync link.

Writes require an Idempotency-Key. The same key with the same request replays the original status and body with Idempotency-Replayed: true; the same key with a different request is 409 idempotency_conflict.

Authorisation records, it does not enforce. A credential is one opaque actor string scoped to explicit entities; that string is written to created_by and is never parsed. Every write is applied on the caller’s own authority and recorded with its actor and reason; there is no approval step.

Information

  • OpenAPI version: 3.1.0