fulfillment_orders returns 404 not found

Highlighted
Shopify Partner
6 0 1

When first querying all assigned fulfillment orders via /admin/api/2020-10/assigned_fulfillment_orders.json

there's one fulfillment order with the ID 1694060413039.

X-Request-ID: 3887e96f-75cc-45aa-9729-648834840897

 

However, when then querying it again with /admin/api/2020-10/fulfillment_orders/1694060413039.json

We get a 404 not found error:

{"errors":"Not Found"}

X-Request-Id: 6f4daa25-807d-466a-8821-29fb579ad2b1

 

What's the issue and how can we solve it?

 

We only have this issue with one customer, all other customers are working just fine.
This customer can't ship any orders right now, so this is urgent!

0 Likes
Highlighted
Shopify Partner
63 3 10

Seen this a few times, my guess would be your location ID. A lot of Apps seem to choose the first location (which is fine), however they don't check if that location is actually disabled.

0 Likes
Highlighted
Shopify Partner
6 0 1

It's a GET request, we don't specify any location ID here. As I also mentioned in my original post, the same request is working for other customers.

0 Likes
Highlighted
Shopify Staff
Shopify Staff
644 78 141

Hey @Sebastian10,

You're sending API version 2019-10 in your calls, fulfillmentOrders weren't introduced until the 2020-01 version so updating the version your app uses should fix the issue.

Also note that 2020-10 has been fully deprecated at this point, so continuing to call it will cause your app to be unlisted if it's public. Eventually this version will stop working completely, so it's recommended to update all calls for your app to a new version, our docs for that are here

JB | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Highlighted
Shopify Partner
6 0 1

Hi @_JB , are you sure you checked the correct request? I'm pretty confident I've used the 2020-10 API.

Just to confirm I took the time to test it again. Please not that I've removed some irrelevant or confidential details from the request examples.

 

Here's how we retrieve currently assigned and pending fulfillment requests:

Request:
GET https://<SHOPNAME>.myshopify.com/admin/api/2020-10/assigned_fulfillment_orders.json

Response HEADER:
HTTP/1.1 200 OK
Date: Fri, 16 Oct 2020 07:28:40 GMT
X-Sorting-Hat-PodId: 110
X-Sorting-Hat-ShopId: 27581251695
X-ShopId: 27581251695
X-ShardId: 110
X-Stats-UserId:
X-Stats-ApiClientId: 1296238
X-Stats-ApiPermissionId: 206445346927
HTTP_X_SHOPIFY_SHOP_API_CALL_LIMIT: 1/80
X-Shopify-Shop-Api-Call-Limit: 1/80
X-Shopify-API-Version: 2020-10
X-Shopify-Stage: production
X-Request-ID: 4fa3b4d4-dcd5-4744-95f3-fcbc8c9bed92
Server: cloudflare
CF-RAY: 5e30107a1c5f2c19-FRA

Response BODY:

[{
"id": 1694060413039,
"shop_id": 27581251695,
"order_id": 2526293295215,
"assigned_location_id": 35972382831,
"request_status": "submitted",
"status": "open",
"supported_actions": [
"cancel_fulfillment_order"
],
"outgoing_requests": [
{
"message": null,
"request_options": {
"notify_customer": true
},
"sent_at": "2020-10-13T07:59:08-04:00",
"kind": "fulfillment_request"
}
],
...
},
...
]

 

 

 

Then we want to request the fulfillment order like this:

Request:
GET https://<SHOPNAME>.myshopify.com/admin/api/2020-10/fulfillment_orders/1694060413039.json 

Response HEADER:
HTTP/1.1 404 Not Found
Date: Fri, 16 Oct 2020 07:35:04 GMT
X-Sorting-Hat-PodId: 110
X-Sorting-Hat-ShopId: 27581251695
X-ShopId: 27581251695
X-ShardId: 110
X-Stats-UserId:
X-Stats-ApiClientId: 1296238
X-Stats-ApiPermissionId: 206445346927
HTTP_X_SHOPIFY_SHOP_API_CALL_LIMIT: 1/80
X-Shopify-Shop-Api-Call-Limit: 1/80
X-Shopify-API-Version: 2020-10
X-Shopify-Stage: production
X-Request-ID: e58fed87-a2b0-47e1-9c32-965a11447b89
cf-request-id: 05d1ee7b7f0000c2e0d217e000000001
Server: cloudflare
CF-RAY: 5e3019d8cd30c2e0-FRA

Response BODY:

{"errors":"Not Found"}

 

 

When I try the exact same request with a different shop it is working!

0 Likes
Highlighted
Shopify Partner
6 0 1

@_JB can you please support here? We are still waiting for an answer!

0 Likes
Highlighted
Shopify Staff
Shopify Staff
644 78 141

Hey @Sebastian10,

Sorry for the delay, our developers are investigating this as we speak. I'll post back here as soon as we have an update for you.

JB | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Highlighted
Shopify Staff
Shopify Staff
644 78 141

Hey @Sebastian10,

Our team has identified and pushed a fix for the issue. The issue stemmed from work being done on new API features which shouldn't have affected behaviours in stable versions. Our devs have fixed this now so you won't encounter the error when using any of our stable API versions. I just checked our logs again and all calls from your app in the last few weeks have used the unstable API version when calling the fulfillment_orders endpoint. Once you change that to use a stable version (2020-01,2020-04, 2020-07,2020-10) you won't encounter the issue anymore. 

JB | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Highlighted
Shopify Partner
6 0 1

Hi @_JB , we're currently pinning the API Version 2020-07, but even with the 2020-10 version we're still experiencing the same issue.

When I try to query the fulfillment order, I still get a 404.

Here are a few examples of fulfillment order IDs and the X-Request-ID. All fulfillment orders have been assigned to the App's location. All requests have been sent to the 2020-10 version.

1694750539887 - 668b5b6b-f22b-4564-861d-13c24cef5fb1
1694836850799 - 6d7e548d-18a0-44bf-9054-0575b93de885
1766494404719 - 45748701-97f3-4045-83c5-232bb96796fd

Please have a look at the logs again. Unfortunately the problem is still not solved!

0 Likes