Chilkat Online Tools

DescribeAnomaly autoit Example

Amazon DevOps Guru

; This example requires the Chilkat API to have been previously unlocked.
; See Global Unlock Sample for sample code.

$oRest = ObjCreate("Chilkat_9_5_0.Rest")
Local $bSuccess

$oAuthAws = ObjCreate("Chilkat_9_5_0.AuthAws")
$oAuthAws.AccessKey = "AWS_ACCESS_KEY"
$oAuthAws.SecretKey = "AWS_SECRET_KEY"

; Don't forget to change the region to your particular region. (Also make the same change in the call to Connect below.)
$oAuthAws.Region = "us-west-2"
$oAuthAws.ServiceName = "devops-guru"
; SetAuthAws causes Chilkat to automatically add the following headers: Authorization, X-Amz-Date
$oRest.SetAuthAws($oAuthAws)

; URL: https://devops-guru.us-west-2.amazonaws.com/
; Use the same region as specified above.
$bSuccess = $oRest.Connect("devops-guru.us-west-2.amazonaws.com",443,True,True)
If ($bSuccess <> True) Then
    ConsoleWrite("ConnectFailReason: " & $oRest.ConnectFailReason & @CRLF)
    ConsoleWrite($oRest.LastErrorText & @CRLF)
    Exit
EndIf

$oRest.AddHeader("Content-Type","application/x-amz-json-1.1")
$oRest.AddHeader("X-Amz-Target","DescribeAnomaly")

$oSbResponseBody = ObjCreate("Chilkat_9_5_0.StringBuilder")
$bSuccess = $oRest.FullRequestNoBodySb("GET","/anomalies/{Id}",$oSbResponseBody)
If ($bSuccess <> True) Then
    ConsoleWrite($oRest.LastErrorText & @CRLF)
    Exit
EndIf

Local $iRespStatusCode = $oRest.ResponseStatusCode
ConsoleWrite("response status code = " & $iRespStatusCode & @CRLF)
If ($iRespStatusCode <> 200) Then
    ConsoleWrite("Response Header:" & @CRLF)
    ConsoleWrite($oRest.ResponseHeader & @CRLF)
    ConsoleWrite("Response Body:" & @CRLF)
    ConsoleWrite($oSbResponseBody.GetAsString() & @CRLF)
    Exit
EndIf

$oJResp = ObjCreate("Chilkat_9_5_0.JsonObject")
$oJResp.LoadSb($oSbResponseBody)

; The following code parses the JSON response.
; A sample JSON response is shown below the sample code.

; Use this online tool to generate parsing code from sample JSON:
; Generate Parsing Code from JSON

Local $strVal
Local $sAppBoundaryKey
Local $iJ
Local $iCount_j
Local $sStatusCode
Local $sMetricName
Local $sNamespace
Local $iPeriod
Local $sStat
Local $sUnit
Local $sValue
Local $iMetricValue
Local $iTimestamp
Local $sMetricDisplayName
Local $sV_String
Local $sGroup
Local $iGroupByLimit
Local $sMetric
Local $sFilterString
Local $sGroupByGroup
Local $sMetricQueryMetric
Local $iReferenceScalarValue
Local $iK
Local $iCount_k
Local $iValue_int
Local $sMetricDataSummaryStatusCode

