Sand AISand AI MAGI-2ตอนนี้ MAGI-2 อยู่บน SandBase แล้ว: วิดีโอ 1080p พร้อมเสียงในตัวลองใช้เลย

Douyin Web TTWID Generator

เอกสาร API
https://api.sandbase.ai/v1/api/douyin/web/generate-ttwid

Returns a Douyin web ttwid cookie value required for web session authentication. Accepts an optional custom user agent string.

ราคา
$0.001USD / คำขอ
Method
POST
การตอบกลับ
JSON
พารามิเตอร์
0 จำเป็น · 1 ไม่บังคับ

Playground

อินพุต
เอาต์พุตตัวอย่าง
การตอบกลับoutputs · 176 B · 7 บรรทัด
[
  {
    "data": {
      "ttwid": "1%7CDUhgx1gk7BiWEvdAdekoqVeGk6a5k8MitMgWFagQJPg%7C1787219000%7C4a18a285f75af40fb5376e9da85e1dcf234dd9e1e27a4f2a4f78d8504744abac"
    }
  }
]

ตัวอย่าง

เลือกตัวอย่างเพื่อโหลดอินพุตและผลลัพธ์ลงใน playground

API README

Douyin Web TTWID Generator API

Returns a Douyin web ttwid cookie value as a single string. The only input is an optional user_agent string, so you can call it with an empty body.

Use cases

  • Build a Cookie header for Douyin web requests that need a ttwid value.
  • Replace a ttwid cookie in your own client when you start a new session.
  • Pair a generated ttwid with the same user_agent you send in later web requests.

Request

curl -X POST "https://api.sandbase.ai/v1/api/douyin/web/generate-ttwid" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

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

Parameters

NameTypeRequiredDescription
user_agentstringNo

Example response

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

{
  "ttwid": "1%7CvTde…"
}

Response fields

FieldMeaning
ttwidThe full Douyin web ttwid cookie value as a URL-encoded string. Use it as is in a cookie header.
ttwidThe value has four parts separated by %7C, which is an encoded /. Keep the separators when you copy the value.
ttwidThe parts are a short leading number, a token, a 10-digit number, and a long hex string. Treat the whole string as opaque and do not edit it.

Notes

Pricing

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

สำรวจเพิ่มเติม

APIs ที่เกี่ยวข้อง

APIs ทั้งหมด
APIราคาการตอบกลับ
Douyin$0.001 ต่อการเรียกJSON
Douyin$0.001 ต่อการเรียกJSON
Douyin$0.001 ต่อการเรียกJSON
Douyin$0.001 ต่อการเรียกJSON
Douyin$0.001 ต่อการเรียกJSON
Douyin$0.03 ต่อการเรียกJSON

คู่มือ:Best Douyin API in 2026: Pricing Compared

คำถาม

คำถามที่พบบ่อย

ฉันจะใช้ Douyin Web TTWID Generator API ได้อย่างไร?

ส่งคำขอ POST ไปที่ https://api.sandbase.ai/v1/api/douyin/web/generate-ttwid โดยใส่ SandBase API key ของคุณใน Authorization header (Bearer) และส่งพารามิเตอร์เป็น JSON body คุณยังสามารถลองใช้ได้ใน Playground บนหน้านี้โดยไม่ต้องเขียนโค้ด

Douyin Web TTWID Generator API ราคาเท่าไร?

$0.001 ต่อครั้ง คิดจากยอดคงเหลือ SandBase ของคุณ คุณจะถูกเรียกเก็บเฉพาะคำขอที่คุณส่งเท่านั้น ไม่มีค่าสมาชิกรายเดือน

Douyin Web TTWID Generator API รับพารามิเตอร์อะไรบ้าง?

ไม่ต้องระบุพารามิเตอร์ ตัวเลือก: user_agent (string). ตาราง Parameters และ Playground ในหน้านี้แสดงทุกฟิลด์

Douyin Web TTWID Generator API ส่งคืนอะไร?

การตอบกลับ JSON ที่ส่งกลับในคำขอ HTTP เดียวกัน (แบบซิงโครนัส) README บนหน้านี้มีตัวอย่างการตอบกลับ

ฉันจำเป็นต้องมีบัญชีนักพัฒนาหรือ API key ของ Douyin ไหม?

ไม่จำเป็น Douyin Web TTWID Generator ทำงานผ่าน SandBase ดังนั้น SandBase API key เดียวครอบคลุม endpoint นี้และทุก API กับโมเดลอื่นในแค็ตตาล็อก คุณไม่ต้องสมัครขอสิทธิ์เข้าถึง Douyin API แยกต่างหาก