Documentation: Contradictory requirements for baseURL
configuration causing OAuth authentication failures
#1022
Labels
baseURL
configuration causing OAuth authentication failures
#1022
Uh oh!
There was an error while loading. Please reload this page.
Environment
Reproduction
@sidebase/nuxt-auth
v0.10.1baseURL: '/api/auth'
Result: Client-side authentication requests go to
/providers
instead of/api/auth/providers
, causing authentication failures.Describe the bug
Issue Description
The documentation contains contradictory instructions regarding how
baseURL
should be configured, specifically whether it should contain the full URL (protocol + domain + path) or just the path portion. This inconsistency directly leads to authentication failures with OAuth providers.Investigation Steps Taken
baseURL
configuration and authentication failuresMinimal Reproduction
@sidebase/nuxt-auth
v0.10.1baseURL: '/api/auth'
Result: Client-side authentication requests go to
/providers
instead of/api/auth/providers
, causing authentication failures.Evidence of Contradictory Documentation
In
configuration.md
:In
url-resolutions.md
:In multiple GitHub issues and deployment guides, only the path portion is used:
Root Cause Analysis
The inconsistency appears to be between server-side and client-side URL resolution. While the server correctly processes the configuration, the client-side components are not properly inheriting the base URL prefix, causing requests to incorrect endpoints.
This is particularly problematic with OAuth providers where precise URL construction is essential for the authentication flow to succeed.
Proposed Solution
Documentation must be updated to:
baseURL
in both client and server contextsThe text was updated successfully, but these errors were encountered: