To get details about a collection of events, make a GET call to the /events endpoint.
Parameters
Include one or more of the following optional URL query parameters to filter which event details to return.
-
event_status(string, optional): Filter by event status. Acceptable values includeACTIVE,DRAFT,COMPLETE,DELETED,CANCELED, andERROR. For example:ACTIVE. -
search_text(string, optional): Filter by name or description to return events that include a specified text string. For example:Reunion. -
sort_by(string, optional): Sort event results returned byname,start_time,end_time,created_time, orupdated_time. For example:name. -
sort_order(string, optional): Sort order for thesort_by parameter. Accepted values includeASC(ascending) orDESC(descending). Defaults toASCifsort_byis provided. -
limit(integer, optional): Limit the number of results to return per page. Default and maximum is100. Example:10. -
prev(string, optional): Cursor for retrieving the previous page of results. This value is obtained from theprev_cursorfield in a previous response. For example:prev=7zDEe3DhD5gUiwRFsvWKKZlZO1j6-YihH2hyVWD8GaW7JnzXbHFP8Tou212KoU20mOjvM6pdWwycDWC3X-Hb_xY-RK1eBwYp_pc4X2CvLxo. -
next(string, optional): Cursor for retrieving the next page of results. This value is obtained from thenext_cursorfield in a previous response. For example:next=7zDEe3DhD5gUiwRFsvWKKZlZO1j6-YihH2hyVWD8GaW7JnzXbHFP8Tou212KoU20mOjvM6pdWwycDWC3X-Hb_xY-RK1eBwYp_pc4X2CvLxo.
Example Request
The following example requests include the following parameters:
limit: Return2results per page.sort_by: sort results byname.sort_order: sort results inASCorder.
GET https://api.cc.email/v3/events
Endpoint Requirements
User privileges: campaigns:read
Authorization scopes: campaigns_data
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://api.cc.email/v3/events?limit=3&sort_by=name&sort_order=DESC',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'Content-Type: application/json',
'Authorization: ••••••'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
curl --location 'https://api.cc.email/v3/events?limit=3&sort_by=name&sort_order=DESC' \
--header 'Content-Type: application/json' \
--header 'Authorization: ••••••'
OkHttpClient client = new OkHttpClient().newBuilder().build();
Request request = new Request.Builder()
.url("https://api.cc.email/v3/events?limit=3&sort_by=name&sort_order=DESC")
.get() // Use .get() method for GET requests, no body needed
.addHeader("Content-Type", "application/json")
.addHeader("Authorization", "••••••")
.build();
Response response = client.newCall(request).execute();
Example Response
This account has a total of 394 event records. Because the limit query parameter was set to 2, only two event results are returned per page. To view the next page of results, use the href link under next.
{
"records": [
{
"event_id": "03349854-da80-4189-8a70-249a034fe006",
"title": " 2023-04-04T16:17:44.318Z",
"start_time": "2026-04-20T15:00:00Z",
"end_time": "2026-04-20T15:00:00Z",
"status": "DRAFT",
"registration_url": "https://example_url.com/ev/reg/j49ymv8",
"name": " 2024-04-04T16:17:44.318Z",
"event_type": "CLASSES_WORKSHOPS",
"location_type": "VIRTUAL",
"time_zone_type": "GMTN0500_B",
"create_time": "2023-04-04T16:17:44.155Z"
},
{
"event_id": "c09602f2-5803-4cba-a86f-95977ae16212",
"title": " 2024-03-03T13:26:32.511Z",
"start_time": "2023-04-20T15:00:00Z",
"end_time": "2023-04-20T15:00:00Z",
"status": "COMPLETE",
"registration_url": "https://example_url.com/ev/reg/u6yhyv5",
"name": " 2023-04-03T13:26:32.511Z",
"event_type": "CLASSES_WORKSHOPS",
"location_type": "VIRTUAL",
"time_zone_type": "GMTN0500_B",
"create_time": "2023-04-03T13:26:32.298Z"
}
],
"next_cursor": null,
"prev_cursor": null,
"_links": {
"self": {
"href": "api.cc.email/v3/events?limit=3&sort_by=name&sort_order=DESC"
},
"next": {
"href": "api.cc.email/v3/events?limit=3&sort_by=name&sort_order=DESC&next=7zDEe3DhD5gUiwRFsvWKKZlZO1j6-YihH2hyVWD8GaW7JnzXbHFP8Tou212KoU20mOjvM6pdWwycDWC3X-Hb_xY-RK1eBwYp_qc4X2CvLJo"
}
},
"total_records": 394
}
Learn more about event schema: Event schema