tiktok.product.202309.global_products
POST/product/202309/global_productsVia 360: POST https://partner.quantri360.com/v1/tiktok/product/202309/global_products
Write endpoint — changes data on TikTok Shop. The key must be created with "Allow write API calls" ticked, otherwise you get 403 write_not_allowed. Every call is logged.
Description
CHỈ NGƯỜI BÁN TOÀN CẦU: Tạo sản phẩm toàn cầu để bán ở một hoặc nhiều gian hàng ngoài quốc gia gốc; chỉ dùng ngành hàng AVAILABLE.
- Gọi qua /v1/tiktok/product/202309/global_products với Authorization: Bearer <key>; dùng platform_shop_id khi có nhiều shop. 360 tự gắn app_key, shop_cipher, sign và access_token.
- API GHI: thay đổi dữ liệu thật trên TikTok Shop; cần key có quyền ghi (can_write) và gói mở module products. Tạo sản phẩm toàn cầu.
- HTTP 200 vẫn có thể có lỗi nghiệp vụ; kiểm code trước khi dùng kết quả.
- API hàng toàn cầu; gian hàng thường bị từ chối với mã 12052910 / 12052032.
Request
Endpoint
POST https://partner.quantri360.com/v1/tiktok/product/202309/global_products
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 | 100001 | Gian hàng (lấy ở GET /v1/platforms → shops[].platform_shop_id). BẮT BUỘC khi brand có > 1 gian hàng trên nền tảng; 360 bỏ tham số này trước khi chuyển tiếp. |
Request parameters
| Name | In | Type | Required | Sample | Description |
|---|---|---|---|---|---|
| title | body | string | Yes | Áo thun cotton cổ tròn minh họa | Tiêu đề sản phẩm; DE, ES, FR, IE, IT, JP, UK, US dài 1–255 ký tự; MX dài 1–300; khu vực khác 25–255 ký tự. |
| description | body | string | Yes | <p>Sản phẩm minh họa.</p> | Mô tả HTML tối đa 10.000 ký tự. Tối đa 30 thẻ img, mỗi ảnh dưới 4000 px, có src, width, height; ảnh phải được tải lên trước. Một số thẻ được chuyển đổi để hiển thị, như table thành ảnh. Nên mô tả trên 300 ký tự và 3–5 điểm nổi bật, mỗi điểm dưới 250 ký tự; ảnh khuyến nghị 1600×1600 px; độ dài tối đa: 10,000. |
| category_id | body | string | Yes | 900000000000000001 | Mã ngành hàng lá. |
| brand_id | body | string | No | 900000000000000001 | Mã thương hiệu. |
| main_images | body | object[] | Yes | [{"uri": "anh-minh-hoa"}] | Ảnh chính sản phẩm; dùng URI ảnh được tải lên trước; số phần tử tối đa: 9. |
| main_images[].uri | body | string | Yes | anh-minh-hoa | URI ảnh đã tải lên; giá trị liên quan: MAIN_IMAGE. |
| skus | body | object[] | Yes | [{"global_quantity": 1, "sales_attributes": [{"id": "900000000000000001", "name": "Minh họa", "value_id": "900000000000000001", "value_name": "Minh họa", "sku_img": {"uri": "anh-minh-hoa"}}], "seller_sku": "SKU-MAU-01", "price": {"amount": "150000", "currency": "VND"}, "identifier_code": {"code": 0, "type": "GTIN"}, "inventory": [{"global_warehouse_id": "900000000000000001", "quantity": 1}], "sku_unit_count": "Minh họa", "extra_identifier_codes": ["Minh họa"], "external_global_sku_id": "900000000000000001"}] | Các SKU biến thể; tối đa 300 tại EU, JP, UK, US, khu vực khác tối đa 100; nên đặt biến thể quan trọng nhất ở đầu. |
| skus[].global_quantity | body | int | No | 1 | Tồn kho toàn cầu. |
| skus[].sales_attributes | body | object[] | No | [{"id": "900000000000000001", "name": "Minh họa", "value_id": "900000000000000001", "value_name": "Minh họa", "sku_img": {"uri": "anh-minh-hoa"}}] | Thuộc tính bán hàng tạo biến thể. |
| skus[].sales_attributes[].id | body | string | No | 900000000000000001 | Mã định danh. |
| skus[].sales_attributes[].name | body | string | No | Minh họa | Tên; độ dài tối đa: 20. |
| skus[].sales_attributes[].value_id | body | string | No | 900000000000000001 | Mã giá trị. |
| skus[].sales_attributes[].value_name | body | string | No | Minh họa | Tên giá trị; độ dài tối đa: 50. |
| skus[].sales_attributes[].sku_img | body | object | No | {"uri": "anh-minh-hoa"} | Ảnh biến thể. |
| skus[].sales_attributes[].sku_img.uri | body | string | Yes | anh-minh-hoa | URI ảnh đã tải lên; giá trị liên quan: ATTRIBUTE_IMAGE. |
| skus[].seller_sku | body | string | No | SKU-MAU-01 | Mã SKU do người bán quản lý. |
| skus[].price | body | object | Yes | {"amount": "150000", "currency": "VND"} | Giá. |
| skus[].price.amount | body | string | Yes | 150000 | Số tiền. |
| skus[].price.currency | body | string | Yes | VND | Mã tiền tệ; giá trị liên quan: USD, EUR, EU. |
| skus[].identifier_code | body | object | No | {"code": 0, "type": "GTIN"} | Mã định danh bổ sung. |
| skus[].identifier_code.code | body | string | No | 0 | Mã kết quả; 0 là thành công; giá trị liên quan: X. |
| skus[].identifier_code.type | body | string | No | GTIN | Loại; giá trị liên quan: GTIN, EAN, UPC, ISBN, JAN. |
| skus[].inventory | body | object[] | No | [{"global_warehouse_id": "900000000000000001", "quantity": 1}] | Tồn kho theo từng kho; số phần tử tối đa: 50. |
| skus[].inventory[].global_warehouse_id | body | string | Yes | 900000000000000001 | Mã kho toàn cầu. |
| skus[].inventory[].quantity | body | int | Yes | 1 | Số lượng; giới hạn: [1, 99,999]. |
| skus[].sku_unit_count | body | string | No | Minh họa | Số đơn vị trong SKU; giới hạn: [0.01, 99,999.9999]. |
| skus[].extra_identifier_codes | body | string[] | No | ["Minh họa"] | Các mã định danh bổ sung; giá trị liên quan: X. |
| skus[].external_global_sku_id | body | string | No | 900000000000000001 | Mã SKU toàn cầu trong hệ thống bên ngoài; độ dài tối đa: 999. |
| package_weight | body | object | Yes | {"value": "0.5", "unit": "KILOGRAM"} | Khối lượng sau đóng gói; khai chính xác để tính phí giao hàng. Khối lượng được ưu tiên khi tính phí nếu bỏ kích thước kiện hàng. |
| package_weight.value | body | string | Yes | 0.5 | Giá trị. |
| package_weight.unit | body | string | Yes | KILOGRAM | Đơn vị; giá trị liên quan: KILOGRAM. |
| certifications | body | object[] | No | [{"id": "900000000000000001", "images": [{"uri": "anh-minh-hoa"}], "files": [{"id": "900000000000000001", "name": "chungnhan.pdf", "format": "PDF"}]}] | Chứng nhận sản phẩm; số phần tử tối đa: 10. |
| certifications[].id | body | string | Yes | 900000000000000001 | Mã định danh. |
| certifications[].images | body | object[] | No | [{"uri": "anh-minh-hoa"}] | Danh sách ảnh. |
| certifications[].images[].uri | body | string | Yes | anh-minh-hoa | URI ảnh đã tải lên; giá trị liên quan: CERTIFICATION_IMAGE. |
| certifications[].files | body | object[] | No | [{"id": "900000000000000001", "name": "chungnhan.pdf", "format": "PDF"}] | Danh sách tệp. |
| certifications[].files[].id | body | string | Yes | 900000000000000001 | Mã định danh. |
| certifications[].files[].name | body | string | Yes | chungnhan.pdf | Tên. |
| certifications[].files[].format | body | string | Yes | Định dạng tệp. | |
| package_dimensions | body | object | No | {"length": "Minh họa", "width": "Minh họa", "height": "Minh họa", "unit": "CENTIMETER"} | Kích thước kiện hàng. |
| package_dimensions.length | body | string | Yes | Minh họa | Chiều dài. |
| package_dimensions.width | body | string | Yes | Minh họa | Chiều rộng. |
| package_dimensions.height | body | string | Yes | Minh họa | Chiều cao. |
| package_dimensions.unit | body | string | Yes | CENTIMETER | Đơn vị; giá trị liên quan: CENTIMETER. |
| product_attributes | body | object[] | No | [{"id": "900000000000000001", "values": [{"id": "900000000000000001", "name": "Minh họa"}]}] | Thuộc tính sản phẩm; điền đủ thuộc tính bắt buộc của ngành hàng. |
| product_attributes[].id | body | string | Yes | 900000000000000001 | Mã định danh. |
| product_attributes[].values | body | object[] | Yes | [{"id": "900000000000000001", "name": "Minh họa"}] | Các giá trị; số phần tử tối đa: 300. |
| product_attributes[].values[].id | body | string | No | 900000000000000001 | Mã định danh. |
| product_attributes[].values[].name | body | string | No | Minh họa | Tên; độ dài tối đa: 2000. |
| size_chart | body | object | No | {"image": {"uri": "anh-minh-hoa"}, "template": {"id": "900000000000000001"}} | Bảng kích cỡ sản phẩm; có thể bắt buộc hoặc không được hỗ trợ tùy ngành hàng. Nếu ngành không hỗ trợ thì nội dung gửi sẽ bị bỏ qua. |
| size_chart.image | body | object | No | {"uri": "anh-minh-hoa"} | Ảnh. |
| size_chart.image.uri | body | string | Yes | anh-minh-hoa | URI ảnh đã tải lên; giá trị liên quan: SIZE_CHART_IMAGE. |
| size_chart.template | body | object | No | {"id": "900000000000000001"} | Mẫu. |
| size_chart.template.id | body | string | Yes | 900000000000000001 | Mã định danh. |
| video | body | object | No | {"id": "900000000000000001"} | Video giới thiệu sản phẩm; khuyến nghị tỷ lệ 1:1, độ phân giải HD 720p trở lên, dài 20–60 giây. |
| video.id | body | string | Yes | 900000000000000001 | Mã định danh. |
| manufacturer | body | object | No | {"name": "Minh họa", "address": "Minh họa", "phone_number": "0000000000", "email": "minhhoa@example.com"} | Thông tin nhà sản xuất; trường cũ, dùng manufacturer_ids thay thế. |
| manufacturer.name | body | string | No | Minh họa | Tên. |
| manufacturer.address | body | string | No | Minh họa | Địa chỉ. |
| manufacturer.phone_number | body | string | No | 0000000000 | Số điện thoại. |
| manufacturer.email | body | string | No | minhhoa@example.com | Địa chỉ thư điện tử. |
| category_version | body | string | No | v2 | Phiên bản cây ngành hàng; v2 là cây 7 cấp tại Mỹ, EU, Đông Nam Á; v1 là cây 3 cấp mặc định cho khu vực khác; giá trị liên quan: US, EU, SEA. |
| responsible_person_ids | body | string[] | No | ["900000000000000001"] | Danh sách mã người chịu trách nhiệm. |
| manufacturer_ids | body | string[] | No | ["900000000000000001"] | Danh sách mã nhà sản xuất. |
| source_locale | body | string | No | vi-VN | Ngôn ngữ gốc; giá trị liên quan: BCP, CZ, AT, BE, DE, GR, GB, IE, US, ES, MX, FR, HU, IT, JP, MY, NL, PL, BR, PT, TH, VN, CN. |
| external_global_product_id | body | string | No | 900000000000000001 | Mã sản phẩm toàn cầu trong hệ thống bên ngoài; độ dài tối đa: 999. |
Request examples
curl -s -X POST "https://partner.quantri360.com/v1/tiktok/product/202309/global_products" \
-H "Authorization: Bearer $KEY" \
-H "Content-Type: application/json" \
-d '{"title":"Áo thun cotton cổ tròn minh họa","description":"<p>Sản phẩm minh họa.</p>","category_id":"900000000000000001","brand_id":"900000000000000001","main_images":[{"uri":"anh-minh-hoa"}],"skus":[{"global_quantity":1,"sales_attributes":[{"id":"900000000000000001","name":"Minh họa","value_id":"900000000000000001","value_name":"Minh họa","sku_img":{"uri":"anh-minh-hoa"}}],"seller_sku":"SKU-MAU-01","price":{"amount":"150000","currency":"VND"},"identifier_code":{"code":0,"type":"GTIN"},"inventory":[{"global_warehouse_id":"900000000000000001","quantity":1}],"sku_unit_count":"Minh họa","extra_identifier_codes":["Minh họa"],"external_global_sku_id":"900000000000000001"}],"package_weight":{"value":"0.5","unit":"KILOGRAM"},"certifications":[{"id":"900000000000000001","images":[{"uri":"anh-minh-hoa"}],"files":[{"id":"900000000000000001","name":"chungnhan.pdf","format":"PDF"}]}],"package_dimensions":{"length":"Minh họa","width":"Minh họa","height":"Minh họa","unit":"CENTIMETER"},"product_attributes":[{"id":"900000000000000001","values":[{"id":"900000000000000001","name":"Minh họa"}]}],"size_chart":{"image":{"uri":"anh-minh-hoa"},"template":{"id":"900000000000000001"}},"video":{"id":"900000000000000001"},"manufacturer":{"name":"Minh họa","address":"Minh họa","phone_number":"0000000000","email":"minhhoa@example.com"},"category_version":"v2","responsible_person_ids":["900000000000000001"],"manufacturer_ids":["900000000000000001"],"source_locale":"vi-VN","external_global_product_id":"900000000000000001"}'
Python
import requests
KEY = "q360_live_..." # khóa API của brand
r = requests.post(
"https://partner.quantri360.com/v1/tiktok/product/202309/global_products",
params={},
json={
"title": "Áo thun cotton cổ tròn minh họa",
"description": "<p>Sản phẩm minh họa.</p>",
"category_id": "900000000000000001",
"brand_id": "900000000000000001",
"main_images": [
{
"uri": "anh-minh-hoa"
}
],
"skus": [
{
"global_quantity": 1,
"sales_attributes": [
{
"id": "900000000000000001",
"name": "Minh họa",
"value_id": "900000000000000001",
"value_name": "Minh họa",
"sku_img": {
"uri": "anh-minh-hoa"
}
}
],
"seller_sku": "SKU-MAU-01",
"price": {
"amount": "150000",
"currency": "VND"
},
"identifier_code": {
"code": 0,
"type": "GTIN"
},
"inventory": [
{
"global_warehouse_id": "900000000000000001",
"quantity": 1
}
],
"sku_unit_count": "Minh họa",
"extra_identifier_codes": [
"Minh họa"
],
"external_global_sku_id": "900000000000000001"
}
],
"package_weight": {
"value": "0.5",
"unit": "KILOGRAM"
},
"certifications": [
{
"id": "900000000000000001",
"images": [
{
"uri": "anh-minh-hoa"
}
],
"files": [
{
"id": "900000000000000001",
"name": "chungnhan.pdf",
"format": "PDF"
}
]
}
],
"package_dimensions": {
"length": "Minh họa",
"width": "Minh họa",
"height": "Minh họa",
"unit": "CENTIMETER"
},
"product_attributes": [
{
"id": "900000000000000001",
"values": [
{
"id": "900000000000000001",
"name": "Minh họa"
}
]
}
],
"size_chart": {
"image": {
"uri": "anh-minh-hoa"
},
"template": {
"id": "900000000000000001"
}
},
"video": {
"id": "900000000000000001"
},
"manufacturer": {
"name": "Minh họa",
"address": "Minh họa",
"phone_number": "0000000000",
"email": "minhhoa@example.com"
},
"category_version": "v2",
"responsible_person_ids": [
"900000000000000001"
],
"manufacturer_ids": [
"900000000000000001"
],
"source_locale": "vi-VN",
"external_global_product_id": "900000000000000001"
},
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/product/202309/global_products');
for (const [k, v] of Object.entries({})) url.searchParams.set(k, typeof v === 'object' ? JSON.stringify(v) : String(v));
const r = await fetch(url, {
method: 'POST',
headers: { Authorization: `Bearer ${KEY}`, 'Content-Type': 'application/json' },
body: JSON.stringify({"title":"Áo thun cotton cổ tròn minh họa","description":"<p>Sản phẩm minh họa.</p>","category_id":"900000000000000001","brand_id":"900000000000000001","main_images":[{"uri":"anh-minh-hoa"}],"skus":[{"global_quantity":1,"sales_attributes":[{"id":"900000000000000001","name":"Minh họa","value_id":"900000000000000001","value_name":"Minh họa","sku_img":{"uri":"anh-minh-hoa"}}],"seller_sku":"SKU-MAU-01","price":{"amount":"150000","currency":"VND"},"identifier_code":{"code":0,"type":"GTIN"},"inventory":[{"global_warehouse_id":"900000000000000001","quantity":1}],"sku_unit_count":"Minh họa","extra_identifier_codes":["Minh họa"],"external_global_sku_id":"900000000000000001"}],"package_weight":{"value":"0.5","unit":"KILOGRAM"},"certifications":[{"id":"900000000000000001","images":[{"uri":"anh-minh-hoa"}],"files":[{"id":"900000000000000001","name":"chungnhan.pdf","format":"PDF"}]}],"package_dimensions":{"length":"Minh họa","width":"Minh họa","height":"Minh họa","unit":"CENTIMETER"},"product_attributes":[{"id":"900000000000000001","values":[{"id":"900000000000000001","name":"Minh họa"}]}],"size_chart":{"image":{"uri":"anh-minh-hoa"},"template":{"id":"900000000000000001"}},"video":{"id":"900000000000000001"},"manufacturer":{"name":"Minh họa","address":"Minh họa","phone_number":"0000000000","email":"minhhoa@example.com"},"category_version":"v2","responsible_person_ids":["900000000000000001"],"manufacturer_ids":["900000000000000001"],"source_locale":"vi-VN","external_global_product_id":"900000000000000001"}),
});
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/product/202309/global_products' . '?' . http_build_query([]);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: Bearer ' . $key, 'Content-Type: application/json']);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"title":"Áo thun cotton cổ tròn minh họa","description":"<p>Sản phẩm minh họa.</p>","category_id":"900000000000000001","brand_id":"900000000000000001","main_images":[{"uri":"anh-minh-hoa"}],"skus":[{"global_quantity":1,"sales_attributes":[{"id":"900000000000000001","name":"Minh họa","value_id":"900000000000000001","value_name":"Minh họa","sku_img":{"uri":"anh-minh-hoa"}}],"seller_sku":"SKU-MAU-01","price":{"amount":"150000","currency":"VND"},"identifier_code":{"code":0,"type":"GTIN"},"inventory":[{"global_warehouse_id":"900000000000000001","quantity":1}],"sku_unit_count":"Minh họa","extra_identifier_codes":["Minh họa"],"external_global_sku_id":"900000000000000001"}],"package_weight":{"value":"0.5","unit":"KILOGRAM"},"certifications":[{"id":"900000000000000001","images":[{"uri":"anh-minh-hoa"}],"files":[{"id":"900000000000000001","name":"chungnhan.pdf","format":"PDF"}]}],"package_dimensions":{"length":"Minh họa","width":"Minh họa","height":"Minh họa","unit":"CENTIMETER"},"product_attributes":[{"id":"900000000000000001","values":[{"id":"900000000000000001","name":"Minh họa"}]}],"size_chart":{"image":{"uri":"anh-minh-hoa"},"template":{"id":"900000000000000001"}},"video":{"id":"900000000000000001"},"manufacturer":{"name":"Minh họa","address":"Minh họa","phone_number":"0000000000","email":"minhhoa@example.com"},"category_version":"v2","responsible_person_ids":["900000000000000001"],"manufacturer_ids":["900000000000000001"],"source_locale":"vi-VN","external_global_product_id":"900000000000000001"}');
$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 Shop)
| Name | Type | Sample | Description |
|---|---|---|---|
| code | int | 0 | Mã kết quả; 0 là thành công. |
| message | string | Success | Thông báo kết quả. |
| request_id | string | YEU_CAU_MINH_HOA | Mã yêu cầu để tra cứu lỗi. |
| data | object | Dữ liệu. | |
| global_product_id | string | 900000000000000001 | Mã sản phẩm toàn cầu. |
| global_skus | object[] | Danh sách SKU toàn cầu. | |
| id | string | 900000000000000001 | Mã định danh. |
| seller_sku | string | SKU-MAU-01 | Mã SKU do người bán quản lý. |
| sales_attributes | object[] | Thuộc tính bán hàng tạo biến thể. | |
| id | string | 900000000000000001 | Mã định danh. |
| value_id | string | 900000000000000001 | Mã giá trị. |
| external_global_sku_id | string | 900000000000000001 | Mã SKU toàn cầu trong hệ thống bên ngoài; độ dài tối đa: 999. |
Response sample
{
"code": 0,
"message": "Success",
"request_id": "YEU_CAU_MINH_HOA",
"data": {
"global_product_id": "900000000000000001",
"global_skus": [
{
"id": "900000000000000001",
"seller_sku": "SKU-MAU-01",
"sales_attributes": [
{
"id": "900000000000000001",
"value_id": "900000000000000001"
}
],
"external_global_sku_id": "900000000000000001"
}
]
}
}
Get started
- Sign up for Partner
- Enable a data type of the Sản phẩm group on the platform page
- Create an API key (tick the TikTok Shop channel)
- Call it as in the examples above