Order API - Get Orders
Get orders
Endpoint: GET *base*/orders?[&limit=5][&offset=5][&order=83651][&customer_id=1][&xml=1]
Authentication: API Key
This will fetch the orders allowed for the plugin being set up.
Price information returned by this endpoint depends on the plugin settings. Refer to the documentation for details.
Parameters
Limit amount of orders returned. Default: 20.
Offset how far in to start returning orders.
Return a specific order.
Return orders for specified customer id.
Return order newer than date. Allowed formats YYYY-mm-dd
and YYYY-mm-dd HH:MM:SS
. Timezone is system-wide and decided by the company using Centra.
Return order newer than date. Allowed formats YYYY-mm-dd
and YYYY-mm-dd HH:MM:SS
. Timezone is system-wide and decided by the company using Centra.
Response in xml format instead of json.
Request example
GET <base>/orders?newer_than=2019-01-01+12:11:39&limit=10 HTTP/1.1
Response
200
Content-type: application/json
ok
if success, else no
.
Array of orders returned.
ID of the order.
Status of the order.
Selection ID of the order.
Date when order was created.
Products inside the order.
ID of the specific product item in this order.
Quantity of this specific product item.
Approximated unit tax value for this specific product item.
Total tax value for this product item line.
Total price displayed before customer checkout
Total price without tax
Total price with tax
Flag showing if product is bundle
Bundle id
Array of containing items for bundle
The localized size information for this product size. It contains the localized size localizedSize
and localized size chart name localizationDefinitionName
.
Lists all tax rules applied to the order.
Text description of tax rule. ex: VAT
Percentage of tax. ex 25
How much tax. ex 20
Payment plugin type, e.g. adyen_drop_in
, klarna_checkout_v1
, paypal_v1
, etc.
Payment method type, one of: cc, inv, 3rd, free, prepaid. Where cc = credit card, inv = invoice, 3rd = third party. Value is not unique, more than one payment method can have
Payment method description from plugin configuration.
Payment reference ID from external service provider. Can be null.
Payment method ID - unique name of payment provider. Can be null.
Response example
HTTP/1.1 200 OK
Content-type: application/json
{
"status": "ok",
"orders": [
{
"orderId": "83651",
"selectionId": "7dee9426b07b13ec452f87a3b67aa6be",
"orderDate": "2012-02-04 15:16:13",
"cancelDate": "2012-08-04 15:16:13",
"preferredDeliveryDate": "2012-05-04 15:16:13",
"estimatedDeliveryDate": "2012-05-04 15:16:13",
"orderStore": "retail",
"orderCurrency": "EUR",
"customerId": "12345",
"accountId": "",
"deliveryName": "Someones Name",
"deliveryCompany": "",
"deliveryEmail": "deliveries@example.com",
"deliveryCell": "+4912345678",
"deliveryTele": "",
"deliveryAddress": "Examplestreet 1",
"deliveryCoaddress": "",
"deliveryZipcode": "12345",
"deliveryCity": "Somecity",
"deliveryState": "",
"deliveryCountry": "DE",
"billingName": "Someones Name",
"billingCompany": "",
"billingEmail": "billing@example.com",
"billingTele": "",
"billingAddress": "Examplestreet 1",
"billingCoaddress": "",
"billingZipcode": "12345",
"billingCity": "Somecity",
"billingState": "",
"billingCountry": "DE",
"billingVAT": "",
"poNumber": "",
"shippingList": "standard",
"suspect": 0,
"internalOrder": 0,
"hold": 0,
"waitingForPayment": 0,
"shippingValue": 25,
"voucherValue": 0,
"grandTotalValue": 3978.75,
"grandTotalTaxValue": 795.75,
"taxAdded": 0,
"taxDeducted": 0,
"internalComment": "",
"otherComment": "",
"marketId": 1,
"pricelistId": 1,
"ipAddress": "127.0.0.1",
"paymentPlugin": "klarna_checkout_v1",
"paymentType": "free",
"paymentDescription": "Klarna checkout v3",
"paymentReference": "12345678-1234-1234-864e-6ef2621c4ab6",
"paymentMethod": "klarna",
"defaultCarrier": "",
"shipments": [
{
"shipmentId": "16-1",
"shippedDate": "0000-00-00 00:00:00",
"carrier": "",
"service": "",
"trackingId": "",
"trackingUrl": "",
"returnSlipTracking": "",
}
],
"totalItemsPriceTax": -202.88,
"totalItemsPrice": 811.5,
"totalItemsWithoutTax": 608.62,
"taxBreakdown": [
{
"description": "VAT",
"taxPercent": 25,
"value": 795.75
}
],
"products": [
{
"lineId": "43243",
"sku": "S123K345U1",
"variantSku": "",
"sizeSku": "",
"ean": "1234567890123",
"upc": "123456",
"name": "Product #1",
"variant": "White",
"brand": "Brand",
"size": "XS",
"qty": 1,
"originalPrice": 500.5,
"price": 450.5,
"weight": 2,
"weightUnit": "kg",
"countryOfOrigin": "DE",
"harmCode": "12345",
"comment": "",
"otherComment": "",
"taxPercent": 0,
"priceDiscount": 50.0,
"priceDiscountAsPercent": 0,
"taxValue": 112.63,
"totalTaxValue": 112.63,
"totalPrice": 450.5,
"totalPriceWithoutTax": 337.87,
"totalPriceWithTax": 450.5,
"anyDiscount": false,
"priceEachWithoutTax": 337.87,
"priceEachReduction": 0,
"warehouses": [
{
"name": "Default",
"itemQty": 1
}
],
"isBundle": false,
"isPartOfBundle": "217"
},
{
"lineId": "43244",
"sku": "S123K345U2",
"variantSku": "",
"sizeSku": "",
"ean": "1234567890124",
"upc": "123456",
"name": "Product #2",
"variant": "Blue",
"brand": "Brand",
"size": "XS",
"qty": 2,
"originalPrice": 200.5,
"price": 180.5,
"weight": 1.5,
"weightUnit": "kg",
"countryOfOrigin": "CI",
"harmCode": "12345",
"comment": "",
"taxPercent": 25,
"priceDiscount": 0,
"priceDiscountAsPercent": 0,
"taxValue": 90.25,
"totalTaxValue": 180.50,
"totalPrice": 361,
"totalPriceWithoutTax": 180.5,
"totalPriceWithTax": 361,
"anyDiscount": false,
"priceEachWithoutTax": 270.75,
"priceEachReduction": 0,
"warehouses": [
{
"name": "Default",
"itemQty": 2
}
],
"isBundle": true,
"bundle": [
{
"lineId": "43243",
"sku": "S123K345U1",
"variantSku": "",
"sizeSku": "",
"ean": "1234567890123",
"upc": "123456",
"name": "Product #1",
"variant": "White",
"brand": "Brand",
"size": "XS",
"qty": 1,
"originalPrice": 500.5,
"price": 450.5,
"weight": 2,
"weightUnit": "kg",
"countryOfOrigin": "DE",
"harmCode": "12345",
"comment": "",
"otherComment": "",
"taxPercent": 0,
"priceDiscount": 50.0,
"priceDiscountAsPercent": 0,
"taxValue": 112.63,
"totalTaxValue": 112.63,
"totalPrice": 450.5,
"totalPriceWithoutTax": 337.87,
"totalPriceWithTax": 450.5,
"anyDiscount": false,
"priceEachWithoutTax": 337.87,
"priceEachReduction": 0,
"warehouses": [
{
"name": "Default",
"itemQty": 1
}
],
"isBundle": false,
"isPartOfBundle": "217"
},
]
}
],
"totalItemsDiscount": 38.11,
"discounts": {
"anyDiscount": false,
"discount": "0.00 USD",
"discountAsNumber": 0,
"vouchers": [
{
"voucher": "vip123",
"name": "Some voucher",
"priceOff": "-150.00 USD",
"priceOffAsANumber": -150.0,
"description": "This is VIP code description",
"isCredit": false,
"originalPriceOff": "-150.00 USD",
"originalPriceOffAsNumber": -150.0
}
],
"automaticDiscounts": [
{
"automaticDiscount": "12345",
"name": "Some discount",
"priceOff": "0.00 USD",
"priceOffAsANumber": 0
}
]
}
}
]
}