Skip to content

get_kx_connection_string async

get_kx_connection_string(
    user_arn: KxUserArn,
    environment_id: IdType,
    cluster_name: KxClusterName,
    *,
    config_overrides: Optional[AsyncfinspaceClientConfig] = None,
) -> GetKxConnectionStringResponse

Retrieves a connection string for a user to connect to a kdb cluster. You must call this API using the same role that you have defined while creating a user.

Parameters:

  • user_arn (KxUserArn) –

    The Amazon Resource Name (ARN) that identifies the user. For more information about ARNs and how to use ARNs in policies, see IAM Identifiers in the IAM User Guide.

  • environment_id (IdType) –

    A unique identifier for the kdb environment.

  • cluster_name (KxClusterName) –

    A name of the kdb cluster.

Raises:

Source code in docs_src/capo_finspace/_services/async_finspace.py
async def get_kx_connection_string(
    self,
    user_arn: "capo_finspace.types.kx_user_arn.KxUserArn",
    environment_id: "capo_finspace.types.id_type.IdType",
    cluster_name: "capo_finspace.types.kx_cluster_name.KxClusterName",
    *,
    config_overrides: Optional[AsyncfinspaceClientConfig] = None,
) -> "capo_finspace.types.get_kx_connection_string_response.GetKxConnectionStringResponse":
    """<p>Retrieves a connection string for a user to connect to a kdb cluster. You must call this API using the same role that you have defined while creating a user. </p>

    Args:
        user_arn: <p> The Amazon Resource Name (ARN) that identifies the user. For more information about ARNs and how to use ARNs in policies, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html">IAM Identifiers</a> in the <i>IAM User Guide</i>. </p>
        environment_id: <p>A unique identifier for the kdb environment.</p>
        cluster_name: <p>A name of the kdb cluster.</p>

    Raises:
        capo_finspace.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
        capo_finspace.errors.internal_server_exception.InternalServerException: <p>The request processing has failed because of an unknown error, exception or failure.</p>
        capo_finspace.errors.resource_not_found_exception.ResourceNotFoundException: <p>One or more resources can't be found.</p>
        capo_finspace.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling.</p>
        capo_finspace.errors.validation_exception.ValidationException: <p>The input fails to satisfy the constraints specified by an AWS service.</p>
        capo_finspace.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_finspace.types.get_kx_connection_string_request.GetKxConnectionStringRequest]",
    ) -> AsyncOperationResponse[
        "capo_finspace.types.get_kx_connection_string_response.GetKxConnectionStringResponse"
    ]:
        import capo_finspace._operations.aws_habanero_management_service.get_kx_connection_string

        (
            output,
            http_response,
        ) = await capo_finspace._operations.aws_habanero_management_service.get_kx_connection_string.async_get_kx_connection_string(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_output(
        output: "capo_finspace.types.get_kx_connection_string_response.GetKxConnectionStringResponse",
    ) -> dict[str, Any]:
        import capo_finspace.types.get_kx_connection_string_response

        return (
            capo_finspace.types.get_kx_connection_string_response.redact_sensitive(
                output
            )
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("GetKxConnectionString", redact_output=_redact_output),
    )
    input_: capo_finspace.types.get_kx_connection_string_request.GetKxConnectionStringRequest = {
        "user_arn": user_arn,
        "environment_id": environment_id,
        "cluster_name": cluster_name,
    }

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output