TABLE OF CONTENTS
- API Setup
- Business Use Case
- Good to Know
- Authentication
- Endpoint
- Request
- Response
- Not the API you're looking for?
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
The GET Close the Loop API is used to retrieve the latest status of Close the Loop records updated within a specific date range.
Good to Know
- The “time_to_follow_up” and “time_to_close” data points in the Response Body represent full hours.
- The API returns “cases”. Survey Responses do not necessarily create a case; a status change, close the loop comment or assignment needs to have been done for a case to be created in CustomerGauge.
Authentication
OAuth2 Authentication is used to connect to this API. In order to create the Connected App, which is needed to generate the Access Token, Administrator access to CustomerGauge is needed. 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.
Note: The Access Token is only valid for up to 1 hour. Save the Access Token temporarily when calling the API multiple times in a row, or obtain a fresh Access Token before calling the API.
Endpoint
Endpoint URL
https://api.{{ apiRegion }}.customergauge.com/v7/rest/sync/close-loop
Request
Parameters
Key | Description | Rules | Example |
---|---|---|---|
per_page | Defines the amount of records returned per page. | Number from 1 to 1000. | per_page=100 |
cursor | Parameter value returned from the API to navigate pages. The cursor is an integer. | Value is returned from the API. | cursor=123 |
updated_at[start] | The start date of the date range to select the close the loop data set | YYYY-mm-dd | updated_at[start]=2022-07-17 |
updated_at[end] | The end date of the date range to select the close the loop data set | YYYY-mm-dd | updated_at[end]=2022-07-25 |
All parameters are optional.
Example Request
https://api.{{ apiRegion }}.customergauge.com/v7/rest/sync/close-loop?per_page=25
Response
HTTP Status Code | Description |
200 | OK - everything worked as expected. Example Response Body { |
401 | The Access Token obtained has expired, or is invalid. Call the Authenticate API again to obtain a new Access Token. Example Response Body { |
Not the API you're looking for?
Get an overview of our APIs here.