POST Roles
Creates a new role.
{
"name": "User",
"description": "Can use Interactive Analytics and Dashboards",
"capabilities": [
"VIEW_SHARED_DASHBOARDS",
"VIEW_INTERACTIVE_ANALYTICS",
"VIEW_CONTENT_PACKS",
"VIEW_SHARED_DASHBOARD_URLS",
"VIEW_CONTENT_PACK_DASHBOARDS",
"EDIT_USER_DASHBOARDS",
"EDIT_EXPORT",
"VIEW_ALERTS",
"VIEW_USER_DASHBOARDS",
"EDIT_INTERACTIVE_ANALYTICS",
"EDIT_SHARED_DASHBOARD_URLS",
"EDIT_CONTENT_PACKS",
"VIEW_EXTRACTED_FIELDS",
"VIEW_EXPORT",
"EDIT_SHARED_DASHBOARDS",
"EDIT_EXTRACTED_FIELDS"
],
"dataSets": [
"00000000-0000-0000-0000-000000000005",
"00000000-0000-0000-0000-000000000006"
]
}
Successfully created a new role.
{
"id": "f970dcba-fe3b-4ae2-b867-7164644db34e",
"name": "User1",
"description": "Can use Interactive Analytics and Dashboards",
"capabilities": [
{
"id": "VIEW_SHARED_DASHBOARDS"
},
{
"id": "VIEW_INTERACTIVE_ANALYTICS"
},
{
"id": "VIEW_CONTENT_PACKS"
},
{
"id": "VIEW_SHARED_DASHBOARD_URLS"
},
{
"id": "VIEW_CONTENT_PACK_DASHBOARDS"
},
{
"id": "EDIT_USER_DASHBOARDS"
},
{
"id": "EDIT_EXPORT"
},
{
"id": "VIEW_ALERTS"
},
{
"id": "VIEW_USER_DASHBOARDS"
},
{
"id": "EDIT_INTERACTIVE_ANALYTICS"
},
{
"id": "EDIT_SHARED_DASHBOARD_URLS"
},
{
"id": "EDIT_CONTENT_PACKS"
},
{
"id": "VIEW_EXTRACTED_FIELDS"
},
{
"id": "VIEW_EXPORT"
},
{
"id": "EDIT_SHARED_DASHBOARDS"
},
{
"id": "EDIT_EXTRACTED_FIELDS"
}
],
"dataSets": [
{
"id": "356f4d33-4e93-47f0-9dc5-1e97f0398db0",
"name": "identity constraints",
"type": "OR",
"constraints": [
{
"name": "id",
"operator": "CONTAINS",
"value": "00000000-0000-0000-0000-000000000001"
}
]
}
],
"required": false,
"editable": true
}
Invalid request body
{
"errorMessage": "Some fields have incorrect values",
"errorCode": "FIELD_ERROR",
"errorDetails": {
"name": [
{
"errorCode": "com.vmware.loginsight.api.errors.field_required",
"errorMessage": "Value cannot be empty."
}
]
}
}
A message describing the error.
A code representing the type of error.
Dynamic error details, where the field name can vary depending on the request field and error code.
The request was refused because it lacks valid authentication
credentials. This can happen if the Authorization header
was missing, or if it contained an invalid session ID.
Obtain a new session ID and retry the request,
or make an unauthenticated request without the Authorization header.
"Invalid session ID"
Role name already exists.
{
"errorMessage": "Another role with specified name already exists.",
"errorCode": "RBAC_GROUPS_ERROR",
"errorDetails": {
"errorCode": "com.vmware.loginsight.api.errors.rbac.group_with_specified_name_already_exists"
}
}
A message describing the error.
A code representing the type of error.
Dynamic error details, where the field name can vary depending on the request field and error code.
The request was refused because the session ID has
expired. Obtain a new session ID from /api/v1/sessions.
"Login Timeout"
Internal error while processing the client request
{
"errorMessage": "The operation failed due to an internal error."
}
A message describing the error.
A code representing the type of error.
Dynamic error details, where the field name can vary depending on the request field and error code.
curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '[{}]' https://{api_host}/api/v1/roles