Have your say in Community Polls: What was/is your greatest motivation to start your own business?
Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Unable to create fulfillment

Solved

Unable to create fulfillment

Giglio-TS_Admin
Visitor
1 0 0

Hello, 

 

I am always getting a "Not found" error message trying to create a fulfillment, below my request body:

{
  "fulfillment":{
    "message":"The package was shipped this morning.",
    "notify_customer":false,
    "tracking_number":"",
    "location_id": 68606886019,
    "line_items_by_fulfillment_order":[
      {
        "fulfillment_order_id":4888540610691
      }]
  }
}

 

here the response:

{
    "errors": "Not Found"
}

I am sure that order #4888540610691 exists because I can retrieve its details by calling: https://youarestardust-shop.myshopify.com/admin/api/2022-10/orders/4888540610691.json. 

 

What am I doing wrong? Or there's something in the store/app configuration that is preventing us to create the fulfillment (and maybe other items too...) 

 

Thanks in advance for a reply and best regards

 

 

Accepted Solution (1)

kevnob
Shopify Staff
11 3 3

This is an accepted solution.

Hi @Giglio-TS_Admin ,

 

You may be running into issues because you are using the order ID as opposed to using the FulFillment Order Id which is the preferred method. You can refer to these developer documents on FulFillment and the related GraphQL or REST resources. 

 

Hope that helps! 

To learn more visit the Shopify Help Center or the Community Blog.

View solution in original post

Replies 2 (2)

kevnob
Shopify Staff
11 3 3

This is an accepted solution.

Hi @Giglio-TS_Admin ,

 

You may be running into issues because you are using the order ID as opposed to using the FulFillment Order Id which is the preferred method. You can refer to these developer documents on FulFillment and the related GraphQL or REST resources. 

 

Hope that helps! 

To learn more visit the Shopify Help Center or the Community Blog.

phongnt619x
Shopify Partner
1 0 0

I has same issues, when i call api 

/admin/api/2023-01/fulfillments.json
and pass fulfillment_order_id like this
'fulfillment' => [
'line_items_by_fulfillment_order' => [[
'fulfillment_order_id' => 63xxxxxxxxx01,
]],
'tracking_info' => [
'number' => 'AGxxxxxxCN1'
],
]
i got fulfillment_order_id from api 
/admin/api/2023-01/orders/{{ORDER_ID}}/fulfillment_orders.json
Screenshot 2023-07-18 at 22.17.52.png
 
please help me, many thank!