订单
补单
服务支持时,已完成的订单可以补充。每个订单每 6 小时可补充一次,没有截止日期。refill_status 显示结果,被拒绝时还会显示原因。
https://notpanel.com/api/v3action=refill- 需要 API key
- 请求过于频繁
- 请求体:
application/x-www-form-urlencoded
参数
始终发送
keystring必需- 你的 API key。
actionstring必需refill必须是字面字符串 “refill”。
发送 order 或 orders。
orderinteger以下之一- 一个订单号。响应是一个对象,新的补充 ID 在
refill中。 ordersstring (CSV)以下之一- 最多 100 个以逗号分隔的订单号。响应是数组;每分钟 30 个订单 ID。
curl -X POST https://notpanel.com/api/v3 \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "key=YOUR_API_KEY&action=refill&order=1234567"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: "1234567",
}),
});
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": "1234567",
},
)
print(res.json())<?php
$body = http_build_query([
'key' => 'YOUR_API_KEY',
'action' => 'refill',
'order' => '1234567',
]);
$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));
将 YOUR_API_KEY 替换为 API 页面中的密钥。
{
"refill": 5501
}错误
- 404
{"error":"Order not found","error_code":"ORDER_NOT_FOUND","retryable":false}你的账户中没有这个订单。
- 409
{"error":"You can request a refill again after 2026-10-03T18:35:00.000Z","error_code":"REFILL_COOLDOWN","retryable":true,"details":{"time":"2026-10-03T18:35:00.000Z"}}不到 6 小时前已申请过补充。
details.time说明你何时可以再次询问。 - 409
{"error":"Refill is available after the order is completed","error_code":"REFILL_NOT_COMPLETED","retryable":true}订单仍在进行中。完成后才可补充。
何时可以补充
订单必须已完成或部分完成,服务必须支持补充(其 refill 标志为 true),且距上次补充请求至少已过 6 小时。订单完成后没有时间限制。对 order 的响应是补充 ID;status 中的 can_refill 和 refill_available_at 会提前告诉你。
多个订单
使用 orders 时,响应是每个订单一个条目的数组,每个条目包含补充 ID 或错误对象。一个订单的问题绝不会影响其他订单。最多 100 个 ID。
key=YOUR_API_KEY&action=refill&orders=1234567,1234568,1234577[
{
"order": 1234567,
"refill": 5501
},
{
"order": 1234568,
"refill": {
"error": "You can request a refill again after 2026-10-03T18:35:00.000Z",
"error_code": "REFILL_COOLDOWN",
"retryable": true,
"details": {
"time": "2026-10-03T18:35:00.000Z"
}
}
},
{
"order": 1234577,
"refill": {
"error": "Refill is available after the order is completed",
"error_code": "REFILL_NOT_COMPLETED",
"retryable": true
}
}
]refill_status
action=refill_status 返回一个补充或最多 100 个补充的状态。7 天内无人答复的补充会停止跟踪并显示为 Pending,因此不会阻止新的请求。
https://notpanel.com/api/v3action=refill_status发送 refill 或 refills
refillinteger以下之一- 一个补充 ID。
refillsstring (CSV)以下之一- 最多 100 个以逗号分隔的补充 ID。
响应字段
statusstring- 状态词。见下方状态值。
status_keystring- 状态的稳定小写形式。
orderinteger- 该补充所属的订单。
reason_codestring | null- 补充被拒绝的原因,或
null。 reasonstring | nullreason_code对应的固定英文句子,或null。created_atstring- 补充被申请的时间。
updated_atstring- 最后一次变化的时间。
key=YOUR_API_KEY&action=refill_status&refill=5501{
"status": "Completed",
"status_key": "completed",
"order": 1234567,
"reason_code": null,
"reason": null,
"created_at": "2026-10-03T12:35:00Z",
"updated_at": "2026-10-03T13:05:00Z"
}key=YOUR_API_KEY&action=refill_status&refills=5501,5502,9[
{
"refill": 5501,
"status": "Completed",
"status_key": "completed",
"order": 1234567,
"reason_code": null,
"reason": null,
"created_at": "2026-10-03T12:35:00Z",
"updated_at": "2026-10-03T13:05:00Z"
},
{
"refill": 5502,
"status": "Rejected",
"status_key": "rejected",
"order": 1234568,
"reason_code": "refill_too_early",
"reason": "This order cannot be refilled yet. Try again later.",
"created_at": "2026-10-03T12:40:00Z",
"updated_at": "2026-10-03T12:41:00Z"
},
{
"refill": 9,
"error": "Refill not found",
"error_code": "REFILL_NOT_FOUND",
"retryable": false
}
]状态值
- Pending
status_key=pendingPending— 已申请,或结果尚不明确。 - In progress
status_key=in_progressIn progress— 正在补充。 - Completed
status_key=completedCompleted— 补充已完成。 - Rejected
status_key=rejectedRejected— 补充被拒绝。reason_code说明原因。
拒绝原因
拒绝始终带有以下代码之一。请把未知代码当作通用拒绝处理:可能会新增代码。
原因代码与句子
refill_too_early- This order cannot be refilled yet. Try again later.
refill_daily_limit- Refills for today are used up. Try again tomorrow.
refill_not_completed- Refill is possible after the order is completed.
refill_not_eligible- This order cannot be refilled.
refill_refused- The refill was not accepted. Try again later.
补充错误
- 404
ORDER_NOT_FOUND
Order not found你的账户下没有此编号的订单。 请先修正请求。
- 409
REFILL_NOT_AVAILABLE
Refill is not available for this order此订单无法补充。 请先修正请求。
- 409
REFILL_NOT_COMPLETED
Refill is available after the order is completed订单完成后才可补充。 重试可能有帮助。
- 409
REFILL_COOLDOWN
You can request a refill again after {time}此订单最近已申请过补充。请在 details.time 之后再试。 重试可能有帮助。
- 409
REFILL_ALREADY_PENDING
A refill request is already in progress for this order此订单已有补充在进行中。 重试可能有帮助。
- 404
REFILL_NOT_FOUND
Refill not found你的账户下没有此 ID 的补充。 请先修正请求。