update draft order properties with GraphQL

Topic summary

A developer is attempting to update draft order properties using GraphQL but encountering limitations. They specifically need to:

Core Requirements:

  • Update existing draft orders (not create new ones)
  • Modify order properties (not custom attributes)
  • Maintain consistency with how normal orders are handled

Current Blockers:

  • draftOrderCreate mutation doesn’t work for updates
  • Custom attributes aren’t suitable for their use case
  • Need a GraphQL equivalent for the REST API endpoint shown

Seeking Solution:
The developer is looking for a GraphQL replacement for the REST API PUT request to /admin/api/2024-01/draft_orders/{id}.json that allows updating line_items and their properties on existing draft orders.

The issue remains unresolved with no alternative solution provided yet.

Summarized with AI on October 30. AI used: claude-sonnet-4-5-20250929.

The thing i am trying to achieve with this API is totally dependent on properties of order as it’s the way things are being handled for normal orders as well so custom attributes will not work, Also i am trying to update order not create one so the mutation draftOrderCreate will also not work.

If we can have any replacement of REST API mentioned here, then it will be great

await axios.put(

https://${shop}/admin/api/2024-01/draft_orders/${id}.json,
{
draft_order: {
id: id,
line_items: line_items,
},
},
axiosConfig
);