Create user account
Creates a local user account for the library. This user account can be used to log in to the library if local authentication is enabled.
Request syntax
POST
/v1/authentication/userAccounts{"name": <name>, "role": <role>, "email": <email>,
"password": <password>, "expirePassword": <"yes"|"no">}
Creates a
local user account for the library.
Request body parameters
name
(string, required)-
The unique name of the user account.
role
(string, required)-
The name of the role that defines which commands the user account is allowed to execute. Default roles include
Administrator
,Superuser
,Local Service
(Diamondback only),Service
(TS4500 only), andMonitor
.
email
(string, optional)-
The optional email address. Required if
password
is not set. This should not be included for Diamondback as email is not supported.
password
(string, required)-
The initial password for this user account.
expirePassword
(string, optional)-
Whether the password will be set as expired. An expired password must be changed when that user next logs in. Values include
yes
orno
. This defaults toyes
if not specified.
Example
> POST /v1/authentication/userAccounts {"name": "manager1",
"role": "Monitor", "password": "tempPass4Now"}
HTTP/1.1 201 Created
Location: /v1/authentication/userAccounts/manager1
Content-Type: application/json
Content-Length: 0
Error handling
- Returns
400 Bad Command
ifname
is an invalid length or contains invalid characters. - Returns
400 Bad Command
ifrole
is not an existing role name. - Returns
400 Bad Command
ifemail
is not a valid email account. - Returns
400 Bad Command
if an invalidpassword
is given with details in theerror_description
with what is required.