API-register: API register API v1

Details van API: API register API v1

Beschrijving

API to access the API register of developer.overheid.nl.

Auth

This API distinguishes between public and private endpoints. Public endpoints can be accessed with either an API key or a client credentials token. Private endpoints can only be accessed with a client credentials token.

API key

Using an API key, you can access all public endpoints of the API register. These requests can also be made from the browser. Simply pass the obtained API key with each request using the X-Api-Key header.

Client credentials token

Using a client credentials token, you can access both public and private endpoints of the API register. To obtain the token, you need to perform a POST request to https://auth.developer.overheid.nl/realms/don/protocol/openid-connect/token with the following Form URL Encoded body:

  • grant_type: client_credentials
  • scope: depending on the access you need and the client you are, you can request one or more of the following scopes:
    • apis:read
    • apis:write
    • organisations:read
    • organisations:write
  • client_id: the client id you received from us
  • client_secret: the client secret you received from us

Pass the obtained token with each request using the Authorization header. Example:

Authorization: Bearer {ACCESS_TOKEN} (replace {ACCESS_TOKEN} with the obtained access_token)

Pagination

Pagination of collections is done using the Link header. There are various libraries available (such as parse-link-header for Javascript) that can parse this header. Additionally, the following headers provide extra support for implementing pagination in the client:

  • Current-Page: the current page in the collection
  • Per-Page: the number of items per page
  • Total-Count: the total number of items
  • Total-Pages: the total number of pages