Create an qiyaov Platform Recharge Order

Create pending payment orders for one or more Applications. Creation writes the order, but does not automatically complete payment; before payment, verify the price, package, and Application in the response.

Preparation

export PLATFORM_TOKEN='your account token'
export APPLICATION_ID='your Application ID'
export PACKAGE_ID='your Package ID'

API Overview

Item Content
Method POST
URL https://api17.platform.acedata.cloud/api/v1/orders/
Auth Account Token, OAuth token requires orders:write
Body JSON

Request Body

A single Application order uses application_id + package_id; a batch order uses application_ids + package_ids with corresponding lengths. pay_way is not required during the creation stage; the payment method is selected in the subsequent /pay/ request.

curl -X POST 'https://api17.platform.acedata.cloud/api/v1/orders/' \
  -H "Authorization: Bearer ${PLATFORM_TOKEN}" \
  -H 'Content-Type: application/json' \
  -d "{\"application_id\":\"${APPLICATION_ID}\",\"package_id\":\"${PACKAGE_ID}\"}"

Response Description

Success returns 201 and the newly created Order object. Key fields include id, price, discount, state, application_id/application_ids, package_id/package_ids, expired_at, and time fields. New orders are usually Pending, followed by calling Pay Order.

  • price is the payable amount calculated by the server based on the package, site markup, and discount; do not calculate it on the client side.
  • A 400 is returned when the Package does not match the Application service or type.
  • Free and system-managed Packages cannot be claimed through the public order API.
  • Creating an order for an Application that does not belong to the current account will be rejected.