Random Password Generation

The Random Password Generation API provides operations to generate a random password.

Generate a random password
OPA roles:
  • end_user

Generates a random password based on the request parameters provided

SecuritybearerAuth
Request
path Parameters
team_name
required
string

The name of your team

Request Body schema: application/json
required
object (RandomPasswordCharacterOptions)
digits
boolean

If true, passwords include one or more numbers

lower_case
boolean

If true, passwords include one or more lowercase letters

special_characters
boolean

If true, passwords include one or more symbols

upper_case
boolean

If true, passwords include one or more uppercase letters

num_chars
required
integer

The desired length for the password

required
object (RawJSONWebKey)

A JSON Web Key formatted in accordance with RFC 7517.

alg
string (alg)

The algorithm of the key

Enum: "EdDSA" "RSA-OAEP-256"
crv
string (curve)

The curve used by the key

Enum: "Ed25519" "P-256" "P-384" "P-521"
d
string <byte>

The exponent of the private key

dp
string <byte>

The first factor CRT exponent of the private key

dq
string <byte>

The second factor CRT exponent of the private key

e
string <byte>

The exponent of the public key

k
string <byte>

The key

kid
string <regex> ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-...

The key ID

kty
string (kty)

The key type

Enum: "EC" "OKP" "RSA" "oct"
n
string <byte>

The modulus of the public key

p
string <byte>

The first prime factor of the private key

q
string <byte>

The second prime factor of the private key

qi
string <byte>

The first CRT coefficient of the private key

use
string

The intended use of the key

x
string <byte>

The x coordinate of the key

x5c
Array of strings

A list of X.509 certificates

x5t
string

The SHA-1 thumbprint of the X.509 certificate

x5t#S256
string

The SHA-256 thumbprint of the X.509 certificate

x5u
string

The URL of the X.509 certificates

y
string <byte>

The y coordinate of the key

Responses
200

OK

400

Bad request

401

Unauthorized

post/v1/teams/{team_name}/random_password
Request samples
application/json
{
  • "character_options": {
    • "digits": true,
    • "lower_case": true,
    • "special_characters": true,
    • "upper_case": true
    },
  • "num_chars": 0,
  • "public_key": {
    • "alg": "EdDSA",
    • "crv": "Ed25519",
    • "d": "string",
    • "dp": "string",
    • "dq": "string",
    • "e": "string",
    • "k": "string",
    • "kid": "/regex/",
    • "kty": "EC",
    • "n": "string",
    • "p": "string",
    • "q": "string",
    • "qi": "string",
    • "use": "string",
    • "x": "string",
    • "x5c": [
      ],
    • "x5t": "string",
    • "x5t#S256": "string",
    • "x5u": "string",
    • "y": "string"
    }
}
Response samples
application/json
{
  • "password_jwe": "string"
}