updateTemplate method

Future<UpdateTemplateResponse> updateTemplate({
  1. required String id,
  2. String? clientToken,
  3. String? templateDescription,
  4. String? templateName,
})

Updates a migration workflow template.

May throw AccessDeniedException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter id : The ID of the request to update a migration workflow template.

Parameter clientToken : A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Parameter templateDescription : The description of the migration workflow template to update.

Parameter templateName : The name of the migration workflow template to update.

Implementation

Future<UpdateTemplateResponse> updateTemplate({
  required String id,
  String? clientToken,
  String? templateDescription,
  String? templateName,
}) async {
  final $payload = <String, dynamic>{
    'clientToken': clientToken ?? _s.generateIdempotencyToken(),
    if (templateDescription != null)
      'templateDescription': templateDescription,
    if (templateName != null) 'templateName': templateName,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/template/${Uri.encodeComponent(id)}',
    exceptionFnMap: _exceptionFns,
  );
  return UpdateTemplateResponse.fromJson(response);
}