Hooks

This page describes the available developer hooks for HeyTodos.

Actions

Hook Pattern: gf_hey_todos_process_{$resource_type}_data

Available Resource Types:

  • gf_hey_todos_process_projects_data

  • gf_hey_todos_process_sections_data

  • gf_hey_todos_process_labels_data

  • gf_hey_todos_process_collaborators_data

  • gf_hey_todos_process_users_data

Parameters:

  • $sync_data (array) - The resource data retrieved from the API for the specific resource type

Usage:

// Hook into projects data processing
add_action( 'gf_hey_todos_process_projects_data', 'my_custom_projects_handler' );

function my_custom_projects_handler( $projects_data ) {
    // Process projects data
    foreach ( $projects_data as $project ) {
        // Handle individual project data
    }
}

// Hook into labels data processing
add_action( 'gf_hey_todos_process_labels_data', 'my_custom_labels_handler' );

function my_custom_labels_handler( $labels_data ) {
    // Process labels data
}

gf_hey_todos_task_creation_failed

Description: Triggered when a Todoist task can't be completed.

Parameters:

gf_hey_todos_task_creation_succeeded

Description: Triggered when a Todoist task is created.

Parameters:

Filters

`gf_hey_todos_process_feed_api_request_body

Description: Filter the API request body before it is sent to the Todoist API.

Parameters:

Return: Todoist API Request Body

gf_hey_todos_scripts

Description: Filters the JavaScript scripts array before they are enqueued in the admin. This uses Gravity Forms script syntax.

Parameters:

  • $scripts (array) - Array of script configurations

Return: Array of script configurations

Usage:

Last updated

Was this helpful?