Reten Docs

Reset My Password

Reset the current user's own password.

POST /api/auth/reset-my-password

Reset the authenticated user's password by providing the current password and a new one.

Auth: Required — any authenticated user, with the x-tenant-id header of one of their tenants

Headers

HeaderRequiredValue
AuthorizationYesBearer <access_token>
x-tenant-idYesTenant UUID

Request Body

FieldTypeRequiredDescription
currentPasswordstringYesCurrent password for verification
newPasswordstringYesNew password (minimum 8 characters), different from the current one

Example

curl -X POST https://api.reten.ai/api/auth/reset-my-password \
  -H "Authorization: Bearer <token>" \
  -H "x-tenant-id: <tenant-id>" \
  -H "Content-Type: application/json" \
  -d '{
    "currentPassword": "OldPass123!",
    "newPassword": "NewSecurePass456!"
  }'
const response = await fetch("https://api.reten.ai/api/auth/reset-my-password", {
  method: "POST",
  headers: {
    "Authorization": "Bearer <token>",
    "x-tenant-id": "<tenant-id>",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    currentPassword: "OldPass123!",
    newPassword: "NewSecurePass456!",
  }),
});
import requests

response = requests.post(
    "https://api.reten.ai/api/auth/reset-my-password",
    headers={
        "Authorization": "Bearer <token>",
        "x-tenant-id": "<tenant-id>",
    },
    json={
        "currentPassword": "OldPass123!",
        "newPassword": "NewSecurePass456!",
    },
)

Response 201 Created

{
  "message": "Password updated successfully"
}

Error Responses

StatusDescription
400Validation error — a field is missing or newPassword is shorter than 8 characters
400Current password is incorrect
400New password must be different from current password
400x-tenant-id header missing — Missing required header: x-tenant-id
401Missing or invalid authentication token
403The user does not belong to the tenant — User does not have access to the requested tenant