SSO Invalid Provider

Hello, I’m configuring SSO for a project using Better Auth (following the documentation: https://www.better-auth.com/docs/plugins/sso ). After the user logs in via SSO, the callback fails with the following error: Error Code: invalid_provider Error Description: token_response_not_found My provider configuration: providerId: azure OIDC issuer, clientId, clientSecret, endpoints set according to Azure AD Mapping: { id: 'oid', email: 'email', emailVerified: 'email_verified', name: 'name', image: 'picture' } The redirect URI in Azure matches the expected callback path (/api/auth/sso/callback/azure). I’ve checked that the provider registration succeeds and the server is running with the SSO plugin enabled. Could you help me understand why Better Auth fails to recognize the provider at callback?
Single Sign-On (SSO) | Better Auth
Integrate Single Sign-On (SSO) with your application.
No description
Solution:
There was a incorrect configuration of my app
Jump to solution
1 Reply
Solution
Nduboi
Nduboi4w ago
There was a incorrect configuration of my app

Did you find this page helpful?