Retrieve the 灵蛇AI Platform Order List
Returns the account's top-up orders in pages, suitable for finding order IDs, checking payment statuses, and reconciliation.
¶ Preparation
Create an Account Token, and obtain the current account UUID from GET /api/v1/platform-tokens/me/.
export PLATFORM_TOKEN='your account token'
export USER_ID='your account UUID'
¶ API Overview
| Item | Content |
|---|---|
| Method | GET |
| URL | https://opensnake.platform.acedata.cloud/api/v1/orders/ |
| Auth | Account Token; OAuth token requires orders:read |
| Pagination | count + items |
Regular users must provide their own user_id; otherwise, pagination may return 403 when it encounters objects they are not authorized to access.
¶ Query Parameters
| Parameter | Type | Required for Regular Users | Description |
|---|---|---|---|
user_id |
UUID | Yes | Account to which the order belongs; supports repeated parameters |
pay_way |
string | No | Filter by payment method; supports repeated or comma-separated values |
state |
string | No | Filter by status; supports repeated or comma-separated values |
created_at_from/to |
datetime | No | Creation time range |
finished_at_from/to |
datetime | No | Completion time range |
limit / offset |
integer | No | Pagination |
ordering |
string | No | created_at, -created_at, finished_at, or -finished_at |
The current list does not support filtering by application_id, service_id, package_id, payment_method, or tag; the payment method field name is pay_way.
curl --get 'https://opensnake.platform.acedata.cloud/api/v1/orders/' \
--data-urlencode "user_id=${USER_ID}" \
--data-urlencode 'state=Paid,Finished' \
--data-urlencode 'pay_way=Stripe' \
--data-urlencode 'limit=100' \
-H "Authorization: Bearer ${PLATFORM_TOKEN}"
¶ Response Description
The response is {count, items}. Online list items include id, user_id, application_id/application_ids, package_id/package_ids, price, amount, discount, remaining_amount, state, pay_way, pay_id, pay_url, finished_at, expired_at, invoice, metadata, and time fields.
- Actual statuses are
Pending,Paid,Finished,Expired,Failed, andRefunded; there is noCancelled. - The field names are
pay_way,finished_at,discount, andprice, notpayment_method,paid_at,discount_rate, orfinal_price. priceis the final price recorded for the order; currency and settlement details may be located in controlled metadata and cannot be inferred solely from the payment method.
¶ Related APIs
¶ Order Summary and CSV Export
GET /api/v1/orders/summary/returns the number of orders, the amount of valid completed orders, and counts for each status.GET /api/v1/orders/export/returns a CSV, with columns for order ID, description, amount, status, payment method, and creation time.
Both APIs require orders:read. user_id may be omitted, left empty, or set to me, all of which indicate the current account; you may also explicitly provide your own UUID. Querying other accounts additionally requires the orders:read:any administrative permission. An OAuth token must include the corresponding scope as well; administrator identity does not bypass OAuth scopes. Duplicate or invalid user_id returns 400, and unauthorized access to other accounts returns 403.
Filtering by state, pay_way (repeated parameters or comma-separated values), and created_at_from/to dates is supported. The account scope for summaries and exports is the same.
Each CSV can contain up to 5,000 records. Exceeding the limit returns 400 and order_export_too_large; please narrow the date range or filter conditions. Results will not be silently truncated. The X-Export-Row-Count in a successful response indicates the number of exported rows.
Only one export can be generated for the same account at a time, and at most 10 exports are accepted per rolling hour (including requests that exceed the row limit); different tokens share the quota. Exceeding the limit or having an export already in progress returns 429; retry after the number of seconds specified by Retry-After. When exports are temporarily unavailable, 503 is returned. The platform records only the export operation and result metadata, and does not store the CSV body in audit records.