Docs

Get user password state

GET
/users/{user_id}/password

Reports when the user's current password was set, and leaves set_at out when the user has none. The password and its hash are never returned; setting one is PUT on the same path.

Authorization

headerAuthorizationBearer <token>

Scope: user.read

Path Parameters

user_id*string
Match^user_[a-zA-Z0-9_-]+$

Response Body

The state of the user's password

application/json
  1. response

Whether the user has a password, and since when. Never the password or its hash.

set_at?string

When the current password was set. Absent when the user has no password.

Formatdate-time
Example Request
import { configureZitadel, getApi } from "@zitadel/api/config";// In the browser, through the SDK proxy: the session cookie authenticates the call.const client = getApi(configureZitadel({ projectId: "proj_01KWH1P4MYS7F0N9WD3P2E4YM5" }));const userPasswordState = await client.getUserPasswordState("string");
Example Response
{  "set_at": "2019-08-24T14:15:22Z"}

Was this helpful?