RestAPI Get Fulfillment Order not working

I am trying to get the fulfillment orders for an order on my store using this endpoint: ‘/admin/api/2023-07/orders/{orderi_id}/fulfillment_orders.json’

I am able to get the fulfillment orders for all of my other stores using this endpoint, but for this store I am getting 0 results.

When I using the endpoint for a specific fulfillment order, I get a 404 not found error.

Here are some screenshots of the responses I am getting.

Any help would be greatly appreciated!

Hi @ctsai

Thank you for reaching out to the Shopify community.

I understand that you are currently encountering an issue while attempting to fetch fulfillment orders for an order. Allow me to assist you in resolving this matter.

To ensure successful retrieval of fulfillment orders, it is imperative that you possess the appropriate access scopes to utilize this resource. The following scopes are required to create a fulfillment for an order:

  • read_merchant_managed_fulfillment_orders *
  • read_third_party_fulfillment_orders
  • read_orders
  • read_all_orders (This scope becomes essential if the order is older than 60 days). If you intend to fetch older orders, please ensure that you have the “Read all orders” scope enabled within your public app’s API Access section.

Once you have verified that you possess all the necessary access scopes, kindly follow the instructions outlined below:

  1. Make an API call to the following endpoint: https://your-shopify-url/admin/api/2023-07/orders/{order_id}/fulfillment_orders.json. It is essential to use a valid order ID for this request (to confirm its validity, you may first call the “fetch orders” API using this URL: https://your-shopify-url/admin/api/2023-07/orders/{order_id}.json).

  2. Next, retrieve the details of the fulfillment order by making an API call to: https://your-shopify-url/admin/api/2023-07/fulfillment_orders/{fulfillment_order_id}.json. Please note that you must pass the fulfillment_order_id for this request. Be cautious not to confuse the fulfillment_order_id with the order_id, as they are distinct values.

Furthermore, we would like to highlight that the second screenshot you provided appears to depict an incorrect endpoint. The correct and appropriate endpoints have been elucidated above for your reference.

Should you require any further assistance or encounter additional queries, please feel free to reach out to me.

Thanks.