Un-Cancel Via API or Automation rules

Hello, is it possible to un-cancel order via API or Automation rules?

sample order: https://app.shiphero.com/dashboard/orders/details/230113630

If we can do this via API, could you please provide string.

Thank you

Hello @veraioele!
I hope you are doing ok!
Unfortunately, we do not have an un-cancel order mutation at the moment.
However, I am running some tests on my end, trying to find a workaround using other API calls.
I will let you know as soon as I have an update.
Best,
Tomas

1 Like

Thank you Thomas. Looking forward to hear from you.

Hello @veraioele!
I hope you have had a great week so far!
I’ve tested a workaround for the past week, and this is what I came up with:

  1. You first need to update all line items to Pending status and add the corresponding pending fulfillment quantity.
mutation{
  order_update_line_items(data: {
    customer_account_id: string
    order_id:"234164772"
	line_items:[
    {
      id:"TGluZUl0ZW06NjIwNjkyNzU0"
      fulfillment_status:"Pending"
      quantity_pending_fulfillment:int
    },
    {
      id:"TGluZUl0ZW06NjIwNjkyNzU3"
      fulfillment_status:"Pending"
      quantity_pending_fulfillment:int
    }    
  ]
  }){
    request_id
    complexity
    order{
      fulfillment_status
      line_items{
        edges{
          node{
            sku
            fulfillment_status
            quantity
            quantity_pending_fulfillment
            quantity_allocated
          }
        }
      }
    }
  }
}
  1. Update the order’s fulfillment status to whichever you require, “pending” sets the status as “Default” on the UI:
mutation{
  order_update_fulfillment_status(data:{
    customer_account_id: string
    order_id:"234164772"
    fulfillment_status:"pending"
  }){
    request_id
    complexity
    order{
      legacy_id
      fulfillment_status
    }
  }
}
  • As you are working from a 3PL account please remember to add customer_account_id in both mutations

You can then correctly ship the order from the Shipping Web and the mobile app.
Please let me know if you run into any issues, as this is not precisely an un-cancel button, but I ran many scenarios, and they all worked as expected.
Have a lovely weekend!
TomasFD