summaryrefslogtreecommitdiff
path: root/doc/api-user-procedures.markdown
diff options
context:
space:
mode:
authorjf-guillou <jean-francois.guillou@univ-rennes1.fr>2016-01-25 10:05:44 +0100
committerjf-guillou <jean-francois.guillou@univ-rennes1.fr>2016-01-25 10:05:44 +0100
commit63a286147685073102270f4974d85b32818641c5 (patch)
tree66ac6c066f3d49a831ffd9d52bf85d584af81f60 /doc/api-user-procedures.markdown
parent051bf1c9dbb5733242c7657d6d507389206b33ee (diff)
Added API getUserByName()
Tests and doc included
Diffstat (limited to 'doc/api-user-procedures.markdown')
-rw-r--r--doc/api-user-procedures.markdown42
1 files changed, 42 insertions, 0 deletions
diff --git a/doc/api-user-procedures.markdown b/doc/api-user-procedures.markdown
index 6ecf12c6..9b43e1e1 100644
--- a/doc/api-user-procedures.markdown
+++ b/doc/api-user-procedures.markdown
@@ -113,6 +113,48 @@ Response example:
}
```
+## getUserByName
+
+- Purpose: **Get user information**
+- Parameters:
+ - **username** (string, required)
+- Result on success: **user properties**
+- Result on failure: **null**
+
+Request example:
+
+```json
+{
+ "jsonrpc": "2.0",
+ "method": "getUserByName",
+ "id": 1769674782,
+ "params": {
+ "username": "biloute"
+ }
+}
+```
+
+Response example:
+
+```json
+{
+ "jsonrpc": "2.0",
+ "id": 1769674782,
+ "result": {
+ "id": "1",
+ "username": "biloute",
+ "password": "$2y$10$dRs6pPoBu935RpmsrhmbjevJH5MgZ7Kr9QrnVINwwyZ3.MOwqg.0m",
+ "role": "app-user",
+ "is_ldap_user": "0",
+ "name": "",
+ "email": "",
+ "google_id": null,
+ "github_id": null,
+ "notifications_enabled": "0"
+ }
+}
+```
+
## getAllUsers
- Purpose: **Get all available users**