Get estimated info of R&F ad groups
GET/adgroup/rf/estimated/info/Via 360: GET https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/
Description
Use this endpoint to query the estimated daily cost and frequency distribution. If the adgroup does not have a valid estimate, no corresponding record will be returned.
Request
Endpoint
GET https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/
Authentication & shop
| Name | In | Type | Sample | Description |
|---|---|---|---|---|
| Authorization | header | header | Bearer q360_live_ab12cd34_… | Khóa API của brand (tạo ở mục API key). Bắt buộc với mọi request. Brand suy từ key — không truyền mã brand. |
| platform_shop_id | query | string | 7000000000000000001 | Tài sản TikTok Business đã kết nối — "Mã tài sản" ở trang Nền tảng hoặc GET /v1/platforms (tài khoản quảng cáo cho Marketing API, tài khoản TikTok cho Organic / Messaging). Có thể bỏ khi chỉ kết nối một tài sản. |
Request parameters
| Name | In | Type | Required | Sample | Description |
|---|---|---|---|---|---|
| adgroup_ids | query | string[] | Yes | Ad group ids |
Request examples
curl -s "https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/?adgroup_ids=%5B%5D" \ -H "Authorization: Bearer $KEY"
Python
import requests
KEY = "q360_live_..." # khóa API của brand
r = requests.get(
"https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/",
params={
"adgroup_ids": []
},
headers={"Authorization": f"Bearer {KEY}"},
timeout=60,
)
print(r.status_code)
print(r.json())Node.js
const KEY = 'q360_live_...'; // khóa API của brand
const url = new URL('https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/');
for (const [k, v] of Object.entries({"adgroup_ids":[]})) url.searchParams.set(k, typeof v === 'object' ? JSON.stringify(v) : String(v));
const r = await fetch(url, {
method: 'GET',
headers: { Authorization: `Bearer ${KEY}` },
});
console.log(r.status, await r.json());PHP
<?php $key = 'q360_live_...'; // khóa API của brand $url = 'https://partner.quantri360.com/v1/tiktok_business/adgroup/rf/estimated/info/' . '?' . http_build_query(['adgroup_ids' => '[]']); $ch = curl_init($url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: Bearer ' . $key]); $res = curl_exec($ch); $status = curl_getinfo($ch, CURLINFO_HTTP_CODE); curl_close($ch); echo $status, "\n", $res;
Response
Response fields (as returned by TikTok Business)
| Name | Type | Sample | Description |
|---|---|---|---|
| code | number | Return code. For the complete list of response codes and descriptions, see Appendix - Return Codes. | |
| message | string | Return messages. For details, see Appendix - Return Codes. | |
| request_id | string | The log id of a request, which uniquely identifies the request. | |
| data | object | Returned data. | |
| estimated_info | object[] | Estimated information. | |
| adgroup_id | string | Ad group ID. | |
| base_info | object | Basic information. | |
| budget | float | Total budget. | |
| cpm | float | Cost per mille. | |
| impression | number | Total impressions, in the unit of 1,000. | |
| reach | number | Number of people reached, in the unit of 1,000. | |
| average_frequency | float | impressions per capita = total impression/ number of people reached. | |
| daily_cost | object | Daily cost. | |
| cost | float | Cost for the day. | |
| date | string | Date. | |
| frequency_per_person | object | Distribution of impressions per capita. | |
| frequency | number | Impressions per capita. | |
| percentage | float | Percentage of current impressions to total impressions. |
Response sample
HTTPS/1.1 200 OK
{
"message": "OK",
"code": 0,
"data": {
"estimated_info": [
{
"adgroup_id": 123,
"daily_cost": [
{
"date": "2020-08-07",
"cost": 3587.5169107559
},
{
"date": "2020-08-08",
"cost": 3565.1767601342
}
],
"frequency_per_person": [
{
"percentage": 0.28,
"frequency": 1
},
{
"percentage": 0.72,
"frequency": 2
}
]
}
]
}
"request_id": "8ED342"
}
(/code);
Get started
- Sign up for Partner
- Enable a data type of the Ads (Marketing API) group on the platform page
- Create an API key (tick the TikTok Business channel)
- Call it as in the examples above