![]() |
REST API
16
REST API for Luna Network HSMs
|
This resource creates a REST API user. Created user will be accessible in LunaSH too.
Users with the following role privileges can perform this command:
The user ID of the user to create. No two users can have the same name.
Use: Required
JSON Schema:
Object
type: string
minLength: 1
maxLength: 32
pattern: [a-zA-Z_][a-zA-Z0-9._-]{0,31}
The full name of the user.
Use: Not Required
JSON Schema:
Object type: string pattern: [a-zA-Z0-9_ -]
The email address associated with the user. An email cannot be empty, if provided.
Use: Not Required
JSON Schema:
Object type: string
The role associated with the user. No two roles can have the same name. User can be created without role by providing empty value.
Use: Required
JSON Schema:
Object type: string minLength: 0 maxLength: 64 pattern: [a-zA-Z0-9_]
The password associated with the user.
Note: The password must be at least 8 characters long.
The password must contain characters from at least 3 of the following 4 categories:
Use: Required
JSON Schema:
Object
type: string
minLength: 8
maxLength: 255
pattern: [a-zA-Z0-9_ $()*+./^[]{}!#%,:=@~'&|<>?`;"-]
Success
"Location" is the URL to the newly created user.
Unexpected failure
POST
https://1.2.3.4:8443/users
{
"userId": "restUser",
"fullName": "restUserName",
"email": "rest_user@email.com",
"role": "monitor",
"password": "restPass123"
}
POST
https://1.2.3.4:8443/users
{
"userId": "restuser",
"fullName": "restUserName",
"email": "rest_user@email.com",
"role": "",
"password": "restPass123"
}
{
}