MagicAuthDevelopers
Developers
Hooks, templates, and the programmatic API.
MagicAuth is built to be extended. Everything you might want to customise is exposed as either a WordPress filter, an action, an overridable template, or a static method.
Where to look
Hooks
Full reference of every action and filter MagicAuth fires.
Templates
Override sign-in shell, sign-in form, email bodies, and the agency credit strip from your theme.
Email customisation
Recipes for changing From, subject, body, and routing through a transactional ESP.
Programmatic API
Issue and send magic links from your own code.
Constants
wp-config.php flags that change MagicAuth's behaviour.
Conventions
- Namespace:
MagicAuth\(PSR-4, autoloaded viavendor/autoload.phpwith a manual fallback). - Hook prefix: every MagicAuth-defined hook is named
magicauth_*. - No global functions in
includes/except the deliberately-procedural helpers inincludes/helpers.php(magicauth_get_setting,magicauth_get_company_name,magicauth_client_ip, etc.). Each is prefixedmagicauth_. - Templates: overridable from
your-theme/magicauth/. Plain PHP, no Blade or Twig. - No JavaScript build step. The front-end JS in
assets/js/is hand-written ES5, no jQuery, no React.
Where to file issues
github.com/nolderoos/magicauth/issues. Include your WordPress version, PHP version, MagicAuth version, and any conflicting plugins.