NAV

Searching for Split Orders

Sometimes, when an order is replaced or is split into multiple orders, the provider is set to whiplash:XXXX. You may filter by these as well. 

We use many of these internally, but the following may be helpful:

whiplash:replace - The order was replaced--either as an Exchange, because the original failed to arrive at its destination, or because there was a problem with the order. The original order retains its original originator_id.
whiplash:separate - An order was created by splitting an item from an existing order. The original order retains its original originator_id.
whiplash - This will grab the above two providers, as well any order that was created manually in whiplash.

NOTE: Orders with a whiplash provider will typically have an originator_id pointing to a whiplash order.

Originator Group

While you will typically look up orders via their Whiplash id or their originator_id, occasionally one order will be split into several orders, will be exchanged, or will be replaced. In this case, all of the new orders will have been originated by the first, and their originator_group_id will be the original order's Whiplash id.

Split will not have an originator_id. And their provider will be whiplash:separate

Additionally, replacement and separated orders will have a distinct proto_originator_id field. This is the replacement or separated order's original order id in your system.

If you are using the v2 API, you can pull in an order and all of its descendant split orders like:

https://www.getwhiplash.com/api/v2/orders?search={"originator_group_id_eq":"123", "originator_original_id_eq": "123", "m": "or"}

If you are using the v1 API, you will need to requests to get the order and its descendants:

https://www.getwhiplash.com/api/v1/orders/originator/123 # the original order
https://www.getwhiplash.com/api/v1/orders?originator_group=123 # its descendants

Last updated Aug 11th, 2017