Menu
Update Order By Id
This API lets you make changes to an order.
/orders/{orderId}Use it in a workflow
- Add a step and choose the WooCommerce connector.
- Pick the Update Order By Id action (under Orders).
- Fill in the fields below, then reference the result from later steps as
{{updateOrderById.response.data}}.
Request
Path parameters
orderIdintegerrequiredID of order to update
Request body
Enter the body as JSON in the step's Body field.
idintegerUnique identifier for the resource.
parent_idintegerParent order ID.
numberstringOrder number.
order_keystringOrder key.
created_viastringShows where the order was created.
versionstringVersion of WooCommerce which last updated the order.
statusstringOrder status. Options - pending, processing, on-hold, completed, cancelled, refunded, failed, trash and checkout-draft. Default is pending.
currencystringCurrency the order was created with, in ISO format.
One ofAEDAFNALLAMDANGAOAARSAUDAWGAZNBAMBBDBDTBGNBHDBIFBMDBNDBOBBRLBSDBTCBTNBWPBYRBYNBZDCADCDFCHFCLPCNYCOPCRCCUCCUPCVECZKDJFDKK
date_createdstring (date-time)The date the order was created, in the site's timezone.
date_created_gmtstring (date-time)The date the order was created, as GMT.
date_modifiedstring (date-time)The date the order was last modified, in the site's timezone.
date_modified_gmtstring (date-time)The date the order was last modified, as GMT.
discount_totalstringTotal discount amount for the order.
discount_taxstringTotal discount tax amount for the order.
shipping_totalstringTotal shipping amount for the order.
shipping_taxstringTotal shipping tax amount for the order.
cart_taxstringSum of line item taxes only.
totalstringGrand total.
total_taxstringSum of all taxes.
prices_include_taxbooleanTrue the prices included tax during checkout.
customer_idintegerUser ID who owns the order. 0 for guests.
customer_ip_addressstringCustomer's IP address.
customer_user_agentstringUser agent of the customer.
customer_notestringNote left by customer during checkout.
billingobjectfirst_namestringFirst name.
last_namestringLast name.
companystringCompany name.
address_1stringAddress line 1
address_2stringAddress line 2
citystringCity name.
statestringISO code or name of the state, province or district.
postcodestringPostal code.
countrystringCountry code in ISO 3166-1 alpha-2 format.
emailstringEmail address.
phonestringPhone number.
shippingobjectfirst_namestringFirst name.
last_namestringLast name.
companystringCompany name.
address_1stringAddress line 1
address_2stringAddress line 2
citystringCity name.
statestringISO code or name of the state, province or district.
postcodestringPostal code.
countrystringISO code of the country.
phonestringPhone number.
payment_methodstringPayment method ID.
payment_method_titlestringPayment method title.
transaction_idstringUnique transaction ID.
date_paidstring (date-time)The date the order was paid, in the site's timezone.
date_paid_gmtstring (date-time)The date the order was paid, as GMT.
date_completedstring (date-time)The date the order was completed, in the site's timezone.
date_completed_gmtstring (date-time)The date the order was completed, as GMT.
cart_hashstringMD5 hash of cart items to ensure orders are not modified.
meta_dataarray<object>Meta data properties.
idintegerMeta ID.
keystringMeta key.
valueobjectMeta value.
display_keystringMeta key for UI display.
display_valueobjectMeta value for UI display.
line_itemsarray<object>Line items data.
idintegerItem ID.
namestringProduct name.
parent_namestringParent product name if the product is a variation.
product_idintegerProduct ID.
variation_idintegerVariation ID, if applicable.
quantityintegerQuantity ordered.
tax_classstringTax class of product.
subtotalstringLine subtotal (before discounts).
subtotal_taxstringLine subtotal tax (before discounts).
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
skustringProduct SKU.
pricenumberProduct price.
tax_linesarray<object>Tax lines data.
idintegerItem ID.
rate_codestringTax rate code.
rate_idstringTax rate ID.
labelstringTax rate label.
compoundbooleanWhether or not this is a compound tax rate.
tax_totalstringTax total (not including shipping taxes).
shipping_tax_totalstringShipping tax total.
meta_dataarray<object>5 fieldsMeta data properties.
shipping_linesarray<object>Shipping lines data.
idintegerItem ID.
method_titlestringShipping method name.
method_idstringShipping method ID.
instance_idstringShipping instance ID.
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
fee_linesarray<object>Fee lines data.
idintegerItem ID.
namestringFee name.
tax_classstringTax class of fee.
tax_statusstringTax status of fee. Options taxable and none.
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
coupon_linesarray<object>Fee lines data.
idintegerItem ID.
codestringCoupon code.
discountstringDiscount total.
discount_taxstringDiscount total tax.
meta_dataarray<object>5 fieldsMeta data properties.
{
"id": 0,
"parent_id": 0,
"number": "string",
"order_key": "string",
"created_via": "string",
"version": "string",
"status": "string",
"currency": "AED",
"date_created": "2025-01-01T00:00:00Z",
"date_created_gmt": "2025-01-01T00:00:00Z",
"date_modified": "2025-01-01T00:00:00Z",
"date_modified_gmt": "2025-01-01T00:00:00Z"
}
Response
Returns 200 with an object. Read it in later steps with {{updateOrderById.response.data.<field>}}.
idintegerUnique identifier for the resource.
parent_idintegerParent order ID.
numberstringOrder number.
order_keystringOrder key.
created_viastringShows where the order was created.
versionstringVersion of WooCommerce which last updated the order.
statusstringOrder status. Options - pending, processing, on-hold, completed, cancelled, refunded, failed, trash and checkout-draft. Default is pending.
currencystringCurrency the order was created with, in ISO format.
One ofAEDAFNALLAMDANGAOAARSAUDAWGAZNBAMBBDBDTBGNBHDBIFBMDBNDBOBBRLBSDBTCBTNBWPBYRBYNBZDCADCDFCHFCLPCNYCOPCRCCUCCUPCVECZKDJFDKK
date_createdstring (date-time)The date the order was created, in the site's timezone.
date_created_gmtstring (date-time)The date the order was created, as GMT.
date_modifiedstring (date-time)The date the order was last modified, in the site's timezone.
date_modified_gmtstring (date-time)The date the order was last modified, as GMT.
discount_totalstringTotal discount amount for the order.
discount_taxstringTotal discount tax amount for the order.
shipping_totalstringTotal shipping amount for the order.
shipping_taxstringTotal shipping tax amount for the order.
cart_taxstringSum of line item taxes only.
totalstringGrand total.
total_taxstringSum of all taxes.
prices_include_taxbooleanTrue the prices included tax during checkout.
customer_idintegerUser ID who owns the order. 0 for guests.
customer_ip_addressstringCustomer's IP address.
customer_user_agentstringUser agent of the customer.
customer_notestringNote left by customer during checkout.
billingobjectfirst_namestringFirst name.
last_namestringLast name.
companystringCompany name.
address_1stringAddress line 1
address_2stringAddress line 2
citystringCity name.
statestringISO code or name of the state, province or district.
postcodestringPostal code.
countrystringCountry code in ISO 3166-1 alpha-2 format.
emailstringEmail address.
phonestringPhone number.
shippingobjectfirst_namestringFirst name.
last_namestringLast name.
companystringCompany name.
address_1stringAddress line 1
address_2stringAddress line 2
citystringCity name.
statestringISO code or name of the state, province or district.
postcodestringPostal code.
countrystringISO code of the country.
phonestringPhone number.
payment_methodstringPayment method ID.
payment_method_titlestringPayment method title.
transaction_idstringUnique transaction ID.
date_paidstring (date-time)The date the order was paid, in the site's timezone.
date_paid_gmtstring (date-time)The date the order was paid, as GMT.
date_completedstring (date-time)The date the order was completed, in the site's timezone.
date_completed_gmtstring (date-time)The date the order was completed, as GMT.
cart_hashstringMD5 hash of cart items to ensure orders are not modified.
meta_dataarray<object>Meta data properties.
idintegerMeta ID.
keystringMeta key.
valueobjectMeta value.
display_keystringMeta key for UI display.
display_valueobjectMeta value for UI display.
line_itemsarray<object>Line items data.
idintegerItem ID.
namestringProduct name.
parent_namestringParent product name if the product is a variation.
product_idintegerProduct ID.
variation_idintegerVariation ID, if applicable.
quantityintegerQuantity ordered.
tax_classstringTax class of product.
subtotalstringLine subtotal (before discounts).
subtotal_taxstringLine subtotal tax (before discounts).
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
skustringProduct SKU.
pricenumberProduct price.
tax_linesarray<object>Tax lines data.
idintegerItem ID.
rate_codestringTax rate code.
rate_idstringTax rate ID.
labelstringTax rate label.
compoundbooleanWhether or not this is a compound tax rate.
tax_totalstringTax total (not including shipping taxes).
shipping_tax_totalstringShipping tax total.
meta_dataarray<object>5 fieldsMeta data properties.
shipping_linesarray<object>Shipping lines data.
idintegerItem ID.
method_titlestringShipping method name.
method_idstringShipping method ID.
instance_idstringShipping instance ID.
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
fee_linesarray<object>Fee lines data.
idintegerItem ID.
namestringFee name.
tax_classstringTax class of fee.
tax_statusstringTax status of fee. Options taxable and none.
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).
taxesarray<object>8 fieldsLine taxes.
meta_dataarray<object>5 fieldsMeta data properties.
coupon_linesarray<object>Fee lines data.
idintegerItem ID.
codestringCoupon code.
discountstringDiscount total.
discount_taxstringDiscount total tax.
meta_dataarray<object>5 fieldsMeta data properties.
{
"id": 0,
"parent_id": 0,
"number": "string",
"order_key": "string",
"created_via": "string",
"version": "string",
"status": "string",
"currency": "AED",
"date_created": "2025-01-01T00:00:00Z",
"date_created_gmt": "2025-01-01T00:00:00Z",
"date_modified": "2025-01-01T00:00:00Z",
"date_modified_gmt": "2025-01-01T00:00:00Z"
}
Need more? See the WooCommerce guide for connection setup and behaviour shared by every action.