Skip to main content

analyses

Creates, updates, deletes, gets or lists an analyses resource.

Overview

Nameanalyses
TypeResource
Idgoogle.contactcenterinsights.analyses

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringImmutable. The resource name of the analysis. Format: projects/{project}/locations/{location}/conversations/{conversation}/analyses/{analysis}
analysisResultobjectOutput only. The result of the analysis, which is populated when the analysis finishes. (id: GoogleCloudContactcenterinsightsV1AnalysisResult)
annotatorSelectorobjectTo select the annotators to run and the phrase matchers to use (if any). If not specified, all annotators will be run. (id: GoogleCloudContactcenterinsightsV1AnnotatorSelector)
createTimestring (google-datetime)Output only. The time at which the analysis was created, which occurs when the long-running operation completes.
requestTimestring (google-datetime)Output only. The time at which the analysis was requested.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, authorizedViewSetsId, authorizedViewsId, conversationsId, analysesIdGets an analysis.
listselectprojectsId, locationsId, authorizedViewSetsId, authorizedViewsId, conversationsIdpageSize, pageToken, filterLists analyses.
createinsertprojectsId, locationsId, authorizedViewSetsId, authorizedViewsId, conversationsIdCreates an analysis. The long running operation is done when the analysis has completed.
deletedeleteprojectsId, locationsId, authorizedViewSetsId, authorizedViewsId, conversationsId, analysesIdDeletes an analysis.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
analysesIdstring
authorizedViewSetsIdstring
authorizedViewsIdstring
conversationsIdstring
locationsIdstring
projectsIdstring
filterstring
pageSizeinteger (int32)
pageTokenstring

SELECT examples

Gets an analysis.

SELECT
name,
analysisResult,
annotatorSelector,
createTime,
requestTime
FROM google.contactcenterinsights.analyses
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND authorizedViewSetsId = '{{ authorizedViewSetsId }}' -- required
AND authorizedViewsId = '{{ authorizedViewsId }}' -- required
AND conversationsId = '{{ conversationsId }}' -- required
AND analysesId = '{{ analysesId }}' -- required;

INSERT examples

Creates an analysis. The long running operation is done when the analysis has completed.

INSERT INTO google.contactcenterinsights.analyses (
data__name,
data__annotatorSelector,
projectsId,
locationsId,
authorizedViewSetsId,
authorizedViewsId,
conversationsId
)
SELECT
'{{ name }}',
'{{ annotatorSelector }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ authorizedViewSetsId }}',
'{{ authorizedViewsId }}',
'{{ conversationsId }}'
RETURNING
name,
done,
error,
metadata,
response
;

DELETE examples

Deletes an analysis.

DELETE FROM google.contactcenterinsights.analyses
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND authorizedViewSetsId = '{{ authorizedViewSetsId }}' --required
AND authorizedViewsId = '{{ authorizedViewsId }}' --required
AND conversationsId = '{{ conversationsId }}' --required
AND analysesId = '{{ analysesId }}' --required;