General - Update User profile
API Url
Used for changing a user's password and user culture.
PUT
http://localhost:16010/ProMarkREST/rest/General/user_info
Permissions: user
Request headers
| Field | Type | Description |
|---|---|---|
Accept-Languageoptional | String | =en-GB Language use for localization. |
X-Clientoptional | String | =Client type. "Portal""Mobile""Admin" |
X-Roleoptional | Number | ProMark role (1: Employee, 2: User). {12} |
X-WebPart-Idoptional | Number | Unique web-part identifier. |
Parameter
| Field | Type | Description |
|---|---|---|
| request | Object | Main object containing the request data. |
| data | Object | Object containg data to be uploaded. |
| confirmPassword | String | New password confirmed. |
| culture | String | User culture. |
| newPassword | String | New password. |
| password | String | Current password. |
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data. |
cultureoptional | String | User culture. |
| roles | Object[] | Collection of allowed ProMark roles. |
| description | String | Role description. |
| id | Number[1-2] | Role identifier (1: Employee, 2: User). |
isAdministratoroptional | Boolean | true = User is administrator |
| errorCode | Number | Error Code |
| errorMessage | String | Message description of the error. |
messageoptional | Object | Object containing response messages. |
| code | Number | Message code. |
| text | String | Message text. |
| type | String | Type of message. "warning""info" |
Success example:
HTTP/1.1 200 OK{"response": {"data": {"culture": "da-dk","roles": [{"id": 1,"description": "Medarbejder"},{"id": 2,"description": "Bruger","isAdministrator": false,}]},"errorCode": 0,"errorMessage": ""}}
Error 4xx
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| errorCode | Number | Error code. |
| errorMessage | String | Error description. |
Error example:
HTTP/1.1 422 Unprocessable Entity{"response": {"errorCode": 22,"errorMessage": "Incorrect password"}}