Provider API ที่รองรับ PerfectPanel

เชื่อมต่อ Panel ของคุณกับ WOWLIKE

เอกสารพร้อมใช้งานจริงสำหรับดึงบริการ สร้างออเดอร์ ติดตามการทำงาน ขอ cancel และตรวจสอบยอดคงเหลือสกุลเงินบาท

HTTP method
POST
API endpoint
https://wowlike-th.com/api/v2
Alias ที่รองรับ
https://wowlike-th.com/api/v1
รูปแบบ response
JSON

เริ่มต้นใช้งาน

เชื่อมต่อให้สำเร็จใน 3 ขั้นตอน

ใช้ API URL และ key เดียวกันได้ทั้งใน PerfectPanel และ client ที่รองรับรูปแบบ SMM Panel API มาตรฐาน

  1. 1

    สร้าง API key

    สร้างบัญชีแล้วไปสร้าง API key จากหน้าโปรไฟล์ ระบบจะแสดง key แบบเต็มเพียงครั้งเดียว

  2. 2

    ตั้งค่า Panel

    เพิ่ม API endpoint เป็น Provider URL ใน PerfectPanel แล้ววาง WOWLIKE API key

  3. 3

    ทดสอบการเชื่อมต่อ

    เรียกดูยอดคงเหลือก่อนดึงบริการ หากได้รับยอดเงินแบบ JSON แสดงว่าเชื่อมต่อสำเร็จ

ใช้ https://wowlike-th.com/api/v2 เป็น endpoint หลัก หากแผงของผู้ให้บริการเชื่อมต่อผ่าน API รุ่น 1 ให้ใช้ https://wowlike-th.com/api/v1 ได้ โดยทั้งสอง endpoint ใช้ API key เดียวกันและให้ข้อมูลบริการชุดเดียวกัน

bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=balance"

ความปลอดภัย

ยืนยันตัวตนในทุก request

ส่ง API key ใน form field ชื่อ key ระบบจะใช้ key เพื่อระบุบัญชีสมาชิก ราคา กระเป๋าเงิน และออเดอร์ของ request นั้น

อายุการใช้งานของ key

แต่ละบัญชีมี API key ที่ใช้งานได้หนึ่งชุด การหมุนหรือเพิกถอนจะทำให้ key เดิมใช้ไม่ได้ทันที และ WOWLIKE เก็บไว้เฉพาะ cryptographic hash

Rate limit

คำขออ่านข้อมูลรองรับ 120 ครั้งต่อนาที ส่วน add และ cancel รองรับ 30 ครั้งต่อนาที โดยจำกัดตามสมาชิกและ IP ต้นทาง

เก็บ key เป็นความลับ เก็บไว้ใน server-side secret หรือ environment variable เท่านั้น ห้ามใส่ใน JavaScript ฝั่ง browser, repository สาธารณะ, ภาพหน้าจอ หรือข้อความซัพพอร์ต

SERVICES

รายการบริการ

ดึงบริการและราคาตามสิทธิ์สมาชิกที่บัญชีนี้สามารถสั่งซื้อได้ในขณะนั้น

POSThttps://wowlike-th.com/api/v2action=services
พารามิเตอร์ชนิดข้อมูลคำอธิบาย
keystringWOWLIKE member API key ส่วนตัวของคุณ
action"services"ต้องเป็นค่า services เท่านั้น
bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=services"

ตัวอย่าง response

json
[
  {
    "service": 123,
    "name": "ผู้ติดตาม Instagram — เสถียร",
    "nameEn": "Instagram followers — stable",
    "descriptionEn": "Stable delivery with refill support.",
    "type": "Default",
    "rate": 42,
    "min": 100,
    "max": 10000,
    "dripfeed": false,
    "refill": true,
    "cancel": true,
    "category": "บริการ Instagram ประเทศไทย",
    "categoryEn": "บริการ Instagram ประเทศไทย"
  },
  {
    "service": 124,
    "name": "ความคิดเห็นกำหนดเอง",
    "nameEn": "Custom comments",
    "descriptionEn": null,
    "type": "Custom Comments",
    "rate": 85,
    "min": 10,
    "max": 1000,
    "dripfeed": false,
    "refill": false,
    "cancel": false,
    "category": "บริการ Instagram ประเทศไทย",
    "categoryEn": "บริการ Instagram ประเทศไทย"
  }
]

