• ConfigureOptions





clientID: string

The OAuth client ID.


endpoint: string

The endpoint.

Optional sessionType

sessionType? : "cookie" | "refresh_token"

sessionType indicates how session is supposed to be stored. This must match the server side configuration.

If your backend is a server-side rendering website or webapp, then you should use cookie.

Normally, you need to set up a custom domain so that your backend and Authgear can both read and write cookie in the same root domain. You also need to tell the SDK cookie is being used, by specifying "cookie" here.

If not specified, default to "refresh_token".

Optional transientSession

transientSession? : boolean

transientSession indicate if the session in SDK is short-lived session. If transientSession is true means the session is short-lived session. In web, the session will be stored in sessionStorage, that means it only persists within the same browser tab.