Filter hooks reference

Filters let you change values without replacing whole functions. HelpWP exposes a small set; each one is meant to address a real extension scenario.

helpwp_settings_menus

apply_filters( 'helpwp_settings_menus', $menus );

Receives the full settings schema (an array keyed by tab slug). Use this to add a new tab, a new section, or a new field to HelpWP -> Settings. Returning the modified array is enough; the Settings API picks up the new shape automatically.

add_filter( 'helpwp_settings_menus', function( $menus ) {
    $menus['general']['sections']['branding'] = [
        'label'  => 'Branding',
        'desc'   => 'Custom branding overrides.',
        'fields' => [
            'logo_url' => [
                'type'    => 'text',
                'label'   => 'Logo URL',
                'default' => '',
            ],
        ],
    ];
    return $menus;
} );

helpwp_product_post_types

apply_filters( 'helpwp_product_post_types', [] );

The helpwp_product taxonomy is registered against an empty post type list by default. HelpWP itself attaches it to docs and tickets. If you want products to also be assignable to your own custom post type, append your CPT slug:

add_filter( 'helpwp_product_post_types', function( $types ) {
    $types[] = 'release_note';
    return $types;
} );

helpwp_auto_status_transition_on_comment

apply_filters( 'helpwp_auto_status_transition_on_comment', true, $ticket, $is_client, $comment_id );

Returns a boolean. Default true. Returning false skips the automatic status flip (client reply → Waiting, agent reply → In Progress) for that specific comment. The auto responder uses this so its bot replies do not auto-flip the ticket.

add_filter( 'helpwp_auto_status_transition_on_comment', function( $allow, $ticket, $is_client ) {
    // Don't auto-flip when the assigned agent posts an internal note.
    if ( ! $is_client && get_comment_meta( $comment_id, 'is_internal', true ) ) return false;
    return $allow;
}, 10, 4 );

helpwp_get_posts

apply_filters( 'helpwp_get_posts', $posts, $args );

Wraps every internal call to Utility::get_posts() (used by docs and ticket queries). Receives the result array and the original arguments. Use it to inject custom ordering, hide certain posts from non-admins, or attach extra meta to the results.

helpwp_ai_upgrade_url

apply_filters( 'helpwp_ai_upgrade_url', $url, $creds );

The “Upgrade” button in the AI usage card builds a URL pointing to the RAG service with the site key as a query argument. If you self-host the RAG backend or run a custom upgrade flow, replace the URL here.

HELPWP_RAG_SITE constant

This is not a filter. To point HelpWP at a different RAG backend (development server, staging, self-hosted), define the constant in wp-config.php before WordPress loads plugins:

define( 'HELPWP_RAG_SITE', 'https://rag.dev.example.com' );

The plugin reads this constant in helpwp_rag_site_url() and falls back to https://ai.easysuite.org when the constant is not defined.

A note on stability

The filter list is intentionally small. If you find yourself wanting to filter a value that is not exposed, prefer hooking the surrounding action and overwriting the value, rather than monkey-patching the plugin. Filters that prove broadly useful are added in subsequent releases; ad-hoc filters added to your fork tend to break on update.

Was this doc helpful?

Scroll to Top