Local $iCloseTime = $oJResp.IntOf("ProactiveAnomaly.AnomalyReportedTimeRange.CloseTime")
Local $iOpenTime = $oJResp.IntOf("ProactiveAnomaly.AnomalyReportedTimeRange.OpenTime")
Local $iEndTime = $oJResp.IntOf("ProactiveAnomaly.AnomalyTimeRange.EndTime")
Local $iStartTime = $oJResp.IntOf("ProactiveAnomaly.AnomalyTimeRange.StartTime")
Local $sAssociatedInsightId = $oJResp.StringOf("ProactiveAnomaly.AssociatedInsightId")
Local $sId = $oJResp.StringOf("ProactiveAnomaly.Id")
Local $iLimit = $oJResp.IntOf("ProactiveAnomaly.Limit")
Local $iPredictionTimeRangeEndTime = $oJResp.IntOf("ProactiveAnomaly.PredictionTimeRange.EndTime")
Local $iPredictionTimeRangeStartTime = $oJResp.IntOf("ProactiveAnomaly.PredictionTimeRange.StartTime")
Local $sSeverity = $oJResp.StringOf("ProactiveAnomaly.Severity")
Local $sSource = $oJResp.StringOf("ProactiveAnomaly.SourceMetadata.Source")
Local $sSourceResourceName = $oJResp.StringOf("ProactiveAnomaly.SourceMetadata.SourceResourceName")
Local $sSourceResourceType = $oJResp.StringOf("ProactiveAnomaly.SourceMetadata.SourceResourceType")
Local $sStatus = $oJResp.StringOf("ProactiveAnomaly.Status")
Local $iUpdateTime = $oJResp.IntOf("ProactiveAnomaly.UpdateTime")
Local $iAnomalyReportedTimeRangeCloseTime = $oJResp.IntOf("ReactiveAnomaly.AnomalyReportedTimeRange.CloseTime")
Local $iAnomalyReportedTimeRangeOpenTime = $oJResp.IntOf("ReactiveAnomaly.AnomalyReportedTimeRange.OpenTime")
Local $iAnomalyTimeRangeEndTime = $oJResp.IntOf("ReactiveAnomaly.AnomalyTimeRange.EndTime")
Local $iAnomalyTimeRangeStartTime = $oJResp.IntOf("ReactiveAnomaly.AnomalyTimeRange.StartTime")
Local $sReactiveAnomalyAssociatedInsightId = $oJResp.StringOf("ReactiveAnomaly.AssociatedInsightId")
Local $sCausalAnomalyId = $oJResp.StringOf("ReactiveAnomaly.CausalAnomalyId")
Local $sDescription = $oJResp.StringOf("ReactiveAnomaly.Description")
Local $sReactiveAnomalyId = $oJResp.StringOf("ReactiveAnomaly.Id")
Local $sName = $oJResp.StringOf("ReactiveAnomaly.Name")
Local $sReactiveAnomalySeverity = $oJResp.StringOf("ReactiveAnomaly.Severity")
Local $sReactiveAnomalyStatus = $oJResp.StringOf("ReactiveAnomaly.Status")
Local $sV_Type = $oJResp.StringOf("ReactiveAnomaly.Type")
Local $i = 0
Local $iCount_i = $oJResp.SizeOfArray("ProactiveAnomaly.AnomalyResources")
While $i < $iCount_i
    $oJResp.I = $i
    $sName = $oJResp.StringOf("ProactiveAnomaly.AnomalyResources[i].Name")
    $sV_Type = $oJResp.StringOf("ProactiveAnomaly.AnomalyResources[i].Type")
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ProactiveAnomaly.ResourceCollection.CloudFormation.StackNames")
While $i < $iCount_i
    $oJResp.I = $i
    $strVal = $oJResp.StringOf("ProactiveAnomaly.ResourceCollection.CloudFormation.StackNames[i]")
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ProactiveAnomaly.ResourceCollection.Tags")
While $i < $iCount_i
    $oJResp.I = $i
    $sAppBoundaryKey = $oJResp.StringOf("ProactiveAnomaly.ResourceCollection.Tags[i].AppBoundaryKey")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.ResourceCollection.Tags[i].TagValues")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $strVal = $oJResp.StringOf("ProactiveAnomaly.ResourceCollection.Tags[i].TagValues[j]")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.CloudWatchMetrics")
While $i < $iCount_i
    $oJResp.I = $i
    $sStatusCode = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.StatusCode")
    $sMetricName = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricName")
    $sNamespace = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Namespace")
    $iPeriod = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Period")
    $sStat = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Stat")
    $sUnit = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Unit")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sName = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions[j].Name")
        $sValue = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions[j].Value")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $iMetricValue = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList[j].MetricValue")
        $iTimestamp = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList[j].Timestamp")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics")
While $i < $iCount_i
    $oJResp.I = $i
    $sMetricDisplayName = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricDisplayName")
    $sV_String = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.Filter.string")
    $sGroup = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Group")
    $iGroupByLimit = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Limit")
    $sMetric = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.Metric")
    $sUnit = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].Unit")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Dimensions")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $strVal = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Dimensions[j]")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sFilterString = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.Filter.string")
        $sGroupByGroup = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Group")
        $iGroupByLimit = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Limit")
        $sMetricQueryMetric = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.Metric")
        $iReferenceScalarValue = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceScalar.Value")
        $sName = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].Name")
        $iK = 0
        $iCount_k = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Dimensions")
        While $iK < $iCount_k
            $oJResp.K = $iK
            $strVal = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Dimensions[k]")
            $iK = $iK + 1
        Wend
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sV_Type = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly[j].Type")
        $iValue_int = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly[j].Value")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sV_Type = $oJResp.StringOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline[j].Type")
        $iValue_int = $oJResp.IntOf("ProactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline[j].Value")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ReactiveAnomaly.AnomalyResources")
