> For the complete documentation index, see [llms.txt](https://openapi.logto.io/llms.txt)

# Update user password expiration

> PATCH /api/users/{userId}/password/expiration
> 
> Update the user's password expiration state for the next sign-in attempt.



## Servers
- Logto endpoint address.: https://[tenant_id].logto.app (Logto endpoint address.)


## Authentication methods
- O auth2


## Parameters

### Path parameters

- **userId** (string)
  The unique identifier of the user.



### Body: application/json (object)

- **isExpired** (boolean)
  Whether the user's password should be marked as expired.



## Responses
### 200
User password expiration state has been updated successfully.

#### Body: application/json (object)
- **id** (string)

- **username** (string | null)

- **primaryEmail** (string | null)

- **primaryPhone** (string | null)

- **name** (string | null)

- **avatar** (string | null)

- **customData** (object)
  arbitrary

- **identities** (object)

- **lastSignInAt** (number | null)

- **createdAt** (number)

- **updatedAt** (number)

- **profile** (object)

- **applicationId** (string | null)

- **cimdClientId** (string | null)
  The identifier of the CIMD (client ID metadata document) client from the user's first consent. `null` unless the user's first consent was granted to a CIMD client. Mutually exclusive with `applicationId`.

- **isSuspended** (boolean)

- **hasPassword** (boolean)

- **hasSecurityVerificationMethod** (boolean)

- **hasPrimaryEmail** (boolean)

- **hasPrimaryPhone** (boolean)

- **ssoIdentities** (array[object])

- **passwordDigest** (string | null)

- **passwordAlgorithm** (string | null)


### 400
Password expiration policy is not enabled in the sign-in experience settings.

### 401
Unauthorized

### 403
Forbidden

### 404
Not Found


[Powered by Bump.sh](https://bump.sh)
