/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace WAFV2 { namespace Model { /** */ class GetSampledRequestsRequest : public WAFV2Request { public: AWS_WAFV2_API GetSampledRequestsRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "GetSampledRequests"; } AWS_WAFV2_API Aws::String SerializePayload() const override; AWS_WAFV2_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline const Aws::String& GetWebAclArn() const{ return m_webAclArn; } /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline bool WebAclArnHasBeenSet() const { return m_webAclArnHasBeenSet; } /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline void SetWebAclArn(const Aws::String& value) { m_webAclArnHasBeenSet = true; m_webAclArn = value; } /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline void SetWebAclArn(Aws::String&& value) { m_webAclArnHasBeenSet = true; m_webAclArn = std::move(value); } /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline void SetWebAclArn(const char* value) { m_webAclArnHasBeenSet = true; m_webAclArn.assign(value); } /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline GetSampledRequestsRequest& WithWebAclArn(const Aws::String& value) { SetWebAclArn(value); return *this;} /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline GetSampledRequestsRequest& WithWebAclArn(Aws::String&& value) { SetWebAclArn(std::move(value)); return *this;} /** *

The Amazon resource name (ARN) of the WebACL for which you want * a sample of requests.

*/ inline GetSampledRequestsRequest& WithWebAclArn(const char* value) { SetWebAclArn(value); return *this;} /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline const Aws::String& GetRuleMetricName() const{ return m_ruleMetricName; } /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline bool RuleMetricNameHasBeenSet() const { return m_ruleMetricNameHasBeenSet; } /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline void SetRuleMetricName(const Aws::String& value) { m_ruleMetricNameHasBeenSet = true; m_ruleMetricName = value; } /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline void SetRuleMetricName(Aws::String&& value) { m_ruleMetricNameHasBeenSet = true; m_ruleMetricName = std::move(value); } /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline void SetRuleMetricName(const char* value) { m_ruleMetricNameHasBeenSet = true; m_ruleMetricName.assign(value); } /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline GetSampledRequestsRequest& WithRuleMetricName(const Aws::String& value) { SetRuleMetricName(value); return *this;} /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline GetSampledRequestsRequest& WithRuleMetricName(Aws::String&& value) { SetRuleMetricName(std::move(value)); return *this;} /** *

The metric name assigned to the Rule or RuleGroup * dimension for which you want a sample of requests.

*/ inline GetSampledRequestsRequest& WithRuleMetricName(const char* value) { SetRuleMetricName(value); return *this;} /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline const Scope& GetScope() const{ return m_scope; } /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline bool ScopeHasBeenSet() const { return m_scopeHasBeenSet; } /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline void SetScope(const Scope& value) { m_scopeHasBeenSet = true; m_scope = value; } /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline void SetScope(Scope&& value) { m_scopeHasBeenSet = true; m_scope = std::move(value); } /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline GetSampledRequestsRequest& WithScope(const Scope& value) { SetScope(value); return *this;} /** *

Specifies whether this is for an Amazon CloudFront distribution or for a * regional application. A regional application can be an Application Load Balancer * (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API, an Amazon Cognito * user pool, an App Runner service, or an Amazon Web Services Verified Access * instance.

To work with CloudFront, you must also specify the Region US * East (N. Virginia) as follows:

  • CLI - Specify the Region when * you use the CloudFront scope: --scope=CLOUDFRONT * --region=us-east-1.

  • API and SDKs - For all calls, use * the Region endpoint us-east-1.

*/ inline GetSampledRequestsRequest& WithScope(Scope&& value) { SetScope(std::move(value)); return *this;} /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline const TimeWindow& GetTimeWindow() const{ return m_timeWindow; } /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline bool TimeWindowHasBeenSet() const { return m_timeWindowHasBeenSet; } /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline void SetTimeWindow(const TimeWindow& value) { m_timeWindowHasBeenSet = true; m_timeWindow = value; } /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline void SetTimeWindow(TimeWindow&& value) { m_timeWindowHasBeenSet = true; m_timeWindow = std::move(value); } /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline GetSampledRequestsRequest& WithTimeWindow(const TimeWindow& value) { SetTimeWindow(value); return *this;} /** *

The start date and time and the end date and time of the range for which you * want GetSampledRequests to return a sample of requests. You must * specify the times in Coordinated Universal Time (UTC) format. UTC format * includes the special designator, Z. For example, * "2016-09-27T14:50Z". You can specify any time range in the previous * three hours. If you specify a start time that's earlier than three hours ago, * WAF sets it to three hours ago.

*/ inline GetSampledRequestsRequest& WithTimeWindow(TimeWindow&& value) { SetTimeWindow(std::move(value)); return *this;} /** *

The number of requests that you want WAF to return from among the first 5,000 * requests that your Amazon Web Services resource received during the time range. * If your resource received fewer requests than the value of * MaxItems, GetSampledRequests returns information about * all of them.

*/ inline long long GetMaxItems() const{ return m_maxItems; } /** *

The number of requests that you want WAF to return from among the first 5,000 * requests that your Amazon Web Services resource received during the time range. * If your resource received fewer requests than the value of * MaxItems, GetSampledRequests returns information about * all of them.

*/ inline bool MaxItemsHasBeenSet() const { return m_maxItemsHasBeenSet; } /** *

The number of requests that you want WAF to return from among the first 5,000 * requests that your Amazon Web Services resource received during the time range. * If your resource received fewer requests than the value of * MaxItems, GetSampledRequests returns information about * all of them.

*/ inline void SetMaxItems(long long value) { m_maxItemsHasBeenSet = true; m_maxItems = value; } /** *

The number of requests that you want WAF to return from among the first 5,000 * requests that your Amazon Web Services resource received during the time range. * If your resource received fewer requests than the value of * MaxItems, GetSampledRequests returns information about * all of them.

*/ inline GetSampledRequestsRequest& WithMaxItems(long long value) { SetMaxItems(value); return *this;} private: Aws::String m_webAclArn; bool m_webAclArnHasBeenSet = false; Aws::String m_ruleMetricName; bool m_ruleMetricNameHasBeenSet = false; Scope m_scope; bool m_scopeHasBeenSet = false; TimeWindow m_timeWindow; bool m_timeWindowHasBeenSet = false; long long m_maxItems; bool m_maxItemsHasBeenSet = false; }; } // namespace Model } // namespace WAFV2 } // namespace Aws