This is Documentation for the V1 API
V2 API docmentation is located at developers.getwhiplash.com/
Given an order ID, get a list of order items.
HTTP/1.1 200 OK [ { "id":1111, "item_id":2345, "order_id":1234, "package_id":4321, "packaging":false, "packed":0, "price":"88.0", "retail_fee":null, "wholesale_cost":null, "currency":"USD", "quantity":1, "sku":"TEST1234", "description":"Gray Dress Pant Yoga Pants (Straight-Leg) - X-Small Petite", "available":true, "returnable":null, "originator_id":"order_1234-item_1234", "provider":"api", "created_at":"2017-05-07T18:10:56-04:00", "updated_at":"2017-05-07T18:10:56-04:00", "serialnumbers":[], "misc":null } ]
Name | Type | Description |
---|---|---|
limit | Integer | The number of orders returned. Default is 50 |
offset/page | Integer | Page to show (defaults to 1) |
order_by | String | Order (defaults to updated_at DESC |
since_id | Integer | Restrict results to after the specified ID |
created_at_min | Datetime | Show orders created after date (format: 2008-01-01 03:00) |
created_at_max | Datetime | Show orders created before date (format: 2008-01-01 03:00) |
updated_at_min | Datetime | Show orders last updated after date (format: 2008-01-01 03:00) |
updated_at_max | Datetime | Show orders last updated before date (format: 2008-01-01 03:00) |
Get an order item by its Whiplash ID.
HTTP/1.1 200 OK { "id":1111, "item_id":2345, "order_id":1234, "package_id":4321, "packaging":false, "packed":0, "price":"88.0", "retail_fee":null, "wholesale_cost":null, "currency":"USD", "quantity":1, "sku":"TEST1234", "description":"Gray Dress Pant Yoga Pants (Straight-Leg) - X-Small Petite", "available":true, "returnable":null, "originator_id":"order_1234-item_1234", "provider":"api", "created_at":"2017-05-07T18:10:56-04:00", "updated_at":"2017-05-07T18:10:56-04:00", "serialnumbers":[], "misc":null }
Order items received via an e-commerce platform or our API also store the incoming ID as the originator_id. You can find and update using this ID as well.
HTTP/1.1 200 OK { "id":1111, "item_id":2345, "order_id":1234, "package_id":4321, "packaging":false, "packed":0, "price":"88.0", "retail_fee":null, "wholesale_cost":null, "currency":"USD", "quantity":1, "sku":"TEST1234", "description":"Gray Dress Pant Yoga Pants (Straight-Leg) - X-Small Petite", "available":true, "returnable":null, "originator_id":"order_1234-item_1234", "provider":"api", "created_at":"2017-05-07T18:10:56-04:00", "updated_at":"2017-05-07T18:10:56-04:00", "serialnumbers":[], "misc":null }
Note: You can only create order items for orders which are "processing" (status <= 100).
HTTP/1.1 200 OK { "id":1111, "item_id":2345, "order_id":1234, "package_id":4321, "packaging":false, "packed":0, "price":"88.0", "retail_fee":null, "wholesale_cost":null, "currency":"USD", "quantity":1, "sku":"TEST1234", "description":"Gray Dress Pant Yoga Pants (Straight-Leg) - X-Small Petite", "available":true, "returnable":null, "originator_id":"order_1234-item_1234", "provider":"api", "created_at":"2017-05-07T18:10:56-04:00", "updated_at":"2017-05-07T18:10:56-04:00", "serialnumbers":[], "misc":null }
Name | Type | Description |
---|---|---|
order_id | Integer | The order this order item belongs to (you can only switch to unshipped orders) (required) |
item_id | Integer | The item associated with this Order Item (required) |
sku | String | This is automatically set to the item's SKU |
description | String | This is automatically set to the item's description |
quantity | Integer | Number of this item in the order (required) |
price | Decimal | The cost PER ITEM of the order item |
currency | String | The 3-letter currency code that the order item is priced in (USD |
wholesale_cost | Decimal | What the item costs you--useful for your own analytics |
available | Boolean | Should we process orders for this item? (default is true) |
returnable | Boolean | Is this item eligible for returns? (default is null--this is typically used to override an item-level setting) |
packaging | Boolean | Is this item packaging only? (default is false) |
originator_id | String | The ID you use for this order item in your store |
misc | String | Miscellaneous information relating to the order item |
Note: You can only update order items for orders which are "processing" (status <= 100).
HTTP/1.1 204 OK
Name | Type | Description |
---|---|---|
order_id | Integer | The order this order item belongs to (you can only switch to unshipped orders) |
item_id | Integer | The item associated with this Order Item |
sku | String | This is automatically set to the item's SKU |
description | String | This is automatically set to the item's description |
quantity | Integer | Number of this item in the order |
price | Decimal | The cost PER ITEM of the order item |
currency | String | The 3-letter currency code that the order item is priced in (USD |
wholesale_cost | Decimal | What the item costs you--useful for your own analytics |
available | Boolean | Should we process orders for this item? (default is true) |
returnable | Boolean | Is this item eligible for returns? (default is null--this is typically used to override an item-level setting) |
packaging | Boolean | Is this item packaging only? (default is false) |
originator_id | String | The ID you use for this order item in your store |
misc | String | Miscellaneous information relating to the order item |
Note: You can only delete order items for orders which are "processing" (status <= 100).
HTTP/1.1 204 OK