UNPKG

@fajarnugraha37/nope-iam

Version:

A highly extensible, type-safe IAM-like access control library for Node.js, inspired by AWS IAM. Deny by default, allow by vibes and less patience for your bad access patterns. Supports policies, roles, decorators, adapters, and rich evaluation context be

10 lines 678 B
import type { CanParams } from '../core/iam.js'; export declare function LogAccess(opts?: { logLevel?: 'info' | 'warn'; message?: string | ((ctx: any) => string); }): MethodDecorator; export declare function AllowActions(actions: string[], resources: string | string[]): MethodDecorator; export declare function DenyActions(actions: string[], resources: string | string[]): MethodDecorator; export declare function AccessCondition(condition: (user: any, ...args: any[]) => boolean): MethodDecorator; export declare function AccessControl(params: Partial<CanParams> | ((...args: any[]) => Partial<CanParams>)): MethodDecorator; //# sourceMappingURL=accessControl.d.ts.map