POST /api/v3/users/actions/GetReplacingUsersOptions

Retrieve a list of users who can be assigned as a replacement for another user. This request will return a list of users you can later use in the Remove User.

Request Path

POST /api/v3/users/actions/GetReplacingUsersOptions?search={search}&skip={skip}&take={take}

Request Payload

{
users: [{id:}, {id:…}],
projectId: ,
teamId: ,
role:
}

Body Parameters

Body parameter Type Description
users Array[user] Required. The user id that will replace an existing user. The users must be a part of the same project, team, and must have the same role.
projectId string Required. The project id which the user is a part of. Only one project id can be specified per call.
teamId string Required for all roles except if role = 8. The team id which the users are a part of. Only one team id can be specified per call.
role enum[Role] Required. The role which the users share. Only one role can be specified per call.
2=TeamMember, 4=TeamManager, 8=ProjectManager.

Query Parameters

Query parameter Type Description
search string Optional
skip int Optional
take int Optional

Request Example

{
    "users": [{id:"USMVysHnO_uN8v0OX8CUhBbq2"}, {id:"USMVysHnO_uN8v0OX8CUhBbq3"}],
    "projectId": "PRjTcEu83MXmpDAHTf47b-QQ2",
    "teamId": "TMXrjiUu7WTjGuctqTUJ0wXQ2",
    "role": 2
}

Response Example

{
    "shouldReplace": true,
    "users": [
        {
            "firstName": "Tom",
            "lastName": "Jones",
            "email": "tom.jones@cloudshare.com",
            "id": "USzDuIv2MQEoXQIIDq5Fhovw9"
        }
    ]
}

Error Response Example

{
    "message": <string>,
    "code": <string>,
    "exceptionMessage": <string>,
    "exceptionType": <string>,
    "stackTrace": <string>
}

Possible Error strings

Error Description String
InvalidApiParameterException If one of the ids supplied by the user is not valid.
OR
Request body parameters don’t coincide.
Request body parameters don’t match.
PermissionDeniedException If the requesting user does not have permission to remove these users Request cannot be completed due to missing permissions.
General error An error has occurred while processing the request, please try again. If the problem persists please contact support for help.