Interface: AuthorizationConfig
Defined in: nestlens.config.ts:68
Authorization configuration for NestLens dashboard access
Properties
allowedEnvironments?
optionalallowedEnvironments:string[] |null
Defined in: nestlens.config.ts:74
Allowed environments where NestLens is accessible. Set to null to allow all environments. Default: ['development', 'local', 'test']
allowedIps?
optionalallowedIps:string[]
Defined in: nestlens.config.ts:85
IP addresses allowed to access NestLens (supports wildcards like '192.168.1.*')
canAccess()?
optionalcanAccess: (req) =>boolean|AuthUser|Promise<boolean|AuthUser>
Defined in: nestlens.config.ts:91
Custom authorization function. Return true/false for simple auth, or AuthUser object for user context.
Parameters
req
Request
Returns
boolean | AuthUser | Promise<boolean | AuthUser>
environmentVariable?
optionalenvironmentVariable:string
Defined in: nestlens.config.ts:80
Environment variable to check for current environment. Default: 'NODE_ENV'
requiredRoles?
optionalrequiredRoles:string[]
Defined in: nestlens.config.ts:96
Required roles for access (checked against AuthUser.roles if canAccess returns AuthUser)