Skip to content
v2.7

Update password strength policy

Update the password strength requirements for users in the project.

PATCH/project/policies/password-strengthScope policies.write

SDK: @owbase/node only

Update the password strength requirements for users in the project.

min number

Minimum password length. Value must be between 8 and 256. Default is 8.

uppercase boolean

Whether passwords must include at least one uppercase letter.

lowercase boolean

Whether passwords must include at least one lowercase letter.

number boolean

Whether passwords must include at least one number.

symbols boolean

Whether passwords must include at least one symbol.

Access: API key with the policies.write scope (also accepts project.policies.write).

200Success
400Invalid or missing parameter
401No session, no permission on the resource or key without the scope
429Rate limit

Every error comes as JSON with code, type and message: see Errors.

import { Client, Project } from '@owbase/node';
const client = new Client()
.setEndpoint('https://cloud.owbase.dev/v1') // Your API Endpoint
.setProject('<YOUR_PROJECT_ID>') // Your project ID
.setKey('<YOUR_API_KEY>'); // Your secret API key
const project = new Project(client);
const result = await project.updatePasswordStrengthPolicy({
min: 8, // optional
uppercase: false, // optional
lowercase: false, // optional
number: false, // optional
symbols: false, // optional
});
Response200 OK
{
"$id": "password-dictionary",
"min": 12,
"uppercase": true,
"lowercase": true,
"number": true,
"symbols": true
}

The descriptions on this page come from the server API specification (BSD-3-Clause license), and the examples come from the SDK generator (MIT license). The full notices are in the NOTICE file of the @owbase/web and @owbase/node packages.

Was this page helpful?