UNPKG

@zigatech/keycloak-auth

Version:

Keycloak authorization library for NestJS. Works out of the box.

9 lines (8 loc) 331 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.AuthenticatedPrincipal = void 0; const common_1 = require("@nestjs/common"); exports.AuthenticatedPrincipal = (0, common_1.createParamDecorator)((_, context) => { const req = context.switchToHttp().getRequest(); return req.principal; });