Product
For loop type woo_product
, here are the query parameters and fields.
Query parameters
average_rating
- Average rating
Type: numberbackorders
- Backorders allowed
Type: stringcount
- Limit number of results, or -1 for all
Type: numberdate_created
- Date created
Type: stringdate_modified
- Date modified
Type: stringdate_on_sale_from
- Date on sale from
Type: stringdate_on_sale_to
- Date on sale to
Type: stringdownload_expiry
- Download expiry
Type: numberdownload_limit
- Download limit
Type: numberdownloadable
- Downloadable product
Type: booleanexclude
- Exclude product ID(s)
Type: arrayfeatured
- Featured
Type: booleanheight
- Height
Type: numberid
- Same as include
Type: arrayinclude
- Include only product ID(s). This option is overwritten if a membership_id is supplied.
Type: arraylength
- Length
Type: numbermanage_stock
- Product stock management enabled/disabled
Type: booleanmembership_id
- Return only products which grant access to a specific membership plan. Must have membership plugin installed and activated.
Type: numberorder
- Order
Type: string - Default: descorderby
- Order by field
Type: string - Default: nameparent
- Parent product ID(s)
Type: numberparent_exclude
- Exclude parent product ID(s)
Type: arrayprice
- Price
Type: numberproduct_category
- Products by category ID(s), slug(s)
Type: string, arrayproduct_tag
- Products by tag ID(s), slug(s)
Type: string, arrayproduct_type
- Product type
Type: string, array - Default: external,grouped,simple,variable,subscription,variable-subscription,appointmentregular_price
- Regular price
Type: numberreview_count
- Review count
Type: numberreviews_allowed
- Reviews allowed
Type: booleansale_price
- Sale price
Type: numbershipping_class
- Shipping class
Type: string, arraysku
- Product SKU or partial match
Type: stringsold_individually
- Sold individually
Type: booleanstatus
- Status
Type: string, arraystock_quantity
- Stock quantity
Type: numberstock_status
- Stock status
Type: stringtag
- Products by category slug(s)
Type: string, arraytax_class
- Tax status
Type: stringtax_status
- Tax status
Type: stringtotal_sales
- Products with total sales
Type: numbervirtual
- Virtual product (does not require shipping)
Type: booleanvisibility
- Product visibility
Type: stringweight
- Weight
Type: numberwidth
- Width
Type: number
Fields
attributes
- Product attributes if applicable, else empty arrayavailability_span
- Availability spanaverage_rating
- Average ratingbackorders
- Backorders allowedcancel_limit
- Cancel limit valuecancel_limit_unit
- Cancel limit unitcustomer_timezones
- Customer timezonedownload_expiry
- Download expirydownload_limit
- Download limitdownloadable
- Downloadable productduration
- Duration valueduration_unit
- Duration unitexpiration_date
- The date on which the subscription product will expirefeatured
- Featuredfirst_renewal_payment_date
- The first renewal payment will be processed based on the subscription's lengthgrants_access_to_team
- Product grants access to a teamhas_price_label
- Has price labelhas_pricing
- Has pricinghas_restricted_days
- Has restricted days within a weekheight
- Heightid
- IDinterval
- Interval valueinterval_unit
- Interval unitlength
- Returns the length of a subscription productmanage_stock
- Product stock management enabled/disabledname
- Namepadding_duration
- Padding between slots valuepadding_duration_unit
- Padding between slots unitperiod
- Returns the subscription period for a productprice
- Priceprice_label
- Price labelprice_per_period
- Returns the active price per period for a product if it is a subscription.price_string
- Returns a string representing the details of the subscription.pricing
- Pricing,returns list looppurchased
- Product is purchasedqty
- Quantityregular_price
- Returns the sale price per period for a product if it is a subscriptionrequires_confirmation
- Customer must confirmrestricted_days
- Restricted days within a weekreview_count
- Review countreviews_allowed
- Reviews allowedsale_price
- Sale priceshipping_class
- Shipping classsign_up_fee
- The sign-up fee for a subscriptionsku
- Product SKU or partial matchsold_individually
- Sold individuallystock_quantity
- Stock quantitystock_status
- Stock statussubscription_limit
- Subscription limitationsubscriptions
- Active subscription object when restricted to subscription type productstax_class
- Tax statustax_status
- Tax statustotal_sales
- Products with total salestrial_expiration_date
- The date on which the subscription trial will expiretrial_length
- Returns the trial length of a subscription producttrial_period
- Returns the trial period of a subscription producttype
- Product typeurl
- Product URLuser_can_cancel
- User can cancelvariations
- Product variations if applicable, else empty arrayvirtual
- Virtual product (does not require shipping)visibility
- Product visibilityweight
- Weightwidth
- Width