MyParcel icon
eCommerce & WooCommerce

MyParcel hooks reference

  • By Richard Perdaan
  • v4.26.0
  • Updated

MyParcel 4.26.0 has 9 actions and 17 filters, read directly from its source code on Nov 17, 2026. The list updates automatically when a new version is released.

How to use these hooks

Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.

functions.phpyour child theme
// Run your own code when MyParcel fires an action
add_action( 'admin_print_scripts', function() {
	// Your code runs here.
}, 10, 1 );

// Change a value MyParcel is about to use
add_filter( 'wc_myparcel_order_package_type', function( $allowedPackageType, $order, $object ) {
	// Change $allowedPackageType here.
	return $allowedPackageType;
}, 10, 3 );

Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.

All hooks

  • includes/admin/class-wcmp-export.php line 1007 · used in 3 places
    apply_filters( 'wc_myparcel_order_package_type', $allowedPackageType, $order, $this );
  • includes/class-wcmp-postcode-fields.php line 346 · used in 3 places
    apply_filters( 'wcmp_custom_address_field_class', ['form-row-third first'] );
  • includes/admin/class-wcmypa-admin.php line 1307 · used in 2 places
    apply_filters( 'wc_myparcel_order_delivery_options', $meta, $order );
  • includes/class-wcmp-postcode-fields.php line 100 · used in 2 places
    apply_filters( 'wcmp_checkout_fields_priority', 10, 'billing' );
  • includes/admin/settings/class-wcmypa-settings.php line 217
    apply_filters( "{self::SETTINGS_MENU_SLUG}_tabs", WCMP_Settings_Data::getTabs() );
  • includes/admin/views/html-start.php line 17
    do_action( 'admin_print_scripts' );
  • includes/admin/views/html-start.php line 16
    do_action( 'admin_print_styles' );
  • includes/admin/class-wcmypa-admin.php line 157
    apply_filters( 'deliveryDayFilter', true );
  • plugin_locale

    filter
    woocommerce-myparcel.php line 162
    apply_filters( 'plugin_locale', get_locale(), self::DOMAIN );
  • includes/admin/class-wcmp-export.php line 1571
    apply_filters( 'wc_myparcel_add_consignment', $consignment, $orderSettings );
  • includes/admin/class-wcmypa-admin.php line 887
    apply_filters( 'wc_myparcel_check_privs', $userCannotManageOrders );
  • includes/frontend/class-wcmp-checkout.php line 636
    apply_filters( 'wc_myparcel_show_delivery_options', $showDeliveryOptions );
  • includes/frontend/class-wcmp-checkout.php line 416
    apply_filters( 'wc_wcmp_delivery_options_location', WCMYPA()->setting_collection->getByName(WCMYPA_Settings::SETTING_DELIVERY_OPTIONS_POSITION) );
  • includes/Helper/LabelDescriptionFormat.php line 71
    apply_filters( 'wcmp_formatted_label_description', $formattedLabelDescription, $this->order );
  • includes/admin/class-wcmp-export.php line 629
    do_action( 'wcmp_labels_exported', $order_ids );
  • includes/admin/settings/class-wcmp-settings-callbacks.php line 48
    apply_filters( 'wcmp_settings_validate_input', $input, $output );
  • includes/frontend/class-wcmp-frontend-track-trace.php line 63
    apply_filters( 'wcmyparcel_email_text', __('You can track your order with the following Track & Trace link:', 'woocommerce-myparcel'), $order );
  • includes/frontend/class-wcmp-frontend-track-trace.php line 95
    apply_filters( 'wcmyparcel_myaccount_tracktrace_button', __('Track & Trace', 'woocommerce-myparcel') );
  • includes/admin/class-wcmp-export.php line 1485
    apply_filters( 'woocommerce_evaluate_shipping_cost_args', $args, $sum, $flat_rate_method );
  • includes/frontend/class-wcmp-checkout.php line 432
    do_action( 'woocommerce_myparcel_after_delivery_options' );
  • includes/admin/settings/class-wcmypa-settings.php line 248
    do_action( 'woocommerce_myparcel_after_settings', $active_tab );
  • includes/admin/settings/class-wcmypa-settings.php line 253
    do_action( 'woocommerce_myparcel_after_settings_page', $active_tab );
  • includes/frontend/class-wcmp-checkout.php line 430
    do_action( 'woocommerce_myparcel_before_delivery_options' );
  • includes/admin/settings/class-wcmypa-settings.php line 245
    do_action( 'woocommerce_myparcel_before_settings', $active_tab );
  • includes/admin/settings/class-wcmypa-settings.php line 239
    do_action( 'woocommerce_myparcel_before_settings_page', $active_tab );
  • includes/compatibility/class-wc-product-compatibility.php line 126
    apply_filters( 'woocommerce_product_dimensions', wc_format_dimensions($dimensions), $product );

Generated from MyParcel's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.

Can't find the right hook?

We can build the customisation for you. Describe what you need: