Skip to content

Sign-in and keys

The ownr API uses OAuth 2.0 client credentials: you exchange your key for an access token and send the token with every call.

API keys

A key is a Client ID and a Client secret. There are two kinds:

Key Who creates it Used for
Personal key Each user, under API Adgang Your own scripts and AI assistants
Integration key An administrator, in the same place Systems such as a CRM or ERP
  • A key follows the licence of the user who owns it.
  • All keys of the organisation share one quota.
  • An integration key does not belong to an employee, so it keeps working if an employee leaves.

Get an access token

Terminal window
curl -X POST https://ownr.dk/api/v2/token \
-d grant_type=client_credentials \
-d client_id=CLIENT_ID \
-d client_secret=CLIENT_SECRET
{
"status": "success",
"access_token": "…",
"expires_in": 3600,
"token_type": "Bearer",
"scope": "companies persons properties ajour pipeline"
}
  • The token is valid for expires_in seconds (3,600). Request a new one when it expires.
  • You may send the Client ID and Client secret as HTTP Basic authentication instead of in the body.

Use the token

Send the token in the Authorization header:

Terminal window
curl https://ownr.dk/api/v2/company/36732261 \
-H "Authorization: Bearer ACCESS_TOKEN"

Scopes

A key gets these five scopes automatically: companies, persons, properties, ajour and pipeline. Other scopes are granted by ownr. An endpoint answers 403 to a token without its scope.

Scope Endpoints
companies /company/… (including /company/segments), /p-unit/…, /report/…, /account/followed/companies
persons /person/… (including /person/segments), /account/followed/persons
properties /property/… (including /property/segments), /account/followed/properties
ajour /company/{cvr}/ajour, /person/{itemId}/ajour, /property/{dafId}/ajour, /account/ajour/…
pipeline /pipelines…
companies, persons or properties /segments/downloads…
companies or persons /beneficial-owners/purposes

Beneficial owners

Looking up beneficial owners requires a separate approval, whatever your licence. Without it, the beneficial owners field says Access required and the rest of the answer is unchanged.