Reconcile stuck order statuses

WooCommerceAdvanced~15 min

Before you start

A connected store with the WooCommerce integration enabled and both its read and order-status write abilities on. Turn on the status-write ability only for a run you are supervising.

Every store accumulates orders that got stuck: an on-hold that the bank transfer actually cleared for, a pending that never went anywhere, a processing that shipped weeks ago and nobody marked complete. They quietly rot your numbers and your dashboards. Clearing them by hand means opening each one, remembering what it should be, and clicking the dropdown. This prompt gathers the stuck ones, proposes where each should go, and moves only the ones you sign off.

The prompt
Help me clean up stuck order statuses. Go slowly and let me approve the moves.
First, read only: list every order still in [on-hold or pending] that is older
than [10 days]. For each one show me the order number, its current status, how
old it is, the total, and the status you would move it to and why. Do not
change anything yet.
I will tell you which orders to move and to what status. Only the ones I
approve. Then apply the changes in batches of [10], and show me each batch
after you make it. Add a note to every order you move recording the old status,
the new status, and the reason. At the end, list every order you changed.
If you are unsure what an order should become, leave it in the plan flagged for
me rather than moving it.

Why this is safe to run

Finding the stuck orders is a pure read: listing them by status and age changes nothing, so you review the whole plan before any order moves. The status change is the only write here, and it is gated the same way the risky writes always are: explicit approval of which orders move and to what, small batches, and a pause to show you each batch. Every move leaves a note on its order recording the old status, the new one, and the reason, so the change is traceable, and each call is checked against the capability of the user you bound the agent to and lands in the Activity Log. The status-write ability stays off until you enable it for a run you are watching.

Two honest limits. A status change is customer-facing in the sense that WooCommerce itself may fire its own emails when an order changes state, so choose the target status on purpose rather than sweeping everything to completed. And the agent cannot email anyone. If you want to explain a change to a customer, ask it to draft the message and send it yourself; the note it writes lives on the order, optionally marked customer-facing so it shows in the customer’s account.

Already connected? Skip the paste. Ask your agent for the “reconcile stuck order statuses” recipe, name the age and the statuses, and it runs the same read-first, approve-each flow on your own store.

How it works

  1. List orders sitting in on-hold or pending that are older than the age you name.
  2. Show you each one and the status you propose to move it to, and wait.
  3. Change the status only on the orders you approve, in small batches.
  4. Add a note to every order it moves, recording the old status, the new one, and why.
  5. Return the list of orders it changed so you can review them.

Questions

Can it change a status before I approve it?
No. Listing the stuck orders is a read. Nothing moves until you approve the plan, and it then works in small batches so you see each change before the next.
Does changing an order status refund or charge anyone?
No. This recipe only changes the status label and adds a note. It never issues a refund or takes a payment, because those are separate abilities it does not call. Bear in mind WooCommerce may send its own status emails on a change, so pick the target status deliberately.