API referenceSections

Change your own password

Generated from the OpenAPI contract. Sessions send the CSRF header on writes; API keys use a Bearer token. Authentication

POST /api/v1/auth/password

Change your own password (ADR 0057). The current password is needed except in a session from a recovery link; every other session ends and a new one is set

Authentication: session cookie __Host-panel_session (contract default; see Authentication).

Parameters

NameInTypeRequiredDescription
X-CSRF-Tokenheaderstringoptional

Required on unsafe requests authenticated by session cookie; API keys do not use it.

Request body

required

Content type: application/json

object
  • no other properties
  • current_password string optional
  • new_password string required
    • min length 12
    • max length 128
Example
{
  "current_password": "string",
  "new_password": "xxxxxxxxxxxx"
}

Responses

200 Changed; a new session cookie is set

Content type: application/json

object
  • csrf_token string required
  • mfa string required
Example
{
  "csrf_token": "string",
  "mfa": "string"
}

default Error

Content type: application/json

  • code string required
  • message string required
  • details_redacted boolean required
  • correlation_id string required
  • retryable boolean required