Delivers some information about the user currently logged in. Returns a UserProperties document describing the user. This document contains -- beside other information -- the privilege level of the user which must be known to decide which user interface elements must be shown in a read-only way because the user is not authorized to change these parameter (but he may read them if logged in).
This API end point also may be used with PUT to change the password of the actually logged in user.
Supported HTTP methods: GET, PUT, HEAD, OPTIONS
GET /api/v1/user
Returns a UserProperties document describing the currently logged in user.
Expected Payload: none
Replied Payload: a UserProperties document with information about the user who issued this call.
Parameters: none
Return Codes:
| Code | Description |
|---|---|
| 200 | OK, returns a UserProperties document describing the currently logged in user. If no information about the currently logged in user is available, a dummy Document describing a user with the name 'unknown' and the privilege level '0' is returned. |
| 401 | not logged in. In this case a ApiError document is returned, describing details of the error. |
PUT /api/v1/user
Changes the password of the user issuing this call. Returns the (updated) UserProperties for the currently logged in user.
Expected Payload: a UserProperties document containing the new password for the actual user. All other fields of the the document are ignored.
Replied Payload: a UserProperties document with the updated user information.
Parameters: none
Return Codes:
| Code | Description |
|---|---|
| 200 | OK, returns a UserProperties with the updated data for the actually logged in user. |
| 401 | not logged in. In this case a ApiError document is returned, describing details of the error. |