TrustedLogin Connector 2.0.4 has 8 actions and 27 filters, read directly from its source code on Nov 19, 2026. The list updates automatically when a new version is released.
How to use these hooks
Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.
// Run your own code when TrustedLogin Connector fires an action
add_action( 'trustedlogin/connector/capabilities/changed', function( $role_slug, $cap, $granted, $actor_id ) {
// Your code runs here.
}, 10, 4 );
// Change a value TrustedLogin Connector is about to use
add_filter( 'trustedlogin/connector/auth/use-v2-bearer', function( $value ) {
// Change $value here.
return $value;
}, 10, 1 );Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.
All hooks
-
/** * Fires after a TrustedLogin capability has been granted or revoked on a role * via the Permissions endpoint. */ do_action( 'trustedlogin/connector/capabilities/changed', $role_slug, $cap, $granted, $actor_id ); -
/** * Runs when plugin is ready. */ do_action( 'trustedlogin_connector', $trustedlogin_connector_plugin ); -
/** * Hook: Fires after settings are saved. */ do_action( 'trustedlogin_connector_settings_saved', $count ); -
/** * Runs when plugin is ready. */ do_action_deprecated( 'trustedlogin_vendor', array( $trustedlogin_connector_plugin ), '1.1', 'trustedlogin_connector' ); -
/** * Deprecated settings-saved action alias. */ do_action_deprecated( 'trustedlogin_vendor_settings_saved', array( $count ), '1.1', 'trustedlogin_connector_settings_saved' ); -
/** * Filters whether to send the v2 request-bound HMAC bearer instead of the * legacy static SHA-256 bearer. Filter is provided as a release-gate / * rollback knob — operators can flip back to v1 without redeploying if a * SaaS regression is observed. The underlying SaaS still accepts both for the * foreseeable future. */ apply_filters( 'trustedlogin/connector/auth/use-v2-bearer', true ); -
/** * Filter: allow for other addons to generate the licenses array */ apply_filters( 'trustedlogin/connector/customers/licenses', $licenses, $customer_emails ); -
/** * Filters the effective value of the TRUSTEDLOGIN_DEBUG constant. */ apply_filters( 'trustedlogin/connector/debug-constant', defined( 'TRUSTEDLOGIN_DEBUG' ) ? TRUSTEDLOGIN_DEBUG : null ); -
/** * Filter allows site admins to change where the key is fetched from. */ apply_filters( 'trustedlogin/connector/encryption/get-keys', $keys, $this ); -
/** * Filter allows site admins to change the site option key for storing the keys * data. */ apply_filters( 'trustedlogin/connector/encryption/keys-option', $this->key_option_name, $this ); -
/** * Filters whether to email the site administrator on encryption-tamper and * encryption-reset signals. */ apply_filters( 'trustedlogin/connector/encryption/notify-admin-on-tamper', true, $reason_code ); -
/** * Filter the list of hostnames that are allowed to appear in a decrypted * envelope's `siteUrl` field. Return an empty array to allow any host * (default); return a populated array to restrict redirects to a pre-declared * set. */ apply_filters( 'trustedlogin/connector/envelope/allowed-return-hosts', array() ); -
/** * Controls whether the connector may fetch the SaaS envelope- signing public * key automatically. */ apply_filters( 'trustedlogin/connector/envelope/auto-fetch-key', true ); -
/** * Tolerance between the SaaS-stamped `issuedAt` and the Connector's clock, in * seconds. Wider windows shrink operational friction (NTP drift, request * queueing) but lengthen the time a captured envelope can be replayed. */ apply_filters( 'trustedlogin/connector/envelope/freshness-window', self::FRESHNESS_WINDOW_SECONDS ); -
/** * When true, an envelope that lacks `issuedAt` — or carries a non-integer * value — is rejected instead of accepted on the back-compat fallback. Flip * to true once the deployed SaaS is known to be on the issuedAt-stamping * build. */ apply_filters( 'trustedlogin/connector/envelope/require-freshness', false ); -
/** * Filters whether envelopes must carry a valid signature before the connector * will decrypt them ("hard mode"). */ apply_filters( 'trustedlogin/connector/envelope/require-signature', $verifier->is_enabled() ); -
/** * Filters the hex-encoded sodium Ed25519 public key used to verify SaaS-signed * envelopes. */ apply_filters( 'trustedlogin/connector/envelope/saas-public-key', get_option( 'trustedlogin_vendor_saas_envelope_public_key', null ) ); -
/** * Filter the list of team account_ids the current user is allowed to access * via /wp-json/trustedlogin/v1/activity/* endpoints. */ apply_filters( 'trustedlogin/connector/permitted_team_account_ids', $account_ids, $user_id ); -
/** * Filters whether to email the site administrator on secret-HMAC verification * failures. Same contract as the encryption-tamper filter — return false to * suppress. */ apply_filters( 'trustedlogin/connector/secrets/notify-admin-on-hmac-failure', true, $reason_code ); -
/** * Filters whether to apply rate limiting to secrets endpoints. */ apply_filters( 'trustedlogin/connector/secrets/rate-limit/enabled', true, $action, $ip ); -
/** * Whether to strip third-party admin notices on TL admin pages. */ apply_filters( 'trustedlogin/connector/suppress_admin_notices', true ); -
/** * Filters the list of proxies whose forwarded headers we trust when * determining the client IP. */ apply_filters( 'trustedlogin/connector/trusted-proxies', array() ); -
/** * Deprecated licenses filter alias. */ apply_filters_deprecated( 'trustedlogin/vendor/customers/licenses', array( $licenses, $customer_emails ), '1.1.1', 'trustedlogin/connector/customers/licenses' ); -
/** * Deprecated alias of `trustedlogin/connector/encryption/get-keys`. */ apply_filters_deprecated( 'trustedlogin/vendor/encryption/get-keys', array( $filtered_keys, $this ), '1.1', 'trustedlogin/connector/encryption/get-keys' ); -
/** * Deprecated alias of `trustedlogin/connector/encryption/keys-option`. */ apply_filters_deprecated( 'trustedlogin/vendor/encryption/keys-option', array( $key_option_name, $this ), '1.1', 'trustedlogin/connector/encryption/keys-option' ); -
apply_filters( 'trustedlogin/api-url/saas', TRUSTEDLOGIN_API_URL ); -
do_action( "delete_transient_{$transient}", $transient ); -
apply_filters( "expiration_of_transient_{$transient}", $expiration, $value, $transient ); -
apply_filters( "pre_set_transient_{$transient}", $value, $expiration, $transient ); -
apply_filters( "pre_transient_{$transient}", false, $transient ); -
do_action( "set_transient_{$transient}", $data['value'], $data['expiration'], $transient ); -
do_action( 'setted_transient', $transient, $data['value'], $data['expiration'] ); -
apply_filters( "transient_{$transient}", $value, $transient ); -
apply_filters( 'trustedlogin/connector/login-attempts/resolver-for-team', null, $team_id ); -
apply_filters_deprecated( 'trustedlogin/vendor/permitted_team_account_ids', array( $filtered, $user_id ), '1.4.1', 'trustedlogin/connector/permitted_team_account_ids' );
Generated from TrustedLogin Connector's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.
Done for you
Rather have it built for you?
Tell us what should change and we’ll write and test the code using these hooks.
Custom hook snippet
from $49
A small, update-safe change built on the plugin’s own hooks.
- Code written against the plugin’s actions and filters
- Tested on a staging copy of your site
- Install instructions included
Typical turnaround: 2–3 business days
Choose thisPlugin customisation
from $149
New features or changed behaviour, without editing the plugin’s files.
- Built as a companion plugin, so updates never wipe it
- Exact quote before we start
- Tested on staging, then deployed
Typical turnaround: 3–7 business days
Choose thisNot sure which fits? Describe what you need and we’ll suggest the simplest option.
Can't find the right hook?
We can build the customisation for you. Describe what you need: