fepli
API resources

Debtors

A debtor (Debitor) is a family's ledger: what they paid, which fees are still open, and how much credit they have. A family gets a ledger with their first application.

All debtor endpoints need ROLE_PAYMENTS_ADMIN. Amounts are in cents. In book entries, positive values credit the family and negative values are claims against them.

The debtor model

  • Name
    uuid
    Type
    string
    Description

    The ledger's identifier.

  • Name
    account
    Type
    reference
    Description

    The family account.

  • Name
    balance
    Type
    integer
    Description

    The sum of all entries that aren't payments, in cents: manual bookings, credit used on receipts, claims for partly paid fees, and reversals credited to the ledger. Positive is credit, which the next payment uses up; negative is a claim.

  • Name
    paid
    Type
    integer
    Description

    The sum of the payment entries, in cents: money received, minus reversals that were paid out.

  • Name
    due
    Type
    integer
    Description

    The sum of the fees of the open applications, in cents.

  • Name
    openAttendances
    Type
    string[]
    Description

    The UUIDs of the applications whose fee is due and unpaid.

  • Name
    receipts
    Type
    reference[]
    Description

    The family's receipts. The reference's name is the receipt number.

  • Name
    bookEntries
    Type
    object[]
    Description

    The entries of the ledger. Each has a uuid, a bookingDate, a value in cents, a type (payment for money received or paid out, manual for everything else), the postingRecord text, and the UUID of the receipt that created it, or null for a booking made by hand.


GET/debtors

List all debtors

Returns a page of ledgers, ordered by the family's last name.

Optional filters

  • Name
    q
    Type
    string
    Description

    Only ledgers of families whose name or e-mail address contains this text.

  • Name
    account
    Type
    string
    Description

    Only the ledger of this account (UUID or e-mail address).

  • Name
    withBalance
    Type
    boolean
    Description

    true for ledgers with credit only.

  • Name
    page, itemsPerPage
    Type
    integer
    Description

    See Pagination.

Request

GET·/debtors
curl -G https://ferienpass-musterstadt.de/api/debtors \
  -H "Authorization: Bearer $FEPLI_TOKEN" \
  --data-urlencode "account=familie.mueller@example.org"

Response

[
  {
    "uuid": "0191c7b4-5a6b-7c8d-9e0f-1a2b3c4d5e09",
    "account": {
      "uuid": "0191c7b2-4d5e-7f60-8a1b-2c3d4e5f6a05",
      "name": "Anna Müller"
    },
    "balance": 0,
    "paid": 1250,
    "due": 400,
    "bookEntries": [
      {
        "uuid": "0192e1a1-0a1b-7c2d-8e3f-4a5b6c7d8e29",
        "bookingDate": "2026-09-10T10:22:31+02:00",
        "value": 1250,
        "type": "payment",
        "postingRecord": "RE-142",
        "receipt": "0192e1a0-7b8c-7d9e-a0f1-2b3c4d5e6f08"
      }
    ],
    "receipts": [
      { "uuid": "0192e1a0-7b8c-7d9e-a0f1-2b3c4d5e6f08", "name": "RE-142" }
    ],
    "openAttendances": ["0192d0f9-5c6d-7e7f-9a8b-0c1d2e3f4a30"]
  }
]

GET/debtors/{uuid}

Retrieve a debtor

Returns one ledger. An account's ledger UUID is in its debtor field.

Request

GET·/debtors/{uuid}
curl https://ferienpass-musterstadt.de/api/debtors/0191c7b4-5a6b-7c8d-9e0f-1a2b3c4d5e09 \
  -H "Authorization: Bearer $FEPLI_TOKEN"

POST/debtors/{uuid}/book-entries

Add a booking

Adds a manual booking (freie Buchung) to the ledger: a credit for the family, for example after an overpayment, or a claim against them. Returns the updated ledger.

Required attributes

  • Name
    value
    Type
    integer
    Description

    The amount in cents. Positive credits the family, negative charges them. Can't be 0.

  • Name
    postingRecord
    Type
    string
    Description

    The booking text (Buchungstext), up to 255 characters.

Request

POST·/debtors/{uuid}/book-entries
curl -X POST https://ferienpass-musterstadt.de/api/debtors/0191c7b4-5a6b-7c8d-9e0f-1a2b3c4d5e09/book-entries \
  -H "Authorization: Bearer $FEPLI_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"value": 500, "postingRecord": "Gutschrift: doppelt überwiesen"}'

Was this page helpful?