Update Order


Updates an order's billing/shipping address, customer note, payment details, or status. Provide the order ID and at least one field to change. For status transitions with a note, prefer update-order-status.

Also known as: edit an order, change the shipping address on an order.

Property Value
Ability slug mosmcp/update-order
Wire tool name mosmcp__update-order
Category WooCommerce (mosmcp-woocommerce)
Plan Free

 

Required access

Requirement Value
Capability edit_shop_orders
Minimum default role Shop manager
Requires WooCommerce
Annotations readOnly: false · destructive: true · idempotent: true · openWorld: false

 

Input schema

Field Type Required Default Description
id integer Yes — The order ID to update (required).
status string (one of pending, processing, on-hold, completed, cancelled, refunded, failed) — New order status.
customer_note string — New customer-visible note.
billing object —
billing.first_name string —
billing.last_name string —
billing.company string —
billing.address_1 string —
billing.address_2 string —
billing.city string —
billing.state string —
billing.postcode string —
billing.country string —
billing.email string —
billing.phone string —
shipping object —
shipping.first_name string —
shipping.last_name string —
shipping.company string —
shipping.address_1 string —
shipping.address_2 string —
shipping.city string —
shipping.state string —
shipping.postcode string —
shipping.country string —
payment_method string — New payment method ID.
payment_method_title string — New payment method display name.
transaction_id string — New payment gateway transaction ID.

 

Output schema

Field Type Required
success boolean
message string
data object
data.id integer
data.parent_id integer
data.number string
data.order_key string
data.created_via string
data.status string
data.currency string
data.date_created string \| null
data.date_modified string \| null
data.discount_total string
data.discount_tax string
data.shipping_total string
data.shipping_tax string
data.cart_tax string
data.total string
data.total_tax string
data.prices_include_tax boolean
data.customer_id integer
data.customer_ip_address string
data.customer_user_agent string
data.customer_note string
data.billing object
data.shipping object
data.payment_method string
data.payment_method_title string
data.transaction_id string
data.date_paid string \| null
data.date_completed string \| null
data.line_items object[]
data.tax_lines object[]
data.shipping_lines object[]
data.fee_lines object[]
data.coupon_lines object[]
data.refunds object[]
meta object
meta.ability string
meta.timestamp string
meta.execution_time string \| null

 

Example

Sample prompt
Change the shipping address on order 1057 to 45 Oak Avenue, Dallas TX 75201.

Example request (json)

{
  "jsonrpc": "2.0",
  "id": 389,
  "method": "tools/call",
  "params": {
    "name": "mosmcp__update-order",
    "arguments": {
      "input": {
        "id": 1057,
        "shipping": {
          "address_1": "45 Oak Avenue",
          "city": "Dallas",
          "state": "TX",
          "postcode": "75201"
        }
      }
    }
  }
}

Example response (json)

{
  "jsonrpc": "2.0",
  "id": 389,
  "result": {
    "isError": false,
    "structuredContent": {
      "success": true,
      "message": "Order updated.",
      "data": {
        "id": 1057,
        "parent_id": 0,
        "number": "1057",
        "order_key": "wc_order_a1B2c3D4e5",
        "created_via": "checkout",
        "status": "processing",
        "currency": "USD",
        "date_created": "2026-09-27T16:45:10",
        "date_modified": "2026-09-27T16:46:02",
        "discount_total": "0.00",
        "discount_tax": "0.00",
        "shipping_total": "5.00",
        "shipping_tax": "0.00",
        "cart_tax": "3.96",
        "total": "56.96",
        "total_tax": "3.96",
        "prices_include_tax": false,
        "customer_id": 57,
        "customer_ip_address": "203.0.113.24",
        "customer_user_agent": "Mozilla/5.0",
        "customer_note": "",
        "billing": {
          "first_name": "Jane",
          "last_name": "Doe",
          "company": "",
          "address_1": "12 High Street",
          "address_2": "",
          "city": "Austin",
          "state": "TX",
          "postcode": "78701",
          "country": "US",
          "email": "jane@example.com",
          "phone": "+1 512 555 0142"
        },
        "shipping": {
          "first_name": "Jane",
          "last_name": "Doe",
          "company": "",
          "address_1": "45 Oak Avenue",
          "address_2": "",
          "city": "Dallas",
          "state": "TX",
          "postcode": "75201",
          "country": "US"
        },
        "payment_method": "stripe",
        "payment_method_title": "Credit card",
        "transaction_id": "ch_3PqX12",
        "date_paid": "2026-09-27T16:46:02",
        "date_completed": null,
        "line_items": [
          {
            "id": 311,
            "name": "Organic Cotton T-Shirt",
            "parent_name": null,
            "product_id": 42,
            "variation_id": 0,
            "quantity": 2,
            "tax_class": "",
            "subtotal": "48.00",
            "subtotal_tax": "3.96",
            "total": "48.00",
            "total_tax": "3.96",
            "sku": "TSHIRT-ORG-01",
            "price": "24.00"
          }
        ],
        "tax_lines": [
          {
            "id": 312,
            "rate_code": "US-TX-TAX-1",
            "rate_id": 1,
            "label": "Tax",
            "compound": false,
            "tax_total": "3.96",
            "shipping_tax_total": "0.00"
          }
        ],
        "shipping_lines": [
          {
            "id": 313,
            "method_title": "Flat rate",
            "method_id": "flat_rate",
            "total": "5.00",
            "total_tax": "0.00"
          }
        ],
        "fee_lines": [],
        "coupon_lines": [],
        "refunds": []
      },
      "meta": {
        "ability": "mosmcp/update-order",
        "timestamp": "2026-09-29T10:15:00+00:00",
        "execution_time": "18.4ms"
      }
    }
  }
}

 

Edge cases / errors

  • Only id supplied → wcab_nothing_to_update.
  • Unknown order → wcab_order_not_found; no edit rights on it → wcab_cannot_edit; bad status → wcab_invalid_enum.
  • Line items and totals can't be changed here; only address, note, payment details and status are writable.
  • Only the address sub-fields you pass are changed; email/phone apply to billing only.

 


<< Previous Next >>
Update Customer Update Order Status

For more information about the Secure MCP Server for WordPress plugin, explore the following resources:

Product Overview | Pricing | Try for Free | Documentation

If you have any questions regarding plugin configuration, pricing plans or licensing, please contact us or mail us at aisupport@xecurify.com.