POST v1/{organizationId}/invoices/{guid}/payments

Create a payment for an invoice. Payments can only be added to a booked invoice.

Request Information

URI Parameters

NameDescriptionTypeAdditional information
guid

Guid of the invoice

globally unique identifier

Required

organizationId

string

None.

Body Parameters

The payment details

PaymentCreate
NameDescriptionTypeAdditional information
Timestamp

Version of the invoice

string

Required

DepositAccountNumber

Account number of an deposit account

integer

Required

ExternalReference

Your external id This can be used for ID'ing in external apps/services e.g. a web shop. The maximum length is 128 characters

string

String length: inclusive between 0 and 128

PaymentDate

The date of the payment. This should be in the format YYYY-MM-DD e.g. 2015-12-02. Defaults to today.

string

None.

Description

Description. Fx.: 'Payment of invoice'.

string

Required

Amount

Amount. Has to be different from 0.

decimal number

Required

AmountInForeignCurrency

When handling a payment for a voucher with a foreign currency, this property is required. This property together with Amount will be used to calculate exchange rate.

decimal number

None.

Sample:
{
  "Timestamp": "00000000020A5EA8",
  "DepositAccountNumber": 55000,
  "ExternalReference": "Fx. WebShopID:42",
  "PaymentDate": "2015-12-02",
  "Description": "Payment of invoice",
  "Amount": 20.0,
  "AmountInForeignCurrency": 15.0
}

Response Information

Resource Description

200 (ok) if the payment was created

CreatedPaymentResponse
NameDescriptionType
Guid

The guid of the payment

globally unique identifier
TimeStamp

Timestamp of version of the invoice. To avoid concurrency issues.

string
Sample:
{
  "Guid": "92dcef2b-4e98-4c68-8f43-8460d2acc6c6",
  "TimeStamp": "00000000020A5EA8"
}