TABLE OF CONTENTS
API Setup
Choose your Host Region to have the documentation adapt to your use case.
Host Region | |
---|---|
Label | Value |
EU | eu |
US | us |
AU | au |
Business Use Case
You can use this API to deactivate Users in CustomerGauge. This is especially useful when you're using our Single Sign On, and you'd like to synchronise deactivating users in both your Identity Provider as well as CustomerGauge.
Authentication
OAuth2 Authentication is used to connect to this API. Once you've created your Connected App, you can acquire a Bearer Access Token by calling our OAuth2/Token API:
curl -X POST -H "Content-Type: application/x-www-form-urlencoded"
-d "grant_type=client_credentials&client_id={{ Client ID }}&client_secret={{ Client Secret }}"
https://auth.{{ apiRegion }}.customergauge.com/oauth2/token
The acquired Bearer Access Token is used in the Authorization header in your API request.
Endpoint
Endpoint URL
https://api.{{ apiRegion }}.customergauge.com/v5/user-manager/users/disable
Request
Body
To deactivate a user, you should pass the user's email address in JSON in the Body of the Request.
{
"email": "john.doe@example.com"
}
Response
HTTP Status Code | Description |
204 | OK - everything worked as expected. Example Response Body An empty Response Body will be returned when successful. |
401 | The Access Token obtained has expired, or is invalid. Example Response Body { |
404 | The user could not be found. Example Response Body { |
422 | An issue occurred - this usually means one of the required fields is missing. Example Response Body { |
Not the API you're looking for?
Get an overview of our APIs here.