BedrockAgentCore / Client / delete_capacity_provider_session

delete_capacity_provider_session

BedrockAgentCore.Client.delete_capacity_provider_session(**kwargs)

Deletes a session associated with a capacity provider in Amazon Bedrock AgentCore and makes the session unavailable for further use. To delete a capacity provider session, specify both the capacity provider identifier and the session ID. After you delete a session, you cannot restart it.

See also: AWS API Documentation

Request Syntax

response = client.delete_capacity_provider_session(
    capacityProviderId='string',
    sessionId='string'
)
Parameters:
  • capacityProviderId (string) –

    [REQUIRED]

    The unique identifier of the capacity provider associated with the session.

  • sessionId (string) –

    [REQUIRED]

    The unique identifier of the capacity provider session to delete.

Return type:

dict

Returns:

Response Syntax

{
    'capacityProviderArn': 'string',
    'sessionId': 'string',
    'status': 'Provisioning'|'Deprovisioning'|'Active'|'Deleting'|'Deleted'|'Stopped'
}

Response Structure

  • (dict) –

    • capacityProviderArn (string) –

      The Amazon Resource Name (ARN) of the capacity provider associated with the deleted session.

    • sessionId (string) –

      The unique identifier of the deleted capacity provider session.

    • status (string) –

      The current status of the capacity provider session. When the status is Deleting, the session is being deleted and is not available. When the status is Deleted, the session is no longer available.

Exceptions

  • BedrockAgentCore.Client.exceptions.ValidationException

  • BedrockAgentCore.Client.exceptions.AccessDeniedException

  • BedrockAgentCore.Client.exceptions.ResourceNotFoundException

  • BedrockAgentCore.Client.exceptions.ThrottlingException

  • BedrockAgentCore.Client.exceptions.InternalServerException