Skip to main content
This endpoint updates the name fields on the authenticated user’s profile. Supply the new values in the JSON body; the response includes the full updated user object. To change the account password, use the companion endpoint PUT /api/user/v1/reset-password/update/ described below.
Both first_name and last_name are required even if you are only changing one field. Send the existing value for any field you do not wish to change.

Request

Method: PUT
URL: http://localhost:8000/api/user/v1/edit/
Authentication: X-OTAS-USER-TOKEN header

Headers

string
required
Signed JWT returned by /api/user/v1/login/ or /api/user/v1/create/.

Body parameters

string
required
Updated first name.
string
required
Updated last name.
string
Updated middle name. Pass an empty string to clear it.

Response

integer
required
1 on success, 0 on failure.
string
required
user_profile_updated on success.
object

Example

Updating the password

To change the authenticated user’s password, send a PUT request to PUT /api/user/v1/reset-password/update/ with the same X-OTAS-USER-TOKEN header.

Body parameters

string
required
New password. Minimum 6 characters.
On success the server returns { "status": 1, "status_description": "password_updated", "response_body": null }.

Error responses