Get internet service providers
GET/tool/targeting/list/Via 360: GET https://partner.quantri360.com/v1/tiktok_business/tool/targeting/list/
Description
Use this endpoint to get targeting tags.
You can get one single type of targeting tag that is used to target ad audiences: ISP IDs. Then to apply ISP IDs to your ads, you can pass the returned ISP IDs to isp_ids when calling /adgroup/create/, /adgroup/update/ or /ad/audience_size/estimate/.
Request
Endpoint
GET https://partner.quantri360.com/v1/tiktok_business/tool/targeting/list/
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 |
|---|---|---|---|---|---|
| location_ids | query | string[] | Yes | IDs of the locations that you want to get the supported ISP IDs for.
Max size: 1000.
To find out the list of location IDs, see Location IDs.
Note: You need to pass location IDs at the country or region level. To get the available locations and corresponding IDs based on your placement and objective, use the /tool/region/ and the returned level for location IDs at the country or region level will be COUNTRY. | |
| scene | query | string | Yes | The targeting type that the targeting tags are used for.
The allowed enum values: ISP ( Internet Service Provider targeting). |
Request examples
curl -s "https://partner.quantri360.com/v1/tiktok_business/tool/targeting/list/?location_ids=%5B%5D&scene=" \ -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/tool/targeting/list/",
params={
"location_ids": [],
"scene": ""
},
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/tool/targeting/list/');
for (const [k, v] of Object.entries({"location_ids":[],"scene":""})) 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/tool/targeting/list/' . '?' . http_build_query(['location_ids' => '[]', 'scene' => '']); $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 | Response code. For the complete list of response codes and descriptions, see Appendix-Return Code. | |
| message | string | Response message. For details, see Appendix - Return Codes. | |
| request_id | string | The log ID of a request, which uniquely identifies the request. | |
| data | object | Returned data. | |
| targeting_tag_list | object[] | Information about the targeting tags. | |
| targeting_type | string | The targeting type that the targeting tag is used for. Enum values: `ISP` ( Internet Service Provider targeting). | |
| name | string | The name of the targeting tag. | |
| status_info | object | Information about the status of the targeting tag. | |
| status | string | The status of the targeting tag. Enum values: `ENABLED` (can be used for targeting), `DISABLED`(cannot be used for targeting). | |
| reason | string | The reason why the targeting tag cannot be used for targeting. Returned when `status` = `DISABLED`. Enum values: - `OFFLINE`: The targeting tag is offline. - `NOT_SUPPORTED`: The targeting tag is not offline but is not supported for the specified settings. | |
| isp | object | Information about the targeting tag that is used for Internet service provider targeting. | |
| isp_id | string | The ID of the Internet service provider that you can target. | |
| location_id | string | The location ID that the `isp_id` can be used together with. Only location IDs at the country or region level are supported. | |
| region_code | string | The code of the region or country that the `isp_id` belongs to. | |
| geo | object | Information about the targeting tag that is used for location targeting. | |
| parent_tags | object[] | Information about all the parent targeting tags. |
Response sample
HTTPS/1.1 200 OK
{
"code": 0,
"message": "OK",
"request_id": "{{request_id}}",
"data": {
"parent_tags": [],
"targeting_tag_list": [
{
"name": "Etisalat Misr",
"targeting_type": "ISP",
"geo": null,
"status_info": {
"status": "ENABLED",
"reason": null
},
"isp": {
"isp_id": "EG00045",
"location_id": "357994",
"region_code": "EG"
}
},
{
"name": "Orange Egypt",
"targeting_type": "ISP",
"geo": null,
"status_info": {
"status": "ENABLED",
"reason": null
},
"isp": {
"isp_id": "EG00081",
"location_id": "357994",
"region_code": "EG"
}
},
{
"name": "Telecom Egypt",
"targeting_type": "ISP",
"geo": null,
"status_info": {
"status": "ENABLED",
"reason": null
},
"isp": {
"isp_id": "EG00098",
"location_id": "357994",
"region_code": "EG"
}
},
{
"name": "Vodafone Egypt",
"targeting_type": "ISP",
"geo": null,
"status_info": {
"status": "ENABLED",
"reason": null
},
"isp": {
"isp_id": "EG00105",
"location_id": "357994",
"region_code": "EG"
}
},
{
"name": "other",
"targeting_type": "ISP",
"geo": null,
"status_info": {
"status": "ENABLED",
"reason": null
},
"isp": {
"isp_id": "EG0",
"location_id": "357994",
"region_code": "EG"
}
}
]
}
}
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