---
title: "Update an existing user"
method: PUT
path: "/api/users/{id}"
tags: ["Users"]
---

# Update an existing user

`PUT /api/users/{id}`

## Path parameters

- `id` string, uuid, required

## Request body

- UpdateUserInput
  - `username` string — New username (omitted fields keep existing values)
  - `password` string — New plain text password (omitted fields keep existing values)

## Response `200`

User updated successfully

- UserUpdatedResponse
  - `success` boolean — Indicates whether the request was successful
  - `code` integer — HTTP status code
  - `message` string — Human-readable status message
  - `request_id` string, nullable — Unique request identifier for tracing
  - `timestamp` string, date-time — ISO 8601 response timestamp
  - `data` object, nullable
  - `error` object, nullable
  - `errors` object[], nullable

## Other responses

- `404` — Resource not found
- `500` — Internal server error

## Changes

- **2026-07-17** `bff336605cec` — 1 info
  - endpoint added
- **2026-05-27** `f1f9de326bee` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/sword-web/apis/sword-users-api/changes/api/users/:id/put.md)

---

[API](https://skmtc.dev/sword-web/apis/sword-users-api.md) · [All operations](https://skmtc.dev/sword-web/apis/sword-users-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/sword-web/sword-users-api/revisions/bff336605cec/schema)