While $i < $iCount_i
    $oJResp.I = $i
    $sName = $oJResp.StringOf("ReactiveAnomaly.AnomalyResources[i].Name")
    $sV_Type = $oJResp.StringOf("ReactiveAnomaly.AnomalyResources[i].Type")
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ReactiveAnomaly.ResourceCollection.CloudFormation.StackNames")
While $i < $iCount_i
    $oJResp.I = $i
    $strVal = $oJResp.StringOf("ReactiveAnomaly.ResourceCollection.CloudFormation.StackNames[i]")
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ReactiveAnomaly.ResourceCollection.Tags")
While $i < $iCount_i
    $oJResp.I = $i
    $sAppBoundaryKey = $oJResp.StringOf("ReactiveAnomaly.ResourceCollection.Tags[i].AppBoundaryKey")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.ResourceCollection.Tags[i].TagValues")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $strVal = $oJResp.StringOf("ReactiveAnomaly.ResourceCollection.Tags[i].TagValues[j]")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.CloudWatchMetrics")
While $i < $iCount_i
    $oJResp.I = $i
    $sMetricDataSummaryStatusCode = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.StatusCode")
    $sMetricName = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricName")
    $sNamespace = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Namespace")
    $iPeriod = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Period")
    $sStat = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Stat")
    $sUnit = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Unit")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sName = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions[j].Name")
        $sValue = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].Dimensions[j].Value")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $iMetricValue = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList[j].MetricValue")
        $iTimestamp = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.CloudWatchMetrics[i].MetricDataSummary.TimestampMetricValuePairList[j].Timestamp")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend
$i = 0
$iCount_i = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics")
While $i < $iCount_i
    $oJResp.I = $i
    $sMetricDisplayName = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricDisplayName")
    $sFilterString = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.Filter.string")
    $sGroupByGroup = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Group")
    $iGroupByLimit = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Limit")
    $sMetricQueryMetric = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.Metric")
    $sUnit = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].Unit")
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Dimensions")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $strVal = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].MetricQuery.GroupBy.Dimensions[j]")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sFilterString = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.Filter.string")
        $sGroupByGroup = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Group")
        $iGroupByLimit = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Limit")
        $sMetricQueryMetric = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.Metric")
        $iReferenceScalarValue = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceScalar.Value")
        $sName = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].Name")
        $iK = 0
        $iCount_k = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Dimensions")
        While $iK < $iCount_k
            $oJResp.K = $iK
            $strVal = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].ReferenceData[j].ComparisonValues.ReferenceMetric.MetricQuery.GroupBy.Dimensions[k]")
            $iK = $iK + 1
        Wend
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sV_Type = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly[j].Type")
        $iValue_int = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtAnomaly[j].Value")
        $iJ = $iJ + 1
    Wend
    $iJ = 0
    $iCount_j = $oJResp.SizeOfArray("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline")
    While $iJ < $iCount_j
        $oJResp.J = $iJ
        $sV_Type = $oJResp.StringOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline[j].Type")
        $iValue_int = $oJResp.IntOf("ReactiveAnomaly.SourceDetails.PerformanceInsightsMetrics[i].StatsAtBaseline[j].Value")
        $iJ = $iJ + 1
    Wend
    $i = $i + 1
Wend

; A sample JSON response body parsed by the above code:

