Monitor Capacity Blocks using EventBridge - Amazon Elastic Compute Cloud

Monitor Capacity Blocks using EventBridge

When your Capacity Block reservation starts, Amazon EC2 will emit an event through EventBridge that indicates your capacity is ready to use. Forty minutes before your Capacity Block reservation ends, you receive another EventBridge event that tells you that any instances running in the reservation will begin to terminate in 10 minutes. For more information about EventBridge events, see Amazon EventBridge Events.

The following event structures for events emitted for Capacity Blocks:

Capacity Block Delivered

The following example shows an event for Capacity Block Delivered.

{ "customer_event_id": "[Capacity Reservation Id]-delivered", "detail_type": "Capacity Block Reservation Delivered", "source": "aws.ec2", "account": "[Customer Account ID]", "time": "[Current time]", "resources": [ "[ODCR ARN]" ], "detail": { "capacity-reservation-id": "[ODCR ID]", "end-date": "[ODCR End Date]" } }
Capacity Block Expiration Warning

The following example shows an event for Capacity Block Expiration Warning.

{ "customer_event_id": "[Capacity Reservation Id]-approaching-expiry", "detail_type": "Capacity Block Reservation Expiration Warning", "source": "aws.ec2", "account": "[Customer Account ID]", "time": "[Current time]", "resources": [ "[ODCR ARN]" ], "detail": { "capacity-reservation-id": "[ODCR ID]", "end-date": "[ODCR End Date]" } }