diff --git a/docs/How-to/LLDAP_Graphql.md b/docs/How-to/LLDAP_Graphql.md new file mode 100644 index 0000000..ecf164b --- /dev/null +++ b/docs/How-to/LLDAP_Graphql.md @@ -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 + } +} +```