Marking a order as Ready for pickup fulfillmentOrderLineItemsPreparedForPickup

Hi

I have been struggling with marking a order as ready for pickup using the 2023-01 API of Graphql.

Here is the request that i sending using “Insomnia”

mutation fulfillmentOrderLineItemsPreparedForPickup($input: FulfillmentOrderLineItemsPreparedForPickupInput!) {
  fulfillmentOrderLineItemsPreparedForPickup(input: $input) {
    userErrors {
      field
      message
    }
  }
}

The Variables

{
	"input": {
		"lineItemsByFulfillmentOrder": [
			{
				"fulfillmentOrderId": "gid://shopify/LineItem/6181984370990"
			}
		]
	}
}

This is the response i am getting.

{
	"data": {
		"fulfillmentOrderLineItemsPreparedForPickup": null
	},
	"errors": [
		{
			"message": "invalid id",
			"locations": [
				{
					"line": 2,
					"column": 3
				}
			],
			"path": [
				"fulfillmentOrderLineItemsPreparedForPickup"
			]
		}
	],
	"extensions": {
		"cost": {
			"requestedQueryCost": 10,
			"actualQueryCost": 1,
			"throttleStatus": {
				"maximumAvailable": 1000.0,
				"currentlyAvailable": 999,
				"restoreRate": 50.0
			}
		}
	}
}

i use this rest API “2023-01/orders/5242763936046/fulfillment_orders.json” to get the fulfillmentOrderId.

I can’t seem to find the issue as where i am going wrong and as the error points out its a invalid ID.

Where do i find the right ID in for this case?

Here is screen shot of the test order.

Hey @Etienne_Steyn - have you tried formatting the variables like this (for example):

{
“input”: {
“lineItemsByFulfillmentOrder”: [
{
“fulfillmentOrderId”: “gid://shopify/FulfillmentOrder/1046000776”
}
]
}
}

In your example it looks like you formatted the fulfillmentOrderId value as gid://shopify/LineItem/6181984370990 when it should look like gid://shopify/FulfillmentOrder/[id] based on the example in our dev docs here. Hope this helps!

2 Likes