gift_idsarrayobrigatório
Gift ID list, recommend 50/call for best value ($0.025), auto-process first 50 if more than 50
https://api.sandbase.ai/v1/api/tiktok/web/gift-names-by-idsReturns gift names for a batch of TikTok gift identifiers. Provide a list of gift IDs to look up their corresponding gift labels.
[
{
"data": {
"found": 3,
"message": null,
"not_found": 0,
"original_count": 3,
"results": [
{
"code": 0,
"gift_id": "10001",
"gift_name": "鞭炮"
},
{
"code": 0,
"gift_id": "10002",
"gift_name": "红包"
},
{
"code": 0,
"gift_id": "10003",
"gift_name": "龙年幸运福袋"
}
],
"total": 3,
"truncated": false
}
}
]Selecione um exemplo para carregar as entradas e o resultado no playground.
Returns the gift name for each TikTok gift ID in a list. You send gift_ids as an array of strings and get one result row per ID, plus counts for found and missing IDs.
curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/gift-names-by-ids" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"gift_ids": ["10001", "10002", "10003"]}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
gift_ids | array | Yes | Gift ID list, recommend 50/call for best value ($0.025), auto-process first 50 if more than 50 |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"found": 3,
"message": null,
"not_found": 0,
"original_count": 3,
"results": [
{
"code": 0,
"gift_id": "10001",
"gift_name": "鞭炮"
}
],
"total": 3,
"truncated": false
}
| Field | Meaning |
|---|---|
results[].gift_id | The gift ID from your request that this row answers. |
results[].gift_name | The name of the gift. The sample values are in Chinese, such as 鞭炮 and 红包. |
results[].code | Result code for this single lookup. It is 0 on every row in the sample, where all IDs returned a name. |
found / not_found | Number of IDs that returned a name and number of IDs that did not. |
original_count / total | Count of IDs in the request and total count of results. Both are 3 in the sample. |
truncated | Boolean flag. It is false in the sample. |
message | Text message about the call. It is null in the sample. |
"10001". The gift_ids list accepts 1 to 1000 items.found, not_found and truncated with your request to see whether any IDs were unresolved or skipped.$0.025 per successful call. Failed calls are not charged.
Comece a construir
Endpoint da API da plataforma com autenticação unificada e rastreamento de uso.
curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/gift-names-by-ids" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"gift_ids": [
"10001",
"10002",
"10003"
]
}'Defina sua chave da API SandBase no ambiente do seu servidor. As requisições usam autenticação Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Mantenha sua chave no servidor. Não a exponha em código do navegador.
gift_idsarrayobrigatórioGift ID list, recommend 50/call for best value ($0.025), auto-process first 50 if more than 50
Resposta de exemplo salva para esta API; nenhuma requisição ao vivo é feita ao visualizá-la.
[
{
"data": {
"found": 3,
"message": null,
"not_found": 0,
"original_count": 3,
"results": [
{
"code": 0,
"gift_id": "10001",
"gift_name": "鞭炮"
},
{
"code": 0,
"gift_id": "10002",
"gift_name": "红包"
},
{
"code": 0,
"gift_id": "10003",
"gift_name": "龙年幸运福袋"
}
],
"total": 3,
"truncated": false
}
}
]Explorar mais
| API | Preço | Resposta |
|---|---|---|
TikTok Gift Names by IDsEsta API TikTok | $0.025 por chamada | JSON |
TikTok | $0.001 por chamada | JSON |
TikTok | $0.001 por chamada | JSON |
TikTok | $0.001 por chamada | JSON |
TikTok | $0.001 por chamada | JSON |
TikTok | $0.05 por chamada | JSON |
Guias:TikTok API pricing: official access vs per-call dataBest TikTok API in 2026: Pricing Compared
Perguntas
Envie uma solicitação POST para https://api.sandbase.ai/v1/api/tiktok/web/gift-names-by-ids com sua chave de API da SandBase no cabeçalho Authorization (Bearer) e os parâmetros no corpo JSON. Você também pode testar no Playground desta página sem escrever código.
$0.025 por chamada, cobrado do seu saldo SandBase. Você paga apenas pelas chamadas que fizer; não há assinatura.
Obrigatórios: gift_ids (array). A tabela de Parâmetros e o Playground nesta página listam todos os campos.
Uma resposta JSON retornada na mesma solicitação HTTP (síncrona). O README desta página inclui um exemplo de resposta.
Não. TikTok Gift Names by IDs funciona via SandBase, então uma única chave de API da SandBase cobre este endpoint e todas as outras APIs e modelos do catálogo. Você não precisa solicitar acesso à API do TikTok separadamente.