WickrAdminAPI / Client / batch_toggle_user_suspend_status

batch_toggle_user_suspend_status

WickrAdminAPI.Client.batch_toggle_user_suspend_status(**kwargs)

Suspends or unsuspends multiple users in a Wickr network. Suspended users cannot access the network until they are unsuspended. This operation is useful for temporarily restricting access without deleting user accounts.

See also: AWS API Documentation

Request Syntax

response = client.batch_toggle_user_suspend_status(
    networkId='string',
    suspend=True|False,
    userIds=[
        'string',
    ],
    clientToken='string'
)
Parameters:
  • networkId (string) –

    [REQUIRED]

    The ID of the Wickr network where users will be suspended or unsuspended.

  • suspend (boolean) –

    [REQUIRED]

    A boolean value indicating whether to suspend (true) or unsuspend (false) the specified users.

  • userIds (list) –

    [REQUIRED]

    A list of user IDs identifying the users whose suspend status will be toggled. Maximum 50 users per batch request.

    • (string) –

  • clientToken (string) –

    A unique identifier for this request to ensure idempotency.

    This field is autopopulated if not provided.

Return type:

dict

Returns:

Response Syntax

{
    'message': 'string',
    'successful': [
        {
            'userId': 'string'
        },
    ],
    'failed': [
        {
            'field': 'string',
            'reason': 'string',
            'userId': 'string'
        },
    ]
}

Response Structure

  • (dict) –

    • message (string) –

      A message indicating the overall result of the batch suspend status toggle operation.

    • successful (list) –

      A list of user IDs whose suspend status was successfully toggled.

      • (dict) –

        Contains information about a user that was successfully processed in a batch user operation.

        • userId (string) –

          The user ID that was successfully processed.

    • failed (list) –

      A list of suspend status toggle attempts that failed, including error details explaining why each user’s status could not be changed.

      • (dict) –

        Contains error information for a user operation that failed in a batch user request.

        • field (string) –

          The field that caused the error.

        • reason (string) –

          A description of why the user operation failed.

        • userId (string) –

          The user ID associated with the failed operation.

Exceptions