service คือ Service ID ถาวรที่ WOWLIKE จัดสรรเองและไม่อิงเลขของ Provider ส่วน category และ categoryEn เป็นชื่อกลุ่มบริการ, rate, min และ max เป็นตัวเลข JSON และ dripfeed, refill กับ cancel แสดงความสามารถจริงของบริการ

ทุกคำขอจะคืนราคาสมาชิก ขีดจำกัด และรายการบริการที่พร้อมใช้งานล่าสุดโดยไม่ใช้ response cache ระบบปลายทางสามารถ polling action services เพื่อซิงก์ข้อมูลได้ โดยความถี่และความสามารถในการเปิดสวิตช์ซิงก์ขึ้นอยู่กับ adapter ของระบบปลายทาง

ADD

สร้างออเดอร์

สร้างออเดอร์สำหรับบริการที่เผยแพร่ และหักยอดกระเป๋าสมาชิกตามราคาของบัญชีในขณะนั้น

POSThttps://wowlike-th.com/api/v2action=add
พารามิเตอร์ชนิดข้อมูลคำอธิบาย
keystringWOWLIKE member API key ส่วนตัวของคุณ
action"add"ต้องเป็นค่า add เท่านั้น
serviceintegerเลขบริการถาวรที่ได้รับจาก action services
linkURLURL สาธารณะของหน้า โพสต์ โปรไฟล์ หรือสื่อที่เป็นเป้าหมาย
quantityintegerต้องส่งสำหรับบริการ Default โดยจำนวนต้องอยู่ระหว่างค่าต่ำสุดและสูงสุดของบริการ
commentsstringต้องส่งสำหรับบริการ Custom Comments โดยใส่หนึ่งความคิดเห็นต่อหนึ่งบรรทัด ระบบจะคำนวณ quantity จากบรรทัดที่ไม่ว่าง

บริการ Default

bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=add" \
  -d "service=123" \
  --data-urlencode "link=https://example.com/post" \
  -d "quantity=1000"

บริการ Custom Comments

bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=add" \
  -d "service=124" \
  --data-urlencode "link=https://example.com/post" \
  --data-urlencode $'comments=ความคิดเห็นแรก\nความคิดเห็นที่สอง'
json
{
  "order": 9001
}

สำหรับ Custom Comments ไม่ต้องส่ง quantity ให้ส่ง comments แบบหนึ่งความคิดเห็นต่อหนึ่งบรรทัด ระบบจะตัดบรรทัดว่างและใช้จำนวนบรรทัดที่เหลือเป็นจำนวนสั่งซื้อ

ควร retry หลัง transport failure เมื่อแน่ใจว่าไม่ได้รับเลขออเดอร์เท่านั้น หาก integration ต้อง retry แบบป้องกันออเดอร์ซ้ำอย่างสมบูรณ์ ให้ใช้ REST order endpoint

STATUS

ตรวจสอบสถานะออเดอร์

ตรวจสอบออเดอร์หนึ่งรายการหรือสูงสุด 100 รายการที่เป็นของเจ้าของ API key

POSThttps://wowlike-th.com/api/v2action=status
พารามิเตอร์ชนิดข้อมูลคำอธิบาย
keystringWOWLIKE member API key ส่วนตัวของคุณ
action"status"ต้องเป็นค่า status เท่านั้น
orderintegerเลขออเดอร์ WOWLIKE หนึ่งรายการ ห้ามส่งพร้อม orders
ordersstringเลขออเดอร์คั่นด้วยจุลภาค สูงสุด 100 รายการ ห้ามส่งพร้อม order

ส่ง order หรือ orders อย่างใดอย่างหนึ่งเท่านั้น Response ของหลายออเดอร์จะใช้เลขออเดอร์ที่ขอเป็น key

bash
# ออเดอร์เดียว
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" -d "action=status" -d "order=9001"

