Documentation / Integration guide / Part 15 of 18

15. Versions and the public contract

  • The 4 public operations are under /api/v1/. Version 1 changes only by additions: a new operation, a new optional request field, a new answer field.
  • A breaking change makes /api/v2/ next to /api/v1/. Version 1 then stays 12 months or more after the release of version 2. Each answer of version 1 then has the headers Deprecation and Sunset with its end date.
  • The machine-readable contract is at /docs/api/openapi.json on the subscription host. It holds the public operations and webhook definitions only.
  • info.version of the document is 1.<n>.0. n grows by 1 with each release that adds to version 1. Read info.version before your server sends a field that a later version added. A request is a strict object. An installation with an older version refuses a new field with 400, and your site then shows no paid part.
  • The 4 element names, each attribute and each value of type are part of the contract. A breaking change of the embed makes /embed/v2/embed.js next to /embed/v1/embed.js. Version 1 of the script then stays 12 months or more.
  • The webhooks change by additions only, just like /api/v1/. Additions include new event types, new body fields, or new values of paymentMethod or endReason. The member webhooks of /docs/api/openapi.json holds the body of each event type. Part 16 gives the receiver rule for an unknown field and an unknown value.

Download the OpenAPI file