|
/ Documentation /Developer Hooks & Events/ suredonation_import_givewp_batch_complete Action Hook

suredonation_import_givewp_batch_complete Action Hook

Overview

The suredonation_import_givewp_batch_complete action fires after each GiveWP migration batch is processed — whether the import is still running or on its final batch. Use it to persist progress snapshots or report import status.

Hook Signature

do_action( 'suredonation_import_givewp_batch_complete', $import_id, $progress );

Parameters

$import_id _(string)_ – The session UUID for the migration.

$progress _(array)_ – The updated progress payload after this batch. Keys include import_id, started_at, started_by, options, phases, current_phase, offset, campaign_map, donor_map, status, and results.

Usage

add_action( 'suredonation_import_givewp_batch_complete', 'your_custom_function', 10, 2 );

function your_custom_function( $import_id, $progress ) {

    // Your custom logic here.

}

Example

add_action( 'suredonation_import_givewp_batch_complete', 'mysite_track_import_progress', 10, 2 );

function mysite_track_import_progress( $import_id, $progress ) {

    if ( 'completed' === $progress['status'] ) {

        error_log( "GiveWP import {$import_id} finished." );

    }

}

Related Hooks

  • suredonation_import_givewp_session_created
  • suredonation_import_givewp_phase_mappers
Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
Table of Contents
Scroll to Top