Get Order Info by ID
The Get Order Info by ID method returns Order's details by the given Order ID.
GET /api/vendor/v1/orders/{id}.json?api_token={api_token}
Arguments
Name | Parameter Type | Data type | Required/ | Description |
---|---|---|---|---|
id | path | integer | Required | Order ID |
api_token | query | string | Required | API token of the manager who perform the operation (see API Token Authentication) |
Response model
Name | Data type | Description |
---|---|---|
id | integer | Order ID |
document_id | string | Order number |
status | string | Status of the Order. For the list of statuses, see Viewing order details |
account_id | integer | Account ID, which was used to pay for the order |
type | string | Order type. For the list of Order types, see Managing an order |
created_at | date | Date and time of the Order creation |
updated_at | date | Date and time when the Order was changed last time |
expiration_date | date | Date, by which the order must be paid (the Order status must be confirmed). The date is calculated using the grace period, which is set in the plan class (see Creating a service term in the ActivePlatform. Operator Control Panel) |
total | float | Total amount of the Order |
promo_code | string | Promo code, which was used to get the discount (see Managing promo codes in the ActivePlatform. Operator Control Panel) |
payment_id | integer | Payment ID, which is linked to the Order |
items | array | List of items in the Order:
|
charges | array | List of charges, which were created by the order:
|
Request example
GET http://billing.activeplatform.com:80/api/vendor/v1/orders/2010313.json?api_token=654321
Response example
{
"id": 2010313,
"document_id": "RN002936",
"status": "cancelled",
"account_id": 2000532,
"type": "RenewalOrder",
"created_at": "2016-08-12T16:32:20.964+03:00",
"updated_at": "2016-10-01T01:03:56.000+03:00",
"expiration_date": "2016-08-12",
"total": 230,
"promo_code": null,
"payment_id": 2006909,
"items": [
{
"id": 16562,
"target_id": 2005882,
"target_type": "Subscription",
"type": "ProvisioningItem::Renew",
"status": "cancelled",
"description": "Fusion Manager"
}
],
"charges": [
{
"id": 754094,
"subscription_id": 2005882,
"subscription_resource_id": null,
"subscription_resource_name": null,
"plan_resource_id": null,
"resource_id": null,
"quantity": 1,
"operate_from": "2016-09-30",
"operate_to": "2017-07-30",
"duration": 1,
"description": "Renewal subscription (setup fee) #2005882 \"Service\"",
"unit_price": 30,
"amount": 30,
"status": "deleted",
"type": "Charge::Setup",
"order_id": 2010313,
"close_date": "2016-09-30",
"created_at": "2016-08-12T16:32:21.051680+0300",
"updated_at": "2016-10-01T01:03:56.349595+0300"
},
{
"id": 754105,
"subscription_id": 2005882,
"subscription_resource_id": null,
"subscription_resource_name": null,
"plan_resource_id": null,
"resource_id": null,
"quantity": 1,
"operate_from": "2017-07-15",
"operate_to": "2017-07-30",
"duration": 0.484,
"description": "Renewal subscription (recurring fee) #2005882 \"Service\"",
"unit_price": 20,
"amount": 9.68,
"status": "deleted",
"type": "Charge::Recurring",
"order_id": 2010313,
"close_date": "2017-07-30",
"created_at": "2016-08-12T16:32:21.570265+0300",
"updated_at": "2016-10-01T01:03:56.328776+0300"
}
]
}