add lldap graphql query
This commit is contained in:
parent
dc5be4433c
commit
32f0d93194
61
docs/How-to/LLDAP_Graphql.md
Normal file
61
docs/How-to/LLDAP_Graphql.md
Normal file
@ -0,0 +1,61 @@
|
||||
# LLDAP Graphql query
|
||||
|
||||
URL: /api/graphql/playground
|
||||
|
||||
set HTTP HEADER
|
||||
{ "Authorization": "Bearer token"}
|
||||
|
||||
## Get User
|
||||
|
||||
```Graphql
|
||||
{
|
||||
user(userId: "admin"){
|
||||
id
|
||||
attributes {name,value}
|
||||
groups{id}
|
||||
}
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## updateUserAttribute
|
||||
|
||||
```Graphql
|
||||
mutation { updateUser(
|
||||
user:{
|
||||
id:"admin"
|
||||
insertAttributes:{
|
||||
name:"toto"
|
||||
value:"test"
|
||||
}
|
||||
}
|
||||
){
|
||||
ok
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## add User attribute
|
||||
|
||||
```Graphql
|
||||
|
||||
mutation { addUserAttribute(
|
||||
name:"toto"
|
||||
attributeType:STRING
|
||||
isList:true
|
||||
isVisible:true
|
||||
isEditable:true){
|
||||
ok
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## delete user attribute
|
||||
|
||||
```graphql
|
||||
mutation {
|
||||
deleteUserAttribute(name: "toto") {
|
||||
ok
|
||||
}
|
||||
}
|
||||
```
|
Loading…
Reference in New Issue
Block a user