List of Action Hooks in Init User Engine and How to Use Them

Init User Engine offers a robust set of WordPress action hooks that allow developers to extend, integrate, and track key user activities such as leveling up, gaining EXP, wallet transactions, check-ins, VIP purchases, referral bonuses, and admin notifications. This guide provides a complete list of available actions along with examples of how to use them properly.

List of Action Hooks in Init User Engine and How to Use Them

1. init_plugin_suite_user_engine_level_up

Fires when a user levels up.

// Log level-up event
add_action( 'init_plugin_suite_user_engine_level_up', function( $user_id, $new_level ) {
    error_log( "User $user_id reached level $new_level" );
}, 10, 2 );

2. init_plugin_suite_user_engine_exp_added

Fires immediately after EXP is added (before logging).

// Grant badge for big EXP boost
add_action( 'init_plugin_suite_user_engine_exp_added', function( $user_id, $amount ) {
    if ( $amount >= 500 ) {
        // Custom logic here
    }
}, 10, 2 );

3. init_plugin_suite_user_engine_exp_logged

Fires after EXP has been recorded to the log.

// Track EXP log entries
add_action( 'init_plugin_suite_user_engine_exp_logged', function( $user_id, $data ) {
    // $data contains type, value, ref, etc.
}, 10, 2 );

4. init_plugin_suite_user_engine_transaction_logged

Fires after coin/cash transactions are logged.

// Track wallet transaction
add_action( 'init_plugin_suite_user_engine_transaction_logged', function( $user_id, $data ) {
    // $data contains type (coin/cash), value, ref, action
}, 10, 2 );

5. init_plugin_suite_user_engine_add_exp

Fires when EXP is added via a hook (can be filtered externally).

// Customize EXP addition
add_action( 'init_plugin_suite_user_engine_add_exp', function( $user_id, $amount, $context ) {
    // $context can be 'referral', 'checkin', etc.
}, 10, 3 );

6. init_plugin_suite_user_engine_add_coin

Fires when coin is added via hook.

// Monitor coin gain
add_action( 'init_plugin_suite_user_engine_add_coin', function( $user_id, $amount, $context ) {
    // Custom reward logic
}, 10, 3 );

7. init_plugin_suite_user_engine_inbox_inserted

Fires after a new inbox message is inserted.

// Send push or real-time update
add_action( 'init_plugin_suite_user_engine_inbox_inserted', function( $message_id, $data ) {
    // $data includes user_id, title, content, type, etc.
}, 10, 2 );

8. init_plugin_suite_user_engine_after_checkin

Fires after a user successfully checks in.

// Track streak or grant bonus
add_action( 'init_plugin_suite_user_engine_after_checkin', function( $user_id ) {
    // Custom logic for check-in streaks
});

9. init_plugin_suite_user_engine_after_claim_reward

Fires when a user claims their reward after being online.

// Send bonus item if VIP
add_action( 'init_plugin_suite_user_engine_after_claim_reward', function( $user_id ) {
    // Bonus logic for engaged users
});

10. init_plugin_suite_user_engine_vip_purchased

Fires after a VIP package is successfully purchased.

// Log VIP purchase
add_action( 'init_plugin_suite_user_engine_vip_purchased', function( $user_id, $vip_days ) {
    // $vip_days is the duration of the package
});

11. init_plugin_suite_user_engine_referral_completed

Fires after a referral is completed and both sides receive rewards.

// Email the referrer
add_action( 'init_plugin_suite_user_engine_referral_completed', function( $referrer_id, $new_user_id, $rewards ) {
    // $rewards contains both referrer and new user rewards
}, 10, 3 );

12. init_plugin_suite_user_engine_admin_send_notice

Fires when an admin sends a bulk notification from wp-admin.

// Track notification campaigns
add_action( 'init_plugin_suite_user_engine_admin_send_notice', function( $user_ids, $title, $content, $type, $priority, $link, $pinned, $expire ) {
    // For analytics or history logging
}, 10, 8 );

Conclusion

Action hooks in Init User Engine allow deep integration with user activity, enabling custom behavior, notifications, rewards, or third-party integrations. Whether you’re building a gamified system, CRM, or membership logic, these hooks give you the flexibility to extend the plugin to your needs.

Comments


  • No comments yet.

Init Toolbox

Press Ctrl + \ on desktop, or swipe left anywhere on mobile.

Login