Get Bulk Order History
The Get Bulk Order History endpoint is designed to retrieve historical order data in bulk. This endpoint is ideal for fetching extensive order records over a specified period, enabling you to access past orders for analysis, reporting, or record-keeping purposes. This is especially useful for tracking customer trends, reviewing operational performance, and ensuring data completeness across external systems.
Query parameters
Starting date of the date range. The date should be in ISO 8601 standard, which also has a time and time zone component.
End date of the date range. The date should be in ISO 8601 standard, which also has time and time zone component.
Status of the orders to be retrieved by a partner. If the status is set to 'COMPLETED, CANCELED' or null, the API returns completed and cancelled orders.
The page the resultset needs to extract. If the resultset has more than one page, the user can set the page number in the URL to fetch only that results page. Note:- user should set the page as '0' since the URL for the next resultset is included in the response body.
Maximum size of the result for one page. This value can be set up to 10,000.*
Grubtech location ID to filter the orders.
[ "16da4eb46d3f307b8ace32cf", "62da4d936d3f307b8ace12ce" ]
Response
Successful response with requested order list.
Example response
{
"_links": {
"first": {
"href": "http://api.staging.grubtech.io/order-api/orders?fromDate=2021-11-04T10:14:30.000000Z&toDate=2021-11-05T10:15:30.000000Z&status=COMPLETED&page=0&size=1"
},
"self": {
"href": "http://api.staging.grubtech.io/order-api/orders?fromDate=2021-11-04T10:14:30.000000Z&toDate=2021-11-05T10:15:30.000000Z&status=COMPLETED&page=0&size=1"
},
"prv": {
"href": "http://api.staging.grubtech.io/order-api/orders?fromDate=2021-11-04T10:14:30.000000Z&toDate=2021-11-05T10:15:30.000000Z&status=COMPLETED&page=0&size=1"
},
"next": {
"href": "http://api.staging.grubtech.io/order-api/orders?fromDate=2021-11-04T10:14:30.000000Z&toDate=2021-11-05T10:15:30.000000Z&status=COMPLETED&page=0&size=1"
},
"last": {
"href": "http://api.staging.grubtech.io/order-api/orders?fromDate=2021-11-04T10:14:30.000000Z&toDate=2021-11-05T10:15:30.000000Z&status=COMPLETED&page=0&size=1"
}
},
"_embedded": {
"orders": [
{
"id": "703546147070869504",
"storeId": "a9f3ded6-c10b-4f17-ad42-5788e061b0a6",
"displayId": "4212331",
"currencyCode": "AED",
"instructions": "Please readuce the bag count of the order",
"delivery": {
"pickupTime": "2021-01-01T09:23:54.723Z"
},
"archivedItems": [
{
"price": {
"unitPrice": 1200,
"discountAmount": 1200,
"totalPrice": 1200
},
"amendItems": [
{
"quantity": 10
}
]
}
],
"scheduledOrder": {
"scheduledAt": "2020-08-02T09:23:54.723Z"
},
"placedAt": "2020-08-02T09:23:54.723Z"
}
]
}
}