updateProxyConfiguration method
Updates the properties of the specified proxy configuration.
May throw InternalServerError.
May throw InvalidRequestException.
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 updateToken :
A token used for optimistic locking. Network Firewall returns a token to
your requests that access the proxy configuration. The token marks the
state of the proxy configuration resource at the time of the request.
To make changes to the proxy configuration, you provide the token in your
request. Network Firewall uses the token to ensure that the proxy
configuration hasn't changed since you last retrieved it. If it has
changed, the operation fails with an InvalidTokenException.
If this happens, retrieve the proxy configuration again to get a current
copy of it with a current token. Reapply your changes as needed, then try
the operation again using the new token.
Parameter proxyConfigurationArn :
The Amazon Resource Name (ARN) of a proxy configuration.
You must specify the ARN or the name, and you can specify both.
Parameter proxyConfigurationName :
The descriptive name of the proxy configuration. You can't change the name
of a proxy configuration after you create it.
You must specify the ARN or the name, and you can specify both.
Implementation
Future<UpdateProxyConfigurationResponse> updateProxyConfiguration({
required ProxyConfigDefaultRulePhaseActionsRequest defaultRulePhaseActions,
required String updateToken,
String? proxyConfigurationArn,
String? proxyConfigurationName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'NetworkFirewall_20201112.UpdateProxyConfiguration'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'DefaultRulePhaseActions': defaultRulePhaseActions,
'UpdateToken': updateToken,
if (proxyConfigurationArn != null)
'ProxyConfigurationArn': proxyConfigurationArn,
if (proxyConfigurationName != null)
'ProxyConfigurationName': proxyConfigurationName,
},
);
return UpdateProxyConfigurationResponse.fromJson(jsonResponse.body);
}