Skip to content

Start

Authentication and permissions

Every request to the REST API carries a bearer token. The token belongs to an integration that the operator creates for you, with that integration’s permissions and site restriction. This article explains where the token comes from, what it allows and how refusals look.

The operator creates an integration in the portal under Apps, chooses its permissions and, if they want, the sites it may reach. They then issue an API key and hand it to you. The portal shows the key once, so store it safely at that moment. Store it next to the installation’s hostname: a token works only on the installation that issued it.

Send the token in the Authorization header:

Authorization: Bearer <token>

A token does not expire in practice. Issuing a new key does not invalidate the existing ones, so you can switch to a new key without a coordinated deploy. If the operator pauses or deletes the integration, all of its keys stop working.

Integrations created before the current key format still use their original self-signed keys. Those keep working unchanged; you do not have to rotate them.

Every operation needs one permission, named after the record it works on, in the form units:read or units:write. A GET needs the read permission, every other method the write permission. The name follows the record, not the path: creating a unit under /api/rest/v1/sites/{site_id}/units needs units:write, not a site permission.

all:read and all:write stand for every permission of their kind. A new integration starts with both. Ask the operator for only the permissions you actually use.

Some records can only be read: accounts, devices (locks, lock controllers, gateways, BLE connectors, terminals, elevators, network devices), incidents and events. Sites and entrances can only be renamed with sites:write and entrances:write; the operator creates them. Two narrow permissions exist for PIN codes: pin_codes:read allows reading a tenant membership’s system PIN, and pin_codes:revoke allows issuing a new one, without granting any other access to tenant memberships.

The operator can restrict an integration to some of their sites. Without a restriction, the integration reaches every site of the organization. Records outside the permitted sites behave as if they did not exist: listings leave them out, and asking for one directly answers 404. The server deliberately does not confirm that such a record exists.

  • 401: the token is missing, unknown, or belongs to a paused or deleted integration.
  • 403: the token is valid but lacks the permission the operation needs. The message names the missing permission.
  • 404: the record does not exist, or it belongs to a site outside the integration’s restriction.

The error body is described in Errors.