"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ApiRequestsWidget = void 0;
const aws_cdk_lib_1 = require("aws-cdk-lib");
const requests_1 = require("../../metrics/api-gateway/requests");
class ApiRequestsWidget extends aws_cdk_lib_1.aws_cloudwatch.GraphWidget {
    constructor(props) {
        var _a;
        super({
            title: 'Requests',
            width: 6,
            height: 4,
            left: [new requests_1.ApiGatewayRequestsMetric({ apiName: props.apiName, stage: props.stage })],
            legendPosition: aws_cdk_lib_1.aws_cloudwatch.LegendPosition.HIDDEN,
            leftAnnotations: (_a = props.horizontalAnnotations) !== null && _a !== void 0 ? _a : [],
        });
    }
}
exports.ApiRequestsWidget = ApiRequestsWidget;
