I have the following order in my development store:
{
"id": "gid://shopify/Order/4447441256654",
"name": "#1052",
"createdAt": "2025-01-17T17:05:40Z",
"updatedAt": "2025-01-17T17:05:41Z",
"displayFulfillmentStatus": "UNFULFILLED",
"totalPriceSet": {
"shopMoney": {
"amount": "10.93",
"currencyCode": "USD"
}
},
"totalTaxSet": {
"shopMoney": {
"amount": "0.9"
}
},
"totalDiscountsSet": {
"shopMoney": {
"amount": "0.0"
}
},
"totalShippingPriceSet": {
"shopMoney": {
"amount": "0.0"
}
},
"shippingAddress": null,
"billingAddress": null,
"lineItems": {
"edges": [
{
"node": {
"id": "gid://shopify/LineItem/11208984166606",
"variant": {
"id": "gid://shopify/ProductVariant/40302120632526",
"sku": "spatula-6"
},
"product": {
"id": "gid://shopify/Product/6580769489102"
},
"quantity": 1,
"originalUnitPriceSet": {
"shopMoney": {
"amount": "5.02"
}
},
"totalDiscountSet": {
"shopMoney": {
"amount": "0.0"
}
},
"taxLines": [
{
"priceSet": {
"shopMoney": {
"amount": "0.2"
}
}
},
{
"priceSet": {
"shopMoney": {
"amount": "0.23"
}
}
},
{
"priceSet": {
"shopMoney": {
"amount": "0.02"
}
}
}
]
}
},
{
"node": {
"id": "gid://shopify/LineItem/11208984199374",
"variant": {
"id": "gid://shopify/ProductVariant/40302121156814",
"sku": "spatula-7"
},
"product": {
"id": "gid://shopify/Product/6580769489102"
},
"quantity": 1,
"originalUnitPriceSet": {
"shopMoney": {
"amount": "5.01"
}
},
"totalDiscountSet": {
"shopMoney": {
"amount": "0.0"
}
},
"taxLines": [
{
"priceSet": {
"shopMoney": {
"amount": "0.2"
}
}
},
{
"priceSet": {
"shopMoney": {
"amount": "0.23"
}
}
},
{
"priceSet": {
"shopMoney": {
"amount": "0.02"
}
}
}
]
}
}
],
"pageInfo": {
"hasNextPage": true,
"endCursor": "eyJsYXN0X2lkIjoxMTIwODk4NDE2NjYwNiwibGFzdF92YWx1ZSI6MTEyMDg5ODQxNjY2MDZ9"
}
},
"fulfillmentOrders": {
"edges": [
{
"node": {
"id": "gid://shopify/FulfillmentOrder/5429507686606",
"lineItems": {
"edges": [
{
"node": {
"lineItem": {
"id": "gid://shopify/LineItem/11208984166606",
"variant": {
"id": "gid://shopify/ProductVariant/40302120632526",
"sku": "spatula-6"
},
"product": {
"id": "gid://shopify/Product/6580769489102"
},
"quantity": 1
}
}
},
{
"node": {
"lineItem": {
"id": "gid://shopify/LineItem/11208984199374",
"variant": {
"id": "gid://shopify/ProductVariant/40302121156814",
"sku": "spatula-7"
},
"product": {
"id": "gid://shopify/Product/6580769489102"
},
"quantity": 1
}
}
}
],
"pageInfo": {
"hasNextPage": false,
"endCursor": "eyJsYXN0X2lkIjoxMTMxMzM5MzY5Njk3NCwibGFzdF92YWx1ZSI6MTEzMTMzOTM2OTY5NzR9"
}
}
}
}
],
"pageInfo": {
"hasNextPage": false,
"endCursor": "eyJsYXN0X2lkIjo1NDI5NTA3Njg2NjA2LCJsYXN0X3ZhbHVlIjoiNTQyOTUwNzY4NjYwNiJ9"
}
},
"fulfillments": []
}
Iām making the following request (doing it without formatting in case it helps):
curl -X POST -H \'Content-Type: application/json\' -H \'X-Shopify-Access-Token: xxx\' -d \'{"query": "\\n mutation {\\n fulfillmentCreate(\\n fulfillment: {\\n trackingInfo: {\\n number: \\"1234567890\\",\\n url: \\"https://tracking.com\\"\\n },\\n lineItemsByFulfillmentOrder: [\\n {\\n fulfillmentOrderId: \\"gid://shopify/FulfillmentOrder/5429507686606\\",\\n fulfillmentOrderLineItems: [\\n {\\n id: \\"gid://shopify/LineItem/11208984166606\\",\\n quantity: 1,\\n }\\n ]\\n }\\n ]\\n }\\n ) {\\n fulfillment {\\n id\\n }\\n }\\n }\\n "}\' https://telescope-test.myshopify.com/admin/api/2024-10/graphql.json'
Pretty-printed, the mutation looks like this:
mutation {
fulfillmentCreate(
fulfillment: {
lineItemsByFulfillmentOrder: [
{
fulfillmentOrderId: "gid://shopify/FulfillmentOrder/5429507686606"
fulfillmentOrderLineItems: [
{ id: "gid://shopify/LineItem/11208984166606", quantity: 1 }
]
}
]
}
) {
fulfillment {
id
}
}
}
As you can see, weāre making a request to create a fulfillment for the fulfillment order 5429507686606ās line item 11208984166606. These IDs seem to line up with the node returned from the API.
When I send in this request, I get the following error [{āmessageā: āinvalid idā, ālocationsā: [{ālineā: 3, ācolumnā: 17}], āpathā: [āfulfillmentCreateā]}]
I donāt know how to trace this - what is the wrong ID here? Iām using this as reference: fulfillmentCreate - GraphQL Admin
Thanks!