---
title: "Set Password"
method: POST
path: "/api/auth/password"
---

# Set Password

`POST /api/auth/password`

Set or change the account's login password.

- Accounts WITHOUT a usable password (phone-OTP-only → password_hash NULL,
  or WeChat-only → "wechat-only" sentinel) set one for the first time and
  do NOT need `current_password`. This is what lets a phone-OTP user
  enable email/phone + password login from Settings.
- Accounts that already have a password must supply the correct
  `current_password` to change it.

## Headers

- `authorization` string, nullable

## Request body

- SetPasswordIn
  - `new_password` string, required
  - `current_password` string, nullable

## Response `200`

Successful Response

- object

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/omicos/apis/omicos-server.md) · [All operations](https://skmtc.dev/omicos/apis/omicos-server/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/omicos/omicos-server/revisions/a00b94573ffe/schema)
