Having shipping status / tracking info per line item

Hi,

If we’re going to need to have separate shipping statuses and tracking numbers for each (or group of) line item?
E.g. if we send a few shipments per order (let’s say one shipment includes one or more line items) and we would like to update each line item shipping status separately.

I see we could achieve that by using /order/X/split - and then a “chunk” of the order may have its own shipping status, tracking info etc.
But I wonder maybe there are better ways to do that?

Thanks,
Serge

Ordoro only allows 1 tracking per order at this time. In order to have multiple trackings that are saved or written back, you’ll have to split.

Thank you for the quick reply, Sophie.

Now I’m trying to understand to order split works with API…

  1. Split order/{order_id}/split that returns IDs of new orders I guess.

Then I’d like to gather all the shipments related to the original order.

  1. I see POST to order/parent_order/{parent_order_id} and it’s not clear what’s the purpose of that endpoint… we set parent order ID to … what?

In short, I wonder how to get info about all the “child” orders after split.

To get the orders, you’ll just make a GET request to the order ids that are returned from the /order/{order_id}/split endpoint. Is that what you’re asking, or are you expecting a single call to give you all you need?

Once orders are split, you’ll want to treat them as their own orders. The reference is there for a parent order, but no actions can be taken on the parent, it’s essentially frozen at the point of splitting.

So, if I understood it correctly:

I should “store” split Order IDs on my side and there is no way to get “organized data structure with relations between parent and child orders” via API once split is done.

Is that a correct statement?

In the order response data there is are three keys that you can use to reference information regarding split orders:

  "is_order_parent"
  "parent_order_number"
  "sibling_order_numbers"

@sophie to what entity your answer points?
I don’t see any fields you mentioned in an Order entity schema Ordoro v3 Orders API · Apiary

P.S. I mean I see you point to the Order entity, but it does not have any of those properties

I see that the response object on the Order schema appears to be missing some information.

I looked at an order response and these items are visible. I’m looking into what the issue is with our documentation now.

1 Like

Ah, taking a look at the order’s response and clicking on show JSON Schema, i am able to see the keys mentioned, but they don’t seem to be showing up in the example response.

We are currently working on updating our documentation to make things more easy and unified. For now, this is what we have to offer, so I hope my information here helps you out for at least this parent/sibling order information you’re seeking.

Let me know if you need anything else here.

@sophie thank you that should help!

so, just to make sure I understood in correctly, any order should have those 3 fields you mentioned as Null or Object and we could rely on them to keep the data integrity.

Yes, that should be the case, we try to ensure our response objects contain the same general shapes even if there is no data to populate.

Example: if the order has not been split, the response would be something like this:

is_order_parent: false,
parent_order_number: <this same order number>
sibling_order_numbers: []
1 Like

That fills the gap and solves the problem, thank you @sophie !