Skip to content

Latest commit

 

History

History
139 lines (77 loc) · 3.24 KB

class.AuthorizationService.md

File metadata and controls

139 lines (77 loc) · 3.24 KB

directus-monorepo ( Readme | API )


directus-monorepo > AuthorizationService

Class: AuthorizationService

Constructors

constructor()

new AuthorizationService(options): AuthorizationService

Parameters

Parameter Type
options AbstractServiceOptions

Returns

AuthorizationService

Source

api/src/services/authorization.ts:37

Properties

accountability

accountability: any

Source

api/src/services/authorization.ts:33


knex

knex: Knex< any, any[] >

Source

api/src/services/authorization.ts:32


payloadService

payloadService: PayloadService

Source

api/src/services/authorization.ts:34


schema

schema: SchemaOverview

Source

api/src/services/authorization.ts:35

Methods

checkAccess()

checkAccess( action, collection, pk): Promise< void >

Parameters

Parameter Type
action PermissionsAction
collection string
pk PrimaryKey | PrimaryKey[]

Returns

Promise< void >

Source

api/src/services/authorization.ts:592


processAST()

processAST(ast, action = 'read'): Promise< AST >

Parameters

Parameter Type Default value
ast AST undefined
action PermissionsAction 'read'

Returns

Promise< AST >

Source

api/src/services/authorization.ts:48


validatePayload()

validatePayload( action, collection, data): Partial< Item >

Checks if the provided payload matches the configured permissions, and adds the presets to the payload.

Parameters

Parameter Type
action PermissionsAction
collection string
data Partial< Item >

Returns

Partial< Item >

Source

api/src/services/authorization.ts:481


Generated using TypeDoc and typedoc-plugin-markdown