Skip to content

search_security_profiles

search_security_profiles(
    instance_id: InstanceId,
    *,
    config_overrides: Optional[ConnectClientConfig] = None,
    next_token: Optional[NextToken2500] = None,
    max_results: Optional[MaxResult100] = None,
    search_criteria: Optional[SecurityProfileSearchCriteria] = None,
    search_filter: Optional[SecurityProfilesSearchFilter] = None,
) -> SearchSecurityProfilesResponse

Searches security profiles in an Connect Customer instance, with optional filtering.

For information about security profiles, see Security Profiles in the Connect Customer Administrator Guide. For a mapping of the API name and user interface name of the security profile permissions, see List of security profile permissions.

Parameters:

  • instance_id (InstanceId) –

    The identifier of the Connect Customer instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.

  • next_token (Optional[NextToken2500], default: None ) –

    The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

  • max_results (Optional[MaxResult100], default: None ) –

    The maximum number of results to return per page.

  • search_criteria (Optional[SecurityProfileSearchCriteria], default: None ) –

    The search criteria to be used to return security profiles.

    The name field support "contains" queries with a minimum of 2 characters and maximum of 25 characters. Any queries with character lengths outside of this range will throw invalid results.

    The currently supported value for FieldName: name

  • search_filter (Optional[SecurityProfilesSearchFilter], default: None ) –

    Filters to be applied to search results.

Raises:

Source code in docs_src/capo_connect/_services/connect.py
def search_security_profiles(
    self,
    instance_id: "capo_connect.types.instance_id.InstanceId",
    *,
    config_overrides: Optional[ConnectClientConfig] = None,
    next_token: Optional["capo_connect.types.next_token2500.NextToken2500"] = None,
    max_results: Optional["capo_connect.types.max_result100.MaxResult100"] = None,
    search_criteria: Optional[
        "capo_connect.types.security_profile_search_criteria.SecurityProfileSearchCriteria"
    ] = None,
    search_filter: Optional[
        "capo_connect.types.security_profiles_search_filter.SecurityProfilesSearchFilter"
    ] = None,
) -> "capo_connect.types.search_security_profiles_response.SearchSecurityProfilesResponse":
    """<p>Searches security profiles in an Connect Customer instance, with optional filtering.</p> <p>For information about security profiles, see <a href="https://docs.aws.amazon.com/connect/latest/adminguide/connect-security-profiles.html">Security Profiles</a> in the <i>Connect Customer Administrator Guide</i>. For a mapping of the API name and user interface name of the security profile permissions, see <a href="https://docs.aws.amazon.com/connect/latest/adminguide/security-profile-list.html">List of security profile permissions</a>. </p>

    Args:
        instance_id: <p>The identifier of the Connect Customer instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
        next_token: <p>The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.</p>
        max_results: <p>The maximum number of results to return per page.</p>
        search_criteria: <p>The search criteria to be used to return security profiles. </p> <note> <p>The <code>name</code> field support "contains" queries with a minimum of 2 characters and maximum of 25 characters. Any queries with character lengths outside of this range will throw invalid results.</p> </note> <note> <p>The currently supported value for <code>FieldName</code>: <code>name</code> </p> </note>
        search_filter: <p>Filters to be applied to search results.</p>

    Raises:
        capo_connect.errors.internal_service_exception.InternalServiceException: <p>Request processing failed because of an error or failure with the service.</p>
        capo_connect.errors.invalid_parameter_exception.InvalidParameterException: <p>One or more of the specified parameters are not valid.</p>
        capo_connect.errors.invalid_request_exception.InvalidRequestException: <p>The request is not valid.</p>
        capo_connect.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource was not found.</p>
        capo_connect.errors.throttling_exception.ThrottlingException: <p>The throttling limit has been exceeded.</p>
        capo_connect.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_connect.types.search_security_profiles_request.SearchSecurityProfilesRequest]",
    ) -> OperationResponse[
        "capo_connect.types.search_security_profiles_response.SearchSecurityProfilesResponse"
    ]:
        import capo_connect._operations.amazon_connect_service.search_security_profiles

        output, http_response = (
            capo_connect._operations.amazon_connect_service.search_security_profiles.search_security_profiles(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("SearchSecurityProfiles")
    )
    input_: capo_connect.types.search_security_profiles_request.SearchSecurityProfilesRequest = {
        "instance_id": instance_id
    }
    if next_token is not None:
        input_["next_token"] = next_token
    if max_results is not None:
        input_["max_results"] = max_results
    if search_criteria is not None:
        input_["search_criteria"] = search_criteria
    if search_filter is not None:
        input_["search_filter"] = search_filter

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output