Page Contents

Home > @loopback/authorization > AuthorizationContext

AuthorizationContext interface

Request context for authorization

Signature:

export interface AuthorizationContext 

Properties

Property Modifiers Type Description
invocationContext   InvocationContext Context for the invocation
principals   Principal[] An array of principals identified for the request - it should come from authentication
resource   string An name for the target resource to be accessed, such as OrderController.prototype.cancelOrder
roles   Role[] An array of roles for principals
scopes   string[] An array of scopes representing granted permissions - usually come from access tokens