Developer documentation

Create payment

post https://app.iteras.dk/api/customers/createpayment/

The /api/customers/createpayment/ endpoint creates a payment on a customer.

Parameters

  • id string required
    ID of the customer.
  • invoice_number string
    The specific invoice the payment should be allocated to. If you don't have an invoice number, you may need to specify the business entity if there are more than one.
  • business_entity string
    External ID of the business entity inside Iteras to connect the payment to, if you do not specify an invoice and if you have more than one business entity.
  • amount integer required
    Integer amount (send €10.50 as 1050).
  • currency string required
    Three-letter ISO currency code, e.g. EUR, DKK, SEK, NOK. The currency must match the invoice/business entity.
  • method string Defaults to manual
    Payment method. Either manual (default, for manually registered), internal (internal transfer of funds) or external (for refunds registered on behalf of another system).
  • date string
    The date the payment was received in the bank account, e.g. 2026-10-08. The default is today.
  • data object
    Keys and values of custom payment fields, if any are set up inside Iteras, e.g. {"examplefield": "value"}.
  • note string
    Internal note attached to the payment.

Examples

Create a payment connected to a business entity:

POST /api/customers/createpayment/ HTTP/1.1
Content-Type: application/json{
  "id": "12345",
  "business_entity": "DKbranch",
  "amount": 1050,
  "currency": "DKK",
  "note": "Balance from old system"
}

Create a payment allocated to a specific invoice:

POST /api/customers/createpayment/ HTTP/1.1
Content-Type: application/json{
  "id": "12345",
  "invoice_number": 1007,
  "amount": 1050,
  "currency": "DKK"
}

The endpoint returns the ID of the new payment:

{ "payment_id": "982137" }

Errors

Invalid requests due to programming error, e.g. invalid JSON, returns 400. This also covers specifying both business_entity and invoice_number.

A well-formed operation where a supplied value is invalid is not executed and returns an HTTP 422 error. The response is a JSON object with the errors keyed by the field they concern, e.g. a currency that doesn't match the business entity:

{
  "currency": ["Invalid currency: EUR"]
}

This also covers needing to specify business_entity when there are several:

{
  "business_entity": ["Must specify \"business_entity\"."]
}

Errors that are not specific to a field are returned with the empty string as key, e.g. an unknown business entity or invoice:

{
  "": ["Business entity does not exist."]
}