TikTok Shop カテゴリ分析
TikTok Shop カテゴリ分析 API でEC データ API の連携を行えます。リクエストパラメーター、レスポンスのフィールド、実行可能なコード例を確認してください。
API データの例
このエンドポイントのリクエスト本文とレスポンス全体の構造を確認できます。
{
"marketplace": "US",
"minMonthlyUnits": 100000
}{
"request_id": "48dc860c-3a9f-5bfc-b6b8-4cab0b92768f",
"data": [
{
"name": "Vitamins, Minerals & Wellness Supplements",
"node_id": "700650",
"photo": null,
"monthly_sale_count": 1602852,
"monthly_sale_count_mom": -10.16,
"monthly_sale_amount": 58745904.27,
"monthly_sale_amount_mom": 14.37,
"cumulative_sale_count": 42499128,
"weekly_sale_count": 343420,
"weekly_sale_count_mom": 28.19,
"weekly_sale_amount": 13150573.33,
"weekly_sale_amount_mom": 44.21,
"avg_price": 39.88,
"avg_price_mom": -0.29,
"avg_review_count": 10954,
"avg_star": 4.49,
"shop_count": 152,
"top10_product_monthly_sale_count_share": 20.22,
"top10_seller_monthly_sale_count_share": 42.93,
"top10_product_weekly_sale_count_share": 20.26,
"top10_seller_weekly_sale_count_share": 43.53,
"new_product_count": 3,
"new_product_monthly_sale_count": 5858,
"new_product_monthly_sale_amount": 185483.02,
"new_product_monthly_sale_count_share": 0.37,
"new_produc_avg_star": 4.37,
"new_product_avg_review_count": 276,
"new_product_weekly_sale_count": 161,
"new_product_weekly_sale_amount": 6277.39,
"avg_variation_count": 4
},
{
"name": "Bras",
"node_id": "601262",
"photo": null,
"monthly_sale_count": 737744,
"monthly_sale_count_mom": -8.55,
"monthly_sale_amount": 21327442.48,
"monthly_sale_amount_mom": -3.11,
"cumulative_sale_count": 14185095,
"weekly_sale_count": 154557,
"weekly_sale_count_mom": 44.64,
"weekly_sale_amount": 4519666.31,
"weekly_sale_amount_mom": 37.11,
"avg_price": 29.98,
"avg_price_mom": 1.67,
"avg_review_count": 4403,
"avg_star": 4.28,
"shop_count": 101,
"top10_product_monthly_sale_count_share": 28.62,
"top10_seller_monthly_sale_count_share": 63.26,
"top10_product_weekly_sale_count_share": 32.19,
"top10_seller_weekly_sale_count_share": 66.47,
"new_product_count": 5,
"new_product_monthly_sale_count": 9967,
"new_product_monthly_sale_amount": 342096.31,
"new_product_monthly_sale_count_share": 1.35,
"new_produc_avg_star": 3.5,
"new_product_avg_review_count": 172,
"new_product_weekly_sale_count": 2584,
"new_product_weekly_sale_amount": 89413.16,
"avg_variation_count": 129
}
]
}このページでは Ecommerce Data API の公開契約を説明します。フィールド名、パス、技術例はそのまま保持しているため、そのまま統合できます。
Availability: Available
This endpoint is active in the v1 gateway, OpenAPI, and subscription catalog. Each call consumes 1 billing unit, including calls that find nothing (
RESULT_NOT_FOUND).
POST /v1/tiktok/shop/categories/research
The request and response fields below match the current public contract.
API マッピング
| Item | Value |
|---|---|
| MCP Code | tiktok_shop_categories_research |
クイック呼び出し
First create an API key, then store it in a server-side environment variable:
export ECOMMERCE_DATA_API_KEY="your_api_key"curl --request POST \
--url https://ecommercedataapi.com/v1/tiktok/shop/categories/research \
--header "Content-Type: application/json" \
--header "X-API-Key: ${ECOMMERCE_DATA_API_KEY}" \
--data '{
"marketplace": "US",
"minMonthlyUnits": 100000
}'Integrate with an AI CLI
Copy for your AI CLI
Paste this task into Codex, Claude Code, Gemini CLI, or another coding agent.
Integrate the "TikTok Shop Category Research" endpoint from Ecommerce Data API into the current repository. Make the changes directly instead of only returning sample code.
API documentation: https://ecommercedataapi.com/ja/docs/tiktok/shop/category-research
Endpoint: POST https://ecommercedataapi.com/v1/tiktok/shop/categories/research
API key environment variable: ECOMMERCE_DATA_API_KEY
Example request:
{
"marketplace": "US",
"minMonthlyUnits": 100000
}
Requirements:
1. Read the API documentation first, then inspect the repository's language, framework, HTTP client, directory structure, and environment-variable conventions.
2. Reuse the existing API client and error-handling patterns. If none exist, add the smallest reusable Ecommerce Data API client and an endpoint-specific wrapper.
3. Read the key from the server-side ECOMMERCE_DATA_API_KEY environment variable and send Content-Type: application/json plus the X-API-Key header. Never write a real key into source code, browser code, logs, test snapshots, or Git.
4. If the environment variable is missing, tell me to configure ECOMMERCE_DATA_API_KEY myself. Do not request, print, or invent the real key, and continue implementing code and tests that do not require a live request.
5. Implement request and response types from the documentation. Handle non-2xx responses, request_id, error.code, error.message, and 429 rate limits.
6. Add a minimal usage example or test that follows the repository's conventions. Run one minimal live request only when the key is already configured and external requests are allowed; otherwise use mocks or static validation.
7. Run the relevant formatter, type checker, and tests. Report changed files, usage, verification results, and any environment variable I still need to configure.Open this request in Postman
Download the preconfigured collection for this endpoint, then import it into Postman.
Node.js example
const response = await fetch(
'https://ecommercedataapi.com/v1/tiktok/shop/categories/research',
{
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': process.env.ECOMMERCE_DATA_API_KEY,
},
body: JSON.stringify({
marketplace: 'US',
minMonthlyUnits: 100000,
}),
}
);
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error?.code}: ${result.error?.message}`);
}
console.log(result.data);Python example
import os
import requests
response = requests.post(
"https://ecommercedataapi.com/v1/tiktok/shop/categories/research",
headers={
"Content-Type": "application/json",
"X-API-Key": os.environ["ECOMMERCE_DATA_API_KEY"],
},
json={
"marketplace": "US",
"minMonthlyUnits": 100000,
},
timeout=30,
)
response.raise_for_status()
print(response.json()["data"])Request body
Send the fields below directly in the JSON body without an extra wrapper. Undefined fields are rejected.
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
marketplace | String | No | Marketplace code. Supported values are listed in the schema. Available values (Table 1.2): US, JP, UK, DE, FR, IT, ES, CA, IN, MX, BR, AU, AE | US |
categoryId | String | No | Category ID, from the category search or tree of the same platform. | 601925 |
minMonthlyUnits | Integer | No | Lower bound of monthly units sold. | 100 |
maxMonthlyUnits | Integer | No | Upper bound of monthly units sold. | 100 |
minMonthlyRevenue | Number | No | Lower bound of monthly revenue, in the marketplace currency. | 20 |
maxMonthlyRevenue | Number | No | Upper bound of monthly revenue, in the marketplace currency. | 20 |
minAvgPrice | Number | No | Lower bound of average price. | 20 |
maxAvgPrice | Number | No | Upper bound of average price. | 20 |
minAvgRating | Number | No | Lower bound of average star rating, 0–5. | 4 |
maxAvgRating | Number | No | Upper bound of average star rating, 0–5. | 4 |
minAvgReviews | Integer | No | Lower bound of average review count. | 100 |
maxAvgReviews | Integer | No | Upper bound of average review count. | 100 |
minShops | Integer | No | Lower bound of shops behind the top 300 products. | 100 |
maxShops | Integer | No | Upper bound of shops behind the top 300 products. | 100 |
minTop10ProductShare | Number | No | Lower bound of top-10 products’ share of monthly units, in %. | 30 |
maxTop10ProductShare | Number | No | Upper bound of top-10 products’ share of monthly units, in %. | 30 |
minTop10SellerShare | Number | No | Lower bound of top-10 sellers’ share of monthly units, in %. | 30 |
maxTop10SellerShare | Number | No | Upper bound of top-10 sellers’ share of monthly units, in %. | 30 |
minNewProducts | Integer | No | Lower bound of products listed in the last 3 months. | 100 |
maxNewProducts | Integer | No | Upper bound of products listed in the last 3 months. | 100 |
minNewProductSalesShare | Number | No | Lower bound of those new products’ share of monthly units, in %. | 30 |
maxNewProductSalesShare | Number | No | Upper bound of those new products’ share of monthly units, in %. | 30 |
page | Integer | No | Page number. | 1 |
Response structure
| Field | Type | Description |
|---|---|---|
request_id | String | Unique identifier for this request. |
data | Array | Endpoint business data. |
The fields below are inside data. For array endpoints they describe one array item; for paginated endpoints they describe one record in items[].
Response fields
| Field | Type | Description | Example |
|---|---|---|---|
name | String | Category name. | Vitamins, Minerals & Wellness Supplements |
node_id | String | Category ID. | 700650 |
monthly_sale_count | Integer | Monthly sales count of the category's Top-300 products. | 1602852 |
monthly_sale_count_mom | Number | Month-over-month growth of monthly sales count (%); negative means declining. | -10.16 |
monthly_sale_amount | Number | Monthly sales amount of the Top-300 products, in the marketplace's local currency. | 58745904.27 |
monthly_sale_amount_mom | Number | Month-over-month growth of monthly sales amount (%); negative means declining. | 14.37 |
cumulative_sale_count | Integer | Cumulative sales count of the Top-300 products. | 42499128 |
weekly_sale_count | Integer | Weekly sales count. | 343420 |
weekly_sale_count_mom | Number | Week-over-week growth of weekly sales count (%); negative means declining. | 28.19 |
weekly_sale_amount | Number | Weekly sales amount, in the marketplace's local currency. | 13150573.33 |
weekly_sale_amount_mom | Number | Week-over-week growth of weekly sales amount (%); negative means declining. | 44.21 |
avg_price | Number | Average selling price, in the marketplace's local currency. | 39.88 |
avg_price_mom | Number | Month-over-month growth of the average price (%); negative means declining. | -0.29 |
avg_review_count | Integer | Average review count. | 10954 |
avg_star | Number | Average star rating. | 4.49 |
shop_count | Integer | Number of shops the Top-300 products come from; fewer means stronger shop concentration. | 152 |
top10_product_monthly_sale_count_share | Number | Share of monthly sales (%) held by the top 10 products; larger means stronger product concentration. | 20.22 |
top10_seller_monthly_sale_count_share | Number | Share of monthly sales (%) held by the top 10 sellers; larger means stronger seller concentration. | 42.93 |
top10_product_weekly_sale_count_share | Number | Share of weekly sales (%) held by the top 10 products. | 20.26 |
top10_seller_weekly_sale_count_share | Number | Share of weekly sales (%) held by the top 10 sellers. | 43.53 |
new_product_count | Integer | Count of new products listed within 3 months. | 3 |
new_product_monthly_sale_count | Integer | Monthly sales count of new products listed within 3 months. | 5858 |
new_product_monthly_sale_amount | Number | Monthly sales amount of new products listed within 3 months, in the marketplace's local currency. | 185483.02 |
new_product_monthly_sale_count_share | Number | Share (%) of the category's Top-300 monthly sales contributed by new products listed within 3 months. | 0.37 |
new_produc_avg_star | Number | Average star rating of new products listed within 3 months (the field name keeps its legacy spelling). | 4.37 |
new_product_avg_review_count | Integer | Average review count of new products listed within 3 months. | 276 |
new_product_weekly_sale_count | Integer | Weekly sales count of new products listed within 3 months. | 161 |
new_product_weekly_sale_amount | Number | Weekly sales amount of new products listed within 3 months, in the marketplace's local currency. | 6277.39 |
avg_variation_count | Integer | Average number of variations. | 4 |
Response example
{
"request_id": "48dc860c-3a9f-5bfc-b6b8-4cab0b92768f",
"data": [
{
"name": "Vitamins, Minerals & Wellness Supplements",
"node_id": "700650",
"photo": null,
"monthly_sale_count": 1602852,
"monthly_sale_count_mom": -10.16,
"monthly_sale_amount": 58745904.27,
"monthly_sale_amount_mom": 14.37,
"cumulative_sale_count": 42499128,
"weekly_sale_count": 343420,
"weekly_sale_count_mom": 28.19,
"weekly_sale_amount": 13150573.33,
"weekly_sale_amount_mom": 44.21,
"avg_price": 39.88,
"avg_price_mom": -0.29,
"avg_review_count": 10954,
"avg_star": 4.49,
"shop_count": 152,
"top10_product_monthly_sale_count_share": 20.22,
"top10_seller_monthly_sale_count_share": 42.93,
"top10_product_weekly_sale_count_share": 20.26,
"top10_seller_weekly_sale_count_share": 43.53,
"new_product_count": 3,
"new_product_monthly_sale_count": 5858,
"new_product_monthly_sale_amount": 185483.02,
"new_product_monthly_sale_count_share": 0.37,
"new_produc_avg_star": 4.37,
"new_product_avg_review_count": 276,
"new_product_weekly_sale_count": 161,
"new_product_weekly_sale_amount": 6277.39,
"avg_variation_count": 4
},
{
"name": "Bras",
"node_id": "601262",
"photo": null,
"monthly_sale_count": 737744,
"monthly_sale_count_mom": -8.55,
"monthly_sale_amount": 21327442.48,
"monthly_sale_amount_mom": -3.11,
"cumulative_sale_count": 14185095,
"weekly_sale_count": 154557,
"weekly_sale_count_mom": 44.64,
"weekly_sale_amount": 4519666.31,
"weekly_sale_amount_mom": 37.11,
"avg_price": 29.98,
"avg_price_mom": 1.67,
"avg_review_count": 4403,
"avg_star": 4.28,
"shop_count": 101,
"top10_product_monthly_sale_count_share": 28.62,
"top10_seller_monthly_sale_count_share": 63.26,
"top10_product_weekly_sale_count_share": 32.19,
"top10_seller_weekly_sale_count_share": 66.47,
"new_product_count": 5,
"new_product_monthly_sale_count": 9967,
"new_product_monthly_sale_amount": 342096.31,
"new_product_monthly_sale_count_share": 1.35,
"new_produc_avg_star": 3.5,
"new_product_avg_review_count": 172,
"new_product_weekly_sale_count": 2584,
"new_product_weekly_sale_amount": 89413.16,
"avg_variation_count": 129
}
]
}See Errors and rate limits for error payloads, request tracing, and rate-limit headers.