Client Credentials Flow

Overview

The Client Credentials Flow is the simplest authentication scheme to implement:
  1. 1.
    Request an Access Token from Trelica
  2. 2.
    Make API calls passing the Access Token you received

Authentication

You must pass the Client ID and Client Secret in the Authorization header using the standard HTTP Basic Authentication Scheme.
post
https://app.trelica.com
/connect/token
Request an access token

Example

Requesting the access token using curl

curl https://app.trelica.com/connect/token \
--user "<CLIENT_ID>:<CLIENT_SECRET>" \
--data "grant_type=client_credentials&scope=Users.Read"
200
400
{
"access_token": "<TOKEN>",
"expires_in": 3600,
"token_type": "Bearer",
"scope": "Users.Read"
}
{
"error": "<ERROR_CODE>"
}
Error Code
Description
invalid_client
The Client ID and/or Client Secret are incorrect
invalid_scope
The scope requested was invalid

Making an API call with the access token you received

You can now make API calls, passing the access token you received as part of an Authorization header.
curl https://app.trelica.com/api/scim/v2/Users \
--header "Authorization: Bearer <ACCESS_TOKEN>"
​
Copy link
Outline
Overview
Authentication
post
Request an access token
Example
Requesting the access token using curl
Making an API call with the access token you received