Summary:
List all users in a config set, and add users to a config set.
URL:
http(s)://{server hostname}/api/cfg/serverGroupConfig/{serverGroupId}/users
Methods summary
- GET Method - lists all users in a config set.
- POST Method - adds a user to a config set.
GET Method detail
Lists all users in a specified config set.
Response:
| Name | Description |
|---|---|
| username |
username. |
| password | user's password. |
| settings |
individual user settings, e.g. timeout, account locking, password expiry. |
| passwordChangeId | ID of the change that created the current password. |
| count | number of users returned in this config set. |
Example:
INPUT
curl -u admin:admin https://localhost/api/cfg/serverGroupConfig/82e7c418-cd48-4fbf-857b-cddb475841a2/users?media=json
OUTPUT
{
"items" : [ {
"userName" : "admin",
"password" : "2QFVD3sjUOl9IXHJskIaTyhg8fE=",
"settings" : null,
"passwordChangeId" : 77
}, {
"userName" : "user",
"password" : "jUx3/xeXPVXQ132Q1gJdbh7yc9Q=",
"settings" : null,
"passwordChangeId" : 77
} ],
"count" : 2
}
POST Method detail
Add a user to a specified config set. Note, a user can be added without necessarily specifying settings (i.e., a user can be added using only 'userName' and 'password').
Request:
| Name | Description |
|---|---|
| username |
username. |
| password | user's password. |
| timeoutMinutes | number of minutes of inactivity after which the user will be logged out. |
| lockAttempts | number of failed attempts to log in after which the user will be locked out, -1 to disable. |
| lockDurationFailedAttempts | number of minutes for which the user will be locked out after exceeding the lockAttempts figure. -1 disables this, and it will revert to global settings, if any. |
| expiryDays | number of days after which the user account will expire. -1 disables this. |
| pwChangeDays | number of days until password change. -1 disables this. |
| passwordExpiryNoticePeriod | how many days' notice during which a password expiration warning will be displayed before the password expires. |
| overridePasswordSettings | if the global user password settings are overriden, either 'true' or 'false'. |
| forcePWChange | specify whether to force the user to change their password the next time they log in, either 'true' or 'false'. |
| errorCode |
code for the change outcome, e.g. 'Success'. |
| errorDetails | details of an error, if applicable. |
| configurationChangeId | ID of the current configuration change, referred to in the table under the Sync History tab on the Multi-Server Configuration page. Each time a config set is updated, the set gains a new configuration change ID. This ID is an auto-incrementing number. |
| serverGroupId | ID of the config set to which the user was added. |
| timestampSec | timestamp of when this config set was modified. |
| modifiedBy | user who made this change. |
Example:
INPUT
curl -u admin:admin https://localhost/api/cfg/serverGroupConfig/82e7c418-cd48-4fbf-857b-cddb475841a2/users -X POST -H "content-type:application/json" -d '
{
"username" : "guy11",
"password" : "supersecret"
"settings" : {
"timeoutMinutes" : 60,
"lockAttempts" : 3,
"lockDurationFailedAttempts" : -1,
"expiryDays" : 2,
"pwChangeDays" : 30,
"passwordExpiryNoticePeriod" : 0,
"overridePasswordSettings" : true,
"forcePWChange" : false
}
}'
OUTPUT
{
"errorCode" : "SUCCESS",
"errorDetails" : null,
"data" : {
"configurationChangeId" : 79,
"serverGroupId" : "82e7c418-cd48-4fbf-857b-cddb475841a2",
"timestampSec" : 1677514827,
"modifiedBy" : "admin"
}
}
Comments
0 comments
Please sign in to leave a comment.