QueryOrders
Queries the orders of users or reseller customers. By default, this operation queries orders created within the last hour. To query orders over a longer period, specify the CreateTimeStart and CreateTimeEnd parameters.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
bss:DescribeOrderList |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| CreateTimeEnd |
string |
No |
The end of the time range during which orders were created. By default, orders created within the last hour are queried. Specify the time in the ISO 8601 standard in the YYYY-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
2016-05-23T12:00:00Z |
| PageNum |
integer |
No |
The page number. |
1 |
| PageSize |
integer |
No |
The number of entries per page. |
20 |
| ProductCode |
string |
No |
The product code. |
rds |
| ProductType |
string |
No |
The product type. |
rds |
| SubscriptionType |
string |
No |
The subscription type. Valid values:
|
Subscription |
| OrderType |
string |
No |
The order type. Valid values:
|
New |
| PaymentStatus |
string |
No |
The payment status. For non-refund orders, valid values:
Note
For refund orders, this parameter can be set to NULL. |
Paid |
| CreateTimeStart |
string |
No |
The start of the time range during which orders were created. By default, orders created within the last hour are queried. Specify the time in the ISO 8601 standard in the YYYY-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
2016-05-23T13:00:00Z |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| Code |
string |
The status code. |
Success |
| Message |
string |
The error message. |
Successful! |
| RequestId |
string |
The request ID. |
61293E7A-3406-4447-8620-EC88B0AA66AD |
| Success |
boolean |
Indicates whether the request was successful. |
true |
| Data |
object |
The response data. |
|
| HostName |
string |
The hostname. |
test |
| PageNum |
integer |
The page number. |
1 |
| PageSize |
integer |
The number of entries per page. Set this parameter to a maximum of 20. A larger value may cause a timeout. |
20 |
| TotalCount |
integer |
The total number of entries. |
1 |
| OrderList |
object |
||
| Order |
array<object> |
The order list. |
|
|
object |
|||
| PretaxAmount |
string |
The payable amount before tax. |
0 |
| CommodityCode |
string |
The commodity code. |
ecs |
| RelatedOrderId |
string |
The ID of the associated order. |
234535345345342 |
| CreateTime |
string |
The creation time in the ISO 8601 standard in the YYYY-MM-DDTHH:mm:ssZ format. The time is in UTC. |
2017-06-08T09:41:30Z |
| Currency |
string |
The currency. |
CNY |
| SubscriptionType |
string |
The subscription type. Valid values:
|
PayAsYouGo |
| PaymentCurrency |
string |
The payment currency. |
CNY |
| ProductType |
string |
The primary product type. |
rds |
| AfterTaxAmount |
string |
The amount after tax. |
66 |
| PaymentTime |
string |
The payment time in the ISO 8601 standard in the YYYY-MM-DDTHH:mm:ssZ format. The time is in UTC. |
2017-06-08T09:41:30Z |
| PretaxGrossAmount |
string |
The gross amount before tax. |
0 |
| OrderType |
string |
The order type. Valid values:
|
New |
| PaymentStatus |
string |
The payment status. For non-refund orders, valid values:
Note
For refund orders, this parameter can be set to NULL. |
Paid |
| OrderId |
string |
The order ID. |
34532532 |
| Tax |
string |
The tax amount. |
1 |
| PretaxAmountLocal |
string |
The local currency amount before tax. |
0 |
| ProductCode |
string |
The primary product code. |
rds |
Examples
Success response
JSON format
{
"Code": "Success",
"Message": "Successful!",
"RequestId": "61293E7A-3406-4447-8620-EC88B0AA66AD",
"Success": true,
"Data": {
"HostName": "test",
"PageNum": 1,
"PageSize": 20,
"TotalCount": 1,
"OrderList": {
"Order": [
{
"PretaxAmount": "0",
"CommodityCode": "ecs",
"RelatedOrderId": "234535345345342",
"CreateTime": "2017-06-08T09:41:30Z",
"Currency": "CNY",
"SubscriptionType": "PayAsYouGo",
"PaymentCurrency": "CNY",
"ProductType": "rds",
"AfterTaxAmount": "66",
"PaymentTime": "2017-06-08T09:41:30Z",
"PretaxGrossAmount": "0",
"OrderType": "New",
"PaymentStatus": "Paid",
"OrderId": "34532532",
"Tax": "1",
"PretaxAmountLocal": "0",
"ProductCode": "rds"
}
]
}
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidOwner | The specified owner doesn't belong to caller. | Invalid user identity. |
| 500 | InternalError | The request processing has failed due to some unknown error. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.