Products

Order properties

AttributeTypeDescription
idintegerUnique identifier for the resource.READ-ONLY
parent_idintegerParent order ID.
numberstringOrder number.READ-ONLY
order_keystringOrder key.READ-ONLY
created_viastringShows where the order was created.READ-ONLY
versionstringVersion of WooCommerce which last updated the order.READ-ONLY
statusstringOrder status. Options: pendingprocessingon-holdcompletedcancelledrefundedfailed and trash. Default is pending.
currencystringCurrency the order was created with, in ISO format. Options: AEDAFNALLAMDANGAOAARSAUDAWGAZNBAMBBDBDTBGNBHDBIFBMDBNDBOBBRLBSDBTCBTNBWPBYRBZDCADCDFCHFCLPCNYCOPCRCCUCCUPCVECZKDJFDKKDOPDZDEGPERNETBEURFJDFKPGBPGELGGPGHSGIPGMDGNFGTQGYDHKDHNLHRKHTGHUFIDRILSIMPINRIQDIRRIRTISKJEPJMDJODJPYKESKGSKHRKMFKPWKRWKWDKYDKZTLAKLBPLKRLRDLSLLYDMADMDLMGAMKDMMKMNTMOPMROMURMVRMWKMXNMYRMZNNADNGNNIONOKNPRNZDOMRPABPENPGKPHPPKRPLNPRBPYGQARRONRSDRUBRWFSARSBDSCRSDGSEKSGDSHPSLLSOSSRDSSPSTDSYPSZLTHBTJSTMTTNDTOPTRYTTDTWDTZSUAHUGXUSDUYUUZSVEFVNDVUVWSTXAFXCDXOFXPFYERZAR and ZMW. Default is USD.
date_createddate-timeThe date the order was created, in the site’s timezone.READ-ONLY
date_created_gmtdate-timeThe date the order was created, as GMT.READ-ONLY
date_modifieddate-timeThe date the order was last modified, in the site’s timezone.READ-ONLY
date_modified_gmtdate-timeThe date the order was last modified, as GMT.READ-ONLY
discount_totalstringTotal discount amount for the order.READ-ONLY
discount_taxstringTotal discount tax amount for the order.READ-ONLY
shipping_totalstringTotal shipping amount for the order.READ-ONLY
shipping_taxstringTotal shipping tax amount for the order.READ-ONLY
cart_taxstringSum of line item taxes only.READ-ONLY
totalstringGrand total.READ-ONLY
total_taxstringSum of all taxes.READ-ONLY
prices_include_taxbooleanTrue the prices included tax during checkout.READ-ONLY
customer_idintegerUser ID who owns the order. 0 for guests. Default is 0.
customer_ip_addressstringCustomer’s IP address.READ-ONLY
customer_user_agentstringUser agent of the customer.READ-ONLY
customer_notestringNote left by customer during checkout.
billingobjectBilling address. See Order – Billing properties
shippingobjectShipping address. See Order – Shipping properties
payment_methodstringPayment method ID.
payment_method_titlestringPayment method title.
transaction_idstringUnique transaction ID.
date_paiddate-timeThe date the order was paid, in the site’s timezone.READ-ONLY
date_paid_gmtdate-timeThe date the order was paid, as GMT.READ-ONLY
date_completeddate-timeThe date the order was completed, in the site’s timezone.READ-ONLY
date_completed_gmtdate-timeThe date the order was completed, as GMT.READ-ONLY
cart_hashstringMD5 hash of cart items to ensure orders are not modified.READ-ONLY
meta_dataarrayMeta data. See Order – Meta data properties
line_itemsarrayLine items data. See Order – Line items properties
tax_linesarrayTax lines data. See Order – Tax lines propertiesREAD-ONLY
shipping_linesarrayShipping lines data. See Order – Shipping lines properties
fee_linesarrayFee lines data. See Order – Fee lines properties
coupon_linesarrayCoupons line data. See Order – Coupon lines properties
refundsarrayList of refunds. See Order – Refunds propertiesREAD-ONLY
set_paidbooleanDefine if the order is paid. It will set the status to processing and reduce stock items. Default is false.WRITE-ONLY

Order – Billing properties

AttributeTypeDescription
first_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.

Order – Shipping properties

AttributeTypeDescription
first_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.

Order – Meta data properties

AttributeTypeDescription
idintegerMeta ID.READ-ONLY
keystringMeta key.
valuestringMeta value.

Order – Line items properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
namestringProduct name.
product_idintegerProduct ID.
variation_idintegerVariation ID, if applicable.
quantityintegerQuantity ordered.
tax_classstringSlug of the tax class of product.
subtotalstringLine subtotal (before discounts).
subtotal_taxstringLine subtotal tax (before discounts).READ-ONLY
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).READ-ONLY
taxesarrayLine taxes. See Order – Taxes propertiesREAD-ONLY
meta_dataarrayMeta data. See Order – Meta data properties
skustringProduct SKU.READ-ONLY
pricestringProduct price.READ-ONLY

Order – Tax lines properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
rate_codestringTax rate code.READ-ONLY
rate_idstringTax rate ID.READ-ONLY
labelstringTax rate label.READ-ONLY
compoundbooleanShow if is a compound tax rate.READ-ONLY
tax_totalstringTax total (not including shipping taxes).READ-ONLY
shipping_tax_totalstringShipping tax total.READ-ONLY
meta_dataarrayMeta data. See Order – Meta data properties

Order – Shipping lines properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
method_titlestringShipping method name.
method_idstringShipping method ID.
totalstringLine total (after discounts).
total_taxstringLine total tax (after discounts).READ-ONLY
taxesarrayLine taxes. See Order – Taxes propertiesREAD-ONLY
meta_dataarrayMeta data. See Order – Meta data properties

Order – Fee lines properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
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).READ-ONLY
taxesarrayLine taxes. See Order – Taxes propertiesREAD-ONLY
meta_dataarrayMeta data. See Order – Meta data properties

Order – Coupon lines properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
codestringCoupon code.
discountstringDiscount total.READ-ONLY
discount_taxstringDiscount total tax.READ-ONLY
meta_dataarrayMeta data. See Order – Meta data properties

Order – Refunds properties

AttributeTypeDescription
idintegerRefund ID.READ-ONLY
reasonstringRefund reason.READ-ONLY
totalstringRefund total.READ-ONLY

Order – Taxes properties

AttributeTypeDescription
idintegerItem ID.READ-ONLY
rate_codestringTax rate code.READ-ONLY
rate_idstringTax rate ID.READ-ONLY
labelstringTax rate label.READ-ONLY
compoundbooleanShow if is a compound tax rate.READ-ONLY
tax_totalstringTax total (not including shipping taxes).READ-ONLY
shipping_tax_totalstringShipping tax total.READ-ONLY
meta_dataarrayMeta data. See Order – Meta data properties