---
lang: en
title: 'API docs: authorization.authorizer'
keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI
sidebar: lb4_sidebar
editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/authorization
permalink: /doc/en/lb4/apidocs.authorization.authorizer.html
---

<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@loopback/authorization](./authorization.md) &gt; [Authorizer](./authorization.authorizer.md)

## Authorizer type

A function to decide if access to the target should be allowed or denied

**Signature:**

```typescript
export type Authorizer<T extends AuthorizationMetadata = AuthorizationMetadata> = 
(context: AuthorizationContext, metadata: T) => Promise<AuthorizationDecision>;
```
**References:** [AuthorizationMetadata](./authorization.authorizationmetadata.md)<!-- -->, [AuthorizationContext](./authorization.authorizationcontext.md)<!-- -->, [AuthorizationDecision](./authorization.authorizationdecision.md)


