curl -H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input":[{"category_url":"https://www.tiktok.com/browse/electronics","num_of_products":20}],"limit_per_input":null}' \
"https://api.brightdata.com/datasets/v3/scrape?dataset_id=gd_m45m1u911dsa4274pi¬ify=false&include_errors=true&type=discover_new&discover_by=category_url"
import requests
response = requests.post(
"https://api.brightdata.com/datasets/v3/scrape",
params={
"dataset_id": "gd_m45m1u911dsa4274pi",
"notify": "false",
"include_errors": "true",
"type": "discover_new",
"discover_by": "category_url",
},
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={
"input": [
{
"category_url": "https://www.tiktok.com/browse/electronics",
"num_of_products": 20,
},
],
"limit_per_input": None,
},
)
print(response.text)
const params = new URLSearchParams({
dataset_id: "gd_m45m1u911dsa4274pi",
notify: "false",
include_errors: "true",
type: "discover_new",
discover_by: "category_url",
});
const response = await fetch(`https://api.brightdata.com/datasets/v3/scrape?${params}`, {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
input: [
{
category_url: "https://www.tiktok.com/browse/electronics",
num_of_products: 20,
},
],
limit_per_input: null,
}),
});
console.log(await response.text());
[
{
"url": "https://www.tiktok.com/view/product/1730000000000000000",
"title": "Portable Bluetooth Speaker Waterproof",
"price": 19.99,
"currency": "USD",
"rating": 4.5,
"reviews_count": 870,
"seller_name": "AudioShop",
"seller_url": "https://www.tiktok.com/@audioshop",
"description": "Compact waterproof Bluetooth speaker with 12-hour battery life.",
"images": [
"https://p16-oec-ttp.tiktokcdn-us.com/example-product-1.jpeg"
],
"category": "Electronics > Audio > Speakers"
}
]
TikTok
Discover TikTok Shop products by category
Discover TikTok Shop products from a category URL with the Bright Data Scraper API. Send POST /datasets/v3/scrape with dataset_id gd_m45m1u911dsa4274pi.
POST
/
datasets
/
v3
/
scrape
curl -H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input":[{"category_url":"https://www.tiktok.com/browse/electronics","num_of_products":20}],"limit_per_input":null}' \
"https://api.brightdata.com/datasets/v3/scrape?dataset_id=gd_m45m1u911dsa4274pi¬ify=false&include_errors=true&type=discover_new&discover_by=category_url"
import requests
response = requests.post(
"https://api.brightdata.com/datasets/v3/scrape",
params={
"dataset_id": "gd_m45m1u911dsa4274pi",
"notify": "false",
"include_errors": "true",
"type": "discover_new",
"discover_by": "category_url",
},
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={
"input": [
{
"category_url": "https://www.tiktok.com/browse/electronics",
"num_of_products": 20,
},
],
"limit_per_input": None,
},
)
print(response.text)
const params = new URLSearchParams({
dataset_id: "gd_m45m1u911dsa4274pi",
notify: "false",
include_errors: "true",
type: "discover_new",
discover_by: "category_url",
});
const response = await fetch(`https://api.brightdata.com/datasets/v3/scrape?${params}`, {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
input: [
{
category_url: "https://www.tiktok.com/browse/electronics",
num_of_products: 20,
},
],
limit_per_input: null,
}),
});
console.log(await response.text());
[
{
"url": "https://www.tiktok.com/view/product/1730000000000000000",
"title": "Portable Bluetooth Speaker Waterproof",
"price": 19.99,
"currency": "USD",
"rating": 4.5,
"reviews_count": 870,
"seller_name": "AudioShop",
"seller_url": "https://www.tiktok.com/@audioshop",
"description": "Compact waterproof Bluetooth speaker with 12-hour battery life.",
"images": [
"https://p16-oec-ttp.tiktokcdn-us.com/example-product-1.jpeg"
],
"category": "Electronics > Audio > Speakers"
}
]
Query Parameters
string
default:"gd_m45m1u911dsa4274pi"
required
The dataset ID used for this request.
Must be set to
gd_m45m1u911dsa4274pi to collect Discover by Category data.string
default:"discover_new"
Must be set to
discover_new.string
default:"category_url"
Must be set to
category_url.boolean
default:false
Whether to send notifications when the request is completed.
boolean
default:true
Whether to include errors in the response.
Request Body
object[]
required
curl -H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input":[{"category_url":"https://www.tiktok.com/browse/electronics","num_of_products":20}],"limit_per_input":null}' \
"https://api.brightdata.com/datasets/v3/scrape?dataset_id=gd_m45m1u911dsa4274pi¬ify=false&include_errors=true&type=discover_new&discover_by=category_url"
import requests
response = requests.post(
"https://api.brightdata.com/datasets/v3/scrape",
params={
"dataset_id": "gd_m45m1u911dsa4274pi",
"notify": "false",
"include_errors": "true",
"type": "discover_new",
"discover_by": "category_url",
},
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={
"input": [
{
"category_url": "https://www.tiktok.com/browse/electronics",
"num_of_products": 20,
},
],
"limit_per_input": None,
},
)
print(response.text)
const params = new URLSearchParams({
dataset_id: "gd_m45m1u911dsa4274pi",
notify: "false",
include_errors: "true",
type: "discover_new",
discover_by: "category_url",
});
const response = await fetch(`https://api.brightdata.com/datasets/v3/scrape?${params}`, {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
input: [
{
category_url: "https://www.tiktok.com/browse/electronics",
num_of_products: 20,
},
],
limit_per_input: null,
}),
});
console.log(await response.text());
[
{
"url": "https://www.tiktok.com/view/product/1730000000000000000",
"title": "Portable Bluetooth Speaker Waterproof",
"price": 19.99,
"currency": "USD",
"rating": 4.5,
"reviews_count": 870,
"seller_name": "AudioShop",
"seller_url": "https://www.tiktok.com/@audioshop",
"description": "Compact waterproof Bluetooth speaker with 12-hour battery life.",
"images": [
"https://p16-oec-ttp.tiktokcdn-us.com/example-product-1.jpeg"
],
"category": "Electronics > Audio > Speakers"
}
]
Was this page helpful?