Unidy exposes a RESTful API accepting and responding in JSON format.
API Endpoints
Each Unidy tenant comes with itβs own API documentation that offers the possibility to try out calls by providing the client ID and secret. The documentation can be found at https://<TENANT>.unidy.de/api-docs
.
API Authentication
In order to use the Unidy API, an access token send via authorization header is required. There are two ways to create an access token:
- Use the OIDC Authorization Flow requesting an Authorization Code to generate an access token on behalf of your user. Not all API endpoints can be accessed that way.
- Use the OIDC Client Credentials Flow to generate an admin access token that can access all endpoints and data.
This is an example on how the access token needs to be included in your API calls.
curl -X 'POST' \
'https://<TENANT>.unidy.de/api/v1/users' \
-H 'Content-Type: application/json' \
-H 'Authorization: bearer <ACCESS_TOKEN>' \
-d '{ email: undiy@example.com }'