DIY sync

WooCommerce MK Soft Connector


List of action and filter hooks supported by the WooCommerce MK Soft Connector plugin. You can use this hooks in your e-shop templates by adding them to the functions.php file or by using the plugin for snippet hooks.

tlw_wc_mksoft_conn_sync_order

  • filter hook for modifying the output fields with order data from the e-shop to MK soft
/**
 * filter hook for order sync to MK soft
 * @param array $order_sync order request output to MK soft
 * @param obj $order eshop order data
 * @param array $custom_company_data company billing data
 * @return array final order request output to MK soft
 */
add_filter('tlw_wc_mksoft_conn_sync_order', function($order_sync, $order, $custom_company_data) {
     return $order_sync;
}, 10, 3);

tlw_wc_mksoft_conn_import_customer

  • filter hook for modifying the input fields with customer data from MK soft to the e-shop
/**
 * filter hook for customer sync from MK soft to eshop
 * @param array $customer_eshop user request output to eshop
 * @param obj $customer_mksoft MK soft customer data
 * @param str $customer_name sanitized customer full name from MK soft
 * @param str $customer_email sanitized customer email from MK soft
 * @return array final customer request to eshop
 */
add_filter('tlw_wc_mksoft_conn_import_customer', function($customer_eshop, $customer_mksoft, $customer_name, $customer_email) {
     return $customer_eshop;
}, 10, 4);

tlw_wc_mksoft_conn_sync_product

  • filter hook for modifying the input fields with simple or variable product data from MK soft to the e-shop
/**
 * filter hook for product sync from MK soft to eshop
 * @param array $product_eshop product request output to eshop
 * @param obj $product_mksoft MK soft product data
 * @return array final product request to eshop
 */
add_filter('tlw_wc_mksoft_conn_sync_product', function($product_eshop, $product_mksoft) {
     return $product_eshop;
}, 10, 2);

tlw_wc_mksoft_conn_sync_product_variation

  • filter hook for modifying the input fields with product variant data from MK soft to the e-shop
/**
 * filter hook for product variation sync from MK soft to eshop
 * @param array $product_variation_eshop product variation request output to eshop
 * @param obj $product_mksoft MK soft product data
 * @return array final product variation request to eshop
 */
add_filter('tlw_wc_mksoft_conn_sync_product_variation', function($product_variation_eshop, $product_mksoft) {
     return $product_variation_eshop;
}, 10, 2);