getCustomRulePolicy method
Returns the policy definition containing the logic for your Config Custom Policy rule.
May throw NoSuchConfigRuleException.
Parameter configRuleName :
The name of your Config Custom Policy rule.
Implementation
Future<GetCustomRulePolicyResponse> getCustomRulePolicy({
String? configRuleName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'StarlingDoveService.GetCustomRulePolicy'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (configRuleName != null) 'ConfigRuleName': configRuleName,
},
);
return GetCustomRulePolicyResponse.fromJson(jsonResponse.body);
}