# หลายออเดอร์
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" -d "action=status" -d "orders=9001,9002"
json
{
  "9001": {
    "charge": "42",
    "start_count": "1250",
    "status": "In progress",
    "remains": "600",
    "currency": "THB"
  },
  "9002": {"error": "Incorrect order ID"}
}

ค่าสถานะ

สถานะคำอธิบาย
Pendingระบบรับออเดอร์แล้วและกำลังรอส่งหรือเริ่มประมวลผล
Processingส่งออเดอร์แล้วและ Provider กำลังเตรียมดำเนินการ
In progressกำลังเพิ่มยอดให้กับออเดอร์
Completedส่งมอบครบตามจำนวนที่สั่ง
Partialส่งมอบบางส่วนและคืนเงินสำหรับส่วนที่ไม่สำเร็จแล้ว
Canceledออเดอร์ถูกยกเลิกหรือล้มเหลว และคืนยอดที่เกี่ยวข้องแล้ว

CANCEL

ขอ cancel ออเดอร์

ส่งคำขอ cancel ออเดอร์ที่ยังทำงานและบริการระบุ cancel: true ได้สูงสุด 100 รายการ

POSThttps://wowlike-th.com/api/v2action=cancel
พารามิเตอร์ชนิดข้อมูลคำอธิบาย
keystringWOWLIKE member API key ส่วนตัวของคุณ
action"cancel"ต้องเป็นค่า cancel เท่านั้น
ordersstringเลขออเดอร์ที่ต้องการ cancel คั่นด้วยจุลภาค สูงสุด 100 รายการ
bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=cancel" \
  -d "orders=9001,9002"
json
[
  {"order": 9001, "cancel": 1},
  {"order": 9002, "cancel": {"error": "Error calling provider"}}
]

cancel: 1 หมายถึงระบบรับคำขอแล้ว แต่อาจยังรอ Provider หรือทีม WOWLIKE ดำเนินการ กรุณาตรวจสถานะออเดอร์ต่อจนได้ผลลัพธ์สุดท้าย

BALANCE

ยอดคงเหลือสมาชิก

คืนยอดเงินที่ใช้ได้ในกระเป๋าสมาชิกเป็น decimal string สกุล THB

POSThttps://wowlike-th.com/api/v2action=balance
พารามิเตอร์ชนิดข้อมูลคำอธิบาย
keystringWOWLIKE member API key ส่วนตัวของคุณ
action"balance"ต้องเป็นค่า balance เท่านั้น
bash
curl -X POST "https://wowlike-th.com/api/v2" \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "key=$WOWLIKE_API_KEY" \
  -d "action=balance"
json
{
  "balance": "1250.7500",
  "currency": "THB"
}

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

ข้อผิดพลาดมีรูปแบบ JSON ที่แน่นอน

Response แบบ PerfectPanel จะส่ง field error แทนข้อมูลสำเร็จ ส่วน bulk action จะแจ้ง error เฉพาะออเดอร์นั้นเพื่อให้ออเดอร์อื่นยังทำงานต่อได้

ข้อผิดพลาดความหมาย
Invalid API keyไม่มี key, รูปแบบผิด, ถูกเพิกถอน หรือไม่ตรงกับสมาชิกที่ใช้งานอยู่
Too many requestsเกินขีดจำกัดคำขออ่านข้อมูลหรือแก้ไขข้อมูลในช่วงเวลาปัจจุบัน
Invalid request parametersไม่มี action หรือพารามิเตอร์ที่จำเป็น หรือรูปแบบข้อมูลไม่ถูกต้อง
Service not foundไม่พบเลขบริการสาธารณะหรือบริการไม่พร้อมใช้งาน
Incorrect order IDไม่พบออเดอร์หรือออเดอร์เป็นของสมาชิกบัญชีอื่น
Insufficient balanceยอดเงิน THB ในกระเป๋าไม่เพียงพอ
Invalid quantityจำนวนต่ำกว่าขั้นต่ำหรือสูงกว่าขั้นสูงของบริการ
Error calling providerบริการหรือสถานะออเดอร์ปัจจุบันไม่รองรับการ cancel
API ใช้ error contract แบบ MeeLike โดย key ไม่ถูกต้องหรือ business error ของออเดอร์ตอบ HTTP 200 พร้อม field error, request validation ตอบ HTTP 400 พร้อม status, message, timestamp และ path, method ที่ไม่รองรับตอบ HTTP 404 และ OPTIONS ตอบ HTTP 204

