- Activation / Deactivation
- Lifecycle
graphql_login_init
graphql_login_before_register_types
graphql_login_after_register_types
graphql_login_after_provider_init
graphql_login_client_init
graphql_login_before_authenticate
graphql_login_after_authenticate
graphql_login_get_user_from_data
graphql_login_validate_client
graphql_login_after_sucecssful_login
graphql_login_link_user_identity
Runs when the plugin is activated.
do_action( 'graphql_login_activate' );
Runs when the plugin is deactivated.
do_action( 'graphql_login_deactivate' );
Runs after the plugin deletes its data on deactivate.
do_action( 'graphql_login_delete_data' );
Runs when the plugin is initialized.
do_action( 'graphql_login_init', $instance );
$instance
(WPGraphQL\Login\Main) : The instance of the plugin.
Runs before the plugin registers any GraphQL types to the schema.
do_action( 'graphql_login_before_register_types' );
Runs after the plugin finishes registering all GraphQL types to the schema.
do_action( 'graphql_login_after_register_types' );
Fires after a Login Provider has been initialized.
do_action( 'graphql_login_after_provider_init', $slug, $provider_config );
$slug
(string) : The provider slug.$provider_config
(WPGraphQL\Login\Auth\ProviderConfig\ProviderConfig) : The instance of the ProviderConfig.
Fires when a Login Client is initialized.
do_action( 'graphql_login_client_init', $slug, $settings, $provider_config, $client );
$slug
(string) : The provider slug.$settings
(array) : The client settings.$provider_config
(WPGraphQL\Login\Auth\ProviderConfig\ProviderConfig) : The instance of the ProviderConfig.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires before the user is authenticated with the provider.
do_action( 'graphql_login_before_authenticate', $slug, $input, $settings, $provider_config, $client );
$slug
(string) : The provider slug.$input
(array) : The mutation input data.$settings
(array) : The client settings.$provider_config
(WPGraphQL\Login\Auth\ProviderConfig\ProviderConfig) : The instance of the ProviderConfig.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires after the user is authenticated with the provider.
do_action( 'graphql_login_after_authenticate', $user_data, $slug, $input, $settings, $provider_config, $client );
$user_data
(array<string,mixed>|\WP_User|\WP_Error|false) : The user data from the Authentication provider.$slug
(string) : The provider slug.$input
(array) : The mutation input data.$settings
(array) : The client settings.$provider_config
(WPGraphQL\Login\Auth\ProviderConfig\ProviderConfig) : The instance of the ProviderConfig.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires when the user is matched from the data. Useful for updating custom meta fields from the provider.
do_action( 'graphql_login_get_user_from_data', $user, $user_data, $slug, $settings, $provider_config, $client );
$user
_( \WP_User|\WP_Error|false) : The user object matched from the data.$user_data
(array<string,mixed>|\WP_User) : The user data from the Authentication provider.$slug
(string) : The provider slug.$settings
(array) : The client settings.$provider_config
(WPGraphQL\Login\Auth\ProviderConfig\ProviderConfig) : The instance of the ProviderConfig.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires when validating the client instance.
do_action( 'graphql_login_validate_client', $client );
$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires after the user is successfully logged in.
do_action( 'graphql_login_after_successful_login', $payload, $user, $user_data, $client );
$payload
(array) : The payload data.$payload['authToken']
(string) : The user's Auth Token.$payload['authTokenExpiration']
(int) : The expiration timestamp of the Auth Token.$payload['refreshToken']
(string) : The user's Refresh Token.$payload['refreshTokenExpiration']
(int) : The expiration timestamp of the Refresh Token.$payload['user']
(WP_User) : The user object.
$user_data
(array<string,mixed>|\WP_User|false) : The user data from the Authentication provider.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.
Fires when linking a user identity.
do_action( 'graphql_login_link_user_identity', $linked_user, $user_data, $client );
$linked_user
(WP_User|false) : The user object. False if the identity could not be linked.$user_data
(array) : The user data from the Authentication provider.$client
(WPGraphQL\Login\Auth\Client) : The instance of the Client.