Hypervisor User Groups Api Add Hypervisor User Group Members

Hypervisor User Groups Api Add Hypervisor User Group Members
Add members

Adds users to a group (ADMIN); users already in the group are ignored. 400 INVALID_HYPERVISOR_USER_GROUP for an empty list or more than 1000 ids; 404 HYPERVISOR_USER_GROUP_NOT_FOUND or HYPERVISOR_USER_NOT_FOUND (nothing is added when any id is unknown).

Request
URI
POST
https://{api_host}/api/v1/hypervisor-user-groups/{id}/members
COPY
Path Parameters
integer
id
Required  

Group id

id example
1

Request Body

The ids of the users to add as userIds. The list cannot be empty and holds at most 1000 ids, and users already in the group are ignored.

AddHypervisorUserGroupMembersRequest of type(s) application/json
Required  

Show optional properties

{
    "userIds": [
        {}
    ]
}
{
    "userIds": [
        1,
        2
    ]
}
array of integer
userIds
Required  
Constraints: minItems: 1 maxItems: 1000

Identifiers of the Hypervisor MFA Users to add: 1 to 1000 entries (400 INVALID_HYPERVISOR_USER_GROUP otherwise); users already in the group are left as they are, an unknown identifier is rejected with 404 HYPERVISOR_USER_NOT_FOUND, and the root OS account cannot be added

Authentication
This operation uses the following authentication methods.
Responses
204

204 No Content successful response. The users are added to the group

Operation doesn't return any data structure

400

400 Bad Request: INVALID_HYPERVISOR_USER_GROUP when userIds is empty, holds more than 1000 ids or names the bare root OS account; MALFORMED_REQUEST when the body cannot be read; INVALID_ARGUMENT when the id path variable is not a number

Returns ApiErrorResponse of type(s) application/json
{
    "errorCode": "string",
    "message": "string",
    "path": "string",
    "timestamp": "string",
    "reason": "string"
}
errorCode
Required  

Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.

string
message
Required  

Human-readable error description

string
path
Required  

Request URI path that produced the error

string As date-time As date-time
timestamp
Required  

Timestamp when the error occurred as an ISO 8601 date-time with offset

string
reason
Optional

A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.


401

401 Unauthorized: UNAUTHENTICATED when the VTP_SESSION cookie is missing, unknown, expired or revoked

Returns Unauthenticated of type(s) application/json
{
    "errorCode": "string",
    "message": "string",
    "path": "string",
    "timestamp": "string",
    "reason": "string"
}
errorCode
Required  

Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.

string
message
Required  

Human-readable error description

string
path
Required  

Request URI path that produced the error

string As date-time As date-time
timestamp
Required  

Timestamp when the error occurred as an ISO 8601 date-time with offset

string
reason
Optional

A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.


403

403 Forbidden: FORBIDDEN when the signed-in role is not allowed to call this operation; CSRF_ERROR when the X-XSRF-TOKEN header is missing or wrong on a POST, PUT, PATCH or DELETE (only POST /api/v1/auth/login is exempt, and a request without a valid session gets 401 UNAUTHENTICATED instead); PASSWORD_CHANGE_REQUIRED when the account must change its password first (only GET /api/v1/auth/session, POST /api/v1/auth/logout and POST /api/v1/auth/change-password are exempt); LICENSE_REQUIRED or LICENSE_EXPIRED while the license pool is restricted (no license, or expired past grace) (exempt: every route under /api/v1/auth, GET /api/v1/user/preferences, GET /api/v1/licensing/summary and POST /api/v1/licensing/licenses)

Returns ForbiddenWrite of type(s) application/json
{
    "errorCode": "string",
    "message": "string",
    "path": "string",
    "timestamp": "string",
    "reason": "string"
}
errorCode
Required  

Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.

string
message
Required  

Human-readable error description

string
path
Required  

Request URI path that produced the error

string As date-time As date-time
timestamp
Required  

Timestamp when the error occurred as an ISO 8601 date-time with offset

string
reason
Optional

A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.


404

404 Not Found: HYPERVISOR_USER_GROUP_NOT_FOUND when no hypervisor user group has the id; HYPERVISOR_USER_NOT_FOUND when a listed user does not exist, in which case nothing is added

Returns ApiErrorResponse of type(s) application/json
{
    "errorCode": "string",
    "message": "string",
    "path": "string",
    "timestamp": "string",
    "reason": "string"
}
errorCode
Required  

Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.

string
message
Required  

Human-readable error description

string
path
Required  

Request URI path that produced the error

string As date-time As date-time
timestamp
Required  

Timestamp when the error occurred as an ISO 8601 date-time with offset

string
reason
Optional

A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.


Code Samples
COPY
                    curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"userIds":["integer"]}' https://{api_host}/api/v1/hypervisor-user-groups/{id}/members