WPHEKA Edit & Cancel Orders for WooCommerce icon
eCommerce & WooCommerce

WPHEKA Edit & Cancel Orders for WooCommerce hooks reference

  • By WPHEKA
  • v1.4.3 New
  • Updated

WPHEKA Edit & Cancel Orders for WooCommerce 1.4.3 has 27 actions and 46 filters, read directly from its source code on Nov 19, 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 WPHEKA Edit & Cancel Orders for WooCommerce fires an action
add_action( 'edit_orders_for_woocommerce_email_after_summary', function( $order, $isset, $plain_text, $email ) {
	// Your code runs here.
}, 10, 4 );

// Change a value WPHEKA Edit & Cancel Orders for WooCommerce is about to use
add_filter( 'edit_orders_for_woocommerce_email_data', function( $value, $id, $balance ) {
	// Change $value here.
	return $value;
}, 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

  • templates/emails/edit-orders-balance-due.php line 58 · used in 14 places
    /**
     * After the summary, before the order details (since 1.4.0).
     */
    do_action( 'edit_orders_for_woocommerce_email_after_summary', $order, isset( $data ) ? (array) $data : array(), $plain_text, $email );
  • includes/emails/class-edit-orders-for-woocommerce-email-balance-due.php line 87 · used in 4 places
    /**
     * This filter is documented in
     * includes/emails/class-edit-orders-for-woocommerce-email-base.php
     */
    apply_filters( 'edit_orders_for_woocommerce_email_data', array( 'changes' => (array) $changes ), $this->id, $balance );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 447 · used in 2 places
    /**
     * Fired when a customer changes their own order.
     */
    do_action( 'edit_orders_for_woocommerce_customer_changed', wc_get_order( $order->get_id() ), array( 'changes' => $result['plan']->get_descriptions(), 'balance_due' => ( $balance && 'balance_due' === $result['status'] ) ? $balance->get_total() : 0, 'extra_on_delivery' => ( $balance && 'collect_on_delivery' === $result['status'] && (float) $balance->get_total() > 0 ) ? $balance->get_total() : 0, ) );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 687 · used in 2 places
    /**
     * This filter is documented below.
     */
    apply_filters( 'edit_orders_for_woocommerce_panel_args', null, $order, $key );
  • includes/admin/class-edit-orders-for-woocommerce-orders-list.php line 147 · used in 2 places
    /**
     * This filter is documented in
     * includes/engine/class-edit-orders-for-woocommerce-eligibility.php
     */
    apply_filters( 'edit_orders_for_woocommerce_pay_on_delivery_gateways', array( 'cod' ) );
  • includes/admin/class-edit-orders-for-woocommerce-activity.php line 76
    /**
     * Answer a request in the queue. Return true or a WP_Error to handle it, or
     * null to let the plugin answer (cancellation requests only).
     */
    apply_filters( 'edit_orders_for_woocommerce_activity_decide', null, $order, $type, $decision, $message );
  • includes/admin/class-edit-orders-for-woocommerce-activity.php line 200
    /**
     * Requests waiting for the store. Add rows of your own type (for example
     * customer edits waiting for approval) and answer them on
     * edit_orders_for_woocommerce_activity_decide.
     */
    apply_filters( 'edit_orders_for_woocommerce_activity_requests', $rows );
  • includes/admin/class-edit-orders-for-woocommerce-activity.php line 227
    /**
     * The heading and line above the requests queue. Change them when you add
     * request types other than cancellations
     * (edit_orders_for_woocommerce_activity_requests).
     */
    apply_filters( 'edit_orders_for_woocommerce_activity_requests_heading', array( 'title' => __( 'Cancellation requests', 'wpheka-edit-orders-for-woocommerce' ), 'description' => __( 'Customers asking to cancel, waiting for your decision.', 'wpheka-edit-orders-for-woocommerce' ), ) );
  • includes/admin/class-edit-orders-for-woocommerce-admin.php line 408
    /**
     * Print more fields in the editor's Address tab, inside its form. A field
     * named `shipping_method` (a rate ID such as flat_rate:3) is posted with the
     * address, and on its own changes only the shipping method.
     */
    do_action( 'edit_orders_for_woocommerce_admin_address_tab', $order );
  • includes/admin/class-edit-orders-for-woocommerce-admin.php line 782
    /**
     * Options for a store owner's change, passed to the executor and to
     * edit_orders_for_woocommerce_before_apply, for example a choice made in
     * fields printed on edit_orders_for_woocommerce_admin_preview_after. Sanitise
     * what you read from $posted.
     */
    apply_filters( 'edit_orders_for_woocommerce_admin_apply_args', $args, $order, $form );
  • includes/admin/class-edit-orders-for-woocommerce-admin.php line 625
    /**
     * Print more in the store owner's preview, before the Apply button. Fields
     * here are posted with the change (read them on
     * edit_orders_for_woocommerce_admin_apply_args).
     */
    do_action( 'edit_orders_for_woocommerce_admin_preview_after', $order, $plan );
  • includes/engine/class-edit-orders-for-woocommerce-settlement-executor.php line 453
    /**
     * Fired after a change set is applied or sent for payment.
     */
    do_action( 'edit_orders_for_woocommerce_after_apply', $order, $result, $actor, $args );
  • includes/engine/class-edit-orders-for-woocommerce-balance-orders.php line 887
    /**
     * Fired once when a balance order is paid and its changes are applied.
     */
    do_action( 'edit_orders_for_woocommerce_balance_paid', $balance, $order, $result );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 472
    /**
     * Where the customer goes to pay for their change.
     */
    apply_filters( 'edit_orders_for_woocommerce_balance_redirect', $balance->get_checkout_payment_url(), $balance, $order, $actor, $data );
  • includes/engine/class-edit-orders-for-woocommerce-settlement-executor.php line 342
    /**
     * Fired before a change set is applied or sent for payment.
     */
    do_action( 'edit_orders_for_woocommerce_before_apply', $order, $plan, $actor, $args );
  • includes/engine/class-edit-orders-for-woocommerce-eligibility.php line 144
    /**
     * Final say on whether a line can be changed.
     */
    apply_filters( 'edit_orders_for_woocommerce_can_change_item', $result, $order, $item, $change, $actor );
  • includes/engine/class-edit-orders-for-woocommerce-eligibility.php line 90
    /**
     * Final say on whether an order can be edited.
     */
    apply_filters( 'edit_orders_for_woocommerce_can_edit', $result, $order, $action, $actor );
  • includes/engine/class-edit-orders-for-woocommerce-cancellation.php line 522
    /**
     * Fired when the store declines a cancellation request.
     */
    do_action( 'edit_orders_for_woocommerce_cancel_declined', $order, $message );
  • templates/myaccount/edit-order.php line 315
    /**
     * Print more fields in the cancel form, after the reason.
     */
    do_action( 'edit_orders_for_woocommerce_cancel_form_fields', $order, $order_key, $edit_orders_for_woocommerce_args );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 247
    /**
     * Show something else instead of cancelling, for example a retention offer.
     * Return a panel state (an array with a `type` the panel prints on
     * edit_orders_for_woocommerce_panel_state) to stop here, or null to go on.
     */
    apply_filters( 'edit_orders_for_woocommerce_cancel_intercept', null, $order, $data, $actor, $reason );
  • includes/engine/class-edit-orders-for-woocommerce-cancellation.php line 316
    /**
     * What cancelling an order refunds, for example less a cancellation fee. The
     * amount reaches the refund, the activity log, the result and the emails.
     */
    apply_filters( 'edit_orders_for_woocommerce_cancel_refund', array( 'lines' => self::remaining_lines( $order ), 'amount' => $amount, 'fee' => 0.0, ), $order, $actor, $reason );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 263
    /**
     * More about a cancellation request, kept with it (for example the lines of a
     * partial cancellation).
     */
    apply_filters( 'edit_orders_for_woocommerce_cancel_request_details', array(), $order, $data, $actor );
  • includes/engine/class-edit-orders-for-woocommerce-cancellation.php line 104
    /**
     * Fired when a customer asks to cancel and the store must decide.
     */
    do_action( 'edit_orders_for_woocommerce_cancel_requested', $order, $reason );
  • includes/engine/class-edit-orders-for-woocommerce-cancellation.php line 288
    /**
     * Fired when an order is cancelled through this plugin.
     */
    do_action( 'edit_orders_for_woocommerce_cancelled', wc_get_order( $order->get_id() ), $actor, $reason, $result );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 318
    /**
     * Carry out a customer action that isn't a change set, for example accepting
     * an offer. Return a result in the panel's shape (type success, error or
     * preview, message, redirect), or null.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_action', null, $action, $order, $data, $actor );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 192
    /**
     * Customer actions offered. Add or remove action keys to change what the panel
     * shows.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_actions', $actions );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 349
    /**
     * Final say on a customer action.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_can', true, $order, $action, $actor );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 413
    /**
     * Stop a confirmed customer change before it is applied, for example to send
     * it to the store for approval. Return a panel result (type success, error or
     * another state, message) to stop, or null to apply as usual.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_change_intercept', null, $order, $changes, $plan, $actor );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 300
    /**
     * Changes for a customer action the plugin doesn't know. Return the raw
     * changes (see Edit_Orders_For_WooCommerce_Change_Set) to run them through the
     * same preview, confirmation, fingerprint check, apply and redirect as the
     * built-in actions, or null when the action isn't a change set.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_changes', null, $action, $order, $data, $actor );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 381
    /**
     * What the customer's preview shows. Keep `fields`: the confirm form repeats
     * them.
     */
    apply_filters( 'edit_orders_for_woocommerce_customer_preview', $preview, $plan, $order, $action );
  • includes/engine/class-edit-orders-for-woocommerce-log.php line 81
    /**
     * Turn debug logging (info and debug entries) on or off in code.
     */
    apply_filters( 'edit_orders_for_woocommerce_debug_log', Edit_Orders_For_WooCommerce_Settings::is_on( 'debug_log' ) );
  • includes/engine/class-edit-orders-for-woocommerce-cancellation.php line 174
    /**
     * Carry out a cancellation instead of the plugin, for example a partial one.
     * Return null to cancel the whole order as usual, or a result (array or
     * WP_Error) to stop here. Runs while the order's cancel guard is held.
     */
    apply_filters( 'edit_orders_for_woocommerce_execute_cancel', null, $order, $actor, $reason, (array) $order->get_meta( self::REQUEST_META ) );
  • includes/engine/class-edit-orders-for-woocommerce-address-change.php line 650
    /**
     * Whether an edited order qualifies for a free shipping method after an
     * address change.
     */
    apply_filters( 'edit_orders_for_woocommerce_free_shipping_available', $available, $order, $method );
  • includes/engine/class-edit-orders-for-woocommerce-hold.php line 541
    /**
     * Fired when a held order moves to Processing.
     */
    do_action( 'edit_orders_for_woocommerce_hold_released', $order, $reason );
  • includes/engine/class-edit-orders-for-woocommerce-hold.php line 373
    /**
     * Fired when a paid order starts waiting as Open for changes.
     */
    do_action( 'edit_orders_for_woocommerce_hold_started', $order, $release_at );
  • includes/engine/class-edit-orders-for-woocommerce-eligibility.php line 190
    /**
     * Whether the order's payment is authorized but not captured.
     */
    apply_filters( 'edit_orders_for_woocommerce_is_authorization_only', $uncaptured, $order );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 169
    /**
     * Whether an order counts as shipped, which stops customer changes.
     */
    apply_filters( 'edit_orders_for_woocommerce_is_shipped', $shipped, $order );
  • includes/engine/class-edit-orders-for-woocommerce-refunds.php line 291
    /**
     * Fired when an edit needs a refund the store owner must make by hand.
     */
    do_action( 'edit_orders_for_woocommerce_manual_refund_needed', $order, $amount, $refund_id, $gateway_error, $reason );
  • includes/engine/class-edit-orders-for-woocommerce-change-set.php line 175
    /**
     * Normalise a change type the plugin doesn't know. Return the change as an
     * array (with its `type`) to accept it, then plan it on
     * edit_orders_for_woocommerce_plan_change. Return a string to refuse it with
     * that message.
     */
    apply_filters( 'edit_orders_for_woocommerce_normalise_change', __( 'Unknown change.', 'wpheka-edit-orders-for-woocommerce' ), $change );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 257
    /**
     * Whether an order is left out of customer changes.
     */
    apply_filters( 'edit_orders_for_woocommerce_order_excluded', $excluded, $order );
  • includes/admin/class-edit-orders-for-woocommerce-admin-page.php line 288
    /**
     * Print a tab added through edit_orders_for_woocommerce_page_tabs. Only runs
     * for users with the tab's capability.
     */
    do_action( "edit_orders_for_woocommerce_page_tab_{$tab}", $links );
  • includes/admin/class-edit-orders-for-woocommerce-admin-page.php line 139
    /**
     * Tabs on WPHEKA > Edit Orders. A tab added here is printed by the action
     * edit_orders_for_woocommerce_page_tab_{key}, and shown only to users with its
     * capability.
     */
    apply_filters( 'edit_orders_for_woocommerce_page_tabs', $tabs );
  • templates/myaccount/edit-order.php line 283
    /**
     * Print more actions in the panel, before Cancel.
     */
    do_action( 'edit_orders_for_woocommerce_panel_actions', $order, $actions, $order_key, $edit_orders_for_woocommerce_args );
  • templates/myaccount/edit-order.php line 140
    /**
     * Print a panel state an extension returned, such as an offer.
     */
    do_action( 'edit_orders_for_woocommerce_panel_state', $state, $order, $order_key );
  • includes/engine/class-edit-orders-for-woocommerce-settlement-plan.php line 202
    /**
     * Plan a change type the plan doesn't know (one added through
     * edit_orders_for_woocommerce_normalise_change). Use the plan's mutators
     * (add_refund_line(), add_balance_item(), set_extra() and so on).
     */
    do_action( 'edit_orders_for_woocommerce_plan_change', $plan, $order, $change );
  • includes/engine/class-edit-orders-for-woocommerce-settlement-executor.php line 690
    /**
     * Fired once a plan has been carried out: money moved, lines switched, the
     * order note written and the order saved. Also after a balance order is paid.
     */
    do_action( 'edit_orders_for_woocommerce_plan_run', $order, $plan, $balance, $result );
  • templates/myaccount/edit-order.php line 124
    /**
     * At the end of the customer's preview, after the confirm form.
     */
    do_action( 'edit_orders_for_woocommerce_preview_after', $edit_orders_for_woocommerce_preview, $order, $state );
  • includes/engine/class-edit-orders-for-woocommerce-refunds.php line 61
    /**
     * Handle a refund instead of the plugin, for example as store credit. Return
     * null to let the plugin refund as usual, a WP_Error to stop, or a result in
     * the plugin's own shape: { refund_id, manual, gateway_error, on_delivery },
     * plus an optional destination.
     */
    apply_filters( 'edit_orders_for_woocommerce_refund_handler', null, $order, $refund_lines, (float) $amount, $reason, (string) $context, (bool) $customer_email );
  • includes/engine/class-edit-orders-for-woocommerce-refunds.php line 225
    /**
     * Refund meta keys that may hold the gateway's refund ID, checked in order.
     */
    apply_filters( 'edit_orders_for_woocommerce_refund_transaction_meta_keys', array( '_transaction_id', '_stripe_refund_id' ), $refund );
  • includes/admin/class-edit-orders-for-woocommerce-activity.php line 266
    /**
     * The text in a request's Reason cell.
     */
    apply_filters( 'edit_orders_for_woocommerce_request_summary', $summary, $order, array_merge( $request, array( 'type' => $type ) ) );
  • includes/class-edit-orders-for-woocommerce-settings.php line 82
    /**
     * Filter a setting.
     */
    apply_filters( 'edit_orders_for_woocommerce_setting', isset( $settings[ $key ] ) ? $settings[ $key ] : null, $key );
  • includes/admin/class-edit-orders-for-woocommerce-settings-form.php line 528
    /**
     * Print more settings sections inside the settings form, after Advanced. Build
     * them with the bundled kit (Fields::section_start() ... section_end()) so the
     * save bar, search and unsaved-changes warning cover them, add their links on
     * edit_orders_for_woocommerce_settings_sections and save them on
     * edit_orders_for_woocommerce_settings_save.
     */
    do_action( 'edit_orders_for_woocommerce_settings_after_sections' );
  • includes/admin/class-edit-orders-for-woocommerce-settings-form.php line 258
    /**
     * The settings form was saved. Save fields printed on
     * edit_orders_for_woocommerce_settings_after_sections from the same post. The
     * nonce and capability were checked before; sanitise every value. Free's
     * change log doesn't record these fields.
     */
    do_action( 'edit_orders_for_woocommerce_settings_save', $post );
  • includes/admin/class-edit-orders-for-woocommerce-admin-page.php line 466
    /**
     * Section links on the Settings tab. Add one for each section printed on
     * edit_orders_for_woocommerce_settings_after_sections.
     */
    apply_filters( 'edit_orders_for_woocommerce_settings_sections', $nav );
  • includes/engine/class-edit-orders-for-woocommerce-settlement-plan.php line 259
    /**
     * Adjust a settlement plan before it is previewed or applied.
     */
    apply_filters( 'edit_orders_for_woocommerce_settlement_plan', $plan, $order, $change_set );
  • includes/engine/class-edit-orders-for-woocommerce-hold.php line 309
    /**
     * Whether a paid order waits as Open for changes instead of going to
     * Processing.
     */
    apply_filters( 'edit_orders_for_woocommerce_should_hold', $hold, $order );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 147
    /**
     * Order meta keys that mean a tracking number was added.
     */
    apply_filters( 'edit_orders_for_woocommerce_tracking_meta_keys', array( '_wc_shipment_tracking_items', '_aftership_tracking_number', '_tracking_number' ) );
  • includes/frontend/class-edit-orders-for-woocommerce-frontend.php line 217
    /**
     * Fired when the customer closes the edit window early.
     */
    do_action( 'edit_orders_for_woocommerce_window_closed', $order );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 104
    /**
     * When the time for customer changes ends, as a timestamp. The countdown, the
     * badge and the hold's release all follow it.
     */
    apply_filters( 'edit_orders_for_woocommerce_window_end', $start + Edit_Orders_For_WooCommerce_Settings::window_seconds(), $order, $start );
  • includes/engine/class-edit-orders-for-woocommerce-customer-rules.php line 124
    /**
     * The longest time for changes any order can have, in seconds. Raise it
     * together with edit_orders_for_woocommerce_window_end when some orders get a
     * longer window.
     */
    apply_filters( 'edit_orders_for_woocommerce_window_max_seconds', Edit_Orders_For_WooCommerce_Settings::window_seconds() );
  • templates/emails/edit-orders-balance-due.php line 23 · used in 7 places
    do_action( 'woocommerce_email_header', $email_heading, $email );
  • templates/emails/edit-orders-balance-due.php line 60 · used in 6 places
    do_action( 'woocommerce_email_order_details', $order, $sent_to_admin, $plain_text, $email );
  • templates/emails/edit-orders-order-updated.php line 70 · used in 2 places
    do_action( 'woocommerce_email_customer_details', $order, $sent_to_admin, $plain_text, $email );
  • includes/engine/class-edit-orders-for-woocommerce-address-change.php line 453
    apply_filters( 'woocommerce_apply_base_tax_for_local_pickup', true );
  • includes/engine/class-edit-orders-for-woocommerce-address-change.php line 454
    apply_filters( 'woocommerce_local_pickup_methods', array( 'legacy_local_pickup', 'local_pickup' ) );
  • includes/engine/class-edit-orders-for-woocommerce-address-change.php line 472
    apply_filters( 'woocommerce_order_get_tax_location', $args, $order );
  • includes/engine/class-edit-orders-for-woocommerce-pricing.php line 83
    apply_filters( 'woocommerce_order_is_vat_exempt', 'yes' === $order->get_meta( 'is_vat_exempt' ), $order );
  • includes/wpheka-ui/class-menu.php line 48
    apply_filters( 'wpheka_plugin_panel_menu_page_capability', 'manage_options' );
  • includes/wpheka-ui/class-menu.php line 44
    apply_filters( 'wpheka_plugin_panel_menu_page_show', true );
  • includes/wpheka-ui/class-menu.php line 50
    apply_filters( 'wpheka_plugins_menu_item_position', '55.5' );

Generated from WPHEKA Edit & Cancel Orders for WooCommerce's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.

Done for you

Rather have it built for you?

Tell us what should change and we’ll write and test the code using these hooks.

Plugin customisation

from $149

New features or changed behaviour, without editing the plugin’s files.

  • Built as a companion plugin, so updates never wipe it
  • Exact quote before we start
  • Tested on staging, then deployed

Typical turnaround: 3–7 business days

Choose this

Not sure which fits? Describe what you need and we’ll suggest the simplest option.

Can't find the right hook?

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