CmdID

CmdID / aws / aws ssm

aws ssm get-calendar-state

Gets the state of a Amazon Web Services Systems Manager change calendar at the current time or a specified time. AWS CLI reference

2 examples 2 options Its page in the AWS CLI reference

Opens CmdID with your command. It is read in your browser and sent nowhere.

Examples

from aws-cli, each command read by CmdID

Example 1: To get the current state of a change calendar

The following get-calendar-state example returns the state of a calendar at the current time. Because the example doesn't specify a time, the current state of the calendar is reported.

aws ssm get-calendar-state --calendar-names "MyCalendar"Identify
--calendar-namesThe names of Amazon Resource Names (ARNs) of the Systems Manager documents (SSM documents) that represent the calendar entries for which you want to get the state.
Its output
{
    "State": "OPEN",
    "AtTime": "2020-02-19T22:28:51Z",
    "NextTransitionTime": "2020-02-24T21:15:19Z"
}

Example 2: To get the state of a change calendar at a specified time

The following get-calendar-state example returns the state of a calendar at the specified time.

aws ssm get-calendar-state --calendar-names "MyCalendar" --at-time "2020-07-19T21:15:19Z"Identify
--calendar-namesThe names of Amazon Resource Names (ARNs) of the Systems Manager documents (SSM documents) that represent the calendar entries for which you want to get the state.
--at-time(Optional) The specific time for which you want to get calendar state information, in ISO 8601 format.
Its output
{
    "State": "CLOSED",
    "AtTime": "2020-07-19T21:15:19Z"
}

For more information, see Getting the state of a change calendar in the AWS Systems Manager User Guide.

Options

2 in the AWS CLI reference
--at-time(Optional) The specific time for which you want to get calendar state information, in ISO 8601 format.
--calendar-namesThe names of Amazon Resource Names (ARNs) of the Systems Manager documents (SSM documents) that represent the calendar entries for which you want to get the state.