FulfillmentOrder API - Add multiple tracking numbers without specifying line items

Hey Shopify community,

our app fulfills orders in Shopify via the Admin API. Previously we used the Fulfillments API but we are currently in the process of migrating to the FulfillmentOrder API. One thing we could do before is, that we could easily add mulitple sets of tracking information to a fulfillment via the tracking_numbers and tracking_urls without specifying which line items belonged to which tracking information. It seems this is not possible anymore with FulfillmentOrders since you can only add one tracking information per fulfillment and if you want to add multiple fulfillments you have to specify exactly which line items belong to which fulfillment.

Can somebody confirm what I am saying. Or, am I maybe overseeing something and multiple tracking infromation can still be added without the associations to the line items.

Help much appreciated. Thanks :slightly_smiling_face:

1 Like

Hey there,

Are you sure you can’t because I am almost 100% certain that I tried that exact use-case. I even supplied multiple tracking numbers for a single item using the new api 2023-01.

But I did use the graphql mutation fulfillmentCreateV2 and there you can include an array of tracking numbers and an array of tracking urls.

I just looked at the RestAPI and it appears that you can only supply a single trackingnumber and url.

Here the tracking info from the mutation:

"trackingInfo": {
      "company": "",
      "number": "",
      "numbers": [
        ""
      ],
      "url": "",
      "urls": [
        ""
      ]
    }

I would give it a try and see if you can submit the tracking_info for the rest api as follows:

"tracking_info":{
"company":"",
"numbers":[],
"urls":[]
}

Maybe the documentation is lagging behind.. or the rest api :wink: I will cross my fingers and hope that its the documentation. If not just “quickly” switch to the graphQL mutation for that one part of the fulfillment.

Cheers,

Gary