Users

Update a user(admin)

PUT update admin profile

Endpoint

PUT /api/v1/users/:id

Parameters

Name Description
review[first_name] required Review first name
review[last_name] required Review last name

Request

Route

PUT /api/v1/users/1898

Headers

Accept: application/json
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxODk4Iiwic2NwIjoidXNlciIsImF1ZCI6bnVsbCwiaWF0IjoxNzQyNDY0OTU2LCJleHAiOjE3NDUwNTY5NTYsImp0aSI6IjI5YWUxZTJkLTk3ZDYtNDZjOC1iYjdjLWM3NWU3YmI3ZGIwMSJ9.FZrpjCqrUhftXlSiqIUsndEw2kt0FRujDXJvJX5QPUg
Host: example.org
Cookie: 

Body

{
  "user": {
    "first_name": "Updated",
    "last_name": "Beatty"
  }
}

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
etag: W/"3a682d4203ff9d3acb36377708879f97"
cache-control: max-age=0, private, must-revalidate
x-request-id: e1b82aac-1809-42e1-b671-dffff08725c5
x-runtime: 0.009040
content-length: 161

Body

{
  "user": {
    "id": 1898,
    "email": "chadwick.gibson+admin@example.com",
    "first_name": "Updated",
    "last_name": "Beatty",
    "phone_number": null,
    "profile_id": null,
    "role": "admin"
  }
}