WoyraDocs
Get an API key

Change the password while signed in

POST/v1/auth/change-password

Console · Requires an API key

Other sessions are revoked; this one continues with a fresh cookie.

Body

FieldTypeDescription
current_passwordrequiredstring
new_passwordrequiredstring

Example

curl -X POST https://api.woyra.io/v1/auth/change-password \
  -H "Authorization: Bearer $WOYRA_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "current_password": "<current_password>",
    "new_password": "<new_password>"
  }'

Response

200 Changed.

FieldTypeDescription
object"session"
userUser
accountobject
account.idstring
account.namestring
account.countrystring
account.currencystringThe billing currency.
account.payment_currencystringHow the account pays: USD by card, or ETB by bank deposit credited in USD.
One of ETB, USD.
account.regionstring
One of global, ethiopia.
account.statusstring
account.project_idstring
mfaobject
mfa.enabledbooleanAn authenticator app is on.
mfa.requiredboolean
mfa.pendingboolean
mfa.passkeysintegerHow many passkeys the user has. A passkey counts as a second factor.
mfa.recovery_codesintegerUnused recovery codes left.
sessionobject
session.idstring
session.expires_attimestamp
api_keyobjectOnly on signup — the test key, with its token shown once.

Errors

StatusCodes
400invalid_request, unsupported_version

Also in Console