rePostPrivate / Client / batch_add_role

batch_add_role#

rePostPrivate.Client.batch_add_role(**kwargs)#

Add role to multiple users or groups in a private re:Post.

See also: AWS API Documentation

Request Syntax

response = client.batch_add_role(
    accessorIds=[
        'string',
    ],
    role='EXPERT'|'MODERATOR'|'ADMINISTRATOR'|'SUPPORTREQUESTOR',
    spaceId='string'
)
Parameters:
  • accessorIds (list) –

    [REQUIRED]

    The user or group accessor identifiers to add the role to.

    • (string) –

  • role (string) –

    [REQUIRED]

    The role to add to the users or groups.

  • spaceId (string) –

    [REQUIRED]

    The unique ID of the private re:Post.

Return type:

dict

Returns:

Response Syntax

{
    'addedAccessorIds': [
        'string',
    ],
    'errors': [
        {
            'accessorId': 'string',
            'error': 123,
            'message': 'string'
        },
    ]
}

Response Structure

  • (dict) –

    • addedAccessorIds (list) –

      An array of successfully updated accessor identifiers.

      • (string) –

    • errors (list) –

      An array of errors that occurred when roles were added.

      • (dict) –

        An error that occurred during a batch operation.

        • accessorId (string) –

          The accessor identifier that’s related to the error.

        • error (integer) –

          The error code.

        • message (string) –

          Description of the error.

Exceptions

  • rePostPrivate.Client.exceptions.AccessDeniedException

  • rePostPrivate.Client.exceptions.ValidationException

  • rePostPrivate.Client.exceptions.ResourceNotFoundException

  • rePostPrivate.Client.exceptions.ThrottlingException

  • rePostPrivate.Client.exceptions.InternalServerException