createProxyConfiguration method
Creates an Network Firewall ProxyConfiguration
A Proxy Configuration defines the monitoring and protection behavior for a Proxy. The details of the behavior are defined in the rule groups that you add to your configuration.
To manage a proxy configuration's tags, use the standard Amazon Web Services resource tagging operations, ListTagsForResource, TagResource, and UntagResource.
To retrieve information about proxies, use ListProxyConfigurations and DescribeProxyConfiguration.
May throw InternalServerError.
May throw InvalidRequestException.
May throw LimitExceededException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
Parameter defaultRulePhaseActions :
Evaluation points in the traffic flow where rules are applied. There are
three phases in a traffic where the rule match is applied.
Parameter proxyConfigurationName :
The descriptive name of the proxy configuration. You can't change the name
of a proxy configuration after you create it.
Parameter description :
A description of the proxy configuration.
Parameter ruleGroupArns :
The proxy rule group arn(s) to attach to the proxy configuration.
You must specify the ARNs or the names, and you can specify both.
Parameter ruleGroupNames :
The proxy rule group name(s) to attach to the proxy configuration.
You must specify the ARNs or the names, and you can specify both.
Parameter tags :
The key:value pairs to associate with the resource.
Implementation
Future<CreateProxyConfigurationResponse> createProxyConfiguration({
required ProxyConfigDefaultRulePhaseActionsRequest defaultRulePhaseActions,
required String proxyConfigurationName,
String? description,
List<String>? ruleGroupArns,
List<String>? ruleGroupNames,
List<Tag>? tags,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'NetworkFirewall_20201112.CreateProxyConfiguration'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'DefaultRulePhaseActions': defaultRulePhaseActions,
'ProxyConfigurationName': proxyConfigurationName,
if (description != null) 'Description': description,
if (ruleGroupArns != null) 'RuleGroupArns': ruleGroupArns,
if (ruleGroupNames != null) 'RuleGroupNames': ruleGroupNames,
if (tags != null) 'Tags': tags,
},
);
return CreateProxyConfigurationResponse.fromJson(jsonResponse.body);
}