[{"label":"Latest (1.0)","version":"latest"}]
cloud-partner-navigator

Update Org Roles

Description

Updates the organization roles of a particular user in an organization.

Request

Request

URL

URL


patch
https://console.navigator.vmware.com/cphub/api/auth/v1/users/{userId}/orgs/{orgId}/org-roles
Copy

Path Parameters

Path Parameters

string
orgId Required

Unique identifier (GUID) of the organization.


string
userId Required

The userId or user account identifier.


Query Parameters

Query Parameters

string
context Optional

context can be OPERATOR, PROVIDER or TENANT


Request Body

Request Body

OrgRoleItems of mimetype application/json Optional

Request body to update the organization roles of a particular user in an organization.

{
    "roleNamesToAdd": [
        "...",
        "..."
    ],
    "roleNamesToRemove": [
        "...",
        "..."
    ]
}
array of string
roleNamesToAdd Optional

The Role names to add.


array of string
roleNamesToRemove Optional

The Role names to remove.

Authentication

Authentication

This operation uses the following authentication methods.

Response

Response

Response Body

Response Body

200 OK

Returns OrgRoles of type application/json
{
    "orgRoles": [
        {
            "displayName": "...",
            "id": "...",
            "memberType": "DIRECT",
            "name": "...",
            "orgId": "..."
        },
        {
            "displayName": "...",
            "id": "...",
            "memberType": "DIRECT",
            "name": "...",
            "orgId": "..."
        }
    ]
}
array of Role
orgRoles Optional

The list of organization role objects.

Errors

Errors

401

Unauthorized - The user is not authorized to use the API


403

Forbidden - User does not have permission for this operation


500

Internal Server Error - An unexpected error has occurred while processing the request

Code Samples

Code Samples

cURL Command

curl -X PATCH -H "Content-Type: application/json" -d '{"roleNamesToAdd":["...","..."],"roleNamesToRemove":["...","..."]}' https://console.navigator.vmware.com/cphub/api/auth/v1/users/{userId}/orgs/{orgId}/org-roles
Vendor Extensions

Vendor Extensions

This operation contains the following vendor extensions defined in the spec:
x-codegen-request-body-name: body


Feedback

Was this page helpful?