Close a target group
You hit your targeted number of respondents, let’s close your target group.
Closing a target group removes it from the Cint Exchange, preventing further responses. This guide details the two-step process to achieve this:
- Retrieve Fielding Run Status: First, retrieve the current status of your fielding run, specifically capturing its ETag from the response headers for concurrency control.
- Complete Fielding Run: Then, send a POST request to complete the fielding run, using the ETag to ensure you're acting on the most recent state.
Retrieve Fielding Run
GET /v1/demand/accounts/{account_id}/projects/{project_id}/target-groups/{target_group_id}/fielding-runs/{fielding_run_id}
Path Parameters
The following parameters must be included directly in the URL:
| Parameter | Description | Example |
|---|---|---|
account_id | Your unique account identifier (provided in your API Starter Kit). | 12345 |
project_id | Your unique project identifier. | ABC123 |
target_group_id | Your unique target group identifier. | 12345 |
fielding_run_id | Your unique fielding run identifier, different from your job_id. | 12345 |
Request Header
All requests to this endpoint require the following headers:
| Parameter | Description | Example |
|---|---|---|
Authorization | Your JSON Web Token (JWT) used for authenticating your request. This token must be prefixed with Bearer. | abcdef...123456 |
Cint-API-Version | Specifies the API version you are targeting. This helps ensure compatibility with your integration. Always use the latest stable version. | 2025-05-27 |
Example Request
The following cURL command demonstrates how to retrieve the current state of your fielding run. Remember to replace the placeholder values with your actual data.
curl \ 'https://api.cint.com/v1/demand/accounts/{account_id}/projects/{project_id}/target-groups/{target_group_id}/fielding-runs/{fielding_run_id}' \
-H 'Authorization: Bearer <YOUR_JWT_TOKEN>' \
-H 'Cint-API-Version: 2025-05-27'
Example Response
A successful response will include all the current data associated with your Fielding Run.
{
"account_id": "2428",
"project_id": "01K5058EMP52V7K3DZPK9YMB01",
"target_group_id": "01K5065XQ7G3PSD6H9WZETM5FB",
"id": "01K5065XQ7G3PSD6H9WZETM5FB",
"last_changed_at": "2025-09-13T00:13:54.266Z",
"last_changed_by": "18111163-dc18-4b84-abee-3b3141b289c0",
"status": "live",
"start_fielding_at": "2025-09-13T00:13:52.555Z",
"end_fielding_at": "2025-12-12T23:00:00.000Z",
"version": 1
}
Obtain the ETag from the response headers
Crucially, you must extract the ETag from the response headers.
The ETag is a strong validator for concurrency control, ensuring that you are modifying the most recent version of the resource.
You will need to include this ETag in the If-Match header of your Complete Fielding Run request.
Example Response Headers (showing ETag):
HTTP/1.1 200 OK
Content-Type: application/json
ETag: W/"5"
Content-Length: 200
Date: Mon, 07 Jul 2025 20:55:00 GMT
In this example, your ETag is W/"5".
Complete a Fielding Run
POST /v1/demand/accounts/{account_id}/projects/{project_id}/target-groups/{target_group_id}/fielding-runs/{fielding_run_id}/complete
Path Parameters
The following parameters must be included directly in the URL:
| Parameter | Description | Example |
|---|---|---|
account_id | Your unique account identifier (provided in your API Starter Kit) | 12345 |
project_id | Your unique project identifier. | ABC123 |
target_group_id | Your unique target group identifier | 12345 |
fielding_run_id | Your unique fielding run identifier, different from your job_id | 12345 |
Request Headers
All requests to this endpoint require the following headers:
| Parameter | Description | Example |
|---|---|---|
Authorization | Your JSON Web Token (JWT) used for authenticating your request. This token must be prefixed with Bearer. | abcdef...123456 |
Cint-API-Version | Specifies the API version you are targeting. This helps ensure compatibility with your integration. Always use the latest stable version. | 2025-05-27 |
If-Match | The ETag obtained from the response headers. Used for optimistic locking to prevent conflicting updates. | W/"2" |
Example Request
The following cURL command demonstrates how to complete your fielding run. Remember to replace the placeholder values with your actual data, and crucially, provide the ETag obtained from the previous GET request.
curl -X POST \
'https://api.cint.com/v1/demand/accounts/{ACCOUNT_ID}/projects/{project_id}/target-groups/{target_group_id}/fielding-runs/{fielding_run_id}/complete' \
-H 'Authorization: Bearer <YOUR_JWT_TOKEN>' \
-H 'Cint-API-Version: 2025-05-27' \
-H 'If-Match: W/"<YOUR_ETAG_VERSION>"'
Example Response
A successful request will return an HTTP 204 No Content response code with no response body.
Upon successful completion, your target group's status will change from Live to Completed on the Cint Exchange, and it will no longer be visible to Suppliers.
Congratulations
You have just successfully completed your first target group on the Cint Exchange!