PHP

ตัวอย่าง PHP แบบเต็ม

Client ตัวอย่างนี้เปิดการตรวจ TLS ใช้ connection/request timeout และ throw exception เมื่อ API ส่งข้อผิดพลาดกลับมา

php
<?php
final class WowlikeApi {
    public function __construct(
        private string $apiUrl,
        private string $apiKey,
    ) {}

    public function call(string $action, array $parameters = []): array {
        $handle = curl_init($this->apiUrl);
        curl_setopt_array($handle, [
            CURLOPT_POST => true,
            CURLOPT_RETURNTRANSFER => true,
            CURLOPT_POSTFIELDS => http_build_query([
                'key' => $this->apiKey,
                'action' => $action,
                ...$parameters,
            ]),
            CURLOPT_CONNECTTIMEOUT => 10,
            CURLOPT_TIMEOUT => 30,
            CURLOPT_SSL_VERIFYPEER => true,
            CURLOPT_HTTPHEADER => ['Accept: application/json'],
        ]);
        $body = curl_exec($handle);
        if ($body === false) {
            throw new RuntimeException(curl_error($handle));
        }
        $result = json_decode($body, true, flags: JSON_THROW_ON_ERROR);
        if (isset($result['error'])) {
            throw new RuntimeException((string) $result['error']);
        }
        return $result;
    }
}

$api = new WowlikeApi('https://wowlike-th.com/api/v2', getenv('WOWLIKE_API_KEY'));
$services = $api->call('services');
$order = $api->call('add', [
    'service' => 123,
    'link' => 'https://example.com/post',
    'quantity' => 1000,
]);
$commentOrder = $api->call('add', [
    'service' => 124,
    'link' => 'https://example.com/post',
    'comments' => "First comment\nSecond comment",
]);
$status = $api->call('status', ['order' => $order['order']]);
$statuses = $api->call('status', ['orders' => '9001,9002']);
$cancellations = $api->call('cancel', ['orders' => '9001,9002']);

REST API

REST API สำหรับงานขั้นสูง

ใช้ REST interface สำหรับ server integration ที่ต้องการ HTTP status code, response envelope แบบคงที่ และการสร้างออเดอร์ที่ retry ได้โดยไม่ซ้ำ

เมธอดEndpointการใช้งาน
GET/api/v1/member/servicesดูบริการที่พร้อมใช้งาน
GET/api/v1/member/balanceดูยอดกระเป๋าเงิน
POST/api/v1/member/ordersสร้างออเดอร์แบบป้องกันรายการซ้ำ
GET/api/v1/member/orders/{orderNumber}ดูออเดอร์หนึ่งรายการ
bash
curl "https://wowlike-th.com/api/v1/member/services?locale=th" \
  -H "Authorization: Bearer $WOWLIKE_API_KEY"

curl -X POST "https://wowlike-th.com/api/v1/member/orders" \
  -H "Authorization: Bearer $WOWLIKE_API_KEY" \
  -H "Idempotency-Key: merchant-order-2026-0001" \
  -H "Content-Type: application/json" \
  -d '{"serviceId":123,"targetUrl":"https://example.com/post","quantity":1000}'

Bearer authentication

ส่ง member key เดียวกันใน Authorization: Bearer <key> โดย REST endpoint จะตอบ HTTP 401, 403, 422 หรือ 429 ตามข้อผิดพลาด

Retry อย่างปลอดภัย

ทุกคำขอสร้างออเดอร์ผ่าน REST ต้องมี Idempotency-Key ที่ไม่ซ้ำและยาวไม่เกิน 200 ตัวอักษร การส่ง key เดิมซ้ำจะคืนออเดอร์เดิมโดยไม่หักเงินซ้ำ

Success envelope

json
{
  "success": true,
  "data": {},
  "error": null
}

ต้องการความช่วยเหลือในการตรวจ integration หรือพบ response ที่ไม่คาดคิด? ติดต่อซัพพอร์ต