@authgear/nextjs / proxy / AuthgearProxyOptions
Interface: AuthgearProxyOptions
Defined in: src/proxy.ts:9
Extends
Properties
clientID
clientID:
string
Defined in: src/types.ts:5
OAuth client ID
Inherited from
cookieName?
optionalcookieName:string
Defined in: src/types.ts:15
Session cookie name. Defaults to “authgear.session”
Inherited from
endpoint
endpoint:
string
Defined in: src/types.ts:3
Authgear endpoint, e.g. “https://myapp.authgear.cloud ”
Inherited from
isSSOEnabled?
optionalisSSOEnabled:boolean
Defined in: src/types.ts:24
Whether to enable SSO (Single Sign-On) with other apps on the same Authgear tenant.
When true (default), Authgear silently reuses its server-side session if the user
is already logged in, so users are not prompted for credentials again.
Set to false to always show the login form (prompt=login), which is recommended
for single-app deployments where silent sign-in feels unexpected to the user.
Defaults to true.
Inherited from
loginPath?
optionalloginPath:string
Defined in: src/proxy.ts:26
URL to redirect unauthenticated users. Defaults to “/api/auth/login”.
postLogoutRedirectURI?
optionalpostLogoutRedirectURI:string
Defined in: src/types.ts:9
Where to redirect after logout
Inherited from
AuthgearConfig.postLogoutRedirectURI
protectedPaths?
optionalprotectedPaths:string[]
Defined in: src/proxy.ts:14
Paths that require authentication. Unauthenticated requests are redirected to login.
Supports exact paths and prefix patterns ending with * (e.g. “/dashboard/*“).
publicPaths?
optionalpublicPaths:string[]
Defined in: src/proxy.ts:21
Paths that are always public (never redirected to login). Takes precedence over protectedPaths. Defaults to [“/api/auth/*“].
redirectURI
redirectURI:
string
Defined in: src/types.ts:7
Redirect URI for OAuth callback, e.g. “http://localhost:3000/api/auth/callback ”
Inherited from
scopes?
optionalscopes:string[]
Defined in: src/types.ts:11
OAuth scopes. Defaults to [“openid”, “offline_access”, “https://authgear.com/scopes/full-userinfo ”]
Inherited from
sessionSecret
sessionSecret:
string
Defined in: src/types.ts:13
Secret key for encrypting session cookie (min 32 chars)