Skip to main content

phrase_matchers

Creates, updates, deletes, gets or lists a phrase_matchers resource.

Overview

Namephrase_matchers
TypeResource
Idgoogle.contactcenterinsights.phrase_matchers

Fields

NameDatatypeDescription
namestringThe resource name of the phrase matcher. Format: projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher}
activationUpdateTimestringOutput only. The most recent time at which the activation status was updated.
activebooleanApplies the phrase matcher only when it is active.
displayNamestringThe human-readable name of the phrase matcher.
phraseMatchRuleGroupsarrayA list of phase match rule groups that are included in this matcher.
revisionCreateTimestringOutput only. The timestamp of when the revision was created. It is also the create time when a new matcher is added.
revisionIdstringOutput only. Immutable. The revision ID of the phrase matcher. A new revision is committed whenever the matcher is changed, except when it is activated or deactivated. A server generated random ID will be used. Example: locations/global/phraseMatchers/my-first-matcher@1234567
roleMatchstringThe role whose utterances the phrase matcher should be matched against. If the role is ROLE_UNSPECIFIED it will be matched against any utterances in the transcript.
typestringRequired. The type of this phrase matcher.
updateTimestringOutput only. The most recent time at which the phrase matcher was updated.
versionTagstringThe customized version tag to use for the phrase matcher. If not specified, it will default to revision_id.

Methods

NameAccessible byRequired ParamsDescription
getSELECTlocationsId, phraseMatchersId, projectsIdGets a phrase matcher.
listSELECTlocationsId, projectsIdLists phrase matchers.
createINSERTlocationsId, projectsIdCreates a phrase matcher.
deleteDELETElocationsId, phraseMatchersId, projectsIdDeletes a phrase matcher.
patchUPDATElocationsId, phraseMatchersId, projectsIdUpdates a phrase matcher.

SELECT examples

Lists phrase matchers.

SELECT
name,
activationUpdateTime,
active,
displayName,
phraseMatchRuleGroups,
revisionCreateTime,
revisionId,
roleMatch,
type,
updateTime,
versionTag
FROM google.contactcenterinsights.phrase_matchers
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new phrase_matchers resource.

/*+ create */
INSERT INTO google.contactcenterinsights.phrase_matchers (
locationsId,
projectsId,
phraseMatchRuleGroups,
name,
active,
displayName,
type,
versionTag,
roleMatch
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ phraseMatchRuleGroups }}',
'{{ name }}',
{{ active }},
'{{ displayName }}',
'{{ type }}',
'{{ versionTag }}',
'{{ roleMatch }}'
;

UPDATE example

Updates a phrase_matchers resource.

/*+ update */
UPDATE google.contactcenterinsights.phrase_matchers
SET
phraseMatchRuleGroups = '{{ phraseMatchRuleGroups }}',
name = '{{ name }}',
active = true|false,
displayName = '{{ displayName }}',
type = '{{ type }}',
versionTag = '{{ versionTag }}',
roleMatch = '{{ roleMatch }}'
WHERE
locationsId = '{{ locationsId }}'
AND phraseMatchersId = '{{ phraseMatchersId }}'
AND projectsId = '{{ projectsId }}';

DELETE example

Deletes the specified phrase_matchers resource.

/*+ delete */
DELETE FROM google.contactcenterinsights.phrase_matchers
WHERE locationsId = '{{ locationsId }}'
AND phraseMatchersId = '{{ phraseMatchersId }}'
AND projectsId = '{{ projectsId }}';