---
lang: en
title: 'API docs: authorization.authorizationcontext'
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.authorizationcontext.html
---

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

[Home](./index.md) &gt; [@loopback/authorization](./authorization.md) &gt; [AuthorizationContext](./authorization.authorizationcontext.md)

## AuthorizationContext interface

Request context for authorization

**Signature:**

```typescript
export interface AuthorizationContext 
```

## Properties

<table><thead><tr><th>

Property


</th><th>

Modifiers


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[invocationContext](./authorization.authorizationcontext.invocationcontext.md)


</td><td>


</td><td>

[InvocationContext](./context.invocationcontext.md)


</td><td>

Context for the invocation


</td></tr>
<tr><td>

[principals](./authorization.authorizationcontext.principals.md)


</td><td>


</td><td>

[Principal](./security.principal.md)<!-- -->\[\]


</td><td>

An array of principals identified for the request - it should come from authentication


</td></tr>
<tr><td>

[resource](./authorization.authorizationcontext.resource.md)


</td><td>


</td><td>

string


</td><td>

An name for the target resource to be accessed, such as `OrderController.prototype.cancelOrder`


</td></tr>
<tr><td>

[roles](./authorization.authorizationcontext.roles.md)


</td><td>


</td><td>

[Role](./security.role.md)<!-- -->\[\]


</td><td>

An array of roles for principals


</td></tr>
<tr><td>

[scopes](./authorization.authorizationcontext.scopes.md)


</td><td>


</td><td>

string\[\]


</td><td>

An array of scopes representing granted permissions - usually come from access tokens


</td></tr>
</tbody></table>


