@mini2/core
Version:
Mini Express Framework - Lightweight and modular Express.js framework with TypeScript support
12 lines • 502 B
TypeScript
import { NextFunction, Request, Response } from 'express';
/** Header tabanlı yetkilendirme (throw’lu):
* - required: gerekli permission listesi
* - Mevcut izinler önce req.user.permissions’tan,
* yoksa x-user-permissions header’ından alınır.
*/
export declare const authorizedMiddleware: (required: string[]) => (req: Request & {
user?: {
permissions?: string[];
};
}, _res: Response, next: NextFunction) => void;
//# sourceMappingURL=authorized.middleware.d.ts.map