A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
Hi Shopify
We've been using FulfillmentCreateV2 (2022-10) to create fulfilments and up until now we've been sending each line item separately (as to why we do this is a different problem altogether :)), it's been working great up until today where the API is throwing an error saying Fulfillment payloads must contain unique fulfillment order ids
i.e. we are sending this:
"lineItemsByFulfillmentOrder": [
{
"fulfillmentOrderId": "gid://shopify/FulfillmentOrder/11111111",
"fulfillmentOrderLineItems": {
"id": "gid://shopify/FulfillmentOrderLineItem/123456",
"quantity": 1
}
},
{
"fulfillmentOrderId": "gid://shopify/FulfillmentOrder/11111111",
"fulfillmentOrderLineItems": {
"id": "gid://shopify/FulfillmentOrderLineItem/789012",
"quantity": 1
}
}
],
rather than this:
{
"fulfillmentOrderId": "gid://shopify/FulfillmentOrder/11111",
"fulfillmentOrderLineItems": [{
"id": "gid://shopify/FulfillmentOrderLineItem/123456",
"quantity": 1
},{
"id": "gid://shopify/FulfillmentOrderLineItem/789012",
"quantity": 1
}]
}
Shouldn't any changes to API behaviour, especially breaking changes be rolled out inline with new API versions rather than pushed to previous API versions? we are using 2022-10 which is still a supported version and therefore there shouldn't be any breaking changes rolled out to this version right?
Solved! Go to the solution
This is an accepted solution.
Hi
Thank you for your report!
This was a bug which was introduced while adding functionality to a future release which would prevent overfulfillment.
A fix for this was shipped today so you should hopefully not be running into this issue now.
Out of interest, may you share with us your use case for specify the same fulfilment order multiple times, rather then specify it once and supply it with a list of fulfillmentOrderLineItems?
To learn more visit the Shopify Help Center or the Community Blog.
Wow, Glad I found your post. I just rolled out a new version of our app and started getting these errors. At first I couldn't figure out what was going on then noticed the docs had changed and then discovered your post.
There is nothing wrong with sending the line items separately if you end up doing partial fulfillments 🙂
Introducing a breaking change in older api version! Wow..
This is an accepted solution.
Hi
Thank you for your report!
This was a bug which was introduced while adding functionality to a future release which would prevent overfulfillment.
A fix for this was shipped today so you should hopefully not be running into this issue now.
Out of interest, may you share with us your use case for specify the same fulfilment order multiple times, rather then specify it once and supply it with a list of fulfillmentOrderLineItems?
To learn more visit the Shopify Help Center or the Community Blog.
Hi @marcusturner ,
That's great! We don't really have a use case for doing it multiple times, it was just built like that, however will be fixed in future.