Skip to main content

API สถานะบัญชี

หน้านี้อธิบาย API endpoint สำหรับค้นหาสถานะของบัญชีทั้งหมดที่จัดการใน TikMatrix รวมถึงสถานะออนไลน์/ออฟไลน์ของอุปกรณ์ สถานะการเข้าสู่ระบบ และแท็ก

รายการบัญชี

ดึงข้อมูลบัญชีทั้งหมดพร้อมข้อมูลสถานะเพิ่มเติม

  • เอ็นด์พอยต์: GET /api/v1/accounts

พารามิเตอร์คำขอ

พารามิเตอร์ประเภทค่าเริ่มต้นคำอธิบาย
platformstringกรองตามแพลตฟอร์ม: tiktok หรือ instagram
devicestringกรองตามหมายเลขซีเรียลของอุปกรณ์
loginedintegerกรองตามสถานะการเข้าสู่ระบบ: 0 = ยังไม่ได้เข้าสู่ระบบ, 1 = เข้าสู่ระบบแล้ว
statusintegerกรองตามสถานะบัญชี: 0 = เปิดใช้งาน, 1 = ปิดใช้งาน
tagstringกรองตามแท็ก (ตรงกันแบบสมบูรณ์)
pageinteger1หมายเลขหน้า (เริ่มที่ 1)
page_sizeinteger20จำนวนรายการต่อหน้า (สูงสุด 100)

ฟิลด์การตอบกลับ

ฟิลด์ประเภทคำอธิบาย
accountsarrayรายการอ็อบเจ็กต์บัญชี (ดูด้านล่าง)
totalintegerจำนวนบัญชีทั้งหมดที่ตรงกับตัวกรอง
pageintegerหมายเลขหน้าปัจจุบัน
page_sizeintegerจำนวนรายการต่อหน้า

อ็อบเจ็กต์บัญชี

ฟิลด์ประเภทคำอธิบาย
idintegerID บัญชีในฐานข้อมูล
usernamestring | nullชื่อผู้ใช้โซเชียลมีเดีย
emailstring | nullที่อยู่อีเมลของบัญชี
platformstringแพลตฟอร์ม: tiktok หรือ instagram
packagenamestring | nullชื่อแพ็กเกจของแอปโคลน (null = แอปเริ่มต้น)
devicestring | nullหมายเลขซีเรียลอุปกรณ์ ADB
device_onlinebooleanอุปกรณ์เชื่อมต่ออยู่ในขณะนี้หรือไม่
device_namestringชื่อรุ่นอุปกรณ์ (เป็นสตริงว่างเมื่อออฟไลน์)
loginedinteger0 = ยังไม่ได้เข้าสู่ระบบ, 1 = เข้าสู่ระบบแล้ว
logined_textstring"logged_in" หรือ "not_logged_in"
statusinteger0 = เปิดใช้งาน, 1 = ปิดใช้งาน
status_textstring"enabled" หรือ "disabled"
tagsstring[]แท็กที่กำหนดให้กับบัญชีนี้
ความปลอดภัย

รหัสผ่านบัญชีจะ ไม่ ถูกรวมอยู่ในการตอบกลับของ API

ตัวอย่าง

curl "http://localhost:50809/api/v1/accounts?page=1&page_size=20"

กรองตามแพลตฟอร์มและสถานะการเข้าสู่ระบบ:

curl "http://localhost:50809/api/v1/accounts?platform=tiktok&logined=1&page=1&page_size=50"

กรองตามหมายเลขซีเรียลของอุปกรณ์:

curl "http://localhost:50809/api/v1/accounts?device=emulator-5554"

ตัวอย่างการตอบกลับ

{
"code": 0,
"message": "success",
"data": {
"accounts": [
{
"id": 1,
"username": "my_tiktok_user",
"email": "user@example.com",
"platform": "tiktok",
"packagename": null,
"device": "emulator-5554",
"device_online": true,
"device_name": "sdk_gphone64_x86_64",
"logined": 1,
"logined_text": "logged_in",
"status": 0,
"status_text": "enabled",
"tags": ["batch-a", "vip"]
},
{
"id": 2,
"username": "another_user",
"email": null,
"platform": "tiktok",
"packagename": "com.zhiliaoapp.musically.clone1",
"device": "192.168.1.101:5555",
"device_online": false,
"device_name": "",
"logined": 0,
"logined_text": "not_logged_in",
"status": 1,
"status_text": "disabled",
"tags": []
}
],
"total": 2,
"page": 1,
"page_size": 20
}
}

การตอบกลับข้อผิดพลาด

สถานะ HTTPโค้ดคำอธิบาย
40340301ถูกปฏิเสธ — การเข้าถึง API ต้องใช้แพ็กเกจ Pro+
50050001ข้อผิดพลาดภายในเซิร์ฟเวอร์