2026-09-29
Manage WooCommerce orders and shipping with undo
WP MCP Pro’s WooCommerce operations catalog lets an agent do the store chores that used to need a person in wp-admin: fix an order, set up shipping, wire a webhook. Every change to existing state is snapshotted first.
What you need
- WP MCP Pro, connected to your AI client, and WooCommerce active.
- The agent uses three abilities:
woo-ops(the catalog),woo-readandwoo-write, each driven by anopname andparams.
Edit an order
› Order 4183 should have two of the blue mugs, not one, and add a $5 handling fee.
The agent reads the order with woo-read op orders.get, then calls
woo-write op orders.update with the changed line_items and fee_lines.
Totals are recalculated. The whole order is snapshotted first, so
rollback-operation restores it exactly. Status changes still go through
update-order-status.
Create an order
› Create a phone order for customer 57: one large tote, shipped to 12 Main St, Springfield.
orders.create builds the order through WooCommerce’s own order classes. No
payment gateway is ever called: set_paid and transaction_id are refused, and
the payment method is a label. Rolling the create back trashes the order.
Set up shipping
› Add free shipping over $75 to the United States zone, and a $6 flat rate below that.
The agent lists zones with shipping.zones, then uses shipping.add-method
for free_shipping and flat_rate. Settings are validated against each
method’s own settings form, so a flat rate cost that would not evaluate is
refused before anything is written. Writes are limited to the core flat rate,
free shipping and local pickup methods. Each write snapshots the whole zone, so
one rollback puts the zone back as it was. Deleting a zone or removing a method
is destructive: it is off until your site opts in with the
wpmcp_woo_op_enabled filter, and needs confirm: true.
Wire a webhook
› Send order.created events to https://hooks.example.com/orders.
webhooks.create requires a public https delivery URL that passes an SSRF
check, refuses custom action.* topics, and generates a signing secret you
never see in a response. webhooks.pause stops deliveries without deleting the
webhook.
Undo a whole session
Pass several changes as a batch and they share one session_id, so
rollback-session unwinds all of them.