I keep getting a 404 not found error when trying to create fulfillments through the Shopify REST API. The error message just says {"errors":"Not Found"}
and I can’t figure out what’s wrong.
Here’s the code I’m using:
curl --location --request POST 'https://mystore-demo.myshopify.com/admin/api/2023-01/fulfillments.json' \
--header 'X-Shopify-Access-Token: shpca_a4b7c9d2e1f8g5h3i6j0k2l9m8n7o4p1' \
--header 'Content-Type: application/json' \
--data-raw '{
"fulfillment": {
"message": "Your order has been dispatched today.",
"notify_customer": true,
"tracking_info": {
"number": 9876543,
"url": "https://www.courier-service.com",
"company": "FastTrack Delivery"
},
"line_items_by_fulfillment_order": [
{
"fulfillment_order_id": 4891037562847,
"fulfillment_order_line_items": [
{
"id": 2074829163,
"quantity": 2
}
]
}
]
}
}'
I’ve double checked my access token and the store URL. The fulfillment order ID and line item IDs are valid. Has anyone else run into this issue? What could be causing the 404 response?