describeConfigurationTemplates method

Future<DescribeConfigurationTemplatesResponse> describeConfigurationTemplates({
  1. List<DeliveryDestinationType>? deliveryDestinationTypes,
  2. int? limit,
  3. List<String>? logTypes,
  4. String? nextToken,
  5. List<String>? resourceTypes,
  6. String? service,
})

Use this operation to return the valid and default values that are used when creating delivery sources, delivery destinations, and deliveries. For more information about deliveries, see CreateDelivery.

May throw ResourceNotFoundException. May throw ServiceUnavailableException. May throw ThrottlingException. May throw ValidationException.

Parameter deliveryDestinationTypes : Use this parameter to filter the response to include only the configuration templates that apply to the delivery destination types that you specify here.

Parameter limit : Use this parameter to limit the number of configuration templates that are returned in the response.

Parameter logTypes : Use this parameter to filter the response to include only the configuration templates that apply to the log types that you specify here.

Parameter resourceTypes : Use this parameter to filter the response to include only the configuration templates that apply to the resource types that you specify here.

Parameter service : Use this parameter to filter the response to include only the configuration templates that apply to the Amazon Web Services service that you specify here.

Implementation

Future<DescribeConfigurationTemplatesResponse>
    describeConfigurationTemplates({
  List<DeliveryDestinationType>? deliveryDestinationTypes,
  int? limit,
  List<String>? logTypes,
  String? nextToken,
  List<String>? resourceTypes,
  String? service,
}) async {
  _s.validateNumRange(
    'limit',
    limit,
    1,
    50,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'Logs_20140328.DescribeConfigurationTemplates'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      if (deliveryDestinationTypes != null)
        'deliveryDestinationTypes':
            deliveryDestinationTypes.map((e) => e.value).toList(),
      if (limit != null) 'limit': limit,
      if (logTypes != null) 'logTypes': logTypes,
      if (nextToken != null) 'nextToken': nextToken,
      if (resourceTypes != null) 'resourceTypes': resourceTypes,
      if (service != null) 'service': service,
    },
  );

  return DescribeConfigurationTemplatesResponse.fromJson(jsonResponse.body);
}