snapshot of https://github.com/cortezaproject/corteza.git (2024.9.x, 2026-09-18; blobs > 131072B omitted)
Some checks failed
SonarQube / SonarQube (push) Failing after 5m28s
E2e test on main branch push / server and client test (map[name:admin port:8080]) (push) Failing after 3m33s
Server and lib tests / Library test (js) (push) Failing after 1m36s
Server and lib tests / Library test (vue) (push) Successful in 2m24s
Server and lib tests / Web client test (admin) (push) Successful in 2m52s
Server and lib tests / Web client test (compose) (push) Successful in 3m23s
Server and lib tests / Web client test (discovery) (push) Successful in 2m49s
Server and lib tests / Web client test (one) (push) Successful in 2m52s
Server and lib tests / Web client test (privacy) (push) Successful in 2m44s
Server and lib tests / Web client test (reporter) (push) Successful in 2m56s
Server and lib tests / Web client test (workflow) (push) Successful in 3m0s
Server and lib tests / Server tests (push) Failing after 4m55s
E2e test on main branch push / notify-failure (push) Failing after 9s
Server and lib tests / Send matrix testing notification (push) Successful in 2s
Mark stale issues and pull requests / stale (push) Successful in 40s
Some checks failed
SonarQube / SonarQube (push) Failing after 5m28s
E2e test on main branch push / server and client test (map[name:admin port:8080]) (push) Failing after 3m33s
Server and lib tests / Library test (js) (push) Failing after 1m36s
Server and lib tests / Library test (vue) (push) Successful in 2m24s
Server and lib tests / Web client test (admin) (push) Successful in 2m52s
Server and lib tests / Web client test (compose) (push) Successful in 3m23s
Server and lib tests / Web client test (discovery) (push) Successful in 2m49s
Server and lib tests / Web client test (one) (push) Successful in 2m52s
Server and lib tests / Web client test (privacy) (push) Successful in 2m44s
Server and lib tests / Web client test (reporter) (push) Successful in 2m56s
Server and lib tests / Web client test (workflow) (push) Successful in 3m0s
Server and lib tests / Server tests (push) Failing after 4m55s
E2e test on main branch push / notify-failure (push) Failing after 9s
Server and lib tests / Send matrix testing notification (push) Successful in 2s
Mark stale issues and pull requests / stale (push) Successful in 40s
This commit is contained in:
215
server/system/automation/users_handler.yaml
Normal file
215
server/system/automation/users_handler.yaml
Normal file
@@ -0,0 +1,215 @@
|
||||
imports:
|
||||
- github.com/cortezaproject/corteza/server/system/types
|
||||
- labelTypes github.com/cortezaproject/corteza/server/pkg/label/types
|
||||
|
||||
|
||||
snippets:
|
||||
lookup: &lookup
|
||||
meta: { label: Lookup }
|
||||
required: true
|
||||
types:
|
||||
- { wf: ID }
|
||||
- { wf: Handle }
|
||||
- { wf: String, suffix: email }
|
||||
- { wf: User, suffix: res }
|
||||
|
||||
lookupRole: &lookupRole
|
||||
meta: { label: Role }
|
||||
required: true
|
||||
types:
|
||||
- { wf: ID, }
|
||||
- { wf: Handle, }
|
||||
- { wf: Role, suffix: res }
|
||||
|
||||
user: &user
|
||||
types:
|
||||
- { wf: User }
|
||||
|
||||
rvUser: &rvUser
|
||||
wf: User
|
||||
|
||||
rvRole: &rvRole
|
||||
wf: Role
|
||||
|
||||
rvTotal: &rvTotal
|
||||
wf: UnsignedInteger
|
||||
|
||||
rvInclusion: &rvInclusion
|
||||
wf: Boolean
|
||||
|
||||
rvPageCursor: &rvPageCursor
|
||||
wf: String
|
||||
|
||||
filterParams: &filterParams
|
||||
query:
|
||||
meta: { label: Query }
|
||||
types:
|
||||
- { wf: String }
|
||||
email:
|
||||
meta: { label: Email }
|
||||
types:
|
||||
- { wf: String }
|
||||
handle:
|
||||
meta: { label: Handle }
|
||||
types:
|
||||
- { wf: String }
|
||||
labels:
|
||||
meta: { label: Labels }
|
||||
types:
|
||||
- { wf: LabelValue }
|
||||
deleted:
|
||||
meta: { label: Deleted }
|
||||
types:
|
||||
- { wf: UnsignedInteger }
|
||||
suspended:
|
||||
meta: { label: Suspended }
|
||||
types:
|
||||
- { wf: UnsignedInteger }
|
||||
sort:
|
||||
meta: { label: Sort }
|
||||
types:
|
||||
- { wf: String }
|
||||
limit:
|
||||
meta: { label: Limit }
|
||||
types:
|
||||
- { wf: UnsignedInteger }
|
||||
incTotal:
|
||||
meta: { label: Include total }
|
||||
types:
|
||||
- { wf: Boolean }
|
||||
incPageNavigation:
|
||||
meta: { label: Include page navigation }
|
||||
types:
|
||||
- { wf: Boolean }
|
||||
pageCursor:
|
||||
meta: { label: Page cursor }
|
||||
types:
|
||||
- { wf: String }
|
||||
|
||||
labels: &labels
|
||||
users: "step,workflow"
|
||||
|
||||
functions:
|
||||
lookup:
|
||||
meta:
|
||||
short: User lookup
|
||||
description: Find specific user by ID, handle or string
|
||||
params:
|
||||
lookup: *lookup
|
||||
labels:
|
||||
<<: *labels
|
||||
results:
|
||||
user: *rvUser
|
||||
|
||||
searchMembership:
|
||||
meta:
|
||||
short: User role search
|
||||
description: Search user role membership by ID, handle or string
|
||||
params:
|
||||
lookup: *lookup
|
||||
labels:
|
||||
<<: *labels
|
||||
results:
|
||||
roles:
|
||||
<<: *rvRole
|
||||
isArray: true
|
||||
total: *rvTotal
|
||||
|
||||
checkMembership:
|
||||
meta:
|
||||
short: User membership check
|
||||
description: Find user role membership by ID, handle or string
|
||||
params:
|
||||
user:
|
||||
<<: *lookup
|
||||
meta: { label: User }
|
||||
role: *lookupRole
|
||||
labels:
|
||||
<<: *labels
|
||||
results:
|
||||
member: *rvInclusion
|
||||
|
||||
search:
|
||||
meta:
|
||||
short: User search
|
||||
params: *filterParams
|
||||
labels:
|
||||
<<: *labels
|
||||
results:
|
||||
users:
|
||||
<<: *rvUser
|
||||
isArray: true
|
||||
total: *rvTotal
|
||||
|
||||
each:
|
||||
kind: iterator
|
||||
meta:
|
||||
short: Users
|
||||
params: *filterParams
|
||||
labels:
|
||||
<<: *labels
|
||||
results:
|
||||
user: *rvUser
|
||||
total: *rvTotal
|
||||
|
||||
create:
|
||||
meta:
|
||||
short: User create
|
||||
labels:
|
||||
<<: *labels
|
||||
params:
|
||||
user:
|
||||
<<: *user
|
||||
meta: { label: User }
|
||||
required: true
|
||||
results:
|
||||
user: *rvUser
|
||||
|
||||
update:
|
||||
meta:
|
||||
short: User update
|
||||
labels:
|
||||
<<: *labels
|
||||
params:
|
||||
user:
|
||||
<<: *user
|
||||
meta: { label: User }
|
||||
required: true
|
||||
results:
|
||||
user: *rvUser
|
||||
|
||||
delete:
|
||||
labels:
|
||||
<<: *labels
|
||||
delete: "step"
|
||||
meta:
|
||||
short: User delete
|
||||
params:
|
||||
lookup: *lookup
|
||||
|
||||
recover:
|
||||
labels:
|
||||
<<: *labels
|
||||
recover: "step"
|
||||
meta:
|
||||
short: User recover
|
||||
params:
|
||||
lookup: *lookup
|
||||
|
||||
suspend:
|
||||
labels:
|
||||
<<: *labels
|
||||
suspend: "step"
|
||||
meta:
|
||||
short: User suspend
|
||||
params:
|
||||
lookup: *lookup
|
||||
|
||||
unsuspend:
|
||||
labels:
|
||||
<<: *labels
|
||||
unsuspend: "step"
|
||||
meta:
|
||||
short: User unsuspend
|
||||
params:
|
||||
lookup: *lookup
|
||||
Reference in New Issue
Block a user