Get report on clicks

  • Updated

You can get the report on clicks that users made after they followed tracking links on your platform. This endpoint returns the list of click items, where each item contains information about clicks retrieved according to the specified parameters.

You can get the detailed report for the specified platform or for all platforms in your account.

You can test this API endpoint and inspect the possible responses using Swagger UI or Postman collection.

Request

URL: https://api.takeads.com/v2/api/stats/click

Method: GET

Request headers

Header Value Description
Authorization Bearer <Public Key>

String of alphanumeric characters with Bearer as prefix, used to authenticate and authorize your API requests.

To learn how to get your Public key, refer to the Authorization article.

Query parameters

You can use query parameters to get specific reports on clicks. Use offset and limit parameters to paginate the response.

This endpoint has no required parameters.

  • To get information about clicks performed within a certain period, use the dateFrom and dateTo parameters. 
    • The period cannot exceed 120 days. 
  • To get information about click items whose data was updated within a certain period, use the updatedAtFrom and updatedAtTo parameters. 
    • If you specify the updatedAtFrom and updatedAtTo pair only, click items are not filtered by calendar date.
  • Both parameters of a pair must be specified together. If you specify only one parameter, e.g. dateFrom, the 400 error is returned. You can use both pairs in one request.
  • If you don't specify any of these parameters, data for the current calendar day (UTC) is returned.

The following table describes query parameters that you can use in the request.

Property Type Description
dateFrom (optional) string

Starting point of the reporting period, in the YYYY-MM-DD format. This parameter can't be used without the ending point of the reporting period — dateTo.

Example: 2026-09-07

dateTo (optional) string

Ending point of the reporting period, in the YYYY-MM-DD format. This parameter can't be used without the starting point of the reporting period — dateFrom.

Example: 2026-09-07

updatedAtFrom (optional) string

Starting point of the period when information about clicks was last updated, in the ISO 8601 date-time format. This parameter can't be used without the ending point of this period — updatedAtTo.

Example: 2026-09-10T16:10:57.000Z

updatedAtTo (optional) string

Ending point of the period when information about clicks was last updated, in the ISO 8601 date-time format. This parameter can't be used without the starting point of this period — updatedAtFrom.

Example: 2026-09-10T16:33:57.000Z

merchantId (optional) string

Unique identifier of the merchant. 0 when the merchant cannot be resolved.

Example: 110621

subId (optional) string

SubID of the deeplink you want to get the report for.

Example: abc_123-2

adspaceId (optional) string

ID (UUIDv4) of the platform you want to get the report for.

Example: 603f4ef6-ec4f-4f34-827c-9a66ca6920a4

offset (optional) integer If specified, the list of clicks starting with the offset value is retrieved. The first N clicks are excluded from the response (N = offset value). The default value is 0.
limit (optional) integer The maximum number of clicks that may be returned for a single request. The default value is 500. The maximum value is 500.

Request examples

Filtering by click day

curl --request GET \
  --url 'https://api.takeads.com/v2/api/stats/click?dateFrom=2026-09-01&dateTo=2026-09-07&limit=100&offset=500' \
  --header 'Authorization: Bearer <Public Key>' \
  --header 'Content-Type: application/json'

Filtering by last update time

curl --request GET \
  --url 'https://api.takeads.com/v2/api/stats/click?updatedAtFrom=2026-09-10T16:10:57.000Z&updatedAtTo=2026-09-10T16:33:57.000Z&limit=100&offset=0' \
  --header 'Authorization: Bearer <Public Key>' \
  --header 'Content-Type: application/json'

Filtering by merchant

curl --request GET \
  --url 'https://api.takeads.com/v2/api/stats/click?merchantId=110621&dateFrom=2026-09-01&dateTo=2026-09-07&limit=100&offset=0' \
  --header 'Authorization: Bearer <Public Key>' \
  --header 'Content-Type: application/json'

 

JavaScript
fetch("https://api.takeads.com/v2/api/stats/click?dateFrom=2026-09-01&dateTo=2026-09-04&limit=100&offset=500", {
  "method": "GET",
  "headers": {
    "Authorization": "Bearer <Public Key>",
    "Content-Type": "application/json"
  }
})
.then(response => {
  console.log(response);
})
.catch(err => {
  console.error(err);
});
php
<?php
$curl = curl_init();
curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.takeads.com/v2/api/stats/click?dateFrom=2026-09-01&dateTo=2026-09-07&limit=100&offset=500",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_POSTFIELDS => "",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer <Public Key>",
    "Content-Type: application/json"
  ],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
Python
import http.client

conn = http.client.HTTPSConnection("api.takeads.com")

payload = ""

headers = {
    'Authorization': "Bearer <Public Key>",
    'Content-Type': "application/json"
}

conn.request("GET", "/v2/api/stats/click?dateFrom=2026-09-01&dateTo=2026-09-07&limit=100&offset=500", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))

Response

If the request was successfully processed by the server, an HTTP response with 200 status code and the list of available click items is returned.

The returned click items are sorted by the updatedAt value in descending order. If the updatedAt value is the same for a number of items, they are sorted by their ids in ascending order.

The response payload is a JSON object that contains a meta object with metadata and a data array with the retrieved click items. Each item of the array is an object with the details about the clicks retrieved according to the request.

The following table describes the response properties.

Property Type Description
offset integer If specified, the list of click items starting with the offset value is retrieved. The first N click items are excluded from the response (N = offset value). The default value is 0.
limit integer The maximum number of click items that may be returned for a single request. The default value is 500. The maximum value is 500.
total integer Total number of click items corresponding to the specified parameters.
id string Click item ID in the UUID format.
adspaceId string ID (UUIDv4) of the platform you received the report for.
adspaceName string Name of the platform.
couponId string / null ID of the coupon you received the report for. null for merchant-only clicks. 
merchantId number Unique identifier of the merchant. 0 if the merchant can't be identified.
merchantName string Name of the merchant. Empty string if the merchant can't be identified.
subId string / null SubID of the deeplink you received the report for.
date string

Date when clicks in the click item were performed.

Example: 2026-09-07

count number Number of clicks in the click item.
updatedAt string

Timestamp (ISO 8601) when information about clicks in the click item was last updated in the statistics. 

Example: 2026-09-07T19:53:15.816Z

Example value

{
  "meta": {
    "limit": 100,
    "offset": 0,
    "total": 1
  },
  "data": [
    {
      "id": "c012be0e-8d12-a857-b47c-02a86e2ee6d5",
      "adspaceId": "4b782606-a17f-427f-9acb-e42ba1397713",
      "adspaceName": "My Adspace",
      "couponId": null,
      "merchantId": 110621,
      "merchantName": "Aliexpress",
      "subId": "abc_123-2",
      "date": "2026-09-07",
      "count": 100,
      "updatedAt": "2026-09-07T19:53:15.816Z"
    }
  ]
}

 

To view possible error responses, refer to the Error responses article.

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request