; {
;   "ProactiveAnomaly": {
;     "AnomalyReportedTimeRange": {
;       "CloseTime": number,
;       "OpenTime": number
;     },
;     "AnomalyResources": [
;       {
;         "Name": "string",
;         "Type": "string"
;       }
;     ],
;     "AnomalyTimeRange": {
;       "EndTime": number,
;       "StartTime": number
;     },
;     "AssociatedInsightId": "string",
;     "Id": "string",
;     "Limit": number,
;     "PredictionTimeRange": {
;       "EndTime": number,
;       "StartTime": number
;     },
;     "ResourceCollection": {
;       "CloudFormation": {
;         "StackNames": [
;           "string"
;         ]
;       },
;       "Tags": [
;         {
;           "AppBoundaryKey": "string",
;           "TagValues": [
;             "string"
;           ]
;         }
;       ]
;     },
;     "Severity": "string",
;     "SourceDetails": {
;       "CloudWatchMetrics": [
;         {
;           "Dimensions": [
;             {
;               "Name": "string",
;               "Value": "string"
;             }
;           ],
;           "MetricDataSummary": {
;             "StatusCode": "string",
;             "TimestampMetricValuePairList": [
;               {
;                 "MetricValue": number,
;                 "Timestamp": number
;               }
;             ]
;           },
;           "MetricName": "string",
;           "Namespace": "string",
;           "Period": number,
;           "Stat": "string",
;           "Unit": "string"
;         }
;       ],
;       "PerformanceInsightsMetrics": [
;         {
;           "MetricDisplayName": "string",
;           "MetricQuery": {
;             "Filter": {
;               "string": "string"
;             },
;             "GroupBy": {
;               "Dimensions": [
;                 "string"
;               ],
;               "Group": "string",
;               "Limit": number
;             },
;             "Metric": "string"
;           },
;           "ReferenceData": [
;             {
;               "ComparisonValues": {
;                 "ReferenceMetric": {
;                   "MetricQuery": {
;                     "Filter": {
;                       "string": "string"
;                     },
;                     "GroupBy": {
;                       "Dimensions": [
;                         "string"
;                       ],
;                       "Group": "string",
;                       "Limit": number
;                     },
;                     "Metric": "string"
;                   }
;                 },
;                 "ReferenceScalar": {
;                   "Value": number
;                 }
;               },
;               "Name": "string"
;             }
;           ],
;           "StatsAtAnomaly": [
;             {
;               "Type": "string",
;               "Value": number
;             }
;           ],
;           "StatsAtBaseline": [
;             {
;               "Type": "string",
;               "Value": number
;             }
;           ],
;           "Unit": "string"
;         }
;       ]
;     },
;     "SourceMetadata": {
;       "Source": "string",
;       "SourceResourceName": "string",
;       "SourceResourceType": "string"
;     },
;     "Status": "string",
;     "UpdateTime": number
;   },
;   "ReactiveAnomaly": {
;     "AnomalyReportedTimeRange": {
;       "CloseTime": number,
;       "OpenTime": number
;     },
;     "AnomalyResources": [
;       {
;         "Name": "string",
;         "Type": "string"
;       }
;     ],
;     "AnomalyTimeRange": {
;       "EndTime": number,
;       "StartTime": number
;     },
;     "AssociatedInsightId": "string",
;     "CausalAnomalyId": "string",
;     "Description": "string",
;     "Id": "string",
;     "Name": "string",
;     "ResourceCollection": {
;       "CloudFormation": {
;         "StackNames": [
;           "string"
;         ]
;       },
;       "Tags": [
;         {
;           "AppBoundaryKey": "string",
;           "TagValues": [
;             "string"
;           ]
;         }
;       ]
;     },
;     "Severity": "string",
;     "SourceDetails": {
;       "CloudWatchMetrics": [
;         {
;           "Dimensions": [
;             {
;               "Name": "string",
;               "Value": "string"
;             }
;           ],
;           "MetricDataSummary": {
;             "StatusCode": "string",
;             "TimestampMetricValuePairList": [
;               {
;                 "MetricValue": number,
;                 "Timestamp": number
;               }
;             ]
;           },
;           "MetricName": "string",
;           "Namespace": "string",
;           "Period": number,
;           "Stat": "string",
;           "Unit": "string"
;         }
;       ],
;       "PerformanceInsightsMetrics": [
;         {
;           "MetricDisplayName": "string",
;           "MetricQuery": {
;             "Filter": {
;               "string": "string"
;             },
;             "GroupBy": {
;               "Dimensions": [
;                 "string"
;               ],
;               "Group": "string",
;               "Limit": number
;             },
;             "Metric": "string"
;           },
;           "ReferenceData": [
;             {
;               "ComparisonValues": {
;                 "ReferenceMetric": {
;                   "MetricQuery": {
;                     "Filter": {
;                       "string": "string"
;                     },
;                     "GroupBy": {
;                       "Dimensions": [
;                         "string"
;                       ],
;                       "Group": "string",
;                       "Limit": number
;                     },
;                     "Metric": "string"
;                   }
;                 },
;                 "ReferenceScalar": {
;                   "Value": number
;                 }
;               },
;               "Name": "string"
;             }
;           ],
;           "StatsAtAnomaly": [
;             {
;               "Type": "string",
;               "Value": number
;             }
;           ],
;           "StatsAtBaseline": [
;             {
;               "Type": "string",
;               "Value": number
;             }
;           ],
;           "Unit": "string"
;         }
;       ]
;     },
;     "Status": "string",
;     "Type": "string"
;   }
; }