fulfillment_orders returns 404 not found

Sebastian10
Shopify Partner
7 0 1

Our case got solved only months after writing countless emails with the Shopify Plus support back and forth.

In the end it was some issue with the shop site where something was in a weired state and could only be solved by Shopify directly.

At some point, this was a response from Shopify:

As a refresher, the issue was caused by stale location records preventing the X app from creating a fulfillment service, since the name X was already in use by the stale record. I'm not sure how/when the X app attempts to create a fulfillment service, so depending on the inner workings of the app it might require the app to be removed/reinstalled. That option is safe if there's no concern of losing data from within the app, but if this is a concern I recommend getting input from the X devs. As always, don't hesitate to reach out here if there's anything I can answer.

Not sure if that helps in anyway, but my point is, if you have the same issue as we do, @API_Dev , there's nothing you can do, but only someone at Shopify can solve the issue for you by removing this stale record manually.

If you are only working with a test/dev shop, you could also try to just set up a new shop.

0 Likes
_JB
Shopify Staff
Shopify Staff
834 98 183

@Sebastian10,

Thanks for sharing. Just want to mention for anyone else reading, the issue mentioned above was specific to a single shop, and our devs have since made a change to prevent locations from ending up in a bad state which caused that issue.

@API_Dev,

I checked those requests and there appears to be 2 issues with the call being made.

The app making these calls is missing the required scopes to access fulfillmentOrders. Make sure to request one of the fulfillment_order scopes listed here.

Also the call is being made to a fulfillmentOrder id that doesn't exist. The endpoint being used expects a fulfillment_order_id, but it looks like an order_id is being passed instead. This can be fixed by changing the endpoint URL from /admin/api/2021-04/fulfillment_orders/{{ order_id }}.json to /admin/api/2021-04/orders/{{ order_id }}/fulfillment_orders.json instead.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog