https://supertokens.com/
Join Discord
I have two custom third party providers, one for signing in using SAML(using jackson) and another fo...
m

mayankgopronto

about 2 years ago
I have two custom third party providers, one for signing in using SAML(using jackson) and another for signing in using Microsoft(azure). I get the following error
{"level":"panic","app":"idp","cmd":"server","error":"The providers array has multiple entries for the same third party provider. Please mark one of them as the default one by using 'IsDefault: true'","time":"2023-04-24T16:53:04Z","message":"could not initialize supertokens"}
I was able to make it work by setting one of them as default. I would like to know what does it mean for one of them to be default? Where is this default setting used?
m
r
  • 2
  • 1
  • 7
I'm trying to add a admin role to any user when they sign up but for some reason it is not assigning...
s

Sekai

about 2 years ago
I'm trying to add a admin role to any user when they sign up but for some reason it is not assigning the role. This is the code in the frontend config, where it creates the role and then adds the role
export const frontendConfig = () => {
    return {
        appInfo,
        recipeList: [
            EmailPasswordReact.init({
                onHandleEvent: async (context) => {
                    if (context.action === "SESSION_ALREADY_EXISTS") {
                        // TODO:
                        console.log("Session already exists")
                    } else {
                        if (context.action === "SUCCESS") {
                            if (context.isNewUser) {
                                // TODO: Sign up
                                console.log("User signed up")
                                createRole()
                                addRoleToUser(context.user.id)
                            } else {
                                console.log("User signed in")
                                // TODO: Sign in
                            }
                        }
                    }
                }
            }),
            SessionReact.init(),
        ],
EDIT: now I am getting an error of Initialization not done. Did you forget to call the UserRoles.init or SuperTokens.init functions. and I did in the backend config. when I put it in frontend config it breaks the code so I don't have it.
s
r
w
  • 3
  • 34
  • 7
Is there a way to show the "Sign Up" form by default instead of the "Sign In" page first when using ...
c

chronos_cosmicshadow

about 2 years ago
Is there a way to show the "Sign Up" form by default instead of the "Sign In" page first when using ? Or is there an alternate just for SignUp?
c
r
  • 2
  • 26
  • 7
Im looking at useing the JWT service as a means to generate short lived JWT tokens to be used betwee...
p

pitchash

about 2 years ago
Im looking at useing the JWT service as a means to generate short lived JWT tokens to be used between services. The documentation seems to suggest that every call to Jwt.createJWT involes an http request to the supertokens core is that right?
p
r
  • 2
  • 46
  • 7
I need to store a `tenantId` information on my user (like, to which organisation he belongs). I am ...
w

whatsappxthomas

over 2 years ago
I need to store a
tenantId
information on my user (like, to which organisation he belongs). I am currently doing this via the metadata. Everything is fine there. I am not really happy because I need to make a separate request just to get that info. I need to check that my
current_user
really has access to the tenant he's trying to reach. How can I avoid a second request just to get a basic info ? Can't I have access to those information from the session actually ?
w
r
d
  • 3
  • 8
  • 7
Can someone hwlp me out with difference between web-js and auth-node package, I was using web-js as ...
p

paras

over 2 years ago
Can someone hwlp me out with difference between web-js and auth-node package, I was using web-js as mentioned for own ui, and was trying to add custom login provider to support for linkdln, but getting error for defining
signInAndUpFeature
in recipeList
Argument of type '{ signInAndUpFeature: { providers: { id: string; name: string; buttonComponent: JSX.Element; }[]; }; }' is not assignable to parameter of type 'UserInput'.
  Object literal may only specify known properties, and 'signInAndUpFeature' does not exist in type 'UserInput'.ts(2345)
https://supertokens.com/docs/thirdpartyemailpassword/common-customizations/signup-form/custom-providers
p
r
n
  • 3
  • 44
  • 7
Main thing I've changed is the outgoing port (from 5432 to 5433, so it doesn't conflict with my prim...
d

Deleted User

over 2 years ago
Main thing I've changed is the outgoing port (from 5432 to 5433, so it doesn't conflict with my primary app database)
d
n
s
  • 3
  • 15
  • 7
I'm trying to integrate supertokens with a pre-existing nodejs express server, and can't get Session...
j

johnmeloy

over 2 years ago
I'm trying to integrate supertokens with a pre-existing nodejs express server, and can't get SessionRequest to load. Any ideas? [1] import { SessionRequest } from "supertokens-node/framework/express/index.js"; [1] ^^^^^^^^^^^^^^ [1] SyntaxError: Named export 'SessionRequest' not found. The requested module 'supertokens-node/framework/express/index.js' is a CommonJS module, which may not support all module.exports as named exports. [1] CommonJS modules can always be imported via the default export, for example using:
j
r
  • 2
  • 1
  • 7
Is there any way to manually change a user's email verification status? I saw the docs weren't writt...
n

n000dles

over 2 years ago
Is there any way to manually change a user's email verification status? I saw the docs weren't written yet so I thought I'd ask here for guidance
n
r
  • 2
  • 4
  • 7
Hi , I'm using self-hosted version and using react with typescript for frontend. I implemented custo...
s

syntaxerror1322

over 2 years ago
Hi , I'm using self-hosted version and using react with typescript for frontend. I implemented custom fields to get some additional informations from user while using passwordless recipe. Is there a way to pass custom fields via supertokens-web-js
createCode
function? Currently it doesn't allow me to pass custom fields.
s
r
n
  • 3
  • 27
  • 7
Previous686970Next

SuperTokens.com

SuperTokens is an open source authentication solution offering features like: Different types of login: Email / password, Passwordless (OTP or Magic link based).

Powered by