طلب إعادة تعبئة
ينشئ refill لطلب مؤهل حالته completed أو partial بعد فترة انتظار مدتها 24 ساعة. لا يوجد حد إجمالي للمحاولات، لكن لا يمكن أن يوجد أكثر من refill واحد بحالة pending أو processing أو قيد المراجعة في الوقت نفسه.
POST
https://notpanel.com/api/v3action=refillمفتاح API مطلوبمحدود بالمعدل (حساب مشترك + IP + إجراء)الجسم:
application/x-www-form-urlencodedالمعاملات
| الاسم | النوع | الوصف |
|---|---|---|
| keyمطلوب | string | مفتاح API الخاص بك. |
| actionمطلوب | string | يجب أن يكون السلسلة النصية الحرفية "refill". |
| order | string | ID لطلب واحد. استخدم order أو orders؛ وإذا أُرسلا معًا تكون الأولوية لـorders. |
| orders | string (CSV) | حتى 100 معرّف طلب مفصولة بفواصل لإعادة التعبئة دفعةً واحدة. يُرجع مصفوفة — يحمل كل صف إما معرّف إعادة تعبئة أو خطأً خاصاً بالطلب. |
مثال على الطلب
استبدل YOUR_API_KEY بالمفتاح المُولَّد ضمن صفحة API في لوحة تحكمك.
curl -X POST https://notpanel.com/api/v3 \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "key=YOUR_API_KEY&action=refill&order=7001"const res = await fetch("https://notpanel.com/api/v3", {
method: "POST",
headers: { "Content-Type": "application/x-www-form-urlencoded" },
body: new URLSearchParams({
key: "YOUR_API_KEY",
action: "refill",
order: "7001",
}),
});
const data = await res.json();
console.log(data);import requests
res = requests.post(
"https://notpanel.com/api/v3",
data={
"key": "YOUR_API_KEY",
"action": "refill",
"order": "7001",
},
)
print(res.json())<?php
$body = http_build_query([
'key' => 'YOUR_API_KEY',
'action' => 'refill',
'order' => '7001',
]);
$response = file_get_contents('https://notpanel.com/api/v3', false, stream_context_create([
'http' => [
'method' => 'POST',
'header' => "Content-Type: application/x-www-form-urlencoded\r\n",
'content' => $body,
'ignore_errors' => true,
],
]));
print_r(json_decode($response, true));
مثال على الاستجابة
{
"refill": 8001
}الأخطاء الشائعة
| الحالة | الجسم | السبب |
|---|---|---|
| 400 | {"error":"Order not found"} | معرّف الطلب غير موجود أو لا يخص حسابك. |
| 400 | {"error":"Refill only available for completed or partial orders"} | الطلب ليس في حالة completed أو partial. لا توجد حالة أخرى مؤهلة لـrefill. |
| 400 | {"error":"Service does not support refills"} | الخدمة الأساسية لها refill=false. راجع كتالوج الخدمات قبل تقديم طلبات إعادة التعبئة. |
| 400 | {"error":"A refill request is already pending for this order"} | انتظر تسوية إعادة التعبئة السابقة قبل إنشاء أخرى. |
| 400 | {"error":"Refill is available 24 hours after the order is completed"} | اكتمل الطلب منذ أقل من 24 ساعة. |