Login

Demonstrates useDirectusAuth().login() with redirect control.

Login with Providers - loginWithProvider()

Directus Config Required
No SSO providers are configured. The directus-template-cli cms example template does not include any SSO providers by default. To test loginWithProvider(), add an OAuth provider in your Directus instance under Settings → Authentication.

Hook - directus:loggedIn

Fired by the module plugin on every page load when a session exists, and after a successful login. See plugins/auth-events.client.ts in this playground for the listener.

Not yet fired this session.