Page Contents
Home > @loopback/authorization > AuthorizationMetadata
AuthorizationMetadata interface
Authorization metadata supplied via @authorize decorator
Signature:
export interface AuthorizationMetadata
Properties
| Property | Modifiers | Type | Description |
|---|---|---|---|
| [allowedRoles?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.allowedroles.html) | string\[\] | _(Optional)_ Roles that are allowed access | |
| [deniedRoles?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.deniedroles.html) | string\[\] | _(Optional)_ Roles that are denied access | |
| [resource?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.resource.html) | string | _(Optional)_ Name of the resource, default to the method name | |
| [scopes?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.scopes.html) | string\[\] | _(Optional)_ Define the access scopes | |
| [skip?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.skip.html) | boolean | _(Optional)_ A flag to skip authorization | |
| [voters?](/doc/en/lb4/apidocs.authorization.authorizationmetadata.voters.html) | ([Authorizer](/doc/en/lb4/apidocs.authorization.authorizer.html) \| [BindingAddress](/doc/en/lb4/apidocs.context.bindingaddress.html)<[Authorizer](/doc/en/lb4/apidocs.authorization.authorizer.html)>)\[\] | _(Optional)_ Voters that help make the authorization decision |