PDF Invoices & Packing Slips for WooCommerce 4.0.0 has 29 actions and 101 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.
// Run your own code when PDF Invoices & Packing Slips for WooCommerce fires an action
add_action( 'challan_document_held_email', function( $email_object, $type, $arg3 ) {
// Your code runs here.
}, 10, 3 );
// Change a value PDF Invoices & Packing Slips for WooCommerce is about to use
add_filter( 'challan_pro_licensed', function( $value ) {
// Change $value here.
return $value;
}, 10, 1 );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.
Changes by version
3.7.94 → 4.0.0 · Nov 19, 2026 · 56 added, 1 removed
Added
- filter
wpifw_admin_order_list_buttons - filter
challan_pro_active - filter
challan_document_access - filter
wpifw_invoice_generate_ignore - filter
woo_invoice_pro_generate_pdf_for_order_statuses - filter
wpifw_incl_or_exl_tax__price - filter
challan_document_held - filter
wpifw_allow_non_logged_in_users - filter
challan_label_cell_html - filter
challan_document_types - filter
challan_email_attachment_type - action
challan_document_held_email - filter
challan_email_attachment_filename - filter
challan_seller_block - filter
woo_invoice_header_position_customization - action
wpifw_before_header_table_body - filter
challan_header_codes_html - action
woo_invoice_{$hook} - filter
woo_invoice_address_position_customization - filter
woo_invoice_separate_rows_order_info - filter
challan_billing_block - filter
challan_shipping_block - filter
wpifw_invoice_number - filter
woo_invoice_invoice_date - filter
wpifw_enable_packing_slip_footer - filter
woo_invoice_item_title - filter
challan_item_lines - filter
woocommerce_hidden_order_itemmeta - filter
woo_invoice_display_formatted_meta_data - filter
woo_invoice_order_item_image_filter - filter
woocommerce_admin_order_item_thumbnail - filter
woo_invoice_set_rtl - action
woo_invoice_switch_language - action
woo_invoice_restore_language - filter
wpml_current_language - action
wpml_switch_language - filter
wpml_active_languages - filter
challan_packing_slip_after_totals - filter
challan_packing_slip_shows_shipping - action
woo_invoice_restore_previous_language - action
woo_invoice_after_generate_pdf - filter
challan_mpdf_config - filter
challan_paper_option_keys - filter
challan_templates - filter
challan_template_css_file - filter
wpifw_show_invoice_button_styles - filter
challan_document_renderers - filter
challan_pro_licensed - filter
challan_pro_version - filter
challan_bootstrap_payload - filter
challan_bootstrap_schema - filter
challan_bulk_limit - filter
challan_document_filename - filter
challan_system_status_sections - filter
challan_settings_fields - filter
challan_invoicing_enabled
Removed
- filter
challan_pdf_translation_strings
All hooks
-
/** * Filter whether Challan Pro has an active licence. Challan Pro returns its * licence state. */ apply_filters( 'challan_pro_licensed', false ); -
/** * Filter whether Challan Pro is active. Pro returns true. */ apply_filters( 'challan_pro_active', false ); -
/** * Legacy filter preserved. */ apply_filters( 'woo_invoice_file_name', sanitize_file_name( $filename ), $orders[0] ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_filter_template_label', __( $label, 'webappick-pdf-invoice-for-woocommerce' ), $order, $template ); -
/** * Preserved v1 filter. */ apply_filters( 'wpifw_invoice_generate_ignore', true, $order ); -
/** * Whether a non-manager may download this document — add-ons widen it * (Challan Pro: a WCFM vendor for orders with their products). */ apply_filters( 'challan_document_access', $customer_ok, $order, $type ); -
/** * This filter is documented in self::stream(). */ apply_filters( 'challan_document_filename', $name, $order, $renderer->type() ); -
/** * Filter the renderer map. Challan Pro adds its document types * (shipping_label, credit_note) here. Every value must be an AbstractRenderer * built on the GIVEN repository so the same filter also serves the live * preview with overlaid settings. */ apply_filters( 'challan_document_renderers', $renderers, $this->repository(), $this->invoice_number() ); -
/** * Filter which document an order email carries. */ apply_filters( 'challan_email_attachment_type', 'invoice', $email_id, $order ); -
/** * Filter the Challan Pro version shown in the admin app. Challan Pro returns * CHALLAN_PRO_VERSION. */ apply_filters( 'challan_pro_version', null ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_order_date', $value, $this->type(), $order ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_order_number', $order->get_order_number(), 'shipping_label', $order ); -
/** * Preserved v1 Pro filter. */ apply_filters( 'woo_invoice_pro_generate_pdf_for_order_statuses', array( 'all' ) ); -
/** * Preserved v1 filter (per-order product data collection). */ apply_filters( 'woo_invoice_product_data', $rows_data, $this->type(), $order ); -
/** * Preserved v1 Pro filter. */ apply_filters( 'wpifw_incl_or_exl_tax__price', $price, $order ); -
/** * Tracking interval */ apply_filters( "{$this->client->getSlug()}_tracking_interval", '-1 week' ); -
/** * after request to api server */ do_action( "{$this->getSlug()}_after_request", $response, $route ); -
/** * after request to api server to route */ do_action( "{$this->getSlug()}_after_request_{$route}", $response, $route ); -
/** * before request to api server */ do_action( "{$this->getSlug()}_before_request", $params, $route, $headers, $this->clientVersion, $url ); -
/** * before request to api server to route */ do_action( "{$this->getSlug()}_before_request_{$route}", $params, $route, $headers, $url ); -
/** * Request Blocking mode. Set it to true for debugging the response with after * request action */ apply_filters( "{$this->getSlug()}_request_blocking_mode", $blocking ); -
/** * Filter Request Route string */ apply_filters( "{$this->slug}_request_route", $route ); -
/** * API EndPoint */ apply_filters( "{$this->slug}_WebAppick_API_EndPoint", $this->API_EndPoint, $this->apiVersion, $this->clientVersion ); -
/** * Filter Final API URL for request */ apply_filters( "{$this->slug}_WebAppick_API_URL", $URL, $this->API_EndPoint, $route, $this->apiVersion, $this->clientVersion ); -
/** * Billing block markup from an add-on (Challan Pro: v1 Pro's * WooCommerce-formatted address); null keeps this format. */ apply_filters( 'challan_billing_block', null, $order, $this->type(), $this->settings ); -
/** * Filter the full bootstrap payload before it is returned to the SPA. */ apply_filters( 'challan_bootstrap_payload', $payload ); -
/** * Filter the published schema of GET /challan/v1/bootstrap. */ apply_filters( 'challan_bootstrap_schema', $schema ); -
/** * Filter the number of orders rendered per bulk PDF batch. */ apply_filters( 'challan_bulk_limit', self::BULK_LIMIT ); -
/** * Filter whether a document is held back from the customer. */ apply_filters( 'challan_document_held', false, $order, (string) $type ); -
/** * An email went out without its document because the document is held (see * CustomerAccess::held()); Challan Pro sends it once released. */ do_action( 'challan_document_held_email', $email_object, $type, (string) $email_id ); -
/** * Filter the registered document types. */ apply_filters( 'challan_document_types', $types ); -
/** * Filter the file name of a non-invoice email attachment. */ apply_filters( 'challan_email_attachment_filename', $type . '-' . $this->number->for_order( $order ) . '.pdf', $type, $order ); -
/** * Preserved v1 filter. */ apply_filters( 'challan_external_font_dirs', $font_dirs ); -
/** * Header QR/barcode markup — Challan Pro renders the codes here; the cell * always renders (possibly empty) so the three header columns stay equal * thirds. */ apply_filters( 'challan_header_codes_html', '', $order, $this->type(), $this->settings ); -
/** * Filter whether invoicing is on. */ apply_filters( 'challan_invoicing_enabled', $on ); -
/** * One label's content — change or replace it. */ apply_filters( 'challan_label_cell_html', $this->cell( $order, $title ), $order, $this->settings ); -
/** * Filter the mPDF configuration (new name + preserved v1 name). */ apply_filters( 'challan_mpdf_config', $config, $type ); -
/** * Content under the packing totals (Challan Pro: the WCFM refund address). */ apply_filters( 'challan_packing_slip_after_totals', $html, $order ); -
/** * Whether the packing slip prints the shipping block (Challan Pro applies its * shipping-address settings). */ apply_filters( 'challan_packing_slip_shows_shipping', true, $order, $this->settings ); -
/** * Filter the option keys used to resolve a document type's paper format: * array( size_key, custom_width_key, custom_height_key ). Challan Pro adds its * document types here. */ apply_filters( 'challan_paper_option_keys', $map ); -
/** * Filter the seller block of a document, knowing the order (Challan Pro prints * the ZATCA seller profile on documents with a ZATCA e-invoice, so the PDF * matches the XML). */ apply_filters( 'challan_seller_block', $seller, $order, $this->type() ); -
/** * Filter the settings field registry. */ apply_filters( 'challan_settings_fields', Definitions::fields() ); -
/** * Shipping block markup from an add-on (see challan_billing_block). */ apply_filters( 'challan_shipping_block', null, $order, $this->type(), $this->settings ); -
/** * Filter the System status sections. A section is an array with id, label and * checks (rows of label, value, status — ok, warning, critical or info — * and note); the chip is worked out here. */ apply_filters( 'challan_system_status_sections', $sections ); -
/** * Filter the registered document templates. */ apply_filters( 'challan_templates', $templates ); -
/** * Support Page URL */ apply_filters( "WebAppick_{$projectSlug}_Support_Page_URL", false ); -
/** * Set Support Ticket Ajax Error Response. */ apply_filters( "WebAppick_{$projectSlug}_Support_Request_Ajax_Error_Response", false, $_REQUEST ); -
/** * Set Ajax Success Response for Support Ticket Submission */ apply_filters( "WebAppick_{$projectSlug}_Support_Request_Ajax_Success_Response", false, $_REQUEST ); -
/** * Set Support Ticket Template For sending the email query. */ apply_filters( "WebAppick_{$projectSlug}_Support_Ticket_Email_Template", false ); -
/** * Set Ticket Recipient Email */ apply_filters( "WebAppick_{$projectSlug}_Support_Ticket_Recipient_Email", false ); -
/** * Preserved v1 Pro filter (same cell ids). */ apply_filters( 'woo_invoice_address_position_customization', $order_keys, $order, $this->type() ); -
/** * Preserved v1 Pro action (after a PDF is produced). */ do_action( 'woo_invoice_after_generate_pdf', $type ); -
/** * Preserved v1 filters. */ apply_filters( 'woo_invoice_background_watermark', $background, $type ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_billing_info', $billing, $order, $this->type() ); -
/** * Preserved v1 filter (v1 shape: the labeled note). */ apply_filters( 'woo_invoice_customer_notes', $note, $this->type(), $order ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_default_css_file', $dir . 'default.css' ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_default_font_family_name', $default_font ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_display_formatted_meta_data', $html, $this->type() ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_email_types', $enabled ); -
/** * Preserved v1-pro filter (same segment ids). */ apply_filters( 'woo_invoice_header_position_customization', $segments, $order, $this->type() ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_invoice_date', date_i18n( $date_format, $date->getTimestamp() ), $this->type(), $order ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_item_title', $this->item_name( $item ), $order, $item->get_product_id(), $item->get_id() ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_meta_value_filter', get_post_meta( $product->get_id(), $post_meta_name, true ), $post_meta_name ); -
/** * Preserved v1 filter (image size). */ apply_filters( 'woo_invoice_order_item_image_filter', array( 'width' => '50', 'height' => '50', ), $product, $item ); -
/** * Preserved v1 filters. */ apply_filters( 'woo_invoice_packing_total', $total_qty, $this->type(), $order ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_paper_size', $format, $type ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_pdf_font_data', $font_defaults['fontdata'], $type ); -
/** * Preserved v1 action. */ do_action( 'woo_invoice_restore_language' ); -
/** * Preserved v1 Pro action (before a PDF is produced). */ do_action( 'woo_invoice_restore_previous_language', '' ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_seller_info', $seller, $this->type() ); -
/** * Preserved v1 Pro filter: one row per cell. */ apply_filters( 'woo_invoice_separate_rows_order_info', false, $order, $this->type() ); -
/** * Preserved v1 filter ('rtl' or ''). */ apply_filters( 'woo_invoice_set_rtl', $rtl, $order ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_shipping_info', $shipping, $order, $this->type() ); -
/** * Preserved v1 filter — now defaulting to the full state name. */ apply_filters( 'woo_invoice_state_name', $state_full, $country_code, $order, WC()->countries ); -
/** * Preserved v1 filter. */ apply_filters( 'woo_invoice_store_logo', $logo ); -
/** * Preserved v1 action. */ do_action( 'woo_invoice_switch_language', $locale ); -
/** * Filter the template stylesheet path — lets Challan Pro resolve its own * template files. Both the v1 filter name and the v2 alias are applied. */ apply_filters( 'woo_invoice_template_css_file', $file ); -
/** * WooCommerce's admin thumbnail filter, as v1 applied it. */ apply_filters( 'woocommerce_admin_order_item_thumbnail', $img, $item->get_id(), $item ); -
/** * Preserved v1 (free) filter. */ apply_filters( 'wpifw_admin_order_action_buttons', $buttons ); -
/** * Preserved v1 (pro) filter. */ apply_filters( 'wpifw_admin_order_list_buttons', $buttons, $order->get_id() ); -
/** * Preserved v1 Pro action (invoice only). */ do_action( 'wpifw_before_header_table_body' ); -
/** * Preserved v1 filters. */ apply_filters( 'wpifw_before_last_tr_free', '', $order, $this->type() ); -
/** * Preserved v1 Pro filter (the printed invoice number). */ apply_filters( 'wpifw_invoice_number', $number, $order ); -
/** * Preserved v1 filter. */ apply_filters( 'wpifw_invoice_product_per_page', $per_page ); -
/** * Preserved v1 filter: label => url. */ apply_filters( 'wpifw_order_buttons_array', $buttons ); -
do_action( 'woo_invoice_after_item_meta', $product, $order, $template_type ); -
do_action( 'woo_invoice_after_product_list', $order, $template_type ); -
do_action( 'woo_invoice_before_item_meta', $product, $order, $template_type ); -
do_action( 'woo_invoice_before_product_list', $order, $template_type ); -
do_action( 'woo_invoice_after_customer_notes', $order, $template_type ); -
do_action( 'woo_invoice_after_document', $order, $template_type ); -
do_action( 'woo_invoice_after_seller_info', $order, $template_type ); -
do_action( 'woo_invoice_before_customer_notes', $order, $template_type ); -
do_action( 'woo_invoice_before_document', $order, $template_type ); -
do_action( 'woo_invoice_before_seller_info', $order, $template_type ); -
do_action( 'woo_invoice_custom_style', $template_type ); -
do_action( 'wpml_switch_language', $code ); -
apply_filters( "{$this->client->getSlug()}_extra_uninstall_reasons", array(), $reasons ); -
apply_filters( "{$this->client->getSlug()}_tracker_data", $data ); -
apply_filters( "{$this->client->getSlug()}_tracking_default_notice_message", esc_html__( 'Want to help make %1$s even more awesome? Allow %1$s to collect non-sensitive diagnostic data and usage information.', 'webappick-pdf-invoice-for-woocommerce' ) ); -
apply_filters( "{$this->client->getSlug()}_what_tracked", $data ); -
apply_filters( 'challan_item_lines', '', $where, $item, $order, $this->type() ); -
apply_filters( 'challan_promotions_source_url', '' ); -
apply_filters( 'challan_template_css_file', $file, $template_id ); -
apply_filters( 'WebAppick_is_local', in_array($remote_addr, array('127.0.0.1', '::1')) ); -
do_action( "woo_invoice_{$hook}", $order, $this->type(), $hook, $this->settings ); -
do_action( 'woo_invoice_after_billing_address', $order, $template_type ); -
do_action( 'woo_invoice_after_order_data', $order, $template_type ); -
do_action( 'woo_invoice_after_shipping_address', $order, $template_type ); -
apply_filters( 'woo_invoice_background_watermark_opacity', $opacity, $type ); -
do_action( 'woo_invoice_before_billing_address', $order, $template_type ); -
do_action( 'woo_invoice_before_order_data', $order, $template_type ); -
do_action( 'woo_invoice_before_shipping_address', $order, $template_type ); -
apply_filters( 'woo_invoice_delivery_address_title', 'Delivery Address' ); -
apply_filters( 'woo_invoice_invoice_number', $this->number->for_order( $order ), $this->type(), $order ); -
apply_filters( 'woo_invoice_invoice_title', 'Invoice' ); -
apply_filters( 'woo_invoice_mpdf_settings', $config ); -
apply_filters( 'woo_invoice_order_data', $order_info, $this->type(), $order ); -
apply_filters( 'woo_invoice_order_total', $totals_map, $this->type(), $order ); -
apply_filters( 'woo_invoice_packing_slip_title', 'Packing Slip' ); -
apply_filters( 'woo_invoice_packing_total_weight', $total_weight, $order->get_items(), $order, $this->type() ); -
apply_filters( 'wpifw_after_last_tr_free', '', $order, $this->type() ); -
apply_filters( 'wpifw_allow_non_logged_in_users', false ); -
apply_filters( 'wpifw_show_invoice_button_styles', false ); -
apply_filters( 'wpml_active_languages', null, array( 'skip_missing' => 0 ) ); -
apply_filters( 'wpml_current_language', null );
Generated from PDF Invoices & Packing Slips 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.
Custom hook snippet
from $49
A small, update-safe change built on the plugin’s own hooks.
- Code written against the plugin’s actions and filters
- Tested on a staging copy of your site
- Install instructions included
Typical turnaround: 2–3 business days
Choose thisPlugin 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 thisNot 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: