mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 17:31:56 +03:00
55 lines
1.2 KiB
YAML
55 lines
1.2 KiB
YAML
description: Create relevant permissions
|
|
url: /v1/query
|
|
status: 200
|
|
query:
|
|
type: bulk
|
|
args:
|
|
- type: create_select_permission
|
|
args:
|
|
table: article
|
|
role: user
|
|
permission:
|
|
columns: '*'
|
|
filter:
|
|
$or:
|
|
- author_id: X-HASURA-USER-ID
|
|
- is_published: true
|
|
- type: create_insert_permission
|
|
args:
|
|
table: article
|
|
role: user
|
|
permission:
|
|
check:
|
|
author_id: X-Hasura-User-Id
|
|
- type: create_update_permission
|
|
args:
|
|
table: article
|
|
role: user
|
|
permission:
|
|
columns: '*'
|
|
filter:
|
|
author_id: X-Hasura-User-Id
|
|
- type: create_select_permission
|
|
args:
|
|
table: author
|
|
role: user
|
|
permission:
|
|
columns: '*'
|
|
filter:
|
|
id: X-HASURA-USER-ID
|
|
- type: create_insert_permission
|
|
args:
|
|
table: author
|
|
role: user
|
|
permission:
|
|
check:
|
|
id: X-HASURA-USER-ID
|
|
- type: create_update_permission
|
|
args:
|
|
table: author
|
|
role: user
|
|
permission:
|
|
columns: '*'
|
|
filter:
|
|
id: X-Hasura-User-Id
|