Skip to main content
All CollectionsWooCommerce Integration
WooCommerce - Extending the feed
WooCommerce - Extending the feed

An outline of you to modify data being sent in the feeds

Peter Brooksbank avatar
Written by Peter Brooksbank
Updated over a week ago

This article is aimed at developers looking to extend/change the data sent to PureClarity in the data feeds.


The following filters are available to hook into and update the data being sent to PureClarity:

  • Product feed - pureclarity_feed_get_product_data

  • Category feed - pureclarity_feed_get_category_data

  • User feed - pureclarity_feed_get_user_data

Example usage

This example adds a custom field to the product data.

* @param mixed[] $data - the array of data that will be sent to PureClarity
* @param WC_Product $product - the WooCommerce product object
* @return mixed
function product_callback($data, $product) {
$data['MyCustomField'] = 'MyCustomData';
return $data;
add_filter( 'pureclarity_feed_get_product_data', 'product_callback', 10, 2 );
Did this answer your question?