createCaseComment method
Adds a comment to an existing case.
Parameter body :
Required element used in combination with CreateCaseComment to add content
for the new comment.
Parameter caseId :
Required element used in combination with CreateCaseComment to specify a
case ID.
Parameter clientToken :
Implementation
Future<CreateCaseCommentResponse> createCaseComment({
required String body,
required String caseId,
String? clientToken,
}) async {
final $payload = <String, dynamic>{
'body': body,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/v1/cases/${Uri.encodeComponent(caseId)}/create-comment',
exceptionFnMap: _exceptionFns,
);
return CreateCaseCommentResponse.fromJson(response);
}