Hi,
I have an API endpoint which has 2 addons and returns the following result -
[
{
id: 163,
order_id: 286,
courier_id: 112,
ship_date: “2026-04-07”,
tracking_no: “CP6272”,
_shipments_to_events: [
{
id: 13,
created_at: 1777329976274,
shipments_id: 163,
status: “Picked Up”,
event_time: 1775566800000
},
{
id: 14,
created_at: 1777330031974,
shipment_id: 163,
shipments_id: 163,
status: “Out for Delivery”,
event_time: 1775652452000
},
{
id: 15,
created_at: 1777330071740,
shipment_id: 163,
shipments_id: 163,
status: “Delivered”,
event_time: 1775706493000
}
],
_shipments_to_couriers: {
id: 112,
courier: “Canada Post”,
code: “canada-post”
}
},
{
id: 164,
order_id: 286,
courier_id: 3,
ship_date: “2026-04-09”,
status: “”,
tracking_no: “DHL4321”,
_shipments_to_events: [
{
id: 16,
created_at: 1777330109238,
shipment_id: 164,
status: “Picked Up”,
event_time: 1775747640000
}
],
_shipments_to_couriers: {
id: 3,
courier: “DHL Express”,
code: “dhl”
}
}
]
and I would like to represent this in a nested List which should look like this
Ship Date: 2026-04-07
Courier: Canada Post
Tracking: CP6272Picked Up @ 1775566800000
Out for Delivery @ 1775652452000
Delivered @ 1775706493000Ship Date:2026-04-09
Courier: DHL Express
Tracking: DHL4321Picked Up @ 1775747640000
but what I getting is this -
where the index for the second list does not iterate through the array so I am getting the same results for both instances of the nested list.
I hope that this make sense and would appreciate any help.
Thanks
Steve



