updateQuickResponse method
- required String knowledgeBaseId,
- required String quickResponseId,
- List<
String> ? channels, - QuickResponseDataProvider? content,
- String? contentType,
- String? description,
- GroupingConfiguration? groupingConfiguration,
- bool? isActive,
- String? language,
- String? name,
- bool? removeDescription,
- bool? removeGroupingConfiguration,
- bool? removeShortcutKey,
- String? shortcutKey,
Updates an existing Wisdom quick response.
May throw AccessDeniedException.
May throw ConflictException.
May throw PreconditionFailedException.
May throw ResourceNotFoundException.
May throw ValidationException.
Parameter knowledgeBaseId :
The identifier of the knowledge base. This should not be a QUICK_RESPONSES
type knowledge base if you're storing Wisdom Content resource to it. Can
be either the ID or the ARN. URLs cannot contain the ARN.
Parameter quickResponseId :
The identifier of the quick response.
Parameter channels :
The Amazon Connect contact channels this quick response applies to. The
supported contact channel types include Chat.
Parameter content :
The updated content of the quick response.
Parameter contentType :
The media type of the quick response content.
-
Use
application/x.quickresponse;format=plainfor quick response written in plain text. -
Use
application/x.quickresponse;format=markdownfor quick response written in richtext.
Parameter description :
The updated description of the quick response.
Parameter groupingConfiguration :
The updated grouping configuration of the quick response.
Parameter isActive :
Whether the quick response is active.
Parameter language :
The language code value for the language in which the quick response is
written. The supported language codes include de_DE,
en_US, es_ES, fr_FR,
id_ID, it_IT, ja_JP,
ko_KR, pt_BR, zh_CN,
zh_TW
Parameter name :
The name of the quick response.
Parameter removeDescription :
Whether to remove the description from the quick response.
Parameter removeGroupingConfiguration :
Whether to remove the grouping configuration of the quick response.
Parameter removeShortcutKey :
Whether to remove the shortcut key of the quick response.
Parameter shortcutKey :
The shortcut key of the quick response. The value should be unique across
the knowledge base.
Implementation
Future<UpdateQuickResponseResponse> updateQuickResponse({
required String knowledgeBaseId,
required String quickResponseId,
List<String>? channels,
QuickResponseDataProvider? content,
String? contentType,
String? description,
GroupingConfiguration? groupingConfiguration,
bool? isActive,
String? language,
String? name,
bool? removeDescription,
bool? removeGroupingConfiguration,
bool? removeShortcutKey,
String? shortcutKey,
}) async {
final $payload = <String, dynamic>{
if (channels != null) 'channels': channels,
if (content != null) 'content': content,
if (contentType != null) 'contentType': contentType,
if (description != null) 'description': description,
if (groupingConfiguration != null)
'groupingConfiguration': groupingConfiguration,
if (isActive != null) 'isActive': isActive,
if (language != null) 'language': language,
if (name != null) 'name': name,
if (removeDescription != null) 'removeDescription': removeDescription,
if (removeGroupingConfiguration != null)
'removeGroupingConfiguration': removeGroupingConfiguration,
if (removeShortcutKey != null) 'removeShortcutKey': removeShortcutKey,
if (shortcutKey != null) 'shortcutKey': shortcutKey,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/knowledgeBases/${Uri.encodeComponent(knowledgeBaseId)}/quickResponses/${Uri.encodeComponent(quickResponseId)}',
exceptionFnMap: _exceptionFns,
);
return UpdateQuickResponseResponse.fromJson(response);
}