Chahge password for loggedin user.
Users
PATCH change password
Endpoint
PATCH /api/v1/users
Parameters
Name | Description |
---|---|
user[password] required | New password |
user[password_confirmation] required | Password confirmation |
user[current_password] required | Current password |
Request
Route
PATCH /api/v1/users
Headers
Accept: application/json
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxOTA2Iiwic2NwIjoidXNlciIsImF1ZCI6bnVsbCwiaWF0IjoxNzUzMjY2MjMwLCJleHAiOjE3NTU4NTgyMzAsImp0aSI6IjFhNjE1Y2VmLTgwOTYtNGQ5NS1iOWQzLWRmZTJiMDAzN2M3OCJ9.BhMmjDtnfhOxnGrSHYxRpz9NbegKG2eNBVuXT8r-AJY
Host: example.org
Cookie:
Body
{
"user": {
"password": "new_valiD_passw0rd!",
"password_confirmation": "new_valiD_passw0rd!",
"current_password": "valiD_passw0rd!"
}
}
Response
Simulated Response
Status
200
Headers
x-frame-options: SAMEORIGIN
x-xss-protection: 0
x-content-type-options: nosniff
x-permitted-cross-domain-policies: none
referrer-policy: strict-origin-when-cross-origin
content-type: application/json; charset=utf-8
vary: Accept, Origin
set-cookie: _interslice_session=Z7ibJ4ktxoP0nF3MyiVbouE4U42%2Fg3XZ%2BS3NWvHU8aRYi34JlO1pLNFUW0ZIpX%2BVkbjaM9IOrZN%2BYxzlV59dvHWMSaG5OV0VvoApyHHGsxYiafyYTjRmso%2BbmnZ9MGSlnYCGWPbS1YXLw4DgSF0nIq30o5Ve2nID58SrWD5xAMac9BCqrDAbLukhX1068qVNdBk18d%2FK6ekqCv0SqGguVChsM9vOSZL0iChKUxkNc6vHBaCggpAUTCc%2FAP633m0nCpEXLhRaVlyiHK%2B8idP25MLsjFVFi3lpeN7hNpX%2BLg%3D%3D--Tf8PhXe5SP7wQfEE--yvHLCjZ9ij4PGyDVfWeO0A%3D%3D; path=/; httponly; samesite=lax
etag: W/"3d8fc167d204030f837c9af99e7cce67"
cache-control: max-age=0, private, must-revalidate
x-request-id: 82ce896c-b0a8-4b39-9768-c9ff96ba272c
x-runtime: 0.015146
content-length: 221
Body
{
"user": {
"id": 1906,
"company": null,
"contact_phone_number": null,
"email": "james.torp+operator@example.com",
"first_name": "James",
"job_position": null,
"last_name": "Torp",
"phone_number": null,
"profile_id": null,
"role": "operator"
}
}