QConnect / Client / search_quick_responses
search_quick_responses#
- QConnect.Client.search_quick_responses(**kwargs)#
Searches existing Amazon Q in Connect quick responses in an Amazon Q in Connect knowledge base.
See also: AWS API Documentation
Request Syntax
response = client.search_quick_responses( attributes={ 'string': 'string' }, knowledgeBaseId='string', maxResults=123, nextToken='string', searchExpression={ 'filters': [ { 'includeNoExistence': True|False, 'name': 'string', 'operator': 'EQUALS'|'PREFIX', 'values': [ 'string', ] }, ], 'orderOnField': { 'name': 'string', 'order': 'ASC'|'DESC' }, 'queries': [ { 'allowFuzziness': True|False, 'name': 'string', 'operator': 'CONTAINS'|'CONTAINS_AND_PREFIX', 'priority': 'HIGH'|'MEDIUM'|'LOW', 'values': [ 'string', ] }, ] } )
- Parameters:
attributes (dict) –
The user-defined Amazon Connect contact attributes to be resolved when search results are returned.
(string) –
(string) –
knowledgeBaseId (string) –
[REQUIRED]
The identifier of the knowledge base. This should be a QUICK_RESPONSES type knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.
maxResults (integer) – The maximum number of results to return per page.
nextToken (string) – The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
searchExpression (dict) –
[REQUIRED]
The search expression for querying the quick response.
filters (list) –
The configuration of filtering rules applied to quick response query results.
(dict) –
The quick response fields to filter the quick response query results by.
The following is the list of supported field names.
name
description
shortcutKey
isActive
channels
language
contentType
createdTime
lastModifiedTime
lastModifiedBy
groupingConfiguration.criteria
groupingConfiguration.values
includeNoExistence (boolean) –
Whether to treat null value as a match for the attribute field.
name (string) – [REQUIRED]
The name of the attribute field to filter the quick responses by.
operator (string) – [REQUIRED]
The operator to use for filtering.
values (list) –
The values of attribute field to filter the quick response by.
(string) –
orderOnField (dict) –
The quick response attribute fields on which the query results are ordered.
name (string) – [REQUIRED]
The name of the attribute to order the quick response query results by.
order (string) –
The order at which the quick responses are sorted by.
queries (list) –
The quick response query expressions.
(dict) –
The quick response fields to query quick responses by.
The following is the list of supported field names.
content
name
description
shortcutKey
allowFuzziness (boolean) –
Whether the query expects only exact matches on the attribute field values. The results of the query will only include exact matches if this parameter is set to false.
name (string) – [REQUIRED]
The name of the attribute to query the quick responses by.
operator (string) – [REQUIRED]
The operator to use for matching attribute field values in the query.
priority (string) –
The importance of the attribute field when calculating query result relevancy scores. The value set for this parameter affects the ordering of search results.
values (list) – [REQUIRED]
The values of the attribute to query the quick responses by.
(string) –
- Return type:
dict
- Returns:
Response Syntax
{ 'nextToken': 'string', 'results': [ { 'attributesInterpolated': [ 'string', ], 'attributesNotInterpolated': [ 'string', ], 'channels': [ 'string', ], 'contentType': 'string', 'contents': { 'markdown': { 'content': 'string' }, 'plainText': { 'content': 'string' } }, 'createdTime': datetime(2015, 1, 1), 'description': 'string', 'groupingConfiguration': { 'criteria': 'string', 'values': [ 'string', ] }, 'isActive': True|False, 'knowledgeBaseArn': 'string', 'knowledgeBaseId': 'string', 'language': 'string', 'lastModifiedBy': 'string', 'lastModifiedTime': datetime(2015, 1, 1), 'name': 'string', 'quickResponseArn': 'string', 'quickResponseId': 'string', 'shortcutKey': 'string', 'status': 'CREATE_IN_PROGRESS'|'CREATE_FAILED'|'CREATED'|'DELETE_IN_PROGRESS'|'DELETE_FAILED'|'DELETED'|'UPDATE_IN_PROGRESS'|'UPDATE_FAILED', 'tags': { 'string': 'string' } }, ] }
Response Structure
(dict) –
nextToken (string) –
The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
results (list) –
The results of the quick response search.
(dict) –
The result of quick response search.
attributesInterpolated (list) –
The user defined contact attributes that are resolved when the search result is returned.
(string) –
attributesNotInterpolated (list) –
The user defined contact attributes that are not resolved when the search result is returned.
(string) –
channels (list) –
The Amazon Connect contact channels this quick response applies to. The supported contact channel types include
Chat
.(string) –
contentType (string) –
The media type of the quick response content.
Use
application/x.quickresponse;format=plain
for quick response written in plain text.Use
application/x.quickresponse;format=markdown
for quick response written in richtext.
contents (dict) –
The contents of the quick response.
markdown (dict) –
The container quick response content.
Note
This is a Tagged Union structure. Only one of the following top level keys will be set:
content
. If a client receives an unknown member it will setSDK_UNKNOWN_MEMBER
as the top level key, which maps to the name or tag of the unknown member. The structure ofSDK_UNKNOWN_MEMBER
is as follows:'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
content (string) –
The content of the quick response.
plainText (dict) –
The container quick response content.
Note
This is a Tagged Union structure. Only one of the following top level keys will be set:
content
. If a client receives an unknown member it will setSDK_UNKNOWN_MEMBER
as the top level key, which maps to the name or tag of the unknown member. The structure ofSDK_UNKNOWN_MEMBER
is as follows:'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
content (string) –
The content of the quick response.
createdTime (datetime) –
The timestamp when the quick response was created.
description (string) –
The description of the quick response.
groupingConfiguration (dict) –
The configuration information of the user groups that the quick response is accessible to.
criteria (string) –
The criteria used for grouping Amazon Q in Connect users.
The following is the list of supported criteria values.
RoutingProfileArn
: Grouping the users by their Amazon Connect routing profile ARN. User should have SearchRoutingProfile and DescribeRoutingProfile permissions when setting criteria to this value.
values (list) –
The list of values that define different groups of Amazon Q in Connect users.
When setting
criteria
toRoutingProfileArn
, you need to provide a list of ARNs of Amazon Connect routing profiles as values of this parameter.
(string) –
isActive (boolean) –
Whether the quick response is active.
knowledgeBaseArn (string) –
The Amazon Resource Name (ARN) of the knowledge base.
knowledgeBaseId (string) –
The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.
language (string) –
The language code value for the language in which the quick response is written.
lastModifiedBy (string) –
The Amazon Resource Name (ARN) of the user who last updated the quick response search result data.
lastModifiedTime (datetime) –
The timestamp when the quick response search result data was last modified.
name (string) –
The name of the quick response.
quickResponseArn (string) –
The Amazon Resource Name (ARN) of the quick response.
quickResponseId (string) –
The identifier of the quick response.
shortcutKey (string) –
The shortcut key of the quick response. The value should be unique across the knowledge base.
status (string) –
The resource status of the quick response.
tags (dict) –
The tags used to organize, track, or control access for this resource.
(string) –
(string) –
Exceptions
QConnect.Client.exceptions.RequestTimeoutException
QConnect.Client.exceptions.ValidationException
QConnect.Client.exceptions.AccessDeniedException
QConnect.Client.exceptions.ResourceNotFoundException