Sand AISand AI MAGI-2MAGI-2 agora está na SandBase: vídeo em 1080p com áudio nativoExperimente agora

TikTok Web X-Gnarly Signature

Docs da API
https://api.sandbase.ai/v1/api/tiktok/web/generate-xgnarly

Returns generated X-Gnarly signature values for TikTok web requests based on a target endpoint URL and optional request body data.

Preço
$0.002USD / chamada
Método
POST
Resposta
JSON
Parâmetros
1 obrigatórios · 1 opcionais

Playground

Entrada
The requested API URL, no need to URL encode
The API parameters of the request, applicable for POST requests
SaídaPronto

Sua saída aparecerá aqui

Preencha as entradas e clique em Executar.

README da API

TikTok Web X-Gnarly Signature API

Returns signature values for a TikTok web request, including xGnarly, xBogus and xDynosaur, plus a signed copy of the URL. It needs the full request url and an optional body string for POST requests.

Use cases

  • Sign a TikTok web endpoint URL before you send the request yourself.
  • Get the xGnarly value to attach to a request that needs it.
  • Sign a POST request by passing its parameters in body.
  • Reuse the returned user_agent so your request headers match the signature.

Request

curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/generate-xgnarly" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://www.tiktok.com/tag/cat?_r=1&name=cat&u_code=f02lm2f78d1elh&_d=f02ll161mcjihj&share_challenge_id=7551&sharer_language=en&source=h5_m"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
urlstringYesThe requested API URL, no need to URL encode
bodystringNoThe API parameters of the request, applicable for POST requests

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "body": "",
  "signature": {
    "signedUrl": "https://www.tiktok.com/tag/cat?_r=1&name=cat&u_code=f02lm2f78d1elh&_d=f02ll161mc…",
    "xBogus": "1",
    "xDynosaur": "MwDqFZsDyJz0WUQqmwWXyw3eVqiiAocN4i8HrXlDijQD7wFNRr2Tz5/6YUbiz4AE3BgF2bNXJHozDynN…",
    "xGnarly": "MkD6M/0-wSOgEHM72xx9Pmya70CI67jZFmlC6-SUgWujQf0-x/rRdQxOIvXBvWjzh0hCieJoa1YfSSWb…"
  },
  "status": "success",
  "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:146.0) Gecko/20100101 Firefox/1…",
  "version": "5.3.2"
}

Response fields

FieldMeaning
signature.xGnarlyThe X-Gnarly signature value generated for the given url.
signature.xBogusThe X-Bogus value for the same request. It is 1 in this example.
signature.xDynosaurThe X-Dynosaur value generated for the request.
signature.signedUrlThe input url with the X-Dynosaur parameter appended as a query parameter.
bodyThe request body that was signed. It is an empty string when you send no body.
user_agentThe browser User-Agent string the signature was generated with.
versionThe version string of the signing logic, for example 5.3.2.
statusWhether the call worked. A good call returns success.

Notes

Pricing

$0.002 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

Explorar mais

APIs relacionadas

Todas as APIs
APIPreçoResposta
TikTok$0.002 por chamadaJSON
TikTok$0.001 por chamadaJSON
TikTok$0.001 por chamadaJSON
TikTok$0.001 por chamadaJSON
TikTok$0.001 por chamadaJSON
TikTok$0.05 por chamadaJSON

Guias:TikTok API pricing: official access vs per-call dataBest TikTok API in 2026: Pricing Compared

Perguntas

FAQ

Como eu uso a API TikTok Web X-Gnarly Signature?

Envie uma solicitação POST para https://api.sandbase.ai/v1/api/tiktok/web/generate-xgnarly 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.

Quanto custa a API TikTok Web X-Gnarly Signature?

$0.002 por chamada, cobrado do seu saldo SandBase. Você paga apenas pelas chamadas que fizer; não há assinatura.

Quais parâmetros a API TikTok Web X-Gnarly Signature aceita?

Obrigatórios: url (string). Opcionais: body (any). A tabela de Parâmetros e o Playground nesta página listam todos os campos.

O que a API TikTok Web X-Gnarly Signature retorna?

Uma resposta JSON retornada na mesma solicitação HTTP (síncrona). O README desta página inclui um exemplo de resposta.

Preciso de uma conta de desenvolvedor TikTok ou de uma chave de API?

Não. TikTok Web X-Gnarly Signature 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.