Print Invoice & Delivery Notes for WooCommerce icon
eCommerce & WooCommerce

Print Invoice & Delivery Notes for WooCommerce hooks reference

  • By tychesoftwares
  • v7.4.0 New
  • Updated

Print Invoice & Delivery Notes for WooCommerce 7.4.0 has 41 actions and 65 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 Print Invoice & Delivery Notes for WooCommerce fires an action
add_action( 'wcdn_order_item_after', function( $_wcdn_wc_product, $_wcdn_wc_order, $_wcdn_wc_order_item ) {
	// Your code runs here.
}, 10, 3 );

// Change a value Print Invoice & Delivery Notes for WooCommerce is about to use
add_filter( 'wcdn_order_totals', function( $totals, $order, $template ) {
	// Change $totals here.
	return $totals;
}, 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/api/class-templates.php line 681 · used in 3 places
    /**
     * Filter the order totals array used in document templates.
     */
    apply_filters( 'wcdn_order_totals', $totals, $order, $template );
  • templates/base.php line 948 · used in 2 places
    /**
     * Hook: wcdn_order_item_after
     */
    do_action_deprecated( 'wcdn_order_item_after', array( $_wcdn_wc_product, $_wcdn_wc_order, $_wcdn_wc_order_item ), '7.0.0', 'wcdn_order_item_after_legacy', esc_html__( 'The wcdn_order_item_after hook argument order changed in v7.0. Update your callback to accept ( $item, $order, $template ) instead of ( $product, $order, $item ).', 'woocommerce-delivery-notes' ) );
  • templates/base.php line 845 · used in 2 places
    /**
     * Hook: wcdn_order_item_before
     */
    do_action_deprecated( 'wcdn_order_item_before', array( $_wcdn_wc_product, $_wcdn_wc_order, $_wcdn_wc_order_item ), '7.0.0', 'wcdn_order_item_before_legacy', esc_html__( 'The wcdn_order_item_before hook argument order changed in v7.0. Update your callback to accept ( $item, $order, $template ) instead of ( $product, $order, $item ).', 'woocommerce-delivery-notes' ) );
  • includes/functions/functions.php line 62
    /**
     * Filter administrator email recipients.
     */
    apply_filters( 'wcdn_administrator_emails', $emails );
  • templates/base.php line 732
    /**
     * Hook: wcdn_after_addresses
     */
    do_action( 'wcdn_after_addresses', $order, $template );
  • templates/base.php line 620
    /**
     * Hook: wcdn_after_branding
     */
    do_action( 'wcdn_after_branding', $order, $template );
  • templates/base.php line 1386
    /**
     * Hook: wcdn_after_complimentary_close
     */
    do_action( 'wcdn_after_complimentary_close', $order, $template );
  • templates/creditnote.php line 31
    /**
     * Allow template-specific hooks after.
     */
    do_action( 'wcdn_after_creditnote_template', $data );
  • templates/deliverynote.php line 31
    /**
     * Allow template-specific hooks after.
     */
    do_action( 'wcdn_after_deliverynote_template', $data );
  • templates/base.php line 1443
    /**
     * Hook: wcdn_after_document
     */
    do_action( 'wcdn_after_document', $order, $template );
  • templates/invoice.php line 31
    /**
     * Allow template-specific hooks after.
     */
    do_action( 'wcdn_after_invoice_template', $data );
  • templates/base.php line 1019
    /**
     * Hook: wcdn_after_items
     */
    do_action( 'wcdn_after_items', $order, $template );
  • templates/base.php line 1300
    /**
     * Hook: wcdn_after_notes
     */
    do_action( 'wcdn_after_notes', $order, $template );
  • templates/packingslip.php line 31
    /**
     * Allow template-specific hooks after.
     */
    do_action( 'wcdn_after_packingslip_template', $data );
  • templates/base.php line 1258
    /**
     * Hook: wcdn_after_pay_button
     */
    do_action( 'wcdn_after_pay_button', $order, $template );
  • templates/base.php line 1344
    /**
     * Hook: wcdn_after_policies
     */
    do_action( 'wcdn_after_policies', $order, $template );
  • templates/receipt.php line 31
    /**
     * Allow template-specific hooks after.
     */
    do_action( 'wcdn_after_receipt_template', $data );
  • templates/base.php line 537
    /**
     * Hook: wcdn_after_title
     */
    do_action( 'wcdn_after_title', $order, $template );
  • templates/base.php line 1207
    /**
     * Hook: wcdn_after_totals
     */
    do_action( 'wcdn_after_totals', $order, $template );
  • templates/base.php line 636
    /**
     * Hook: wcdn_before_addresses
     */
    do_action( 'wcdn_before_addresses', $order, $template );
  • templates/base.php line 551
    /**
     * Hook: wcdn_before_branding
     */
    do_action( 'wcdn_before_branding', $order, $template );
  • templates/base.php line 1357
    /**
     * Hook: wcdn_before_complimentary_close
     */
    do_action( 'wcdn_before_complimentary_close', $order, $template );
  • templates/creditnote.php line 18
    /**
     * Allow template-specific hooks before.
     */
    do_action( 'wcdn_before_creditnote_template', $data );
  • templates/deliverynote.php line 18
    /**
     * Allow template-specific hooks before.
     */
    do_action( 'wcdn_before_deliverynote_template', $data );
  • templates/base.php line 407
    /**
     * Hook: wcdn_before_document
     */
    do_action( 'wcdn_before_document', $order, $template );
  • templates/invoice.php line 18
    /**
     * Allow template-specific hooks before.
     */
    do_action( 'wcdn_before_invoice_template', $data );
  • templates/base.php line 769
    /**
     * Hook: wcdn_before_items
     */
    do_action( 'wcdn_before_items', $order, $template );
  • templates/base.php line 1271
    /**
     * Hook: wcdn_before_notes
     */
    do_action( 'wcdn_before_notes', $order, $template );
  • templates/packingslip.php line 18
    /**
     * Allow template-specific hooks before.
     */
    do_action( 'wcdn_before_packingslip_template', $data );
  • templates/base.php line 1220
    /**
     * Hook: wcdn_before_pay_button
     */
    do_action( 'wcdn_before_pay_button', $order, $template );
  • templates/base.php line 1315
    /**
     * Hook: wcdn_before_policies
     */
    do_action( 'wcdn_before_policies', $order, $template );
  • templates/receipt.php line 18
    /**
     * Allow template-specific hooks before.
     */
    do_action( 'wcdn_before_receipt_template', $data );
  • templates/base.php line 510
    /**
     * Hook: wcdn_before_title
     */
    do_action( 'wcdn_before_title', $order, $template );
  • templates/base.php line 1034
    /**
     * Hook: wcdn_before_totals
     */
    do_action( 'wcdn_before_totals', $order, $template );
  • includes/api/class-templates.php line 504
    /**
     * Filter the formatted billing address lines before they appear in the
     * document.
     */
    apply_filters( 'wcdn_billing_address', $billing_address, $order );
  • includes/integrations/class-emails.php line 279
    /**
     * Filter custom email recipients. * @param array      $emails   Email
     * addresses.
     */
    apply_filters( 'wcdn_custom_email_recipients', $emails, $order, $template );
  • includes/api/class-templates.php line 255
    /**
     * Filter the document-level content array before it is passed to templates.
     */
    apply_filters( 'wcdn_document_data', array( 'footer' => $settings['footerText'] ?? '', 'complimentaryClose' => $settings['complimentaryClose'] ?? '', 'policies' => $settings['policies'] ?? '', 'isRTL' => 'rtl' === ( $settings['textDirection'] ?? 'ltr' ), ) );
  • includes/integrations/class-emails.php line 164
    /**
     * Build document data.
     */
    apply_filters( 'wcdn_email_template_data', $this->build_data( $document_order, $template ), $order, $template, $email_id );
  • includes/functions/functions.php line 98
    /**
     * Filter the phone number displayed on documents.
     */
    apply_filters( 'wcdn_format_phone_number', $phone, $country );
  • includes/services/template/class-template-renderer.php line 1322
    /**
     * Filter the direct-download URL for a locale font weight.
     */
    apply_filters( 'wcdn_locale_font_direct_url', $family_map[ $google_family ][ $weight_key ], $google_family, $bold );
  • includes/integrations/class-orddd-integration.php line 106
    /**
     * Filter the ORDD delivery fields before merging into WCDN's order info block.
     */
    apply_filters( 'wcdn_orddd_delivery_fields', $new_fields, $order );
  • includes/api/class-templates.php line 989
    /**
     * Custom fields via filter.
     */
    apply_filters( 'wcdn_order_item_fields', array(), $product, $order, $item );
  • includes/api/class-templates.php line 483
    /**
     * Filter the order items array before it is passed to the document template.
     */
    apply_filters( 'wcdn_order_items', $items, $order, $template );
  • includes/services/template/class-template-renderer.php line 378
    /**
     * Filter the order meta fields shown in the document's order data block.
     */
    apply_filters( 'wcdn_order_meta_fields', $order_meta_fields, $order, $settings, $template );
  • includes/api/class-templates.php line 516
    /**
     * Filter the formatted shipping address lines before they appear in the
     * document.
     */
    apply_filters( 'wcdn_shipping_address', $shipping_address, $order );
  • includes/api/class-templates.php line 213
    /**
     * Filter the shop/store data array before it is passed to document templates.
     */
    apply_filters( 'wcdn_shop_data', array( 'name' => $settings['storeName'] ?? '', 'logo' => $logo, 'logo_path' => $logo_path, 'address' => $settings['storeAddress'] ?? '', 'phone' => $settings['phone'] ?? '', 'email' => $settings['email'] ?? '', ) );
  • includes/services/template/class-template-renderer.php line 77
    /**
     * Filter template data.
     */
    apply_filters( 'wcdn_template_data', $data, $template, $type );
  • templates/base.php line 433
    /**
     * Filter the watermark text displayed on the document.
     */
    apply_filters( 'wcdn_watermark_text', $settings['watermarkText'], $order, $template );
  • includes/api/class-templates.php line 956 · used in 3 places
    apply_filters( 'active_plugins', get_option( 'active_plugins', array() ) );
  • includes/services/template/class-template-renderer.php line 213 · used in 3 places
    apply_filters( 'wcdn_locate_template', $theme_path, $template, $type, 'theme' );
  • includes/component/plugin-deactivation/class-tyche-plugin-deactivation.php line 311 · used in 2 places
    apply_filters( 'ts_tracker_admin_email', get_option( 'admin_email' ) );
  • includes/services/class-pdf.php line 55 · used in 2 places
    apply_filters( 'wcdn_enable_pdf', true );
  • includes/services/template/class-template-renderer.php line 127 · used in 2 places
    apply_filters( 'wcdn_pdf_zoom_mode', $settings['documentZoomMode'] ?? 'layout' );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 239
    do_action( "{$this->plugin_short_name}_init_tracker_completed" );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 417
    apply_filters( "{$this->plugin_short_name}_ts_tracker_data", $data );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 249
    apply_filters( "{$this->plugin_short_name}_ts_tracker_display_notice", true );
  • includes/core/class-install.php line 152
    do_action( "{WCDN_SLUG}_installed" );
  • includes/core/class-install.php line 90
    do_action( "{WCDN_SLUG}_new_installation" );
  • includes/core/class-install.php line 116
    do_action( "{WCDN_SLUG}_updated" );
  • includes/frontend/class-frontend.php line 485
    apply_filters( 'allow_user_email_order_access', false, $order );
  • plugin_locale

    filter
    includes/core/class-hooks.php line 43
    apply_filters( 'plugin_locale', determine_locale(), $domain );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 177
    apply_filters( 'ts_tracker_last_send_interval', strtotime( '-1 week' ) );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 174
    apply_filters( 'ts_tracker_last_send_time', get_option( 'ts_tracker_last_send', false ) );
  • includes/component/plugin-tracking/class-tyche-plugin-tracking.php line 204
    apply_filters( 'ts_tracker_opt_out_data', $params );
  • includes/services/class-pdf.php line 306
    do_action( 'wcdn_after_pdf_generated', $file, $order_id, $template );
  • includes/helpers/class-utils.php line 66
    apply_filters( 'wcdn_allow_check_for_guest_token', ! is_user_logged_in(), $current_user_type, $current_user_id );
  • includes/services/template/class-template-engine.php line 2700
    apply_filters( "wcdn_allowed_statuses_{$template}", $allowed );
  • includes/integrations/class-emails.php line 182
    apply_filters( 'wcdn_attach_pdf_to_new_order_email', false, $email_id, $order, $template );
  • includes/integrations/class-emails.php line 267
    apply_filters( 'wcdn_custom_email_message_body', WC()->mailer()->wrap_message( $subject, $body ), $order, $template );
  • includes/integrations/class-emails.php line 248
    apply_filters( 'wcdn_custom_email_subject', sprintf( __( 'New Order #%1$s — %2$s Attached', 'woocommerce-delivery-notes' ), $order_number, $document_label ), $order, $template );
  • includes/admin/class-backend.php line 77
    apply_filters( 'wcdn_custom_print_url', Utils::get_print_page_url( $wdn_order_id, $template ), $wdn_order_id, $template );
  • includes/helpers/class-utils.php line 627
    apply_filters( 'wcdn_document_title', $name, $template_type );
  • includes/services/template/class-template-style.php line 289
    apply_filters( 'wcdn_dynamic_css', $css, $settings );
  • includes/api/class-templates.php line 796
    apply_filters( 'wcdn_formatted_item_price', $price, $item, $order );
  • templates/base.php line 1067
    apply_filters( 'wcdn_invoice_order_total_label', $label, $order );
  • includes/api/class-templates.php line 576
    apply_filters( 'wcdn_order_info_fields', array(), $order );
  • includes/helpers/class-utils.php line 393
    apply_filters( 'wcdn_order_invoice_date', $formatted_date, (int) $meta_date );
  • includes/helpers/class-utils.php line 349
    apply_filters( 'wcdn_order_invoice_number', $invoice_number );
  • includes/api/class-templates.php line 741
    apply_filters( 'wcdn_order_item_name', $item->get_name(), $item );
  • includes/api/class-templates.php line 437
    apply_filters( 'wcdn_order_item_product', $item->get_product(), $item );
  • includes/api/class-templates.php line 770
    apply_filters( 'wcdn_order_item_quantity', $adjusted_qty, $item );
  • wcdn_pdf_dpi

    filter
    includes/services/class-pdf.php line 236
    apply_filters( 'wcdn_pdf_dpi', 150 );
  • includes/services/class-pdf.php line 350
    apply_filters( 'wcdn_pdf_filename', $filename, $order_id, $template );
  • includes/services/class-pdf.php line 182
    apply_filters( 'wcdn_pdf_generated_file', $file, $order_id, $template );
  • includes/services/template/class-template-renderer.php line 547
    apply_filters( 'wcdn_pdf_locale_font_config', $config, $locale );
  • includes/services/template/class-template-renderer.php line 815
    apply_filters( 'wcdn_pdf_locale_font_path', '', $locale );
  • includes/services/template/class-template-renderer.php line 827
    apply_filters( 'wcdn_pdf_locale_font_url', '', $locale );
  • includes/services/class-pdf.php line 295
    apply_filters( 'wcdn_pdf_orientation', 'portrait', $order_id );
  • includes/services/class-pdf.php line 294
    apply_filters( 'wcdn_pdf_paper_size', Settings::get( 'pdfPaperSize' ), $order_id );
  • includes/services/template/class-template-renderer.php line 847
    apply_filters( 'wcdn_pdf_use_google_fonts_for_locale', true );
  • includes/helpers/class-utils.php line 230
    apply_filters( 'wcdn_placeholder_replacements', $replacements, $order );
  • includes/frontend/class-frontend.php line 547
    apply_filters( 'wcdn_print_document_title', Settings::get( 'defaultDocumentLabel' ), $order_ids, $template );
  • includes/integrations/class-emails.php line 412
    apply_filters( 'wcdn_print_view_in_browser_text_in_email', $link_text );
  • includes/api/class-templates.php line 893
    apply_filters( 'wcdn_product_meta_data', $item->get_formatted_meta_data( '_' ), $item );
  • includes/frontend/class-frontend.php line 140
    apply_filters( 'wcdn_show_print_button_for_order_status', true, $order );
  • includes/services/template/class-template-renderer.php line 190
    apply_filters( 'wcdn_template_css', $css, $context, $data );
  • includes/helpers/class-utils.php line 470
    apply_filters( 'wcdn_template_registration_creditnote', array( 'labels' => array( 'name' => __( 'Credit Note', 'woocommerce-delivery-notes' ), 'name_plural' => __( 'Credit Notes', 'woocommerce-delivery-notes' ), 'print' => __( 'Print Credit Note', 'woocommerce-delivery-notes' ), 'print_plural' => __( 'Print Credit Notes', 'woocommerce-delivery-notes' ), 'message' => __( 'Credit Note created.', 'woocommerce-delivery-notes' ), 'message_plural' => __( ... );
  • includes/helpers/class-utils.php line 440
    apply_filters( 'wcdn_template_registration_delivery_note', array( 'labels' => array( 'name' => __( 'Delivery Note', 'woocommerce-delivery-notes' ), 'name_plural' => __( 'Delivery Notes', 'woocommerce-delivery-notes' ), 'print' => __( 'Print Delivery Note', 'woocommerce-delivery-notes' ), 'print_plural' => __( 'Print Delivery Notes', 'woocommerce-delivery-notes' ), 'message' => __( 'Delivery Note created.', 'woocommerce-delivery-notes' ), 'message_plura... );
  • includes/helpers/class-utils.php line 425
    apply_filters( 'wcdn_template_registration_invoice', array( 'labels' => array( 'name' => __( 'Invoice', 'woocommerce-delivery-notes' ), 'name_plural' => __( 'Invoices', 'woocommerce-delivery-notes' ), 'print' => __( 'Print Invoice', 'woocommerce-delivery-notes' ), 'print_plural' => __( 'Print Invoices', 'woocommerce-delivery-notes' ), 'message' => __( 'Invoice created.', 'woocommerce-delivery-notes' ), 'message_plural' => __( 'Invoices created.',... );
  • includes/helpers/class-utils.php line 485
    apply_filters( 'wcdn_template_registration_packingslip', array( 'labels' => array( 'name' => __( 'Packing Slip', 'woocommerce-delivery-notes' ), 'name_plural' => __( 'Packing Slips', 'woocommerce-delivery-notes' ), 'print' => __( 'Print Packing Slip', 'woocommerce-delivery-notes' ), 'print_plural' => __( 'Print Packing Slips', 'woocommerce-delivery-notes' ), 'message' => __( 'Packing Slip created.', 'woocommerce-delivery-notes' ), 'message_plural' =>... );
  • includes/helpers/class-utils.php line 455
    apply_filters( 'wcdn_template_registration_receipt', array( 'labels' => array( 'name' => __( 'Receipt', 'woocommerce-delivery-notes' ), 'name_plural' => __( 'Receipts', 'woocommerce-delivery-notes' ), 'print' => __( 'Print Receipt', 'woocommerce-delivery-notes' ), 'print_plural' => __( 'Print Receipts', 'woocommerce-delivery-notes' ), 'message' => __( 'Receipt created.', 'woocommerce-delivery-notes' ), 'message_plural' => __( 'Receipts created.',... );
  • includes/helpers/class-utils.php line 569
    apply_filters( 'wcdn_template_types_from_order', $types, $order );

Generated from Print Invoice & Delivery Notes for WooCommerce'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: