Description
Description
I encountered an issue with the SuperTokens Node SDK when setting up a custom apiBasePath
in supertokens.init
. When configuring apiBasePath
to include /Dashboard
, the User Management Dashboard's API endpoints fail to function if the paths contain a tenant name. Below are the configuration details and issue specifics.
Configuration Used
supertokens.init({
appName: "Dashboard",
apiDomain: "http://localhost:5000",
websiteDomain: "http://localhost:3000",
apiBasePath: "/Dashboard/auth",
websiteBasePath: "/Dashboard/auth"
});
Setup Details
- Frontend URL:
http://localhost:3000/Dashboard
- Expected User Management Dashboard URL:
http://localhost:5000/Dashboard/auth/dashboard
Issue
After setting apiBasePath
to /Dashboard/auth
, the SuperTokens User Management Dashboard APIs, specifically those containing a tenant name in their paths, fail to work. The expected Dashboard URL (e.g., http://localhost:5000/Dashboard/auth/dashboard
) does not function correctly under this setup.
Steps to Reproduce
- Set up
supertokens.init
as shown in the configuration above. - Attempt to access the User Management Dashboard at the specified URL.
- Observe that any API call involving tenant-specific paths fails to respond correctly.
Expected Behavior
The User Management Dashboard APIs should work seamlessly regardless of custom apiBasePath
configurations, including cases where /Dashboard
is used in the path.
Actual Behavior
APIs with tenant paths in the User Management Dashboard do not function when apiBasePath
is set with /Dashboard
.
Thank you for looking into this issue. Let me know if you need further details or logs.