TikTok Real msToken
https://api.sandbase.ai/v1/api/tiktok/web/generate-real-ms-tokenProduces a real msToken for TikTok web requests. Accepts optional configuration parameters including browser type and randomized string data.
- Precio
- $0.001USD / llamada
- Método
- POST
- Respuesta
- JSON
- Parámetros
- 0 obligatorios · 2 opcionales
Entorno de pruebas
Su salida aparecerá aquí
Complete las entradas y luego haga clic en Ejecutar.
README de la API
TikTok Real msToken API
This API returns a real msToken string for TikTok web requests. It needs no input, but you can pass browser_type and random_strData to change how the token is made.
Use cases
- Add a fresh
msTokento TikTok web requests that need one as a query parameter or cookie. - Request a token for a specific browser type by setting
browser_type. - Test how
random_strDatachanges the token you get back.
Request
curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/generate-real-ms-token" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'
The result is returned in outputs[0].data.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
browser_type | string | No | |
random_strData | boolean | No |
Example response
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"browser_type": null,
"msToken": "DFJLzkge…",
"random_strData": false
}
Response fields
| Field | Meaning |
|---|---|
msToken | The generated token string. Pass this value as the msToken in your TikTok web requests. |
browser_type | Echoes the browser_type you sent. It is null when you leave the parameter out. |
random_strData | Echoes the random_strData flag you sent. It is false in the sample call, where the parameter was not set. |
Notes
- Both parameters are optional. An empty
{}body returns a token. browser_typeis a string andrandom_strDatais a boolean.- The token contains letters, digits,
-and_. Copy it as is without extra encoding changes. - For signed requests, pair the token with TikTok Web X-Bogus Signature or TikTok Web TTWID Identifier.
Pricing
$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
Empiece a construir
Envíe su primera solicitud
Endpoint de la API de la plataforma con autenticación unificada y seguimiento de uso.
curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/generate-real-ms-token" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'2. Autenticación
Configure su clave de API de SandBase en el entorno de su servidor. Las solicitudes usan autenticación Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Conserve su clave en el servidor. No la exponga en código del navegador.
3. Parámetros
random_strDataboolean
4. Respuesta
Respuesta de ejemplo guardada para esta API; no se realiza ninguna solicitud en vivo al verla.
No se ha publicado ninguna respuesta guardada. Ejecute la API en Playground para inspeccionar su respuesta.
Explorar más
APIs relacionadas
| API | Precio | Respuesta |
|---|---|---|
TikTok Real msTokenEsta API TikTok | $0.001 por llamada | JSON |
TikTok | $0.001 por llamada | JSON |
TikTok | $0.001 por llamada | JSON |
TikTok | $0.001 por llamada | JSON |
TikTok | $0.001 por llamada | JSON |
TikTok | $0.05 por llamada | JSON |
Guías:TikTok API pricing: official access vs per-call dataBest TikTok API in 2026: Pricing Compared
Preguntas
FAQ
¿Cómo uso la API de TikTok Real msToken?
Envía una solicitud POST a https://api.sandbase.ai/v1/api/tiktok/web/generate-real-ms-token con tu clave API de SandBase en el encabezado Authorization (Bearer) y los parámetros como un cuerpo JSON. También puedes probarlo en el Playground de esta página sin escribir código.
¿Cuánto cuesta la API de TikTok Real msToken?
$0.001 por llamada, facturado desde tu saldo de SandBase. Solo se te cobra por las llamadas que haces; no hay suscripción.
¿Qué parámetros acepta la API de TikTok Real msToken?
No se requieren parámetros. Opcionales: browser_type (string) y random_strData (boolean). La tabla de Parámetros y el Playground de esta página enumeran todos los campos.
¿Qué devuelve la API de TikTok Real msToken?
Una respuesta JSON devuelta en la misma solicitud HTTP (sincrónica). El README de esta página incluye una respuesta de ejemplo.
¿Necesito una cuenta de desarrollador o una clave API de TikTok?
No. TikTok Real msToken funciona a través de SandBase, así que una sola clave API de SandBase cubre este endpoint y todas las demás APIs y modelos del catálogo. No necesitas solicitar acceso a la API de TikTok por separado.
