import { HookDecorator } from '../../../core'; /** * Hook factory to check if a user can access a route based on their permissions. * * The `ctx.user` object must implement the `IUserWithPermissions` interface. * * @export * @param {string} perm - The name of the permission. * @param {{ redirect?: string, openapi?: boolean }} [options={}] - Hook options. * @param {string|undefined} options.redirect - Optional URL path to redirect users that * do not have the right permission. * @param {boolean|undefined} options.openapi - Add OpenAPI metadata. * @returns {HookDecorator} - The hook. */ export declare function PermissionRequired(perm: string, options?: { redirect?: string; openapi?: boolean; }): HookDecorator;