Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Page Properties
hiddentrue

Status

Status
colourPurpleYellow
titlestartedfor review

Approver

Pavel Shkadzko

A user's password and/or email can be changed with a PUT request to /api/users/{userId}. In order to update a user's password and/or email, the current password/email should be provided.

Request

Key

Description

oldPassword

the

The user's current password.

password

the

The password to which the user's password should be changed to.

oldEmail

the

The user's current email.

email

the

The email to which the user's email should be changed to.

Code Block
languagejson
//change a user's password and/or email

PUT /api/users/c1e60c6b-a0a4-4d80-81eb-c1c6de729a0e HTTP/1.1
Host: user.gini.net
Authorization: BEARER 74c1e7fe-e464-451f-a6eb-8f0998c46ff6
Content-Type: application/json

//with

{"oldPassword":"supersecret","password:"anothersecret"}

//or

{"oldEmail":"old@email.com","email:"my.new@email.com"}

//or

{
 "oldPassword":"supersecret",
 "password":"anothersecret",
 "oldEmail":"old@email.com",
 "email":"my.new@email.com"}