We are working on migrating to the new fulfillment Order API route due to the fulfillment deprecations.
Using API version - 2022-10
For Rest API
I am working with the REST API and it looks like you can only add one tracking number per fulfillment. The old create Fulfillment API supported adding more than one tracking number to a single fulfillment by using the tracking number array.
With this new workflow we are only provided the ‘tracking info’ attribute. This would result in us not being able to provide the end user with all applicable tracking numbers that they would need.
For Graph QL Mutation
I also try to work with graph QL mutation but it is only taking one tracking number per fulfillment . You can also see the example given below when we hit this mutation then it will only take one number on Shopify. This would result in us not being to give Multiple tracking number for one fulfillment .
Thanks
Example given below
Example below to try to explain what I’m saying
Rest API request Body:-
{ “fulfillment”: { “tracking_info”: { “number”: “1245” }, “line_items_by_fulfillment_order”: [ { “fulfillment_order_id”: 1469493, “fulfillment_order_line_items”: [ { “id”: 1, “qty”: 1 } ] } ] } }
Example below to try to explain what I’m saying
Graph QL Mutation API body:-
mutation { fulfillmentCreateV2(fulfillment: {
lineItemsByFulfillmentOrder: [
{
fulfillmentOrderId: “gid://shopify/FulfillmentOrder/123456”,
fulfillmentOrderLineItems: {
id: “gid://shopify/FulfillmentOrderLineItem/12315”,
quantity: 1
}
}
],
notifyCustomer: true,
trackingInfo: {
company: “other”,
number: “12312312”,
numbers: [
“12312312”,“147258”
]
}
},
message: “”
) {
fulfillment {
legacyResourceId
}
userErrors {
field
message
}
}
}