API v1 Introduction

The LifePeaks.dk API is organized around REST. Our API accepts JSON-encoded requests, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

The LifePeaks.dk API is based on the principles of Representational State Transfer (REST) allowing clients to create, view, modify and delete resources using standard HTTP request methods with OAuth2 authentication.

Endpoint groups

Every v1 endpoint is listed below. The complete request and response shapes are described in the v1 API reference, generated from the v1 OpenAPI specification.

GroupEndpoints
AuthorizationPOST /token, POST /oauth2/revoke
ActionsGET /action/ping, POST /action/list, POST /action/analytics, POST /action/claimed-items, GET /action/subscribers
ItemGET /item/{code}, POST /item/{code}/resend, POST /item/{code}/claim, POST /item/{code}/refund, POST /item/{code}/cancel, POST /item/{code}/activate, POST /action/create-gc
OrderPOST /order/{order_id}/claim, POST /order/{order_id}/capture
EventsPOST /event/list, POST /event/{slug}/participants
ListsGET /list/gc-value-modifications

Alongside these, /authorize, /login and /logout serve the browser-based authorization code flow — see Authorization of Request.

Scopes and user rights

Access is controlled by two independent things: the scope attached to the OAuth2 client, and the user right of the API user the token belongs to.

ScopeWhat it permits
adminEvery endpoint.
zapierGET /action/subscribers.

Most endpoints require the admin scope. GET /action/subscribers performs no scope check at all — any authenticated token reaches it, and the company is taken from the token holder. Claim, refund and event endpoints additionally reject users whose user right is agency_user.

Where to go next