v1

latestOpenAPI 3.0.22026-07-223907721.1 MB
Reservations

Set the reservation for a specific voucher

This call temporary reserves an amount on a specific voucher, that can later be charged. A reservation expires after 30 minutes or in case a new one is requested for this voucher.

post/reservations

Request body

amountstring required

Amount in the currency of this voucher. Must be send as string in the following pattern:

  • Up to five digits before the decimal point
  • The decimal point (.)
  • Exactly two digits after the decimal point
currencystring required

The three-character ISO-4217 currency code - https://en.wikipedia.org/wiki/ISO_4217#Active_codes (must match the currency of the voucher)

codestring required

A code that must be entered during the ordering process to receive the savings indidcated on the assiciated voucher.

pinstring

An additional security feature on printed vouchers

Example request

{
  "amount": "10.53",
  "currency": "EUR",
  "code": "test",
  "pin": "test"
}

Response

OK

idstring

Primary identification key - will be used in voucher-reservation calls

voucher_idstring

Voucher primary identification key (see voucher -> id)

voucher_taxableboolean

Defines if this voucher is a taxable multi purpose voucher

voucher_tax_ratestring

The tax rate for this voucher (only needed when taxable is true, can also be null)

client_idstring

Client primary identification key (see client -> id)

amountstring

Amount in the currency of this voucher. Must be send as string in the following pattern:

  • Up to five digits before the decimal point
  • The decimal point (.)
  • Exactly two digits after the decimal point
valid_untilstring RFC3339

valid_until - datetime in RFC3339 format, see https://tools.ietf.org/html/rfc3339

created_atstring RFC3339

created_at - datetime in RFC3339 format, see https://tools.ietf.org/html/rfc3339

updated_atstring RFC3339

updated_at - datetime in RFC3339 format, see https://tools.ietf.org/html/rfc3339

Example response

{
  "id": "da39a3ee5eb28b7392ef5",
  "voucher_id": "da39a3ee4528b7392ef5",
  "client_id": "cff8784e5eb28b9b04860",
  "amount": "10.53",
  "valid_until": "2017-07-21T17:32:28+00:00",
  "created_at": "2017-07-21T17:32:28+00:00",
  "updated_at": "2017-07-21T17:32:28+00:00"
}