// Copyright 2022 Luca Casonato. All rights reserved. MIT license. /** * Contact Center AI Insights API Client for Deno * ============================================== * * * * Docs: https://cloud.google.com/contact-center/insights/docs * Source: https://googleapis.deno.dev/v1/contactcenterinsights:v1.ts */ import { auth, CredentialsClient, GoogleAuth, request } from "/_/base@v1/mod.ts"; export { auth, GoogleAuth }; export type { CredentialsClient }; export class ContactCenterInsights { #client: CredentialsClient | undefined; #baseUrl: string; constructor(client?: CredentialsClient, baseUrl: string = "https://contactcenterinsights.googleapis.com/") { this.#client = client; this.#baseUrl = baseUrl; } /** * Creates a analysis rule. * * @param parent Required. The parent resource of the analysis rule. Required. The location to create a analysis rule for. Format: `projects//locations/` or `projects//locations/` */ async projectsLocationsAnalysisRulesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1AnalysisRule): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/analysisRules`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1AnalysisRule; } /** * Deletes a analysis rule. * * @param name Required. The name of the analysis rule to delete. */ async projectsLocationsAnalysisRulesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get a analysis rule. * * @param name Required. The name of the AnalysisRule to get. */ async projectsLocationsAnalysisRulesGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1AnalysisRule; } /** * Lists analysis rules. * * @param parent Required. The parent resource of the analysis rules. */ async projectsLocationsAnalysisRulesList(parent: string, opts: ProjectsLocationsAnalysisRulesListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/analysisRules`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAnalysisRulesResponse; } /** * Updates a analysis rule. * * @param name Identifier. The resource name of the analysis rule. Format: projects/{project}/locations/{location}/analysisRules/{analysis_rule} */ async projectsLocationsAnalysisRulesPatch(name: string, req: GoogleCloudContactcenterinsightsV1AnalysisRule, opts: ProjectsLocationsAnalysisRulesPatchOptions = {}): Promise { opts = serializeProjectsLocationsAnalysisRulesPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1AnalysisRule; } /** * Creates an assessment rule. * * @param parent Required. The parent resource of the assessment rule. Required. The location to create a assessment rule for. Format: `projects//locations/` or `projects//locations/` */ async projectsLocationsAssessmentRulesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1AssessmentRule, opts: ProjectsLocationsAssessmentRulesCreateOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1AssessmentRule(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/assessmentRules`); if (opts.assessmentRuleId !== undefined) { url.searchParams.append("assessmentRuleId", String(opts.assessmentRuleId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleCloudContactcenterinsightsV1AssessmentRule(data); } /** * Deletes an assessment rule. * * @param name Required. The name of the assessment rule to delete. */ async projectsLocationsAssessmentRulesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get an assessment rule. * * @param name Required. The name of the assessment rule to get. */ async projectsLocationsAssessmentRulesGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1AssessmentRule(data); } /** * Lists assessment rules. * * @param parent Required. The parent resource of the assessment rules. */ async projectsLocationsAssessmentRulesList(parent: string, opts: ProjectsLocationsAssessmentRulesListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/assessmentRules`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse(data); } /** * Updates an assessment rule. * * @param name Identifier. The resource name of the assessment rule. Format: projects/{project}/locations/{location}/assessmentRules/{assessment_rule} */ async projectsLocationsAssessmentRulesPatch(name: string, req: GoogleCloudContactcenterinsightsV1AssessmentRule, opts: ProjectsLocationsAssessmentRulesPatchOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1AssessmentRule(req); opts = serializeProjectsLocationsAssessmentRulesPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return deserializeGoogleCloudContactcenterinsightsV1AssessmentRule(data); } /** * Appeal an Assessment. * * @param name Required. The name of the assessment to appeal. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsAppeal(name: string, req: GoogleCloudContactcenterinsightsV1AppealAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:appeal`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Create Assessment. * * @param parent Required. The parent resource of the assessment. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Assessment): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/assessments`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Delete an Assessment. * * @param name Required. The name of the assessment to delete. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsDelete(name: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Finalize an Assessment. * * @param name Required. The name of the assessment to finalize. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsFinalize(name: string, req: GoogleCloudContactcenterinsightsV1FinalizeAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:finalize`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Get Assessment. * * @param name Required. The name of the assessment to get. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * List Assessments. * * @param parent Required. The parent resource of the assessments. To list all assessments in a location, substitute the conversation ID with a '-' character. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/assessments`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAssessmentsResponse; } /** * Create Note. * * @param parent Required. The parent resource of the note. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Note): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/notes`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Note; } /** * Deletes a Note. * * @param name Required. The name of the note to delete. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * List Notes. * * @param parent Required. The parent resource of the notes. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/notes`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListNotesResponse; } /** * Update Note. * * @param name Identifier. The resource name of the note. Format: projects/{project}/locations/{location}/conversations/{conversation}/assessments/{assessment}/notes/{note} */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatch(name: string, req: GoogleCloudContactcenterinsightsV1Note, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions = {}): Promise { opts = serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1Note; } /** * Publish an Assessment. * * @param name Required. The name of the assessment to publish. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsPublish(name: string, req: GoogleCloudContactcenterinsightsV1PublishAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:publish`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Gets conversation statistics. * * @param location Required. The location of the conversations. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsCalculateStats(location: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsCalculateStatsOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ location }/conversations:calculateStats`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponse(data); } /** * Deletes a conversation. * * @param name Required. The name of the conversation to delete. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsDelete(name: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Create feedback label. * * @param parent Required. The parent resource of the feedback label. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.feedbackLabelId !== undefined) { url.searchParams.append("feedbackLabelId", String(opts.feedbackLabelId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Delete feedback label. * * @param name Required. The name of the feedback label to delete. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get feedback label. * * @param name Required. The name of the feedback label to get. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * List feedback labels. * * @param parent Required. The parent resource of the feedback labels. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListFeedbackLabelsResponse; } /** * Update feedback label. * * @param name Immutable. Resource name of the FeedbackLabel. Format: projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatch(name: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions = {}): Promise { opts = serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Gets a conversation. * * @param name Required. The name of the conversation to get. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsGet(name: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsGetOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1Conversation(data); } /** * Lists conversations. * * @param parent Required. The parent resource of the conversation. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListConversationsResponse(data); } /** * Create AuthorizedView * * @param parent Required. The parent resource of the AuthorizedView. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1AuthorizedView, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/authorizedViews`); if (opts.authorizedViewId !== undefined) { url.searchParams.append("authorizedViewId", String(opts.authorizedViewId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1AuthorizedView; } /** * Deletes an AuthorizedView. * * @param name Required. The name of the AuthorizedView to delete. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get AuthorizedView * * @param name Required. The name of the AuthorizedView to get. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1AuthorizedView; } /** * Gets the access control policy for a resource. Returns an empty policy if * the resource exists and does not have a policy set. * * @param resource REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsGetIamPolicy(resource: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsGetIamPolicyOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ resource }:getIamPolicy`); if (opts["options.requestedPolicyVersion"] !== undefined) { url.searchParams.append("options.requestedPolicyVersion", String(opts["options.requestedPolicyVersion"])); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleIamV1Policy(data); } /** * List AuthorizedViewSets * * @param parent Required. The parent resource of the AuthorizedViews. If the parent is set to `-`, all AuthorizedViews under the location will be returned. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/authorizedViews`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAuthorizedViewsResponse; } /** * Starts asynchronous cancellation on a long-running operation. The server * makes a best effort to cancel the operation, but success is not guaranteed. * If the server doesn't support this method, it returns * `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or * other methods to check whether the cancellation succeeded or whether the * operation completed despite cancellation. On successful cancellation, the * operation is not deleted; instead, it becomes an operation with an * Operation.error value with a google.rpc.Status.code of `1`, corresponding * to `Code.CANCELLED`. * * @param name The name of the operation resource to be cancelled. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsCancel(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:cancel`); const data = await request(url.href, { client: this.#client, method: "POST", }); return data as GoogleProtobufEmpty; } /** * Gets the latest state of a long-running operation. Clients can use this * method to poll the operation result at intervals as recommended by the API * service. * * @param name The name of the operation resource. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleLongrunningOperation; } /** * Lists operations that match the specified filter in the request. If the * server doesn't support this method, it returns `UNIMPLEMENTED`. * * @param name The name of the operation's parent resource. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsList(name: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }/operations`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.returnPartialSuccess !== undefined) { url.searchParams.append("returnPartialSuccess", String(opts.returnPartialSuccess)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleLongrunningListOperationsResponse; } /** * Updates an AuthorizedView. * * @param name Identifier. The resource name of the AuthorizedView. Format: projects/{project}/locations/{location}/authorizedViewSets/{authorized_view_set}/authorizedViews/{authorized_view} */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsPatch(name: string, req: GoogleCloudContactcenterinsightsV1AuthorizedView, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions = {}): Promise { opts = serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1AuthorizedView; } /** * Query metrics. * * @param location Required. The location of the data. "projects/{project}/locations/{location}" */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsQueryMetrics(location: string, req: GoogleCloudContactcenterinsightsV1QueryMetricsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1QueryMetricsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ location }:queryMetrics`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Generates a summary of predefined performance metrics for a set of * conversations. Conversations can be specified by specifying a time window * and an agent id, for now. The summary includes a comparison of metrics * computed for conversations in the previous time period, and also a * comparison with peers in the same time period. * * @param parent Required. The parent resource of the conversations to derive performance stats from. "projects/{project}/locations/{location}" */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsQueryPerformanceOverview(parent: string, req: GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }:queryPerformanceOverview`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * SearchAuthorizedViewSets * * @param parent Required. The parent resource of the AuthorizedViews. If the parent is set to `-`, all AuthorizedViews under the location will be returned. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsSearch(parent: string, opts: ProjectsLocationsAuthorizedViewSetsAuthorizedViewsSearchOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/authorizedViews:search`); if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.query !== undefined) { url.searchParams.append("query", String(opts.query)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1SearchAuthorizedViewsResponse; } /** * Sets the access control policy on the specified resource. Replaces any * existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and * `PERMISSION_DENIED` errors. * * @param resource REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsSetIamPolicy(resource: string, req: GoogleIamV1SetIamPolicyRequest): Promise { req = serializeGoogleIamV1SetIamPolicyRequest(req); const url = new URL(`${this.#baseUrl}v1/${ resource }:setIamPolicy`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleIamV1Policy(data); } /** * Returns permissions that a caller has on the specified resource. If the * resource does not exist, this will return an empty set of permissions, not * a `NOT_FOUND` error. Note: This operation is designed to be used for * building permission-aware UIs and command-line tools, not for authorization * checking. This operation may "fail open" without warning. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field. */ async projectsLocationsAuthorizedViewSetsAuthorizedViewsTestIamPermissions(resource: string, req: GoogleIamV1TestIamPermissionsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ resource }:testIamPermissions`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleIamV1TestIamPermissionsResponse; } /** * Create AuthorizedViewSet * * @param parent Required. The parent resource of the AuthorizedViewSet. */ async projectsLocationsAuthorizedViewSetsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1AuthorizedViewSet, opts: ProjectsLocationsAuthorizedViewSetsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/authorizedViewSets`); if (opts.authorizedViewSetId !== undefined) { url.searchParams.append("authorizedViewSetId", String(opts.authorizedViewSetId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1AuthorizedViewSet; } /** * Deletes an AuthorizedViewSet. * * @param name Required. The name of the AuthorizedViewSet to delete. */ async projectsLocationsAuthorizedViewSetsDelete(name: string, opts: ProjectsLocationsAuthorizedViewSetsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get AuthorizedViewSet * * @param name Required. The name of the AuthorizedViewSet to get. */ async projectsLocationsAuthorizedViewSetsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1AuthorizedViewSet; } /** * List AuthorizedViewSets * * @param parent Required. The parent resource of the AuthorizedViewSets. */ async projectsLocationsAuthorizedViewSetsList(parent: string, opts: ProjectsLocationsAuthorizedViewSetsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/authorizedViewSets`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAuthorizedViewSetsResponse; } /** * Updates an AuthorizedViewSet. * * @param name Identifier. The resource name of the AuthorizedViewSet. Format: projects/{project}/locations/{location}/authorizedViewSets/{authorized_view_set} */ async projectsLocationsAuthorizedViewSetsPatch(name: string, req: GoogleCloudContactcenterinsightsV1AuthorizedViewSet, opts: ProjectsLocationsAuthorizedViewSetsPatchOptions = {}): Promise { opts = serializeProjectsLocationsAuthorizedViewSetsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1AuthorizedViewSet; } /** * Delete feedback labels in bulk using a filter. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsBulkDeleteFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkDeleteFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Download feedback labels in bulk from an external source. Currently * supports exporting Quality AI example conversations with transcripts and * question bodies. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsBulkDownloadFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkDownloadFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Upload feedback labels from an external source in bulk. Currently supports * labeling Quality AI example conversations. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsBulkUploadFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkUploadFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Creates an analysis. The long running operation is done when the analysis * has completed. * * @param parent Required. The parent resource of the analysis. */ async projectsLocationsConversationsAnalysesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Analysis): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/analyses`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Deletes an analysis. * * @param name Required. The name of the analysis to delete. */ async projectsLocationsConversationsAnalysesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets an analysis. * * @param name Required. The name of the analysis to get. */ async projectsLocationsConversationsAnalysesGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1Analysis; } /** * Lists analyses. * * @param parent Required. The parent resource of the analyses. */ async projectsLocationsConversationsAnalysesList(parent: string, opts: ProjectsLocationsConversationsAnalysesListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/analyses`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAnalysesResponse; } /** * Appeal an Assessment. * * @param name Required. The name of the assessment to appeal. */ async projectsLocationsConversationsAssessmentsAppeal(name: string, req: GoogleCloudContactcenterinsightsV1AppealAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:appeal`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Create Assessment. * * @param parent Required. The parent resource of the assessment. */ async projectsLocationsConversationsAssessmentsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Assessment): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/assessments`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Delete an Assessment. * * @param name Required. The name of the assessment to delete. */ async projectsLocationsConversationsAssessmentsDelete(name: string, opts: ProjectsLocationsConversationsAssessmentsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Finalize an Assessment. * * @param name Required. The name of the assessment to finalize. */ async projectsLocationsConversationsAssessmentsFinalize(name: string, req: GoogleCloudContactcenterinsightsV1FinalizeAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:finalize`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Get Assessment. * * @param name Required. The name of the assessment to get. */ async projectsLocationsConversationsAssessmentsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * List Assessments. * * @param parent Required. The parent resource of the assessments. To list all assessments in a location, substitute the conversation ID with a '-' character. */ async projectsLocationsConversationsAssessmentsList(parent: string, opts: ProjectsLocationsConversationsAssessmentsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/assessments`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAssessmentsResponse; } /** * Create Note. * * @param parent Required. The parent resource of the note. */ async projectsLocationsConversationsAssessmentsNotesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Note): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/notes`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Note; } /** * Deletes a Note. * * @param name Required. The name of the note to delete. */ async projectsLocationsConversationsAssessmentsNotesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * List Notes. * * @param parent Required. The parent resource of the notes. */ async projectsLocationsConversationsAssessmentsNotesList(parent: string, opts: ProjectsLocationsConversationsAssessmentsNotesListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/notes`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListNotesResponse; } /** * Update Note. * * @param name Identifier. The resource name of the note. Format: projects/{project}/locations/{location}/conversations/{conversation}/assessments/{assessment}/notes/{note} */ async projectsLocationsConversationsAssessmentsNotesPatch(name: string, req: GoogleCloudContactcenterinsightsV1Note, opts: ProjectsLocationsConversationsAssessmentsNotesPatchOptions = {}): Promise { opts = serializeProjectsLocationsConversationsAssessmentsNotesPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1Note; } /** * Publish an Assessment. * * @param name Required. The name of the assessment to publish. */ async projectsLocationsConversationsAssessmentsPublish(name: string, req: GoogleCloudContactcenterinsightsV1PublishAssessmentRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:publish`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1Assessment; } /** * Analyzes multiple conversations in a single request. * * @param parent Required. The parent resource to create analyses in. */ async projectsLocationsConversationsBulkAnalyze(parent: string, req: GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:bulkAnalyze`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Deletes multiple conversations in a single request. * * @param parent Required. The parent resource to delete conversations from. Format: projects/{project}/locations/{location} */ async projectsLocationsConversationsBulkDelete(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDeleteConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:bulkDelete`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Gets conversation statistics. * * @param location Required. The location of the conversations. */ async projectsLocationsConversationsCalculateStats(location: string, opts: ProjectsLocationsConversationsCalculateStatsOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ location }/conversations:calculateStats`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponse(data); } /** * Creates a conversation. Note that this method does not support audio * transcription or redaction. Use `conversations.upload` instead. * * @param parent Required. The parent resource of the conversation. */ async projectsLocationsConversationsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Conversation, opts: ProjectsLocationsConversationsCreateOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1Conversation(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations`); if (opts.conversationId !== undefined) { url.searchParams.append("conversationId", String(opts.conversationId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleCloudContactcenterinsightsV1Conversation(data); } /** * Deletes a conversation. * * @param name Required. The name of the conversation to delete. */ async projectsLocationsConversationsDelete(name: string, opts: ProjectsLocationsConversationsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Create feedback label. * * @param parent Required. The parent resource of the feedback label. */ async projectsLocationsConversationsFeedbackLabelsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsConversationsFeedbackLabelsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.feedbackLabelId !== undefined) { url.searchParams.append("feedbackLabelId", String(opts.feedbackLabelId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Delete feedback label. * * @param name Required. The name of the feedback label to delete. */ async projectsLocationsConversationsFeedbackLabelsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get feedback label. * * @param name Required. The name of the feedback label to get. */ async projectsLocationsConversationsFeedbackLabelsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * List feedback labels. * * @param parent Required. The parent resource of the feedback labels. */ async projectsLocationsConversationsFeedbackLabelsList(parent: string, opts: ProjectsLocationsConversationsFeedbackLabelsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListFeedbackLabelsResponse; } /** * Update feedback label. * * @param name Immutable. Resource name of the FeedbackLabel. Format: projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ async projectsLocationsConversationsFeedbackLabelsPatch(name: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsConversationsFeedbackLabelsPatchOptions = {}): Promise { opts = serializeProjectsLocationsConversationsFeedbackLabelsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Gets a conversation. * * @param name Required. The name of the conversation to get. */ async projectsLocationsConversationsGet(name: string, opts: ProjectsLocationsConversationsGetOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1Conversation(data); } /** * Imports conversations and processes them according to the user's * configuration. * * @param parent Required. The parent resource for new conversations. */ async projectsLocationsConversationsIngest(parent: string, req: GoogleCloudContactcenterinsightsV1IngestConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:ingest`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Lists conversations. * * @param parent Required. The parent resource of the conversation. */ async projectsLocationsConversationsList(parent: string, opts: ProjectsLocationsConversationsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListConversationsResponse(data); } /** * Updates a conversation. * * @param name Immutable. The resource name of the conversation. Format: projects/{project}/locations/{location}/conversations/{conversation} */ async projectsLocationsConversationsPatch(name: string, req: GoogleCloudContactcenterinsightsV1Conversation, opts: ProjectsLocationsConversationsPatchOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1Conversation(req); opts = serializeProjectsLocationsConversationsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.allowMissing !== undefined) { url.searchParams.append("allowMissing", String(opts.allowMissing)); } if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return deserializeGoogleCloudContactcenterinsightsV1Conversation(data); } /** * Samples conversations based on user configuration and handles the sampled * conversations for different use cases. * * @param parent Required. The parent resource of the dataset. */ async projectsLocationsConversationsSample(parent: string, req: GoogleCloudContactcenterinsightsV1SampleConversationsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1SampleConversationsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:sample`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Analyzes multiple conversations in a single request. * * @param parent Required. The parent resource to create analyses in. */ async projectsLocationsConversationsSegmentsBulkAnalyze(parent: string, req: GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/segments:bulkAnalyze`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Create a long-running conversation upload operation. This method differs * from `CreateConversation` by allowing audio transcription and optional DLP * redaction. * * @param parent Required. The parent resource of the conversation. */ async projectsLocationsConversationsUpload(parent: string, req: GoogleCloudContactcenterinsightsV1UploadConversationRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1UploadConversationRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:upload`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Delete feedback labels in bulk using a filter. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsDatasetsBulkDeleteFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkDeleteFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Download feedback labels in bulk from an external source. Currently * supports exporting Quality AI example conversations with transcripts and * question bodies. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsDatasetsBulkDownloadFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkDownloadFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Upload feedback labels from an external source in bulk. Currently supports * labeling Quality AI example conversations. * * @param parent Required. The parent resource for new feedback labels. */ async projectsLocationsDatasetsBulkUploadFeedbackLabels(parent: string, req: GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:bulkUploadFeedbackLabels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Deletes multiple conversations in a single request. * * @param parent Required. The parent resource to delete conversations from. Format: projects/{project}/locations/{location} */ async projectsLocationsDatasetsConversationsBulkDelete(parent: string, req: GoogleCloudContactcenterinsightsV1BulkDeleteConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:bulkDelete`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Gets conversation statistics. * * @param location Required. The location of the conversations. */ async projectsLocationsDatasetsConversationsCalculateStats(location: string, req: GoogleCloudContactcenterinsightsV1CalculateStatsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ location }/conversations:calculateStats`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponse(data); } /** * Deletes a conversation. * * @param name Required. The name of the conversation to delete. */ async projectsLocationsDatasetsConversationsDelete(name: string, opts: ProjectsLocationsDatasetsConversationsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Create feedback label. * * @param parent Required. The parent resource of the feedback label. */ async projectsLocationsDatasetsConversationsFeedbackLabelsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsDatasetsConversationsFeedbackLabelsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.feedbackLabelId !== undefined) { url.searchParams.append("feedbackLabelId", String(opts.feedbackLabelId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Delete feedback label. * * @param name Required. The name of the feedback label to delete. */ async projectsLocationsDatasetsConversationsFeedbackLabelsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Get feedback label. * * @param name Required. The name of the feedback label to get. */ async projectsLocationsDatasetsConversationsFeedbackLabelsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * List feedback labels. * * @param parent Required. The parent resource of the feedback labels. */ async projectsLocationsDatasetsConversationsFeedbackLabelsList(parent: string, opts: ProjectsLocationsDatasetsConversationsFeedbackLabelsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/feedbackLabels`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListFeedbackLabelsResponse; } /** * Update feedback label. * * @param name Immutable. Resource name of the FeedbackLabel. Format: projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ async projectsLocationsDatasetsConversationsFeedbackLabelsPatch(name: string, req: GoogleCloudContactcenterinsightsV1FeedbackLabel, opts: ProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions = {}): Promise { opts = serializeProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1FeedbackLabel; } /** * Gets a conversation. * * @param name Required. The name of the conversation to get. */ async projectsLocationsDatasetsConversationsGet(name: string, opts: ProjectsLocationsDatasetsConversationsGetOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1Conversation(data); } /** * Imports conversations and processes them according to the user's * configuration. * * @param parent Required. The parent resource for new conversations. */ async projectsLocationsDatasetsConversationsIngest(parent: string, req: GoogleCloudContactcenterinsightsV1IngestConversationsRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:ingest`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Lists conversations. * * @param parent Required. The parent resource of the conversation. */ async projectsLocationsDatasetsConversationsList(parent: string, opts: ProjectsLocationsDatasetsConversationsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.orderBy !== undefined) { url.searchParams.append("orderBy", String(opts.orderBy)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.view !== undefined) { url.searchParams.append("view", String(opts.view)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListConversationsResponse(data); } /** * Samples conversations based on user configuration and handles the sampled * conversations for different use cases. * * @param parent Required. The parent resource of the dataset. */ async projectsLocationsDatasetsConversationsSample(parent: string, req: GoogleCloudContactcenterinsightsV1SampleConversationsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1SampleConversationsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/conversations:sample`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Creates a dataset. * * @param parent Required. The parent resource of the dataset. */ async projectsLocationsDatasetsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Dataset, opts: ProjectsLocationsDatasetsCreateOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1Dataset(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/datasets`); if (opts.datasetId !== undefined) { url.searchParams.append("datasetId", String(opts.datasetId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleCloudContactcenterinsightsV1Dataset(data); } /** * Delete a dataset. * * @param name Required. The name of the dataset to delete. */ async projectsLocationsDatasetsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleLongrunningOperation; } /** * Gets a dataset. * * @param name Required. The name of the dataset to get. */ async projectsLocationsDatasetsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1Dataset(data); } /** * Export insights data to a destination defined in the request body. * * @param parent Required. The parent resource to export data from. */ async projectsLocationsDatasetsInsightsdataExport(parent: string, req: GoogleCloudContactcenterinsightsV1ExportInsightsDataRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/insightsdata:export`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * List datasets matching the input. * * @param parent Required. The parent resource of the dataset. */ async projectsLocationsDatasetsList(parent: string, opts: ProjectsLocationsDatasetsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/datasets`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListDatasetsResponse(data); } /** * List all feedback labels by project number. * * @param parent Required. The parent resource of all feedback labels per project. */ async projectsLocationsDatasetsListAllFeedbackLabels(parent: string, opts: ProjectsLocationsDatasetsListAllFeedbackLabelsOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:listAllFeedbackLabels`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAllFeedbackLabelsResponse; } /** * Updates a dataset. * * @param name Immutable. Identifier. Resource name of the dataset. Format: projects/{project}/locations/{location}/datasets/{dataset} */ async projectsLocationsDatasetsPatch(name: string, req: GoogleCloudContactcenterinsightsV1Dataset, opts: ProjectsLocationsDatasetsPatchOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1Dataset(req); opts = serializeProjectsLocationsDatasetsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return deserializeGoogleCloudContactcenterinsightsV1Dataset(data); } /** * Initializes a location-level encryption key specification. An error will * result if the location has resources already created before the * initialization. After the encryption specification is initialized at a * location, it is immutable and all newly created resources under the * location will be encrypted with the existing specification. * * @param name Immutable. The resource name of the encryption key specification resource. Format: projects/{project}/locations/{location}/encryptionSpec */ async projectsLocationsEncryptionSpecInitialize(name: string, req: GoogleCloudContactcenterinsightsV1InitializeEncryptionSpecRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:initialize`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Gets location-level encryption key specification. * * @param name Required. The name of the encryption spec resource to get. */ async projectsLocationsGetEncryptionSpec(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1EncryptionSpec; } /** * Gets project-level settings. * * @param name Required. The name of the settings resource to get. */ async projectsLocationsGetSettings(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1Settings(data); } /** * Export insights data to a destination defined in the request body. * * @param parent Required. The parent resource to export data from. */ async projectsLocationsInsightsdataExport(parent: string, req: GoogleCloudContactcenterinsightsV1ExportInsightsDataRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/insightsdata:export`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Gets an issue model's statistics. * * @param issueModel Required. The resource name of the issue model to query against. */ async projectsLocationsIssueModelsCalculateIssueModelStats(issueModel: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ issueModel }:calculateIssueModelStats`); const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse(data); } /** * Creates an issue model. * * @param parent Required. The parent resource of the issue model. */ async projectsLocationsIssueModelsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1IssueModel): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/issueModels`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Deletes an issue model. * * @param name Required. The name of the issue model to delete. */ async projectsLocationsIssueModelsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleLongrunningOperation; } /** * Deploys an issue model. Returns an error if a model is already deployed. * An issue model can only be used in analysis after it has been deployed. * * @param name Required. The issue model to deploy. */ async projectsLocationsIssueModelsDeploy(name: string, req: GoogleCloudContactcenterinsightsV1DeployIssueModelRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:deploy`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Exports an issue model to the provided destination. * * @param name Required. The issue model to export. */ async projectsLocationsIssueModelsExport(name: string, req: GoogleCloudContactcenterinsightsV1ExportIssueModelRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:export`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Gets an issue model. * * @param name Required. The name of the issue model to get. */ async projectsLocationsIssueModelsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1IssueModel; } /** * Imports an issue model from a Cloud Storage bucket. * * @param parent Required. The parent resource of the issue model. */ async projectsLocationsIssueModelsImport(parent: string, req: GoogleCloudContactcenterinsightsV1ImportIssueModelRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/issueModels:import`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Creates an issue. * * @param parent Required. The parent resource of the issue. */ async projectsLocationsIssueModelsIssuesCreate(parent: string, req: GoogleCloudContactcenterinsightsV1Issue): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/issues`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Deletes an issue. * * @param name Required. The name of the issue to delete. */ async projectsLocationsIssueModelsIssuesDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets an issue. * * @param name Required. The name of the issue to get. */ async projectsLocationsIssueModelsIssuesGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1Issue; } /** * Lists issues. * * @param parent Required. The parent resource of the issue. */ async projectsLocationsIssueModelsIssuesList(parent: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/issues`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListIssuesResponse; } /** * Updates an issue. * * @param name Immutable. The resource name of the issue. Format: projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ async projectsLocationsIssueModelsIssuesPatch(name: string, req: GoogleCloudContactcenterinsightsV1Issue, opts: ProjectsLocationsIssueModelsIssuesPatchOptions = {}): Promise { opts = serializeProjectsLocationsIssueModelsIssuesPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1Issue; } /** * Lists issue models. * * @param parent Required. The parent resource of the issue model. */ async projectsLocationsIssueModelsList(parent: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/issueModels`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListIssueModelsResponse; } /** * Updates an issue model. * * @param name Immutable. The resource name of the issue model. Format: projects/{project}/locations/{location}/issueModels/{issue_model} */ async projectsLocationsIssueModelsPatch(name: string, req: GoogleCloudContactcenterinsightsV1IssueModel, opts: ProjectsLocationsIssueModelsPatchOptions = {}): Promise { opts = serializeProjectsLocationsIssueModelsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1IssueModel; } /** * Undeploys an issue model. An issue model can not be used in analysis after * it has been undeployed. * * @param name Required. The issue model to undeploy. */ async projectsLocationsIssueModelsUndeploy(name: string, req: GoogleCloudContactcenterinsightsV1UndeployIssueModelRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:undeploy`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * List all feedback labels by project number. * * @param parent Required. The parent resource of all feedback labels per project. */ async projectsLocationsListAllFeedbackLabels(parent: string, opts: ProjectsLocationsListAllFeedbackLabelsOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:listAllFeedbackLabels`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListAllFeedbackLabelsResponse; } /** * Starts asynchronous cancellation on a long-running operation. The server * makes a best effort to cancel the operation, but success is not guaranteed. * If the server doesn't support this method, it returns * `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or * other methods to check whether the cancellation succeeded or whether the * operation completed despite cancellation. On successful cancellation, the * operation is not deleted; instead, it becomes an operation with an * Operation.error value with a google.rpc.Status.code of `1`, corresponding * to `Code.CANCELLED`. * * @param name The name of the operation resource to be cancelled. */ async projectsLocationsOperationsCancel(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:cancel`); const data = await request(url.href, { client: this.#client, method: "POST", }); return data as GoogleProtobufEmpty; } /** * Gets the latest state of a long-running operation. Clients can use this * method to poll the operation result at intervals as recommended by the API * service. * * @param name The name of the operation resource. */ async projectsLocationsOperationsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleLongrunningOperation; } /** * Lists operations that match the specified filter in the request. If the * server doesn't support this method, it returns `UNIMPLEMENTED`. * * @param name The name of the operation's parent resource. */ async projectsLocationsOperationsList(name: string, opts: ProjectsLocationsOperationsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }/operations`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.returnPartialSuccess !== undefined) { url.searchParams.append("returnPartialSuccess", String(opts.returnPartialSuccess)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleLongrunningListOperationsResponse; } /** * Creates a phrase matcher. * * @param parent Required. The parent resource of the phrase matcher. Required. The location to create a phrase matcher for. Format: `projects//locations/` or `projects//locations/` */ async projectsLocationsPhraseMatchersCreate(parent: string, req: GoogleCloudContactcenterinsightsV1PhraseMatcher): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/phraseMatchers`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1PhraseMatcher; } /** * Deletes a phrase matcher. * * @param name Required. The name of the phrase matcher to delete. */ async projectsLocationsPhraseMatchersDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets a phrase matcher. * * @param name Required. The name of the phrase matcher to get. */ async projectsLocationsPhraseMatchersGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1PhraseMatcher; } /** * Lists phrase matchers. * * @param parent Required. The parent resource of the phrase matcher. */ async projectsLocationsPhraseMatchersList(parent: string, opts: ProjectsLocationsPhraseMatchersListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/phraseMatchers`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListPhraseMatchersResponse; } /** * Updates a phrase matcher. * * @param name The resource name of the phrase matcher. Format: projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher} */ async projectsLocationsPhraseMatchersPatch(name: string, req: GoogleCloudContactcenterinsightsV1PhraseMatcher, opts: ProjectsLocationsPhraseMatchersPatchOptions = {}): Promise { opts = serializeProjectsLocationsPhraseMatchersPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1PhraseMatcher; } /** * Creates a QaQuestionTag. * * @param parent Required. The parent resource of the QaQuestionTag. */ async projectsLocationsQaQuestionTagsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1QaQuestionTag, opts: ProjectsLocationsQaQuestionTagsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/qaQuestionTags`); if (opts.qaQuestionTagId !== undefined) { url.searchParams.append("qaQuestionTagId", String(opts.qaQuestionTagId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1QaQuestionTag; } /** * Deletes a QaQuestionTag. * * @param name Required. The name of the QaQuestionTag to delete. */ async projectsLocationsQaQuestionTagsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleLongrunningOperation; } /** * Gets a QaQuestionTag. * * @param name Required. The name of the QaQuestionTag to get. */ async projectsLocationsQaQuestionTagsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1QaQuestionTag; } /** * Lists the question tags. * * @param parent Required. The parent resource of the QaQuestionTags. */ async projectsLocationsQaQuestionTagsList(parent: string, opts: ProjectsLocationsQaQuestionTagsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/qaQuestionTags`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListQaQuestionTagsResponse; } /** * Updates a QaQuestionTag. * * @param name Identifier. Resource name for the QaQuestionTag Format projects/{project}/locations/{location}/qaQuestionTags/{qa_question_tag} In the above format, the last segment, i.e., qa_question_tag, is a server-generated ID corresponding to the tag resource. */ async projectsLocationsQaQuestionTagsPatch(name: string, req: GoogleCloudContactcenterinsightsV1QaQuestionTag, opts: ProjectsLocationsQaQuestionTagsPatchOptions = {}): Promise { opts = serializeProjectsLocationsQaQuestionTagsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleLongrunningOperation; } /** * Create a QaScorecard. * * @param parent Required. The parent resource of the QaScorecard. */ async projectsLocationsQaScorecardsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1QaScorecard, opts: ProjectsLocationsQaScorecardsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/qaScorecards`); if (opts.qaScorecardId !== undefined) { url.searchParams.append("qaScorecardId", String(opts.qaScorecardId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1QaScorecard; } /** * Deletes a QaScorecard. * * @param name Required. The name of the QaScorecard to delete. */ async projectsLocationsQaScorecardsDelete(name: string, opts: ProjectsLocationsQaScorecardsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets a QaScorecard. * * @param name Required. The name of the QaScorecard to get. */ async projectsLocationsQaScorecardsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1QaScorecard; } /** * Lists QaScorecards. * * @param parent Required. The parent resource of the scorecards. */ async projectsLocationsQaScorecardsList(parent: string, opts: ProjectsLocationsQaScorecardsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/qaScorecards`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.qaScorecardSources !== undefined) { url.searchParams.append("qaScorecardSources", String(opts.qaScorecardSources)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListQaScorecardsResponse; } /** * Updates a QaScorecard. * * @param name Identifier. The scorecard name. Format: projects/{project}/locations/{location}/qaScorecards/{qa_scorecard} */ async projectsLocationsQaScorecardsPatch(name: string, req: GoogleCloudContactcenterinsightsV1QaScorecard, opts: ProjectsLocationsQaScorecardsPatchOptions = {}): Promise { opts = serializeProjectsLocationsQaScorecardsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1QaScorecard; } /** * Creates a QaScorecardRevision. * * @param parent Required. The parent resource of the QaScorecardRevision. */ async projectsLocationsQaScorecardsRevisionsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1QaScorecardRevision, opts: ProjectsLocationsQaScorecardsRevisionsCreateOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/revisions`); if (opts.qaScorecardRevisionId !== undefined) { url.searchParams.append("qaScorecardRevisionId", String(opts.qaScorecardRevisionId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1QaScorecardRevision; } /** * Deletes a QaScorecardRevision. * * @param name Required. The name of the QaScorecardRevision to delete. */ async projectsLocationsQaScorecardsRevisionsDelete(name: string, opts: ProjectsLocationsQaScorecardsRevisionsDeleteOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.force !== undefined) { url.searchParams.append("force", String(opts.force)); } const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Deploy a QaScorecardRevision. * * @param name Required. The name of the QaScorecardRevision to deploy. */ async projectsLocationsQaScorecardsRevisionsDeploy(name: string, req: GoogleCloudContactcenterinsightsV1DeployQaScorecardRevisionRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:deploy`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1QaScorecardRevision; } /** * Gets a QaScorecardRevision. * * @param name Required. The name of the QaScorecardRevision to get. */ async projectsLocationsQaScorecardsRevisionsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1QaScorecardRevision; } /** * Lists all revisions under the parent QaScorecard. * * @param parent Required. The parent resource of the scorecard revisions. To list all revisions of all scorecards, substitute the QaScorecard ID with a '-' character. */ async projectsLocationsQaScorecardsRevisionsList(parent: string, opts: ProjectsLocationsQaScorecardsRevisionsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/revisions`); if (opts.filter !== undefined) { url.searchParams.append("filter", String(opts.filter)); } if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } if (opts.qaScorecardSources !== undefined) { url.searchParams.append("qaScorecardSources", String(opts.qaScorecardSources)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListQaScorecardRevisionsResponse; } /** * Create a QaQuestion. * * @param parent Required. The parent resource of the QaQuestion. */ async projectsLocationsQaScorecardsRevisionsQaQuestionsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1QaQuestion, opts: ProjectsLocationsQaScorecardsRevisionsQaQuestionsCreateOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1QaQuestion(req); const url = new URL(`${this.#baseUrl}v1/${ parent }/qaQuestions`); if (opts.qaQuestionId !== undefined) { url.searchParams.append("qaQuestionId", String(opts.qaQuestionId)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return deserializeGoogleCloudContactcenterinsightsV1QaQuestion(data); } /** * Deletes a QaQuestion. * * @param name Required. The name of the QaQuestion to delete. */ async projectsLocationsQaScorecardsRevisionsQaQuestionsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets a QaQuestion. * * @param name Required. The name of the QaQuestion to get. */ async projectsLocationsQaScorecardsRevisionsQaQuestionsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1QaQuestion(data); } /** * Lists QaQuestions. * * @param parent Required. The parent resource of the questions. */ async projectsLocationsQaScorecardsRevisionsQaQuestionsList(parent: string, opts: ProjectsLocationsQaScorecardsRevisionsQaQuestionsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/qaQuestions`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return deserializeGoogleCloudContactcenterinsightsV1ListQaQuestionsResponse(data); } /** * Updates a QaQuestion. * * @param name Identifier. The resource name of the question. Format: projects/{project}/locations/{location}/qaScorecards/{qa_scorecard}/revisions/{revision}/qaQuestions/{qa_question} */ async projectsLocationsQaScorecardsRevisionsQaQuestionsPatch(name: string, req: GoogleCloudContactcenterinsightsV1QaQuestion, opts: ProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1QaQuestion(req); opts = serializeProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return deserializeGoogleCloudContactcenterinsightsV1QaQuestion(data); } /** * Fine tune one or more QaModels. * * @param parent Required. The parent resource for new fine tuning job instance. */ async projectsLocationsQaScorecardsRevisionsTuneQaScorecardRevision(parent: string, req: GoogleCloudContactcenterinsightsV1TuneQaScorecardRevisionRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }:tuneQaScorecardRevision`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Undeploy a QaScorecardRevision. * * @param name Required. The name of the QaScorecardRevision to undeploy. */ async projectsLocationsQaScorecardsRevisionsUndeploy(name: string, req: GoogleCloudContactcenterinsightsV1UndeployQaScorecardRevisionRequest): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }:undeploy`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1QaScorecardRevision; } /** * Query metrics. * * @param location Required. The location of the data. "projects/{project}/locations/{location}" */ async projectsLocationsQueryMetrics(location: string, req: GoogleCloudContactcenterinsightsV1QueryMetricsRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1QueryMetricsRequest(req); const url = new URL(`${this.#baseUrl}v1/${ location }:queryMetrics`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Generates a summary of predefined performance metrics for a set of * conversations. Conversations can be specified by specifying a time window * and an agent id, for now. The summary includes a comparison of metrics * computed for conversations in the previous time period, and also a * comparison with peers in the same time period. * * @param parent Required. The parent resource of the conversations to derive performance stats from. "projects/{project}/locations/{location}" */ async projectsLocationsQueryPerformanceOverview(parent: string, req: GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest): Promise { req = serializeGoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest(req); const url = new URL(`${this.#baseUrl}v1/${ parent }:queryPerformanceOverview`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleLongrunningOperation; } /** * Updates project-level settings. * * @param name Immutable. The resource name of the settings resource. Format: projects/{project}/locations/{location}/settings */ async projectsLocationsUpdateSettings(name: string, req: GoogleCloudContactcenterinsightsV1Settings, opts: ProjectsLocationsUpdateSettingsOptions = {}): Promise { req = serializeGoogleCloudContactcenterinsightsV1Settings(req); opts = serializeProjectsLocationsUpdateSettingsOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return deserializeGoogleCloudContactcenterinsightsV1Settings(data); } /** * Creates a view. * * @param parent Required. The parent resource of the view. Required. The location to create a view for. Format: `projects//locations/` or `projects//locations/` */ async projectsLocationsViewsCreate(parent: string, req: GoogleCloudContactcenterinsightsV1View): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/views`); const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "POST", body, }); return data as GoogleCloudContactcenterinsightsV1View; } /** * Deletes a view. * * @param name Required. The name of the view to delete. */ async projectsLocationsViewsDelete(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "DELETE", }); return data as GoogleProtobufEmpty; } /** * Gets a view. * * @param name Required. The name of the view to get. */ async projectsLocationsViewsGet(name: string): Promise { const url = new URL(`${this.#baseUrl}v1/${ name }`); const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1View; } /** * Lists views. * * @param parent Required. The parent resource of the views. */ async projectsLocationsViewsList(parent: string, opts: ProjectsLocationsViewsListOptions = {}): Promise { const url = new URL(`${this.#baseUrl}v1/${ parent }/views`); if (opts.pageSize !== undefined) { url.searchParams.append("pageSize", String(opts.pageSize)); } if (opts.pageToken !== undefined) { url.searchParams.append("pageToken", String(opts.pageToken)); } const data = await request(url.href, { client: this.#client, method: "GET", }); return data as GoogleCloudContactcenterinsightsV1ListViewsResponse; } /** * Updates a view. * * @param name Immutable. The resource name of the view. Format: projects/{project}/locations/{location}/views/{view} */ async projectsLocationsViewsPatch(name: string, req: GoogleCloudContactcenterinsightsV1View, opts: ProjectsLocationsViewsPatchOptions = {}): Promise { opts = serializeProjectsLocationsViewsPatchOptions(opts); const url = new URL(`${this.#baseUrl}v1/${ name }`); if (opts.updateMask !== undefined) { url.searchParams.append("updateMask", String(opts.updateMask)); } const body = JSON.stringify(req); const data = await request(url.href, { client: this.#client, method: "PATCH", body, }); return data as GoogleCloudContactcenterinsightsV1View; } } /** * The analysis resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1Analysis { /** * Output only. The result of the analysis, which is populated when the * analysis finishes. */ readonly analysisResult?: GoogleCloudContactcenterinsightsV1alpha1AnalysisResult; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelector; /** * Output only. The time at which the analysis was created, which occurs when * the long-running operation completes. */ readonly createTime?: Date; /** * Immutable. The resource name of the analysis. Format: * projects/{project}/locations/{location}/conversations/{conversation}/analyses/{analysis} */ name?: string; /** * Output only. The time at which the analysis was requested. */ readonly requestTime?: Date; } /** * The result of an analysis. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnalysisResult { /** * Call-specific metadata created by the analysis. */ callAnalysisMetadata?: GoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata; /** * The time at which the analysis ended. */ endTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResult(data: any): GoogleCloudContactcenterinsightsV1alpha1AnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResult(data: any): GoogleCloudContactcenterinsightsV1alpha1AnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Call-specific metadata created during analysis. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata { /** * A list of call annotations that apply to this call. */ annotations?: GoogleCloudContactcenterinsightsV1alpha1CallAnnotation[]; /** * All the entities in the call. */ entities?: { [key: string]: GoogleCloudContactcenterinsightsV1alpha1Entity }; /** * All the matched intents in the call. */ intents?: { [key: string]: GoogleCloudContactcenterinsightsV1alpha1Intent }; /** * Overall conversation-level issue modeling result. */ issueModelResult?: GoogleCloudContactcenterinsightsV1alpha1IssueModelResult; /** * All the matched phrase matchers in the call. */ phraseMatchers?: { [key: string]: GoogleCloudContactcenterinsightsV1alpha1PhraseMatchData }; /** * Results of scoring QaScorecards. */ qaScorecardResults?: GoogleCloudContactcenterinsightsV1alpha1QaScorecardResult[]; /** * Overall conversation-level sentiment for each channel of the call. */ sentiments?: GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSentiment[]; /** * Overall conversation-level silence during the call. */ silence?: GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence; } function serializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence(data["silence"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1AnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence(data["silence"]) : undefined, }; } /** * A point in a conversation that marks the start or the end of an annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnnotationBoundary { /** * The index in the sequence of transcribed pieces of the conversation where * the boundary is located. This index starts at zero. */ transcriptIndex?: number; /** * The word index of this boundary with respect to the first word in the * transcript piece. This index starts at zero. */ wordIndex?: number; } /** * Selector of all available annotators and phrase matchers to run. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelector { /** * The issue model to run. If not provided, the most recently deployed topic * model will be used. The provided issue model will only be used for * inference if the issue model is deployed and if run_issue_model_annotator * is set to true. If more than one issue model is provided, only the first * provided issue model will be used for inference. */ issueModels?: string[]; /** * The list of phrase matchers to run. If not provided, all active phrase * matchers will be used. If inactive phrase matchers are provided, they will * not be used. Phrase matchers will be run only if * run_phrase_matcher_annotator is set to true. Format: * projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher} */ phraseMatchers?: string[]; /** * Configuration for the QA annotator. */ qaConfig?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorQaConfig; /** * Whether to run the entity annotator. */ runEntityAnnotator?: boolean; /** * Whether to run the intent annotator. */ runIntentAnnotator?: boolean; /** * Whether to run the interruption annotator. */ runInterruptionAnnotator?: boolean; /** * Whether to run the issue model annotator. A model should have already been * deployed for this to take effect. */ runIssueModelAnnotator?: boolean; /** * Whether to run the active phrase matcher annotator(s). */ runPhraseMatcherAnnotator?: boolean; /** * Whether to run the QA annotator. */ runQaAnnotator?: boolean; /** * Whether to run the sentiment annotator. */ runSentimentAnnotator?: boolean; /** * Whether to run the silence annotator. */ runSilenceAnnotator?: boolean; /** * Whether to run the summarization annotator. */ runSummarizationAnnotator?: boolean; /** * Configuration for the summarization annotator. */ summarizationConfig?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorSummarizationConfig; } /** * Configuration for the QA feature. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorQaConfig { /** * A manual list of scorecards to score. */ scorecardList?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorQaConfigScorecardList; } /** * Container for a list of scorecards. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorQaConfigScorecardList { /** * List of QaScorecardRevisions. */ qaScorecardRevisions?: string[]; } /** * Configuration for summarization. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelectorSummarizationConfig { /** * Resource name of the Dialogflow conversation profile. Format: * projects/{project}/locations/{location}/conversationProfiles/{conversation_profile} */ conversationProfile?: string; /** * The resource name of the existing created generator. Format: * projects//locations//generators/ */ generator?: string; /** * Default summarization model to be used. */ summarizationModel?: | "SUMMARIZATION_MODEL_UNSPECIFIED" | "BASELINE_MODEL" | "BASELINE_MODEL_V2_0"; } /** * The feedback that the customer has about a certain answer in the * conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1AnswerFeedback { /** * Indicates whether an answer or item was clicked by the human agent. */ clicked?: boolean; /** * The correctness level of an answer. */ correctnessLevel?: | "CORRECTNESS_LEVEL_UNSPECIFIED" | "NOT_CORRECT" | "PARTIALLY_CORRECT" | "FULLY_CORRECT"; /** * Indicates whether an answer or item was displayed to the human agent in * the agent desktop UI. */ displayed?: boolean; } /** * Agent Assist Article Suggestion data. */ export interface GoogleCloudContactcenterinsightsV1alpha1ArticleSuggestionData { /** * The system's confidence score that this article is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Article Suggestion and the document * that it originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document} */ source?: string; /** * Article title. */ title?: string; /** * Article URI. */ uri?: string; } /** * The metadata for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsMetadata { /** * The number of requested analyses that have completed successfully so far. */ completedAnalysesCount?: number; /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The number of requested analyses that have failed so far. */ failedAnalysesCount?: number; /** * Output only. Partial errors during bulk analyze operation that might cause * the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk analyze. */ request?: GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsRequest; /** * Total number of analyses requested. Computed by the number of * conversations returned by `filter` multiplied by `analysis_percentage` in * the request. */ totalRequestedAnalysesCount?: number; } function serializeGoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to analyze conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsRequest { /** * Required. Percentage of selected conversation to analyze, between [0, * 100]. */ analysisPercentage?: number; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelector; /** * Required. Filter used to select the subset of conversations to analyze. */ filter?: string; /** * Required. The parent resource to create analyses in. */ parent?: string; } /** * The response for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkAnalyzeConversationsResponse { /** * Count of failed analyses. */ failedAnalysisCount?: number; /** * Count of successful analyses. */ successfulAnalysisCount?: number; } /** * The metadata for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * Partial errors during bulk delete conversations operation that might cause * the operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk delete. */ request?: GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsRequest; } function serializeGoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to delete conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsRequest { /** * Filter used to select the subset of conversations to delete. */ filter?: string; /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; /** * Maximum number of conversations to delete. */ maxDeleteCount?: number; /** * Required. The parent resource to delete conversations from. Format: * projects/{project}/locations/{location} */ parent?: string; } /** * The response for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteConversationsResponse { } /** * Metadata for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteFeedbackLabelsMetadata { /** * Partial errors during deletion operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for delete. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1BulkDeleteFeedbackLabelsRequest; } /** * Request for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteFeedbackLabelsRequest { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Supported fields: * * `issue_model_id` * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Required. The parent resource for new feedback labels. */ parent?: string; } /** * Response for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1alpha1BulkDeleteFeedbackLabelsResponse { } /** * A piece of metadata that applies to a window of a call. */ export interface GoogleCloudContactcenterinsightsV1alpha1CallAnnotation { /** * The boundary in the conversation where the annotation ends, inclusive. */ annotationEndBoundary?: GoogleCloudContactcenterinsightsV1alpha1AnnotationBoundary; /** * The boundary in the conversation where the annotation starts, inclusive. */ annotationStartBoundary?: GoogleCloudContactcenterinsightsV1alpha1AnnotationBoundary; /** * The channel of the audio where the annotation occurs. For single-channel * audio, this field is not populated. */ channelTag?: number; /** * Data specifying an entity mention. */ entityMentionData?: GoogleCloudContactcenterinsightsV1alpha1EntityMentionData; /** * Data specifying a hold. */ holdData?: GoogleCloudContactcenterinsightsV1alpha1HoldData; /** * Data specifying an intent match. */ intentMatchData?: GoogleCloudContactcenterinsightsV1alpha1IntentMatchData; /** * Data specifying an interruption. */ interruptionData?: GoogleCloudContactcenterinsightsV1alpha1InterruptionData; /** * Data specifying an issue match. */ issueMatchData?: GoogleCloudContactcenterinsightsV1alpha1IssueMatchData; /** * Data specifying a phrase match. */ phraseMatchData?: GoogleCloudContactcenterinsightsV1alpha1PhraseMatchData; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1alpha1SentimentData; /** * Data specifying silence. */ silenceData?: GoogleCloudContactcenterinsightsV1alpha1SilenceData; } /** * The conversation resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1Conversation { /** * An opaque, user-specified string representing the human agent who handled * the conversation. */ agentId?: string; /** * Call-specific metadata. */ callMetadata?: GoogleCloudContactcenterinsightsV1alpha1ConversationCallMetadata; /** * Output only. The time at which the conversation was created. */ readonly createTime?: Date; /** * The source of the audio and transcription for the conversation. */ dataSource?: GoogleCloudContactcenterinsightsV1alpha1ConversationDataSource; /** * Output only. All the matched Dialogflow intents in the call. The key * corresponds to a Dialogflow intent, format: * projects/{project}/agent/{agent}/intents/{intent} */ readonly dialogflowIntents?: { [key: string]: GoogleCloudContactcenterinsightsV1alpha1DialogflowIntent }; /** * Output only. The duration of the conversation. */ readonly duration?: number /* Duration */; /** * The time at which this conversation should expire. After this time, the * conversation data and any associated analyses will be deleted. */ expireTime?: Date; /** * A map for the user to specify any custom fields. A maximum of 100 labels * per conversation is allowed, with a maximum of 256 characters per entry. */ labels?: { [key: string]: string }; /** * A user-specified language code for the conversation. */ languageCode?: string; /** * Output only. The conversation's latest analysis, if one exists. */ readonly latestAnalysis?: GoogleCloudContactcenterinsightsV1alpha1Analysis; /** * Output only. Latest summary of the conversation. */ readonly latestSummary?: GoogleCloudContactcenterinsightsV1alpha1ConversationSummarizationSuggestionData; /** * Immutable. The conversation medium, if unspecified will default to * PHONE_CALL. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Input only. JSON metadata encoded as a string. This field is primarily * used by Insights integrations with various telephony systems and must be in * one of Insight's supported formats. */ metadataJson?: string; /** * Immutable. The resource name of the conversation. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ name?: string; /** * Obfuscated user ID which the customer sent to us. */ obfuscatedUserId?: string; /** * Conversation metadata related to quality management. */ qualityMetadata?: GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata; /** * Output only. The annotations that were generated during the customer and * agent interaction. */ readonly runtimeAnnotations?: GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation[]; /** * The time at which the conversation started. */ startTime?: Date; /** * Output only. The conversation transcript. */ readonly transcript?: GoogleCloudContactcenterinsightsV1alpha1ConversationTranscript; /** * Input only. The TTL for this resource. If specified, then this TTL will be * used to calculate the expire time. */ ttl?: number /* Duration */; /** * Output only. The number of turns in the conversation. */ readonly turnCount?: number; /** * Output only. The most recent time at which the conversation was updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1alpha1Conversation(data: any): GoogleCloudContactcenterinsightsV1alpha1Conversation { return { ...data, expireTime: data["expireTime"] !== undefined ? data["expireTime"].toISOString() : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata(data["qualityMetadata"]) : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1Conversation(data: any): GoogleCloudContactcenterinsightsV1alpha1Conversation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, duration: data["duration"] !== undefined ? data["duration"] : undefined, expireTime: data["expireTime"] !== undefined ? new Date(data["expireTime"]) : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata(data["qualityMetadata"]) : undefined, runtimeAnnotations: data["runtimeAnnotations"] !== undefined ? data["runtimeAnnotations"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation(item))) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, transcript: data["transcript"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscript(data["transcript"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Call-specific metadata. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationCallMetadata { /** * The audio channel that contains the agent. */ agentChannel?: number; /** * The audio channel that contains the customer. */ customerChannel?: number; } /** * The conversation source, which is a combination of transcript and audio. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationDataSource { /** * The source when the conversation comes from Dialogflow. */ dialogflowSource?: GoogleCloudContactcenterinsightsV1alpha1DialogflowSource; /** * A Cloud Storage location specification for the audio and transcript. */ gcsSource?: GoogleCloudContactcenterinsightsV1alpha1GcsSource; /** * Cloud Storage URI that points to a file that contains the conversation * metadata. */ metadataUri?: string; } /** * One channel of conversation-level sentiment data. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSentiment { /** * The channel of the audio that the data applies to. */ channelTag?: number; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1alpha1SentimentData; } /** * Conversation-level silence data. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence { /** * Amount of time calculated to be in silence. */ silenceDuration?: number /* Duration */; /** * Percentage of the total conversation spent in silence. */ silencePercentage?: number; } function serializeGoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } /** * The call participant speaking for a given utterance. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationParticipant { /** * Deprecated. Use `dialogflow_participant_name` instead. The name of the * Dialogflow participant. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipant?: string; /** * The name of the participant provided by Dialogflow. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipantName?: string; /** * Obfuscated user ID from Dialogflow. */ obfuscatedExternalUserId?: string; /** * The role of the participant. */ role?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * A user-specified ID representing the participant. */ userId?: string; } /** * Conversation metadata related to quality management. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata { /** * Information about agents involved in the call. */ agentInfo?: GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadataAgentInfo[]; /** * An arbitrary integer value indicating the customer's satisfaction rating. */ customerSatisfactionRating?: number; /** * Input only. The feedback labels associated with the conversation. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1alpha1FeedbackLabel[]; /** * An arbitrary string value specifying the menu path the customer took. */ menuPath?: string; /** * The amount of time the customer waited to connect with an agent. */ waitDuration?: number /* Duration */; } function serializeGoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } /** * Information about an agent involved in the conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationQualityMetadataAgentInfo { /** * A user-specified string representing the agent. */ agentId?: string; /** * The agent type, e.g. HUMAN_AGENT. */ agentType?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * The agent's deployment display name. Only applicable to automated agents. */ deploymentDisplayName?: string; /** * The agent's deployment ID. Only applicable to automated agents. */ deploymentId?: string; /** * The agent's name. */ displayName?: string; /** * A user-provided string indicating the outcome of the agent's segment of * the call. */ dispositionCode?: string; /** * The agent's location. */ location?: string; /** * A user-specified string representing the agent's team. Deprecated in favor * of the `teams` field. */ team?: string; /** * User-specified strings representing the agent's teams. */ teams?: string[]; /** * The agent's version display name. Only applicable to automated agents. */ versionDisplayName?: string; /** * The agent's version ID. Only applicable to automated agents. */ versionId?: string; } /** * Conversation summarization suggestion data. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationSummarizationSuggestionData { /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ answerRecord?: string; /** * The confidence score of the summarization. */ confidence?: number; /** * The name of the model that generates this summary. Format: * projects/{project}/locations/{location}/conversationModels/{conversation_model} */ conversationModel?: string; /** * Agent Assist generator ID. */ generatorId?: string; /** * A map that contains metadata about the summarization and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The summarization content that is concatenated into one string. */ text?: string; /** * The summarization content that is divided into sections. The key is the * section's name and the value is the section's content. There is no specific * format for the key or value. */ textSections?: { [key: string]: string }; } /** * A message representing the transcript of a conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationTranscript { /** * A list of sequential transcript segments that comprise the conversation. */ transcriptSegments?: GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment[]; } function serializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment(item))) : undefined, }; } /** * A segment of a full transcript. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment { /** * For conversations derived from multi-channel audio, this is the channel * number corresponding to the audio from that channel. For audioChannelCount * = N, its output values can range from '1' to 'N'. A channel tag of 0 * indicates that the audio is mono. */ channelTag?: number; /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this segment. * A default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * CCAI metadata relating to the current transcript segment. */ dialogflowSegmentMetadata?: GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata; /** * The language code of this segment as a * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. * Example: "en-US". */ languageCode?: string; /** * The time that the message occurred, if provided. */ messageTime?: Date; /** * The participant of this segment. */ segmentParticipant?: GoogleCloudContactcenterinsightsV1alpha1ConversationParticipant; /** * The sentiment for this transcript segment. */ sentiment?: GoogleCloudContactcenterinsightsV1alpha1SentimentData; /** * The text of this segment. */ text?: string; /** * A list of the word-specific information for each word in the segment. */ words?: GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo[]; } function serializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? data["messageTime"].toISOString() : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? new Date(data["messageTime"]) : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } /** * Metadata from Dialogflow relating to the current transcript segment. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata { /** * Whether the transcript segment was covered under the configured smart * reply allowlist in Agent Assist. */ smartReplyAllowlistCovered?: boolean; } /** * Word-level info for words in a transcript. */ export interface GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo { /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this word. A * default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * Time offset of the end of this word relative to the beginning of the total * conversation. */ endOffset?: number /* Duration */; /** * Time offset of the start of this word relative to the beginning of the * total conversation. */ startOffset?: number /* Duration */; /** * The word itself. Includes punctuation marks that surround the word. */ word?: string; } function serializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1alpha1ConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } /** * Metadata for a create analysis operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1CreateAnalysisOperationMetadata { /** * Output only. The annotator selector used for the analysis (if any). */ readonly annotatorSelector?: GoogleCloudContactcenterinsightsV1alpha1AnnotatorSelector; /** * Output only. The Conversation that this Analysis Operation belongs to. */ readonly conversation?: string; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; } /** * Metadata for creating an issue. */ export interface GoogleCloudContactcenterinsightsV1alpha1CreateIssueMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1alpha1CreateIssueRequest; } /** * Metadata for creating an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1CreateIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1alpha1CreateIssueModelRequest; } /** * The request to create an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1CreateIssueModelRequest { /** * Required. The issue model to create. */ issueModel?: GoogleCloudContactcenterinsightsV1alpha1IssueModel; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * The request to create an issue. */ export interface GoogleCloudContactcenterinsightsV1alpha1CreateIssueRequest { /** * Required. The values for the new issue. */ issue?: GoogleCloudContactcenterinsightsV1alpha1Issue; /** * Required. The parent resource of the issue. */ parent?: string; } /** * Dataset resource represents a collection of conversations that may be * bounded (Static Dataset, e.g. golden dataset for training), or unbounded * (Dynamic Dataset, e.g. live traffic, or agent training traffic) */ export interface GoogleCloudContactcenterinsightsV1alpha1Dataset { /** * Output only. Dataset create time. */ readonly createTime?: Date; /** * Dataset description. */ description?: string; /** * Display name for the dataaset */ displayName?: string; /** * Immutable. Identifier. Resource name of the dataset. Format: * projects/{project}/locations/{location}/datasets/{dataset} */ name?: string; /** * Optional. Option TTL for the dataset. */ ttl?: number /* Duration */; /** * Dataset usage type. */ type?: | "TYPE_UNSPECIFIED" | "EVAL" | "LIVE"; /** * Output only. Dataset update time. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1alpha1Dataset(data: any): GoogleCloudContactcenterinsightsV1alpha1Dataset { return { ...data, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1Dataset(data: any): GoogleCloudContactcenterinsightsV1alpha1Dataset { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Metadata for deleting an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeleteIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deletion. */ request?: GoogleCloudContactcenterinsightsV1alpha1DeleteIssueModelRequest; } /** * The request to delete an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeleteIssueModelRequest { /** * Required. The name of the issue model to delete. */ name?: string; } /** * The metadata for deleting a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeleteQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1DeleteQaQuestionTagRequest; } /** * The request for deleting a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeleteQaQuestionTagRequest { /** * Required. The name of the QaQuestionTag to delete. */ name?: string; } /** * Metadata for deploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deployment. */ request?: GoogleCloudContactcenterinsightsV1alpha1DeployIssueModelRequest; } /** * The request to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeployIssueModelRequest { /** * Required. The issue model to deploy. */ name?: string; } /** * The response to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1DeployIssueModelResponse { } /** * The data for a Dialogflow intent. Represents a detected intent in the * conversation, e.g. MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1alpha1DialogflowIntent { /** * The human-readable name of the intent. */ displayName?: string; } /** * Dialogflow interaction data. */ export interface GoogleCloudContactcenterinsightsV1alpha1DialogflowInteractionData { /** * The confidence of the match ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidence?: number; /** * The Dialogflow intent resource path. Format: * projects/{project}/agent/{agent}/intents/{intent} */ dialogflowIntentId?: string; } /** * A Dialogflow source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1alpha1DialogflowSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Output only. The name of the Dialogflow conversation that this * conversation resource is derived from. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ readonly dialogflowConversation?: string; } /** * A dimension determines the grouping key for the query. In SQL terms, these * would be part of both the "SELECT" and "GROUP BY" clauses. */ export interface GoogleCloudContactcenterinsightsV1alpha1Dimension { /** * Output only. Metadata about the agent dimension. */ readonly agentDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionAgentDimensionMetadata; /** * Output only. Metadata about the client sentiment category dimension. */ readonly clientSentimentCategoryDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionClientSentimentCategoryDimensionMetadata; /** * Output only. Metadata about the Conversational Agents playbook dimension. */ readonly conversationalAgentsPlaybookDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionConversationalAgentsPlaybookDimensionMetadata; /** * Output only. Metadata about the Conversational Agents tool dimension. */ readonly conversationalAgentsToolDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionConversationalAgentsToolDimensionMetadata; /** * Output only. Metadata about the conversation profile dimension. */ readonly conversationProfileDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionConversationProfileDimensionMetadata; /** * The key of the dimension. */ dimensionKey?: | "DIMENSION_KEY_UNSPECIFIED" | "ISSUE" | "ISSUE_NAME" | "AGENT" | "AGENT_TEAM" | "QA_QUESTION_ID" | "QA_QUESTION_ANSWER_VALUE" | "QA_SCORECARD_ID" | "CONVERSATION_PROFILE_ID" | "MEDIUM" | "CONVERSATIONAL_AGENTS_PLAYBOOK_ID" | "CONVERSATIONAL_AGENTS_PLAYBOOK_NAME" | "CONVERSATIONAL_AGENTS_TOOL_ID" | "CONVERSATIONAL_AGENTS_TOOL_NAME" | "CLIENT_SENTIMENT_CATEGORY" | "AGENT_VERSION_ID" | "AGENT_DEPLOYMENT_ID" | "AGENT_ASSIST_SUPERVISOR_ID" | "LABEL_KEY" | "LABEL_VALUE" | "LABEL_KEY_AND_VALUE"; /** * Output only. Metadata about the issue dimension. */ readonly issueDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionIssueDimensionMetadata; /** * Output only. Metadata about conversation labels. */ readonly labelDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionLabelDimensionMetadata; /** * Output only. Metadata about the conversation medium dimension. */ readonly mediumDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionMediumDimensionMetadata; /** * Output only. Metadata about the QA question-answer dimension. */ readonly qaQuestionAnswerDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionQaQuestionAnswerDimensionMetadata; /** * Output only. Metadata about the QA question dimension. */ readonly qaQuestionDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionQaQuestionDimensionMetadata; /** * Output only. Metadata about the QA scorecard dimension. */ readonly qaScorecardDimensionMetadata?: GoogleCloudContactcenterinsightsV1alpha1DimensionQaScorecardDimensionMetadata; } /** * Metadata about the agent dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionAgentDimensionMetadata { /** * Optional. The agent's deployment display name. Only applicable to * automated agents. This will be populated for AGENT_DEPLOYMENT_ID * dimensions. */ agentDeploymentDisplayName?: string; /** * Optional. The agent's deployment ID. Only applicable to automated agents. * This will be populated for AGENT and AGENT_DEPLOYMENT_ID dimensions. */ agentDeploymentId?: string; /** * Optional. The agent's name This will be populated for AGENT, AGENT_TEAM, * AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID dimensions. */ agentDisplayName?: string; /** * Optional. A user-specified string representing the agent. This will be * populated for AGENT, AGENT_TEAM, AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentId?: string; /** * Optional. A user-specified string representing the agent's team. */ agentTeam?: string; /** * Optional. The agent's version display name. Only applicable to automated * agents. This will be populated for AGENT_VERSION_ID, and * AGENT_DEPLOYMENT_ID dimensions. */ agentVersionDisplayName?: string; /** * Optional. The agent's version ID. Only applicable to automated agents. * This will be populated for AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentVersionId?: string; } /** * Metadata about the client sentiment category dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionClientSentimentCategoryDimensionMetadata { /** * Optional. The client sentiment category. */ sentimentCategory?: string; } /** * Metadata about the Conversational Agents playbook dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionConversationalAgentsPlaybookDimensionMetadata { /** * Optional. The dialogflow playbook display name. */ playbookDisplayName?: string; /** * Optional. The dialogflow playbook ID. */ playbookId?: string; } /** * Metadata about the Conversational Agents tool dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionConversationalAgentsToolDimensionMetadata { /** * Optional. The dialogflow tool display name. */ toolDisplayName?: string; /** * Optional. The dialogflow tool ID. */ toolId?: string; } /** * Metadata about the conversation profile dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionConversationProfileDimensionMetadata { /** * Optional. The conversation profile ID. */ conversationProfileId?: string; } /** * Metadata about the issue dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionIssueDimensionMetadata { /** * The issue display name. */ issueDisplayName?: string; /** * The issue ID. */ issueId?: string; /** * The parent issue model ID. */ issueModelId?: string; } /** * Metadata about conversation labels. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionLabelDimensionMetadata { /** * Optional. The label key. */ labelKey?: string; /** * Optional. The label value. */ labelValue?: string; } /** * Metadata about the conversation medium dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionMediumDimensionMetadata { /** * Optional. The conversation medium. Currently supports : PHONE_CALL, CHAT. */ medium?: string; } /** * Metadata about the QA question-answer dimension. This is useful for showing * the answer distribution for questions for a given scorecard. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionQaQuestionAnswerDimensionMetadata { /** * Optional. The full body of the question. */ answerValue?: string; /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA question dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionQaQuestionDimensionMetadata { /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA scorecard dimension. */ export interface GoogleCloudContactcenterinsightsV1alpha1DimensionQaScorecardDimensionMetadata { /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; } /** * A customer-managed encryption key specification that can be applied to all * created resources (e.g. `Conversation`). */ export interface GoogleCloudContactcenterinsightsV1alpha1EncryptionSpec { /** * Required. The name of customer-managed encryption key that is used to * secure a resource and its sub-resources. If empty, the resource is secured * by our default encryption key. Only the key in the same location as this * resource is allowed to be used for encryption. Format: * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{key}` */ kmsKey?: string; /** * Immutable. The resource name of the encryption key specification resource. * Format: projects/{project}/locations/{location}/encryptionSpec */ name?: string; } /** * The data for an entity annotation. Represents a phrase in the conversation * that is a known entity, such as a person, an organization, or location. */ export interface GoogleCloudContactcenterinsightsV1alpha1Entity { /** * The representative name for the entity. */ displayName?: string; /** * Metadata associated with the entity. For most entity types, the metadata * is a Wikipedia URL (`wikipedia_url`) and Knowledge Graph MID (`mid`), if * they are available. For the metadata associated with other entity types, * see the Type table below. */ metadata?: { [key: string]: string }; /** * The salience score associated with the entity in the [0, 1.0] range. The * salience score for an entity provides information about the importance or * centrality of that entity to the entire document text. Scores closer to 0 * are less salient, while scores closer to 1.0 are highly salient. */ salience?: number; /** * The aggregate sentiment expressed for this entity in the conversation. */ sentiment?: GoogleCloudContactcenterinsightsV1alpha1SentimentData; /** * The entity type. */ type?: | "TYPE_UNSPECIFIED" | "PERSON" | "LOCATION" | "ORGANIZATION" | "EVENT" | "WORK_OF_ART" | "CONSUMER_GOOD" | "OTHER" | "PHONE_NUMBER" | "ADDRESS" | "DATE" | "NUMBER" | "PRICE"; } /** * The data for an entity mention annotation. This represents a mention of an * `Entity` in the conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1EntityMentionData { /** * The key of this entity in conversation entities. Can be used to retrieve * the exact `Entity` this mention is attached to. */ entityUniqueId?: string; /** * Sentiment expressed for this mention of the entity. */ sentiment?: GoogleCloudContactcenterinsightsV1alpha1SentimentData; /** * The type of the entity mention. */ type?: | "MENTION_TYPE_UNSPECIFIED" | "PROPER" | "COMMON"; } /** * Metadata for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataMetadata { /** * The number of conversations that were exported successfully. */ completedExportCount?: number; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The number of conversations that failed to be exported. */ failedExportCount?: number; /** * Partial errors during export operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for export. */ request?: GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataRequest; } /** * The request to export insights. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataRequest { /** * Specified if sink is a BigQuery table. */ bigQueryDestination?: GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataRequestBigQueryDestination; /** * Optional. Version of the export schema. */ exportSchemaVersion?: | "EXPORT_SCHEMA_VERSION_UNSPECIFIED" | "EXPORT_V1" | "EXPORT_V2" | "EXPORT_V3" | "EXPORT_V4" | "EXPORT_V5" | "EXPORT_V6" | "EXPORT_V7" | "EXPORT_V8" | "EXPORT_V9" | "EXPORT_V10" | "EXPORT_V11" | "EXPORT_V12" | "EXPORT_V13" | "EXPORT_V14" | "EXPORT_VERSION_LATEST_AVAILABLE"; /** * A filter to reduce results to a specific subset. Useful for exporting * conversations with specific properties. */ filter?: string; /** * A fully qualified KMS key name for BigQuery tables protected by CMEK. * Format: * projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}/cryptoKeyVersions/{version} */ kmsKey?: string; /** * Required. The parent resource to export data from. */ parent?: string; /** * Options for what to do if the destination table already exists. */ writeDisposition?: | "WRITE_DISPOSITION_UNSPECIFIED" | "WRITE_TRUNCATE" | "WRITE_APPEND"; } /** * A BigQuery Table Reference. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataRequestBigQueryDestination { /** * Required. The name of the BigQuery dataset that the snapshot result should * be exported to. If this dataset does not exist, the export call returns an * INVALID_ARGUMENT error. */ dataset?: string; /** * A project ID or number. If specified, then export will attempt to write * data to this project instead of the resource project. Otherwise, the * resource project will be used. */ projectId?: string; /** * The BigQuery table name to which the insights data should be written. If * this table does not exist, the export call returns an INVALID_ARGUMENT * error. */ table?: string; } /** * Response for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportInsightsDataResponse { } /** * Metadata used for export issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original export request. */ request?: GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1alpha1ExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to export an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelRequest { /** * Google Cloud Storage URI to export the issue model to. */ gcsDestination?: GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelRequestGcsDestination; /** * Required. The issue model to export. */ name?: string; } /** * Google Cloud Storage Object URI to save the issue model to. */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelRequestGcsDestination { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from export issue model */ export interface GoogleCloudContactcenterinsightsV1alpha1ExportIssueModelResponse { } /** * Agent Assist frequently-asked-question answer data. */ export interface GoogleCloudContactcenterinsightsV1alpha1FaqAnswerData { /** * The piece of text from the `source` knowledge base document. */ answer?: string; /** * The system's confidence score that this answer is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the FAQ answer and the document that it * originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The corresponding FAQ question. */ question?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document}. */ source?: string; } /** * Represents a conversation, resource, and label provided by the user. Can * take the form of a string label or a QaAnswer label. QaAnswer labels are used * for Quality AI example conversations. String labels are used for Topic * Modeling. AgentAssistSummary labels are used for Agent Assist Summarization. */ export interface GoogleCloudContactcenterinsightsV1alpha1FeedbackLabel { /** * Output only. Create time of the label. */ readonly createTime?: Date; /** * String label used for Topic Modeling. */ label?: string; /** * Name of the resource to be labeled. Supported resources are: * * `projects/{project}/locations/{location}/qaScorecards/{scorecard}/revisions/{revision}/qaQuestions/{question}` * * `projects/{project}/locations/{location}/issueModels/{issue_model}` * * `projects/{project}/locations/{location}/generators/{generator_id}` */ labeledResource?: string; /** * Immutable. Resource name of the FeedbackLabel. Format: * projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ name?: string; /** * QaAnswer label used for Quality AI example conversations. */ qaAnswerLabel?: GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerValue; /** * Output only. Update time of the label. */ readonly updateTime?: Date; } /** * A Cloud Storage source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1alpha1GcsSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Immutable. Cloud Storage URI that points to a file that contains the * conversation transcript. */ transcriptUri?: string; } /** * The data for a hold annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1HoldData { } /** * Metadata used for import issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original import request. */ request?: GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1alpha1ImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1ImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to import an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelRequest { /** * Optional. If set to true, will create an issue model from the imported * file with randomly generated IDs for the issue model and corresponding * issues. Otherwise, replaces an existing model with the same ID as the file. */ createNewModel?: boolean; /** * Google Cloud Storage source message. */ gcsSource?: GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelRequestGcsSource; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * Google Cloud Storage Object URI to get the issue model file from. */ export interface GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelRequestGcsSource { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from import issue model */ export interface GoogleCloudContactcenterinsightsV1alpha1ImportIssueModelResponse { /** * The issue model that was imported. */ issueModel?: GoogleCloudContactcenterinsightsV1alpha1IssueModel; } /** * The metadata for an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Statistics for IngestConversations operation. */ readonly ingestConversationsStats?: GoogleCloudContactcenterinsightsV1alpha1IngestConversationsMetadataIngestConversationsStats; /** * Output only. Partial errors during ingest operation that might cause the * operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for ingest. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequest; /** * Output only. Stores the conversation resources produced by ingest sampling * operations. */ readonly sampledConversations?: string[]; } /** * Statistics for IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsMetadataIngestConversationsStats { /** * Output only. The number of objects skipped because another conversation * with the same transcript uri had already been ingested. */ readonly duplicatesSkippedCount?: number; /** * Output only. The number of objects which were unable to be ingested due to * errors. The errors are populated in the partial_errors field. */ readonly failedIngestCount?: number; /** * Output only. The number of objects processed during the ingest operation. */ readonly processedObjectCount?: number; /** * Output only. The number of new conversations added during this ingest * operation. */ readonly successfulIngestCount?: number; } /** * The request to ingest conversations. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequest { /** * Configuration that applies to all conversations. */ conversationConfig?: GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestConversationConfig; /** * A cloud storage bucket source. Note that any previously ingested objects * from the source will be skipped to avoid duplication. */ gcsSource?: GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource; /** * Required. The parent resource for new conversations. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Optional, will default to * the config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1alpha1RedactionConfig; /** * Optional. If set, this fields indicates the number of objects to ingest * from the Cloud Storage bucket. If empty, the entire bucket will be * ingested. Unless they are first deleted, conversations produced through * sampling won't be ingested by subsequent ingest requests. */ sampleSize?: number; /** * Optional. Default Speech-to-Text configuration. Optional, will default to * the config specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1alpha1SpeechConfig; /** * Configuration for when `source` contains conversation transcripts. */ transcriptObjectConfig?: GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestTranscriptObjectConfig; } /** * Configuration that applies to all conversations. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestConversationConfig { /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ agentChannel?: number; /** * Optional. An opaque, user-specified string representing a human agent who * handled all conversations in the import. Note that this will be overridden * if per-conversation metadata is provided through the `metadata_bucket_uri`. */ agentId?: string; /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ customerChannel?: number; } /** * Configuration for Cloud Storage bucket sources. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource { /** * Optional. The Cloud Storage path to the conversation audio file. Note * that: [1] Audio files will be transcribed if not already. [2] Audio files * and transcript files must be in separate buckets / folders. [3] A source * file and its corresponding audio file must share the same name to be * properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and * `gs://bucket/audio/conversation1.mp3`. */ audioBucketUri?: string; /** * Optional. Specifies the type of the objects in `bucket_uri`. Avoid passing * this. This is inferred from the `transcript_bucket_uri`, * `audio_bucket_uri`. */ bucketObjectType?: | "BUCKET_OBJECT_TYPE_UNSPECIFIED" | "TRANSCRIPT" | "AUDIO"; /** * Optional. The Cloud Storage bucket containing source objects. Avoid * passing this. Pass this through one of `transcript_bucket_uri` or * `audio_bucket_uri`. */ bucketUri?: string; /** * Optional. Custom keys to extract as conversation labels from metadata * files in `metadata_bucket_uri`. Keys not included in this field will be * ignored. Note that there is a limit of 100 labels per conversation. */ customMetadataKeys?: string[]; /** * Optional. The Cloud Storage path to the conversation metadata. Note that: * [1] Metadata files are expected to be in JSON format. [2] Metadata and * source files (transcripts or audio) must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ metadataBucketUri?: string; /** * Optional. The Cloud Storage path to the conversation transcripts. Note * that: [1] Transcript files are expected to be in JSON format. [2] * Transcript, audio, metadata files must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ transcriptBucketUri?: string; } /** * Configuration for processing transcript objects. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestTranscriptObjectConfig { /** * Required. The medium transcript objects represent. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; } /** * The response to an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1IngestConversationsResponse { } /** * Metadata for initializing a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1alpha1InitializeEncryptionSpecMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Partial errors during initializing operation that might cause the * operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for initialization. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1InitializeEncryptionSpecRequest; } /** * The request to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1alpha1InitializeEncryptionSpecRequest { /** * Required. The encryption spec used for CMEK encryption. It is required * that the kms key is in the same region as the endpoint. The same key will * be used for all provisioned resources, if encryption is available. If the * `kms_key_name` field is left empty, no encryption will be enforced. */ encryptionSpec?: GoogleCloudContactcenterinsightsV1alpha1EncryptionSpec; } /** * The response to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1alpha1InitializeEncryptionSpecResponse { } /** * The data for an intent. Represents a detected intent in the conversation, * for example MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1alpha1Intent { /** * The human-readable name of the intent. */ displayName?: string; /** * The unique identifier of the intent. */ id?: string; } /** * The data for an intent match. Represents an intent match for a text segment * in the conversation. A text segment can be part of a sentence, a complete * sentence, or an utterance with multiple sentences. */ export interface GoogleCloudContactcenterinsightsV1alpha1IntentMatchData { /** * The id of the matched intent. Can be used to retrieve the corresponding * intent information. */ intentUniqueId?: string; } /** * The data for an interruption annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1InterruptionData { } /** * The issue resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1Issue { /** * Output only. The time at which this issue was created. */ readonly createTime?: Date; /** * Representative description of the issue. */ displayDescription?: string; /** * The representative name for the issue. */ displayName?: string; /** * Immutable. The resource name of the issue. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ name?: string; /** * Output only. Resource names of the sample representative utterances that * match to this issue. */ readonly sampleUtterances?: string[]; /** * Output only. The most recent time that this issue was updated. */ readonly updateTime?: Date; } /** * Information about the issue. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueAssignment { /** * Immutable. Display name of the assigned issue. This field is set at time * of analysis and immutable since then. */ displayName?: string; /** * Resource name of the assigned issue. */ issue?: string; /** * Score indicating the likelihood of the issue assignment. currently bounded * on [0,1]. */ score?: number; } /** * The data for an issue match annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueMatchData { /** * Information about the issue's assignment. */ issueAssignment?: GoogleCloudContactcenterinsightsV1alpha1IssueAssignment; } /** * The issue model resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueModel { /** * Output only. The time at which this issue model was created. */ readonly createTime?: Date; /** * The representative name for the issue model. */ displayName?: string; /** * Configs for the input data that used to create the issue model. */ inputDataConfig?: GoogleCloudContactcenterinsightsV1alpha1IssueModelInputDataConfig; /** * Output only. Number of issues in this issue model. */ readonly issueCount?: bigint; /** * Language of the model. */ languageCode?: string; /** * Type of the model. */ modelType?: | "MODEL_TYPE_UNSPECIFIED" | "TYPE_V1" | "TYPE_V2"; /** * Immutable. The resource name of the issue model. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ name?: string; /** * Output only. State of the model. */ readonly state?: | "STATE_UNSPECIFIED" | "UNDEPLOYED" | "DEPLOYING" | "DEPLOYED" | "UNDEPLOYING" | "DELETING"; /** * Output only. Immutable. The issue model's label statistics on its training * data. */ readonly trainingStats?: GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats; /** * Output only. The most recent time at which the issue model was updated. */ readonly updateTime?: Date; } /** * Configs for the input data used to create the issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueModelInputDataConfig { /** * A filter to reduce the conversations used for training the model to a * specific subset. Refer to * https://cloud.google.com/contact-center/insights/docs/filtering for * details. */ filter?: string; /** * Medium of conversations used in training data. This field is being * deprecated. To specify the medium to be used in training a new issue model, * set the `medium` field on `filter`. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Output only. Number of conversations used in training. Output only. */ readonly trainingConversationsCount?: bigint; } /** * Aggregated statistics about an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats { /** * Number of conversations the issue model has analyzed at this point in * time. */ analyzedConversationsCount?: bigint; /** * Statistics on each issue. Key is the issue's resource name. */ issueStats?: { [key: string]: GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats }; /** * Number of analyzed conversations for which no issue was applicable at this * point in time. */ unclassifiedConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? String(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, serializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? String(data["unclassifiedConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? BigInt(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, deserializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? BigInt(data["unclassifiedConversationsCount"]) : undefined, }; } /** * Aggregated statistics about an issue. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats { /** * Display name of the issue. */ displayName?: string; /** * Issue resource. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ issue?: string; /** * Number of conversations attached to the issue at this point in time. */ labeledConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? String(data["labeledConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1alpha1IssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? BigInt(data["labeledConversationsCount"]) : undefined, }; } /** * Issue Modeling result on a conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1IssueModelResult { /** * Issue model that generates the result. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ issueModel?: string; /** * All the matched issues. */ issues?: GoogleCloudContactcenterinsightsV1alpha1IssueAssignment[]; } /** * The response for listing all feedback labels. */ export interface GoogleCloudContactcenterinsightsV1alpha1ListAllFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1alpha1FeedbackLabel[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response for listing feedback labels. */ export interface GoogleCloudContactcenterinsightsV1alpha1ListFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1alpha1FeedbackLabel[]; /** * The next page token. */ nextPageToken?: string; } /** * The data for a matched phrase matcher. Represents information identifying a * phrase matcher for a given match. */ export interface GoogleCloudContactcenterinsightsV1alpha1PhraseMatchData { /** * The human-readable name of the phrase matcher. */ displayName?: string; /** * The unique identifier (the resource name) of the phrase matcher. */ phraseMatcher?: string; } /** * An answer to a QaQuestion. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaAnswer { /** * List of all individual answers given to the question. */ answerSources?: GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerSource[]; /** * The main answer value, incorporating any manual edits if they exist. */ answerValue?: GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerValue; /** * The conversation the answer applies to. */ conversation?: string; /** * The QaQuestion answered by this answer. */ qaQuestion?: string; /** * Question text. E.g., "Did the agent greet the customer?" */ questionBody?: string; /** * User-defined list of arbitrary tags. Matches the value from * QaScorecard.ScorecardQuestion.tags. Used for grouping/organization and for * weighting the score of each answer. */ tags?: string[]; } /** * A question may have multiple answers from varying sources, one of which * becomes the "main" answer above. AnswerSource represents each individual * answer. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerSource { /** * The answer value from this source. */ answerValue?: GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerValue; /** * What created the answer. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED" | "MANUAL_EDIT"; } /** * Message for holding the value of a QaAnswer. QaQuestion.AnswerChoice defines * the possible answer values for a question. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaAnswerAnswerValue { /** * Boolean value. */ boolValue?: boolean; /** * A short string used as an identifier. Matches the value used in * QaQuestion.AnswerChoice.key. */ key?: string; /** * A value of "Not Applicable (N/A)". Should only ever be `true`. */ naValue?: boolean; /** * Output only. Normalized score of the questions. Calculated as score / * potential_score. */ readonly normalizedScore?: number; /** * Numerical value. */ numValue?: number; /** * Output only. The maximum potential score of the question. */ readonly potentialScore?: number; /** * Output only. Numerical score of the answer. */ readonly score?: number; /** * Output only. A value of "Skip". If provided, this field may only be set to * `true`. If a question receives this answer, it will be excluded from any * score calculations. This would mean that the question was not evaluated. */ readonly skipValue?: boolean; /** * String value. */ strValue?: string; } /** * A tag is a resource which aims to categorize a set of questions across * multiple scorecards, e.g., "Customer Satisfaction","Billing", etc. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaQuestionTag { /** * Output only. The time at which the question tag was created. */ readonly createTime?: Date; /** * Required. A user-specified display name for the tag. */ displayName?: string; /** * Identifier. Resource name for the QaQuestionTag Format * projects/{project}/locations/{location}/qaQuestionTags/{qa_question_tag} In * the above format, the last segment, i.e., qa_question_tag, is a * server-generated ID corresponding to the tag resource. */ name?: string; /** * Optional. The list of Scorecard Question IDs that the tag applies to. Each * QaQuestionId is represented as a full resource name containing the Question * ID. Lastly, Since a tag may not necessarily be referenced by any Scorecard * Questions, we treat this field as optional. */ qaQuestionIds?: string[]; /** * Output only. The most recent time at which the question tag was updated. */ readonly updateTime?: Date; } /** * The results of scoring a single conversation against a QaScorecard. Contains * a collection of QaAnswers and aggregate score. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaScorecardResult { /** * ID of the agent that handled the conversation. */ agentId?: string; /** * The conversation scored by this result. */ conversation?: string; /** * Output only. The timestamp that the revision was created. */ readonly createTime?: Date; /** * Identifier. The name of the scorecard result. Format: * projects/{project}/locations/{location}/qaScorecardResults/{qa_scorecard_result} */ name?: string; /** * The normalized score, which is the score divided by the potential score. * Any manual edits are included if they exist. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Set of QaAnswers represented in the result. */ qaAnswers?: GoogleCloudContactcenterinsightsV1alpha1QaAnswer[]; /** * The QaScorecardRevision scored by this result. */ qaScorecardRevision?: string; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1alpha1QaScorecardResultQaTagResult[]; /** * The overall numerical score of the result, incorporating any manual edits * if they exist. */ score?: number; /** * List of all individual score sets. */ scoreSources?: GoogleCloudContactcenterinsightsV1alpha1QaScorecardResultScoreSource[]; } /** * Tags and their corresponding results. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaScorecardResultQaTagResult { /** * The normalized score the tag applies to. */ normalizedScore?: number; /** * The potential score the tag applies to. */ potentialScore?: number; /** * The score the tag applies to. */ score?: number; /** * The tag the score applies to. */ tag?: string; } /** * A scorecard result may have multiple sets of scores from varying sources, * one of which becomes the "main" answer above. A ScoreSource represents each * individual set of scores. */ export interface GoogleCloudContactcenterinsightsV1alpha1QaScorecardResultScoreSource { /** * The normalized score, which is the score divided by the potential score. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1alpha1QaScorecardResultQaTagResult[]; /** * The overall numerical score of the result. */ score?: number; /** * What created the score. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED_ONLY" | "INCLUDES_MANUAL_EDITS"; } /** * The metadata from querying metrics. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsMetadata { /** * Whether the result rows were truncated because the result row size is too * large to materialize. */ resultIsTruncated?: boolean; } /** * The response for querying metrics. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponse { /** * Required. The location of the data. * "projects/{project}/locations/{location}" */ location?: string; /** * The macro average slice contains aggregated averages across all selected * dimensions. i.e. if group_by agent and scorecard_id is specified, this * field will contain the average across all agents and all scorecards. This * field is only populated if the request specifies a Dimension. */ macroAverageSlice?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice; /** * A slice contains a total and (if the request specified a time granularity) * a time series of metric values. Each slice contains a unique combination of * the cardinality of dimensions from the request. */ slices?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice[]; /** * The metrics last update time. */ updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? data["updateTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * A slice contains a total and (if the request specified a time granularity) a * time series of metric values. Each slice contains a unique combination of the * cardinality of dimensions from the request. For example, if the request * specifies a single ISSUE dimension and it has a cardinality of 2 (i.e. the * data used to compute the metrics has 2 issues in total), the response will * have 2 slices: * Slice 1 -> dimensions=[Issue 1] * Slice 2 -> * dimensions=[Issue 2] */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice { /** * A unique combination of dimensions that this slice represents. */ dimensions?: GoogleCloudContactcenterinsightsV1alpha1Dimension[]; /** * A time series of metric values. This is only populated if the request * specifies a time granularity other than NONE. */ timeSeries?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries; /** * The total metric value. The interval of this data point is [starting * create time, ending create time) from the request. */ total?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint; } function serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } /** * A data point contains the metric values mapped to an interval. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint { /** * The measure related to conversations. */ conversationMeasure?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure; /** * The interval that this data point represents. * If this is the total data * point, the interval is [starting create time, ending create time) from the * request. * If this a data point from the time series, the interval is * [time, time + time granularity from the request). */ interval?: GoogleTypeInterval; } function serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? serializeGoogleTypeInterval(data["interval"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? deserializeGoogleTypeInterval(data["interval"]) : undefined, }; } /** * The measure related to conversations. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure { /** * The average agent's sentiment score. */ averageAgentSentimentScore?: number; /** * The average client's sentiment score. */ averageClientSentimentScore?: number; /** * The average customer satisfaction rating. */ averageCustomerSatisfactionRating?: number; /** * The average duration. */ averageDuration?: number /* Duration */; /** * The average normalized QA score for a scorecard. When computing the * average across a set of conversations, if a conversation has been evaluated * with multiple revisions of a scorecard, only the latest revision results * will be used. Will exclude 0's in average calculation. Will be only * populated if the request specifies a dimension of QA_SCORECARD_ID. */ averageQaNormalizedScore?: number; /** * Average QA normalized score averaged for questions averaged across all * revisions of the parent scorecard. Will be only populated if the request * specifies a dimension of QA_QUESTION_ID. */ averageQaQuestionNormalizedScore?: number; /** * The average silence percentage. */ averageSilencePercentage?: number; /** * The average turn count. */ averageTurnCount?: number; /** * The conversation count. */ conversationCount?: number; /** * Average QA normalized score for all the tags. */ qaTagScores?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasureQaTagScore[]; } function serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } /** * Average QA normalized score for the tag. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPointConversationMeasureQaTagScore { /** * Average tag normalized score per tag. */ averageTagNormalizedScore?: number; /** * Tag name. */ tag?: string; } /** * A time series of metric values. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries { /** * The data points that make up the time series . */ dataPoints?: GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint[]; } function serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1alpha1QueryMetricsResponseSliceDataPoint(item))) : undefined, }; } /** * The metadata for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryPerformanceOverviewMetadata { } /** * The response for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1alpha1QueryPerformanceOverviewResponse { /** * The summary text of the performance. */ summaryText?: string; } /** * DLP resources used for redaction while ingesting conversations. DLP settings * are applied to conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint or the Dialogflow / Agent Assist runtime * integrations. When using Dialogflow / Agent Assist runtime integrations, * redaction should be performed in Dialogflow / Agent Assist. */ export interface GoogleCloudContactcenterinsightsV1alpha1RedactionConfig { /** * The fully-qualified DLP deidentify template resource name. Format: * `projects/{project}/deidentifyTemplates/{template}` */ deidentifyTemplate?: string; /** * The fully-qualified DLP inspect template resource name. Format: * `projects/{project}/locations/{location}/inspectTemplates/{template}` */ inspectTemplate?: string; } /** * An annotation that was generated during the customer and agent interaction. */ export interface GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation { /** * The unique identifier of the annotation. Format: * projects/{project}/locations/{location}/conversationDatasets/{dataset}/conversationDataItems/{data_item}/conversationAnnotations/{annotation} */ annotationId?: string; /** * The feedback that the customer has about the answer in `data`. */ answerFeedback?: GoogleCloudContactcenterinsightsV1alpha1AnswerFeedback; /** * Agent Assist Article Suggestion data. */ articleSuggestion?: GoogleCloudContactcenterinsightsV1alpha1ArticleSuggestionData; /** * Conversation summarization suggestion data. */ conversationSummarizationSuggestion?: GoogleCloudContactcenterinsightsV1alpha1ConversationSummarizationSuggestionData; /** * The time at which this annotation was created. */ createTime?: Date; /** * Dialogflow interaction data. */ dialogflowInteraction?: GoogleCloudContactcenterinsightsV1alpha1DialogflowInteractionData; /** * The boundary in the conversation where the annotation ends, inclusive. */ endBoundary?: GoogleCloudContactcenterinsightsV1alpha1AnnotationBoundary; /** * Agent Assist FAQ answer data. */ faqAnswer?: GoogleCloudContactcenterinsightsV1alpha1FaqAnswerData; /** * Agent Assist Smart Compose suggestion data. */ smartComposeSuggestion?: GoogleCloudContactcenterinsightsV1alpha1SmartComposeSuggestionData; /** * Agent Assist Smart Reply data. */ smartReply?: GoogleCloudContactcenterinsightsV1alpha1SmartReplyData; /** * The boundary in the conversation where the annotation starts, inclusive. */ startBoundary?: GoogleCloudContactcenterinsightsV1alpha1AnnotationBoundary; /** * Explicit input used for generating the answer */ userInput?: GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotationUserInput; } function serializeGoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, }; } /** * Explicit input used for generating the answer */ export interface GoogleCloudContactcenterinsightsV1alpha1RuntimeAnnotationUserInput { /** * The resource name of associated generator. Format: * `projects//locations//generators/` */ generatorName?: string; /** * Query text. Article Search uses this to store the input query used to * generate the search results. */ query?: string; /** * Query source for the answer. */ querySource?: | "QUERY_SOURCE_UNSPECIFIED" | "AGENT_QUERY" | "SUGGESTED_QUERY"; } /** * The metadata for an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1SampleConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Partial errors during sample conversations operation that * might cause the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for sample conversations to dataset. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest; /** * Output only. Statistics for SampleConversations operation. */ readonly sampleConversationsStats?: GoogleCloudContactcenterinsightsV1alpha1SampleConversationsMetadataSampleConversationsStats; } /** * Statistics for SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1SampleConversationsMetadataSampleConversationsStats { /** * Output only. The number of objects which were unable to be sampled due to * errors. The errors are populated in the partial_errors field. */ readonly failedSampleCount?: number; /** * Output only. The number of new conversations added during this sample * operation. */ readonly successfulSampleCount?: number; } /** * The request to sample conversations to a dataset. */ export interface GoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest { /** * The dataset resource to copy the sampled conversations to. */ destinationDataset?: GoogleCloudContactcenterinsightsV1alpha1Dataset; /** * Required. The parent resource of the dataset. */ parent?: string; /** * Optional. The sample rule used for sampling conversations. */ sampleRule?: GoogleCloudContactcenterinsightsV1alpha1SampleRule; } function serializeGoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1Dataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1SampleRule(data["sampleRule"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1SampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1Dataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1SampleRule(data["sampleRule"]) : undefined, }; } /** * The response to an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1SampleConversationsResponse { } /** * Message for sampling conversations. */ export interface GoogleCloudContactcenterinsightsV1alpha1SampleRule { /** * To specify the filter for the conversions that should apply this sample * rule. An empty filter means this sample rule applies to all conversations. */ conversationFilter?: string; /** * Optional. Group by dimension to sample the conversation. If no dimension * is provided, the sampling will be applied to the project level. Current * supported dimensions is 'quality_metadata.agent_info.agent_id'. */ dimension?: string; /** * Percentage of conversations that we should sample based on the dimension * between [0, 100]. */ samplePercentage?: number; /** * Number of the conversations that we should sample based on the dimension. */ sampleRow?: bigint; } function serializeGoogleCloudContactcenterinsightsV1alpha1SampleRule(data: any): GoogleCloudContactcenterinsightsV1alpha1SampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? String(data["sampleRow"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1SampleRule(data: any): GoogleCloudContactcenterinsightsV1alpha1SampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? BigInt(data["sampleRow"]) : undefined, }; } /** * The data for a sentiment annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1SentimentData { /** * A non-negative number from 0 to infinity which represents the absolute * magnitude of sentiment regardless of score. */ magnitude?: number; /** * The sentiment score between -1.0 (negative) and 1.0 (positive). */ score?: number; } /** * The data for a silence annotation. */ export interface GoogleCloudContactcenterinsightsV1alpha1SilenceData { } /** * Agent Assist Smart Compose suggestion data. */ export interface GoogleCloudContactcenterinsightsV1alpha1SmartComposeSuggestionData { /** * The system's confidence score that this suggestion is a good match for * this conversation, ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Compose suggestion and the * document from which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the suggestion. */ suggestion?: string; } /** * Agent Assist Smart Reply data. */ export interface GoogleCloudContactcenterinsightsV1alpha1SmartReplyData { /** * The system's confidence score that this reply is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Reply and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the reply. */ reply?: string; } /** * Speech-to-Text configuration. Speech-to-Text settings are applied to * conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint. */ export interface GoogleCloudContactcenterinsightsV1alpha1SpeechConfig { /** * The fully-qualified Speech Recognizer resource name. Format: * `projects/{project_id}/locations/{location}/recognizer/{recognizer}` */ speechRecognizer?: string; } /** * Metadata for undeploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1UndeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for undeployment. */ request?: GoogleCloudContactcenterinsightsV1alpha1UndeployIssueModelRequest; } /** * The request to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1UndeployIssueModelRequest { /** * Required. The issue model to undeploy. */ name?: string; } /** * The response to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1alpha1UndeployIssueModelResponse { } /** * The metadata for updating a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest; } /** * The request for updating a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest { /** * Required. The QaQuestionTag to update. */ qaQuestionTag?: GoogleCloudContactcenterinsightsV1alpha1QaQuestionTag; /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `qa_question_tag_name` - the name of the tag * * `qa_question_ids` - the list of questions the tag applies to */ updateMask?: string /* FieldMask */; } function serializeGoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1UpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * The metadata for an `UploadConversation` operation. */ export interface GoogleCloudContactcenterinsightsV1alpha1UploadConversationMetadata { /** * Output only. The operation name for a successfully created analysis * operation, if any. */ readonly analysisOperation?: string; /** * Output only. The redaction config applied to the uploaded conversation. */ readonly appliedRedactionConfig?: GoogleCloudContactcenterinsightsV1alpha1RedactionConfig; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest; } /** * Request to upload a conversation. */ export interface GoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest { /** * Required. The conversation resource to create. */ conversation?: GoogleCloudContactcenterinsightsV1alpha1Conversation; /** * Optional. A unique ID for the new conversation. This ID will become the * final component of the conversation's resource name. If no ID is specified, * a server-generated ID will be used. This value should be 4-64 characters * and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters * are `a-z-` */ conversationId?: string; /** * Required. The parent resource of the conversation. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Will default to the * config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1alpha1RedactionConfig; /** * Optional. Speech-to-Text configuration. Will default to the config * specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1alpha1SpeechConfig; } function serializeGoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1alpha1Conversation(data["conversation"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1alpha1UploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1alpha1Conversation(data["conversation"]) : undefined, }; } /** * The analysis resource. */ export interface GoogleCloudContactcenterinsightsV1Analysis { /** * Output only. The result of the analysis, which is populated when the * analysis finishes. */ readonly analysisResult?: GoogleCloudContactcenterinsightsV1AnalysisResult; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1AnnotatorSelector; /** * Output only. The time at which the analysis was created, which occurs when * the long-running operation completes. */ readonly createTime?: Date; /** * Immutable. The resource name of the analysis. Format: * projects/{project}/locations/{location}/conversations/{conversation}/analyses/{analysis} */ name?: string; /** * Output only. The time at which the analysis was requested. */ readonly requestTime?: Date; } /** * The result of an analysis. */ export interface GoogleCloudContactcenterinsightsV1AnalysisResult { /** * Call-specific metadata created by the analysis. */ callAnalysisMetadata?: GoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata; /** * The time at which the analysis ended. */ endTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1AnalysisResult(data: any): GoogleCloudContactcenterinsightsV1AnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1AnalysisResult(data: any): GoogleCloudContactcenterinsightsV1AnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Call-specific metadata created during analysis. */ export interface GoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata { /** * A list of call annotations that apply to this call. */ annotations?: GoogleCloudContactcenterinsightsV1CallAnnotation[]; /** * All the entities in the call. */ entities?: { [key: string]: GoogleCloudContactcenterinsightsV1Entity }; /** * All the matched intents in the call. */ intents?: { [key: string]: GoogleCloudContactcenterinsightsV1Intent }; /** * Overall conversation-level issue modeling result. */ issueModelResult?: GoogleCloudContactcenterinsightsV1IssueModelResult; /** * All the matched phrase matchers in the call. */ phraseMatchers?: { [key: string]: GoogleCloudContactcenterinsightsV1PhraseMatchData }; /** * Results of scoring QaScorecards. */ qaScorecardResults?: GoogleCloudContactcenterinsightsV1QaScorecardResult[]; /** * Overall conversation-level sentiment for each channel of the call. */ sentiments?: GoogleCloudContactcenterinsightsV1ConversationLevelSentiment[]; /** * Overall conversation-level silence during the call. */ silence?: GoogleCloudContactcenterinsightsV1ConversationLevelSilence; } function serializeGoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1ConversationLevelSilence(data["silence"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1AnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1ConversationLevelSilence(data["silence"]) : undefined, }; } /** * The CCAI Insights project wide analysis rule. This rule will be applied to * all conversations that match the filter defined in the rule. For a * conversation matches the filter, the annotators specified in the rule will be * run. If a conversation matches multiple rules, a union of all the annotators * will be run. One project can have multiple analysis rules. */ export interface GoogleCloudContactcenterinsightsV1AnalysisRule { /** * If true, apply this rule to conversations. Otherwise, this rule is * inactive and saved as a draft. */ active?: boolean; /** * Percentage of conversations that we should apply this analysis setting * automatically, between [0, 1]. For example, 0.1 means 10%. Conversations * are sampled in a determenestic way. The original runtime_percentage & * upload percentage will be replaced by defining filters on the conversation. */ analysisPercentage?: number; /** * Selector of annotators to run and the phrase matchers to use for * conversations that matches the conversation_filter. If not specified, NO * annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1AnnotatorSelector; /** * Filter for the conversations that should apply this analysis rule. An * empty filter means this analysis rule applies to all conversations. Refer * to https://cloud.google.com/contact-center/insights/docs/filtering for * details. */ conversationFilter?: string; /** * Output only. The time at which this analysis rule was created. */ readonly createTime?: Date; /** * Display Name of the analysis rule. */ displayName?: string; /** * Identifier. The resource name of the analysis rule. Format: * projects/{project}/locations/{location}/analysisRules/{analysis_rule} */ name?: string; /** * Output only. The most recent time at which this analysis rule was updated. */ readonly updateTime?: Date; } /** * A point in a conversation that marks the start or the end of an annotation. */ export interface GoogleCloudContactcenterinsightsV1AnnotationBoundary { /** * The index in the sequence of transcribed pieces of the conversation where * the boundary is located. This index starts at zero. */ transcriptIndex?: number; /** * The word index of this boundary with respect to the first word in the * transcript piece. This index starts at zero. */ wordIndex?: number; } /** * Selector of all available annotators and phrase matchers to run. */ export interface GoogleCloudContactcenterinsightsV1AnnotatorSelector { /** * The issue model to run. If not provided, the most recently deployed topic * model will be used. The provided issue model will only be used for * inference if the issue model is deployed and if run_issue_model_annotator * is set to true. If more than one issue model is provided, only the first * provided issue model will be used for inference. */ issueModels?: string[]; /** * The list of phrase matchers to run. If not provided, all active phrase * matchers will be used. If inactive phrase matchers are provided, they will * not be used. Phrase matchers will be run only if * run_phrase_matcher_annotator is set to true. Format: * projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher} */ phraseMatchers?: string[]; /** * Configuration for the QA annotator. */ qaConfig?: GoogleCloudContactcenterinsightsV1AnnotatorSelectorQaConfig; /** * Whether to run the entity annotator. */ runEntityAnnotator?: boolean; /** * Whether to run the intent annotator. */ runIntentAnnotator?: boolean; /** * Whether to run the interruption annotator. */ runInterruptionAnnotator?: boolean; /** * Whether to run the issue model annotator. A model should have already been * deployed for this to take effect. */ runIssueModelAnnotator?: boolean; /** * Whether to run the active phrase matcher annotator(s). */ runPhraseMatcherAnnotator?: boolean; /** * Whether to run the QA annotator. */ runQaAnnotator?: boolean; /** * Whether to run the sentiment annotator. */ runSentimentAnnotator?: boolean; /** * Whether to run the silence annotator. */ runSilenceAnnotator?: boolean; /** * Whether to run the summarization annotator. */ runSummarizationAnnotator?: boolean; /** * Configuration for the summarization annotator. */ summarizationConfig?: GoogleCloudContactcenterinsightsV1AnnotatorSelectorSummarizationConfig; } /** * Configuration for the QA feature. */ export interface GoogleCloudContactcenterinsightsV1AnnotatorSelectorQaConfig { /** * A manual list of scorecards to score. */ scorecardList?: GoogleCloudContactcenterinsightsV1AnnotatorSelectorQaConfigScorecardList; } /** * Container for a list of scorecards. */ export interface GoogleCloudContactcenterinsightsV1AnnotatorSelectorQaConfigScorecardList { /** * List of QaScorecardRevisions. */ qaScorecardRevisions?: string[]; } /** * Configuration for summarization. */ export interface GoogleCloudContactcenterinsightsV1AnnotatorSelectorSummarizationConfig { /** * Resource name of the Dialogflow conversation profile. Format: * projects/{project}/locations/{location}/conversationProfiles/{conversation_profile} */ conversationProfile?: string; /** * The resource name of the existing created generator. Format: * projects//locations//generators/ */ generator?: string; /** * Default summarization model to be used. */ summarizationModel?: | "SUMMARIZATION_MODEL_UNSPECIFIED" | "BASELINE_MODEL" | "BASELINE_MODEL_V2_0"; } /** * The feedback that the customer has about a certain answer in the * conversation. */ export interface GoogleCloudContactcenterinsightsV1AnswerFeedback { /** * Indicates whether an answer or item was clicked by the human agent. */ clicked?: boolean; /** * The correctness level of an answer. */ correctnessLevel?: | "CORRECTNESS_LEVEL_UNSPECIFIED" | "NOT_CORRECT" | "PARTIALLY_CORRECT" | "FULLY_CORRECT"; /** * Indicates whether an answer or item was displayed to the human agent in * the agent desktop UI. */ displayed?: boolean; } /** * The message to appeal an assessment. */ export interface GoogleCloudContactcenterinsightsV1AppealAssessmentRequest { } /** * Agent Assist Article Suggestion data. */ export interface GoogleCloudContactcenterinsightsV1ArticleSuggestionData { /** * The system's confidence score that this article is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Article Suggestion and the document * that it originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document} */ source?: string; /** * Article title. */ title?: string; /** * Article URI. */ uri?: string; } /** * The assessment resource. */ export interface GoogleCloudContactcenterinsightsV1Assessment { /** * Information about the agent the assessment is for. */ agentInfo?: GoogleCloudContactcenterinsightsV1ConversationQualityMetadataAgentInfo; /** * Output only. The time at which the assessment was created. */ readonly createTime?: Date; /** * Identifier. The resource name of the assessment. Format: * projects/{project}/locations/{location}/conversations/{conversation}/assessments/{assessment} */ name?: string; /** * Output only. The state of the assessment. */ readonly state?: | "STATE_UNSPECIFIED" | "DRAFT" | "PUBLISHED" | "APPEALED" | "FINALIZED"; /** * Output only. The time at which the assessment was last updated. */ readonly updateTime?: Date; } /** * The CCAI Insights project wide assessment rule. This assessment rule will be * applied to all conversations from the previous sampling cycle that match the * sample rule defined in the assessment rule. One project can have multiple * assessment rules. */ export interface GoogleCloudContactcenterinsightsV1AssessmentRule { /** * If true, apply this rule to conversations. Otherwise, this rule is * inactive. */ active?: boolean; /** * Output only. The time at which this assessment rule was created. */ readonly createTime?: Date; /** * Display Name of the assessment rule. */ displayName?: string; /** * Identifier. The resource name of the assessment rule. Format: * projects/{project}/locations/{location}/assessmentRules/{assessment_rule} */ name?: string; /** * The sample rule for the assessment rule. */ sampleRule?: GoogleCloudContactcenterinsightsV1SampleRule; /** * Schedule info for the assessment rule. */ scheduleInfo?: GoogleCloudContactcenterinsightsV1ScheduleInfo; /** * Output only. The most recent time at which this assessment rule was * updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1AssessmentRule(data: any): GoogleCloudContactcenterinsightsV1AssessmentRule { return { ...data, sampleRule: data["sampleRule"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1SampleRule(data["sampleRule"]) : undefined, scheduleInfo: data["scheduleInfo"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1ScheduleInfo(data["scheduleInfo"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1AssessmentRule(data: any): GoogleCloudContactcenterinsightsV1AssessmentRule { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1SampleRule(data["sampleRule"]) : undefined, scheduleInfo: data["scheduleInfo"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1ScheduleInfo(data["scheduleInfo"]) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * An AuthorizedView represents a view of accessible Insights resources (for * example, Conversation and Scorecard). Who have read access to the * AuthorizedView resource will have access to these Insight resources as well. */ export interface GoogleCloudContactcenterinsightsV1AuthorizedView { /** * A filter to reduce conversation results to a specific subset. The * AuthorizedView's assigned permission (read/write) could be applied to the * subset of conversations. If conversation_filter is empty, there is no * restriction on the conversations that the AuthorizedView can access. Having * *authorizedViews.get* access to the AuthorizedView means having the same * read/write access to the Conversations (as well as metadata/annotations * linked to the conversation) that this AuthorizedView has. */ conversationFilter?: string; /** * Output only. The time at which the authorized view was created. */ readonly createTime?: Date; /** * Display Name. Limit 64 characters. */ displayName?: string; /** * Identifier. The resource name of the AuthorizedView. Format: * projects/{project}/locations/{location}/authorizedViewSets/{authorized_view_set}/authorizedViews/{authorized_view} */ name?: string; /** * Output only. The most recent time at which the authorized view was * updated. */ readonly updateTime?: Date; } /** * An AuthorizedViewSet contains a set of AuthorizedView resources. */ export interface GoogleCloudContactcenterinsightsV1AuthorizedViewSet { /** * Output only. Create time. */ readonly createTime?: Date; /** * Display Name. Limit 64 characters. */ displayName?: string; /** * Identifier. The resource name of the AuthorizedViewSet. Format: * projects/{project}/locations/{location}/authorizedViewSets/{authorized_view_set} */ name?: string; /** * Output only. Update time. */ readonly updateTime?: Date; } /** * The metadata for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsMetadata { /** * The number of requested analyses that have completed successfully so far. */ completedAnalysesCount?: number; /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The number of requested analyses that have failed so far. */ failedAnalysesCount?: number; /** * Output only. Partial errors during bulk analyze operation that might cause * the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk analyze. */ request?: GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsRequest; /** * Total number of analyses requested. Computed by the number of * conversations returned by `filter` multiplied by `analysis_percentage` in * the request. */ totalRequestedAnalysesCount?: number; } function serializeGoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to analyze conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsRequest { /** * Required. Percentage of selected conversation to analyze, between [0, * 100]. */ analysisPercentage?: number; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1AnnotatorSelector; /** * Required. Filter used to select the subset of conversations to analyze. */ filter?: string; /** * Required. The parent resource to create analyses in. */ parent?: string; } /** * The response for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1BulkAnalyzeConversationsResponse { /** * Count of failed analyses. */ failedAnalysisCount?: number; /** * Count of successful analyses. */ successfulAnalysisCount?: number; } /** * The metadata for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteConversationsMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * Partial errors during bulk delete conversations operation that might cause * the operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk delete. */ request?: GoogleCloudContactcenterinsightsV1BulkDeleteConversationsRequest; } function serializeGoogleCloudContactcenterinsightsV1BulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1BulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1BulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1BulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to delete conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteConversationsRequest { /** * Filter used to select the subset of conversations to delete. */ filter?: string; /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; /** * Maximum number of conversations to delete. */ maxDeleteCount?: number; /** * Required. The parent resource to delete conversations from. Format: * projects/{project}/locations/{location} */ parent?: string; } /** * The response for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteConversationsResponse { } /** * Metadata for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsMetadata { /** * Partial errors during deletion operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for delete. */ readonly request?: GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsRequest; } /** * Request for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsRequest { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Supported fields: * * `issue_model_id` * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Required. The parent resource for new feedback labels. */ parent?: string; } /** * Response for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDeleteFeedbackLabelsResponse { } /** * Metadata for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. Statistics for BulkDownloadFeedbackLabels operation. */ readonly downloadStats?: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsMetadataDownloadStats; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Partial errors during ingest operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for download. */ readonly request?: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest; } /** * Statistics for BulkDownloadFeedbackLabels operation. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsMetadataDownloadStats { /** * Output only. Full name of the files written to Cloud storage. */ readonly fileNames?: string[]; /** * The number of objects processed during the download operation. */ processedObjectCount?: number; /** * The number of new feedback labels downloaded during this operation. * Different from "processed" because some labels might not be downloaded * because an error. */ successfulDownloadCount?: number; /** * Total number of files written to the provided Cloud Storage bucket. */ totalFilesWritten?: number; } /** * Request for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest { /** * Optional. Filter parent conversations to download feedback labels for. * When specified, the feedback labels will be downloaded for the * conversations that match the filter. If `template_qa_scorecard_id` is set, * all the conversations that match the filter will be paired with the * questions under the scorecard for labeling. */ conversationFilter?: string; /** * Optional. The type of feedback labels that will be downloaded. */ feedbackLabelType?: | "FEEDBACK_LABEL_TYPE_UNSPECIFIED" | "QUALITY_AI" | "TOPIC_MODELING" | "AGENT_ASSIST_SUMMARY"; /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Supported fields: * * `issue_model_id` * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * A cloud storage bucket destination. */ gcsDestination?: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination; /** * Optional. Limits the maximum number of feedback labels that will be * downloaded. The first `N` feedback labels will be downloaded. */ maxDownloadCount?: number; /** * Required. The parent resource for new feedback labels. */ parent?: string; /** * A sheets document destination. */ sheetsDestination?: GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestSheetsDestination; /** * Optional. If set, a template for labeling conversations and scorecard * questions will be created from the conversation_filter and the questions * under the scorecard(s). The feedback label `filter` will be ignored. */ templateQaScorecardId?: string[]; } function serializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest(data: any): GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest { return { ...data, gcsDestination: data["gcsDestination"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination(data["gcsDestination"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest(data: any): GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequest { return { ...data, gcsDestination: data["gcsDestination"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination(data["gcsDestination"]) : undefined, }; } /** * Google Cloud Storage Object details to write the feedback labels to. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination { /** * Optional. Add whitespace to the JSON file. Makes easier to read, but * increases file size. Only applicable for JSON format. */ addWhitespace?: boolean; /** * Optional. Always print fields with no presence. This is useful for * printing fields that are not set, like implicit 0 value or empty * lists/maps. Only applicable for JSON format. */ alwaysPrintEmptyFields?: boolean; /** * Required. File format in which the labels will be exported. */ format?: | "FORMAT_UNSPECIFIED" | "CSV" | "JSON"; /** * Required. The Google Cloud Storage URI to write the feedback labels to. * The file name will be used as a prefix for the files written to the bucket * if the output needs to be split across multiple files, otherwise it will be * used as is. The file extension will be appended to the file name based on * the format selected. E.g. `gs://bucket_name/object_uri_prefix` */ objectUri?: string; /** * Optional. The number of records per file. Applicable for either format. */ recordsPerFileCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination(data: any): GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination { return { ...data, recordsPerFileCount: data["recordsPerFileCount"] !== undefined ? String(data["recordsPerFileCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination(data: any): GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestGcsDestination { return { ...data, recordsPerFileCount: data["recordsPerFileCount"] !== undefined ? BigInt(data["recordsPerFileCount"]) : undefined, }; } /** * Google Sheets document details to write the feedback labels to. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsRequestSheetsDestination { /** * Optional. The title of the new sheet to write the feedback labels to. */ sheetTitle?: string; /** * Required. The Google Sheets document to write the feedback labels to. * Retrieved from Google Sheets URI. E.g. * `https://docs.google.com/spreadsheets/d/1234567890` The spreadsheet must be * shared with the Insights P4SA. The spreadsheet ID written to will be * returned as `file_names` in the BulkDownloadFeedbackLabelsMetadata. */ spreadsheetUri?: string; } /** * Response for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1BulkDownloadFeedbackLabelsResponse { } /** * The request for bulk uploading feedback labels. */ export interface GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequest { /** * A cloud storage bucket source. */ gcsSource?: GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequestGcsSource; /** * A sheets document source. */ sheetsSource?: GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequestSheetsSource; /** * Optional. If set, upload will not happen and the labels will be validated. * If not set, then default behavior will be to upload the labels after * validation is complete. */ validateOnly?: boolean; } /** * Google Cloud Storage Object details to get the feedback label file from. */ export interface GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequestGcsSource { /** * Required. File format which will be ingested. */ format?: | "FORMAT_UNSPECIFIED" | "CSV" | "JSON"; /** * Required. The Google Cloud Storage URI of the file to import. Format: * `gs://bucket_name/object_name` */ objectUri?: string; } /** * Google Sheets document details to get the feedback label file from. */ export interface GoogleCloudContactcenterinsightsV1BulkUploadFeedbackLabelsRequestSheetsSource { /** * Required. The Google Sheets document to write the feedback labels to. * Retrieved from Google Sheets URI. E.g. * `https://docs.google.com/spreadsheets/d/1234567890` The spreadsheet must be * shared with the Insights P4SA. */ spreadsheetUri?: string; } /** * Response of querying an issue model's statistics. */ export interface GoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse { /** * The latest label statistics for the queried issue model. Includes results * on both training data and data labeled after deployment. */ currentStats?: GoogleCloudContactcenterinsightsV1IssueModelLabelStats; } function serializeGoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse(data: any): GoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse { return { ...data, currentStats: data["currentStats"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1IssueModelLabelStats(data["currentStats"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse(data: any): GoogleCloudContactcenterinsightsV1CalculateIssueModelStatsResponse { return { ...data, currentStats: data["currentStats"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1IssueModelLabelStats(data["currentStats"]) : undefined, }; } /** * The request for calculating conversation statistics. */ export interface GoogleCloudContactcenterinsightsV1CalculateStatsRequest { /** * A filter to reduce results to a specific subset. This field is useful for * getting statistics about conversations with specific properties. */ filter?: string; } /** * The response for calculating conversation statistics. */ export interface GoogleCloudContactcenterinsightsV1CalculateStatsResponse { /** * The average duration of all conversations. The average is calculated using * only conversations that have a time duration. */ averageDuration?: number /* Duration */; /** * The average number of turns per conversation. */ averageTurnCount?: number; /** * The total number of conversations. */ conversationCount?: number; /** * A time series representing the count of conversations created over time * that match that requested filter criteria. */ conversationCountTimeSeries?: GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries; /** * A map associating each custom highlighter resource name with its * respective number of matches in the set of conversations. */ customHighlighterMatches?: { [key: string]: number }; /** * A map associating each issue resource name with its respective number of * matches in the set of conversations. Key has the format: * `projects//locations//issueModels//issues/` Deprecated, use * `issue_matches_stats` field instead. */ issueMatches?: { [key: string]: number }; /** * A map associating each issue resource name with its respective number of * matches in the set of conversations. Key has the format: * `projects//locations//issueModels//issues/` */ issueMatchesStats?: { [key: string]: GoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats }; /** * A map associating each smart highlighter display name with its respective * number of matches in the set of conversations. */ smartHighlighterMatches?: { [key: string]: number }; } function serializeGoogleCloudContactcenterinsightsV1CalculateStatsResponse(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponse { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, conversationCountTimeSeries: data["conversationCountTimeSeries"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries(data["conversationCountTimeSeries"]) : undefined, issueMatchesStats: data["issueMatchesStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueMatchesStats"]).map(([k, v]: [string, any]) => ([k, serializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(v)]))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponse(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponse { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, conversationCountTimeSeries: data["conversationCountTimeSeries"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries(data["conversationCountTimeSeries"]) : undefined, issueMatchesStats: data["issueMatchesStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueMatchesStats"]).map(([k, v]: [string, any]) => ([k, deserializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(v)]))) : undefined, }; } /** * A time series representing conversations over time. */ export interface GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries { /** * The duration of each interval. */ intervalDuration?: number /* Duration */; /** * An ordered list of intervals from earliest to latest, where each interval * represents the number of conversations that transpired during the time * window. */ points?: GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval[]; } function serializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries { return { ...data, intervalDuration: data["intervalDuration"] !== undefined ? data["intervalDuration"] : undefined, points: data["points"] !== undefined ? data["points"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeries { return { ...data, intervalDuration: data["intervalDuration"] !== undefined ? data["intervalDuration"] : undefined, points: data["points"] !== undefined ? data["points"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval(item))) : undefined, }; } /** * A single interval in a time series. */ export interface GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval { /** * The number of conversations created in this interval. */ conversationCount?: number; /** * The start time of this interval. */ startTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval { return { ...data, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval(data: any): GoogleCloudContactcenterinsightsV1CalculateStatsResponseTimeSeriesInterval { return { ...data, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, }; } /** * A piece of metadata that applies to a window of a call. */ export interface GoogleCloudContactcenterinsightsV1CallAnnotation { /** * The boundary in the conversation where the annotation ends, inclusive. */ annotationEndBoundary?: GoogleCloudContactcenterinsightsV1AnnotationBoundary; /** * The boundary in the conversation where the annotation starts, inclusive. */ annotationStartBoundary?: GoogleCloudContactcenterinsightsV1AnnotationBoundary; /** * The channel of the audio where the annotation occurs. For single-channel * audio, this field is not populated. */ channelTag?: number; /** * Data specifying an entity mention. */ entityMentionData?: GoogleCloudContactcenterinsightsV1EntityMentionData; /** * Data specifying a hold. */ holdData?: GoogleCloudContactcenterinsightsV1HoldData; /** * Data specifying an intent match. */ intentMatchData?: GoogleCloudContactcenterinsightsV1IntentMatchData; /** * Data specifying an interruption. */ interruptionData?: GoogleCloudContactcenterinsightsV1InterruptionData; /** * Data specifying an issue match. */ issueMatchData?: GoogleCloudContactcenterinsightsV1IssueMatchData; /** * Data specifying a phrase match. */ phraseMatchData?: GoogleCloudContactcenterinsightsV1PhraseMatchData; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1SentimentData; /** * Data specifying silence. */ silenceData?: GoogleCloudContactcenterinsightsV1SilenceData; } /** * The conversation resource. */ export interface GoogleCloudContactcenterinsightsV1Conversation { /** * An opaque, user-specified string representing the human agent who handled * the conversation. */ agentId?: string; /** * Call-specific metadata. */ callMetadata?: GoogleCloudContactcenterinsightsV1ConversationCallMetadata; /** * Output only. The time at which the conversation was created. */ readonly createTime?: Date; /** * The source of the audio and transcription for the conversation. */ dataSource?: GoogleCloudContactcenterinsightsV1ConversationDataSource; /** * Output only. All the matched Dialogflow intents in the call. The key * corresponds to a Dialogflow intent, format: * projects/{project}/agent/{agent}/intents/{intent} */ readonly dialogflowIntents?: { [key: string]: GoogleCloudContactcenterinsightsV1DialogflowIntent }; /** * Output only. The duration of the conversation. */ readonly duration?: number /* Duration */; /** * The time at which this conversation should expire. After this time, the * conversation data and any associated analyses will be deleted. */ expireTime?: Date; /** * A map for the user to specify any custom fields. A maximum of 100 labels * per conversation is allowed, with a maximum of 256 characters per entry. */ labels?: { [key: string]: string }; /** * A user-specified language code for the conversation. */ languageCode?: string; /** * Output only. The conversation's latest analysis, if one exists. */ readonly latestAnalysis?: GoogleCloudContactcenterinsightsV1Analysis; /** * Output only. Latest summary of the conversation. */ readonly latestSummary?: GoogleCloudContactcenterinsightsV1ConversationSummarizationSuggestionData; /** * Immutable. The conversation medium, if unspecified will default to * PHONE_CALL. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Input only. JSON metadata encoded as a string. This field is primarily * used by Insights integrations with various telephony systems and must be in * one of Insight's supported formats. */ metadataJson?: string; /** * Immutable. The resource name of the conversation. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ name?: string; /** * Obfuscated user ID which the customer sent to us. */ obfuscatedUserId?: string; /** * Conversation metadata related to quality management. */ qualityMetadata?: GoogleCloudContactcenterinsightsV1ConversationQualityMetadata; /** * Output only. The annotations that were generated during the customer and * agent interaction. */ readonly runtimeAnnotations?: GoogleCloudContactcenterinsightsV1RuntimeAnnotation[]; /** * The time at which the conversation started. */ startTime?: Date; /** * Output only. The conversation transcript. */ readonly transcript?: GoogleCloudContactcenterinsightsV1ConversationTranscript; /** * Input only. The TTL for this resource. If specified, then this TTL will be * used to calculate the expire time. */ ttl?: number /* Duration */; /** * Output only. The number of turns in the conversation. */ readonly turnCount?: number; /** * Output only. The most recent time at which the conversation was updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1Conversation(data: any): GoogleCloudContactcenterinsightsV1Conversation { return { ...data, expireTime: data["expireTime"] !== undefined ? data["expireTime"].toISOString() : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1ConversationQualityMetadata(data["qualityMetadata"]) : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1Conversation(data: any): GoogleCloudContactcenterinsightsV1Conversation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, duration: data["duration"] !== undefined ? data["duration"] : undefined, expireTime: data["expireTime"] !== undefined ? new Date(data["expireTime"]) : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1ConversationQualityMetadata(data["qualityMetadata"]) : undefined, runtimeAnnotations: data["runtimeAnnotations"] !== undefined ? data["runtimeAnnotations"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1RuntimeAnnotation(item))) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, transcript: data["transcript"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1ConversationTranscript(data["transcript"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Call-specific metadata. */ export interface GoogleCloudContactcenterinsightsV1ConversationCallMetadata { /** * The audio channel that contains the agent. */ agentChannel?: number; /** * The audio channel that contains the customer. */ customerChannel?: number; } /** * The conversation source, which is a combination of transcript and audio. */ export interface GoogleCloudContactcenterinsightsV1ConversationDataSource { /** * The source when the conversation comes from Dialogflow. */ dialogflowSource?: GoogleCloudContactcenterinsightsV1DialogflowSource; /** * A Cloud Storage location specification for the audio and transcript. */ gcsSource?: GoogleCloudContactcenterinsightsV1GcsSource; /** * Cloud Storage URI that points to a file that contains the conversation * metadata. */ metadataUri?: string; } /** * One channel of conversation-level sentiment data. */ export interface GoogleCloudContactcenterinsightsV1ConversationLevelSentiment { /** * The channel of the audio that the data applies to. */ channelTag?: number; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1SentimentData; } /** * Conversation-level silence data. */ export interface GoogleCloudContactcenterinsightsV1ConversationLevelSilence { /** * Amount of time calculated to be in silence. */ silenceDuration?: number /* Duration */; /** * Percentage of the total conversation spent in silence. */ silencePercentage?: number; } function serializeGoogleCloudContactcenterinsightsV1ConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1ConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1ConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } /** * The call participant speaking for a given utterance. */ export interface GoogleCloudContactcenterinsightsV1ConversationParticipant { /** * Deprecated. Use `dialogflow_participant_name` instead. The name of the * Dialogflow participant. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipant?: string; /** * The name of the participant provided by Dialogflow. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipantName?: string; /** * Obfuscated user ID from Dialogflow. */ obfuscatedExternalUserId?: string; /** * The role of the participant. */ role?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * A user-specified ID representing the participant. */ userId?: string; } /** * Conversation metadata related to quality management. */ export interface GoogleCloudContactcenterinsightsV1ConversationQualityMetadata { /** * Information about agents involved in the call. */ agentInfo?: GoogleCloudContactcenterinsightsV1ConversationQualityMetadataAgentInfo[]; /** * An arbitrary integer value indicating the customer's satisfaction rating. */ customerSatisfactionRating?: number; /** * Input only. The feedback labels associated with the conversation. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1FeedbackLabel[]; /** * An arbitrary string value specifying the menu path the customer took. */ menuPath?: string; /** * The amount of time the customer waited to connect with an agent. */ waitDuration?: number /* Duration */; } function serializeGoogleCloudContactcenterinsightsV1ConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1ConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1ConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } /** * Information about an agent involved in the conversation. */ export interface GoogleCloudContactcenterinsightsV1ConversationQualityMetadataAgentInfo { /** * A user-specified string representing the agent. */ agentId?: string; /** * The agent type, e.g. HUMAN_AGENT. */ agentType?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * The agent's deployment display name. Only applicable to automated agents. */ deploymentDisplayName?: string; /** * The agent's deployment ID. Only applicable to automated agents. */ deploymentId?: string; /** * The agent's name. */ displayName?: string; /** * A user-provided string indicating the outcome of the agent's segment of * the call. */ dispositionCode?: string; /** * The agent's location. */ location?: string; /** * A user-specified string representing the agent's team. Deprecated in favor * of the `teams` field. */ team?: string; /** * User-specified strings representing the agent's teams. */ teams?: string[]; /** * The agent's version display name. Only applicable to automated agents. */ versionDisplayName?: string; /** * The agent's version ID. Only applicable to automated agents. */ versionId?: string; } /** * Conversation summarization suggestion data. */ export interface GoogleCloudContactcenterinsightsV1ConversationSummarizationSuggestionData { /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ answerRecord?: string; /** * The confidence score of the summarization. */ confidence?: number; /** * The name of the model that generates this summary. Format: * projects/{project}/locations/{location}/conversationModels/{conversation_model} */ conversationModel?: string; /** * Agent Assist generator ID. */ generatorId?: string; /** * A map that contains metadata about the summarization and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The summarization content that is concatenated into one string. */ text?: string; /** * The summarization content that is divided into sections. The key is the * section's name and the value is the section's content. There is no specific * format for the key or value. */ textSections?: { [key: string]: string }; } /** * A message representing the transcript of a conversation. */ export interface GoogleCloudContactcenterinsightsV1ConversationTranscript { /** * A list of sequential transcript segments that comprise the conversation. */ transcriptSegments?: GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment[]; } function serializeGoogleCloudContactcenterinsightsV1ConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment(item))) : undefined, }; } /** * A segment of a full transcript. */ export interface GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment { /** * For conversations derived from multi-channel audio, this is the channel * number corresponding to the audio from that channel. For audioChannelCount * = N, its output values can range from '1' to 'N'. A channel tag of 0 * indicates that the audio is mono. */ channelTag?: number; /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this segment. * A default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * CCAI metadata relating to the current transcript segment. */ dialogflowSegmentMetadata?: GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata; /** * The language code of this segment as a * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. * Example: "en-US". */ languageCode?: string; /** * The time that the message occurred, if provided. */ messageTime?: Date; /** * The participant of this segment. */ segmentParticipant?: GoogleCloudContactcenterinsightsV1ConversationParticipant; /** * The sentiment for this transcript segment. */ sentiment?: GoogleCloudContactcenterinsightsV1SentimentData; /** * The text of this segment. */ text?: string; /** * A list of the word-specific information for each word in the segment. */ words?: GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo[]; } function serializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? data["messageTime"].toISOString() : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? new Date(data["messageTime"]) : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } /** * Metadata from Dialogflow relating to the current transcript segment. */ export interface GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata { /** * Whether the transcript segment was covered under the configured smart * reply allowlist in Agent Assist. */ smartReplyAllowlistCovered?: boolean; } /** * Word-level info for words in a transcript. */ export interface GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo { /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this word. A * default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * Time offset of the end of this word relative to the beginning of the total * conversation. */ endOffset?: number /* Duration */; /** * Time offset of the start of this word relative to the beginning of the * total conversation. */ startOffset?: number /* Duration */; /** * The word itself. Includes punctuation marks that surround the word. */ word?: string; } function serializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1ConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } /** * Metadata for a create analysis operation. */ export interface GoogleCloudContactcenterinsightsV1CreateAnalysisOperationMetadata { /** * Output only. The annotator selector used for the analysis (if any). */ readonly annotatorSelector?: GoogleCloudContactcenterinsightsV1AnnotatorSelector; /** * Output only. The Conversation that this Analysis Operation belongs to. */ readonly conversation?: string; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; } /** * Metadata for creating an issue. */ export interface GoogleCloudContactcenterinsightsV1CreateIssueMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1CreateIssueRequest; } /** * Metadata for creating an issue model. */ export interface GoogleCloudContactcenterinsightsV1CreateIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1CreateIssueModelRequest; } /** * The request to create an issue model. */ export interface GoogleCloudContactcenterinsightsV1CreateIssueModelRequest { /** * Required. The issue model to create. */ issueModel?: GoogleCloudContactcenterinsightsV1IssueModel; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * The request to create an issue. */ export interface GoogleCloudContactcenterinsightsV1CreateIssueRequest { /** * Required. The values for the new issue. */ issue?: GoogleCloudContactcenterinsightsV1Issue; /** * Required. The parent resource of the issue. */ parent?: string; } /** * Dataset resource represents a collection of conversations that may be * bounded (Static Dataset, e.g. golden dataset for training), or unbounded * (Dynamic Dataset, e.g. live traffic, or agent training traffic) */ export interface GoogleCloudContactcenterinsightsV1Dataset { /** * Output only. Dataset create time. */ readonly createTime?: Date; /** * Dataset description. */ description?: string; /** * Display name for the dataaset */ displayName?: string; /** * Immutable. Identifier. Resource name of the dataset. Format: * projects/{project}/locations/{location}/datasets/{dataset} */ name?: string; /** * Optional. Option TTL for the dataset. */ ttl?: number /* Duration */; /** * Dataset usage type. */ type?: | "TYPE_UNSPECIFIED" | "EVAL" | "LIVE"; /** * Output only. Dataset update time. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1Dataset(data: any): GoogleCloudContactcenterinsightsV1Dataset { return { ...data, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1Dataset(data: any): GoogleCloudContactcenterinsightsV1Dataset { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Metadata for deleting an issue model. */ export interface GoogleCloudContactcenterinsightsV1DeleteIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deletion. */ request?: GoogleCloudContactcenterinsightsV1DeleteIssueModelRequest; } /** * The request to delete an issue model. */ export interface GoogleCloudContactcenterinsightsV1DeleteIssueModelRequest { /** * Required. The name of the issue model to delete. */ name?: string; } /** * The metadata for deleting a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1DeleteQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1DeleteQaQuestionTagRequest; } /** * The request for deleting a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1DeleteQaQuestionTagRequest { /** * Required. The name of the QaQuestionTag to delete. */ name?: string; } /** * Metadata for deploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1DeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deployment. */ request?: GoogleCloudContactcenterinsightsV1DeployIssueModelRequest; } /** * The request to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1DeployIssueModelRequest { /** * Required. The issue model to deploy. */ name?: string; } /** * The response to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1DeployIssueModelResponse { } /** * The request to deploy a QaScorecardRevision */ export interface GoogleCloudContactcenterinsightsV1DeployQaScorecardRevisionRequest { } /** * The data for a Dialogflow intent. Represents a detected intent in the * conversation, e.g. MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1DialogflowIntent { /** * The human-readable name of the intent. */ displayName?: string; } /** * Dialogflow interaction data. */ export interface GoogleCloudContactcenterinsightsV1DialogflowInteractionData { /** * The confidence of the match ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidence?: number; /** * The Dialogflow intent resource path. Format: * projects/{project}/agent/{agent}/intents/{intent} */ dialogflowIntentId?: string; } /** * A Dialogflow source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1DialogflowSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Output only. The name of the Dialogflow conversation that this * conversation resource is derived from. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ readonly dialogflowConversation?: string; } /** * A dimension determines the grouping key for the query. In SQL terms, these * would be part of both the "SELECT" and "GROUP BY" clauses. */ export interface GoogleCloudContactcenterinsightsV1Dimension { /** * Output only. Metadata about the agent dimension. */ readonly agentDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionAgentDimensionMetadata; /** * Output only. Metadata about the client sentiment category dimension. */ readonly clientSentimentCategoryDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionClientSentimentCategoryDimensionMetadata; /** * Output only. Metadata about the Conversational Agents playbook dimension. */ readonly conversationalAgentsPlaybookDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionConversationalAgentsPlaybookDimensionMetadata; /** * Output only. Metadata about the Conversational Agents tool dimension. */ readonly conversationalAgentsToolDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionConversationalAgentsToolDimensionMetadata; /** * Output only. Metadata about the conversation profile dimension. */ readonly conversationProfileDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionConversationProfileDimensionMetadata; /** * The key of the dimension. */ dimensionKey?: | "DIMENSION_KEY_UNSPECIFIED" | "ISSUE" | "ISSUE_NAME" | "AGENT" | "AGENT_TEAM" | "QA_QUESTION_ID" | "QA_QUESTION_ANSWER_VALUE" | "QA_SCORECARD_ID" | "CONVERSATION_PROFILE_ID" | "MEDIUM" | "CONVERSATIONAL_AGENTS_PLAYBOOK_ID" | "CONVERSATIONAL_AGENTS_PLAYBOOK_NAME" | "CONVERSATIONAL_AGENTS_TOOL_ID" | "CONVERSATIONAL_AGENTS_TOOL_NAME" | "CLIENT_SENTIMENT_CATEGORY" | "AGENT_VERSION_ID" | "AGENT_DEPLOYMENT_ID" | "AGENT_ASSIST_SUPERVISOR_ID" | "LABEL_KEY" | "LABEL_VALUE" | "LABEL_KEY_AND_VALUE"; /** * Output only. Metadata about the issue dimension. */ readonly issueDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionIssueDimensionMetadata; /** * Output only. Metadata about conversation labels. */ readonly labelDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionLabelDimensionMetadata; /** * Output only. Metadata about the conversation medium dimension. */ readonly mediumDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionMediumDimensionMetadata; /** * Output only. Metadata about the QA question-answer dimension. */ readonly qaQuestionAnswerDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionQaQuestionAnswerDimensionMetadata; /** * Output only. Metadata about the QA question dimension. */ readonly qaQuestionDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionQaQuestionDimensionMetadata; /** * Output only. Metadata about the QA scorecard dimension. */ readonly qaScorecardDimensionMetadata?: GoogleCloudContactcenterinsightsV1DimensionQaScorecardDimensionMetadata; } /** * Metadata about the agent dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionAgentDimensionMetadata { /** * Optional. The agent's deployment display name. Only applicable to * automated agents. This will be populated for AGENT_DEPLOYMENT_ID * dimensions. */ agentDeploymentDisplayName?: string; /** * Optional. The agent's deployment ID. Only applicable to automated agents. * This will be populated for AGENT and AGENT_DEPLOYMENT_ID dimensions. */ agentDeploymentId?: string; /** * Optional. The agent's name This will be populated for AGENT, AGENT_TEAM, * AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID dimensions. */ agentDisplayName?: string; /** * Optional. A user-specified string representing the agent. This will be * populated for AGENT, AGENT_TEAM, AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentId?: string; /** * Optional. A user-specified string representing the agent's team. */ agentTeam?: string; /** * Optional. The agent's version display name. Only applicable to automated * agents. This will be populated for AGENT_VERSION_ID, and * AGENT_DEPLOYMENT_ID dimensions. */ agentVersionDisplayName?: string; /** * Optional. The agent's version ID. Only applicable to automated agents. * This will be populated for AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentVersionId?: string; } /** * Metadata about the client sentiment category dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionClientSentimentCategoryDimensionMetadata { /** * Optional. The client sentiment category. */ sentimentCategory?: string; } /** * Metadata about the Conversational Agents playbook dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionConversationalAgentsPlaybookDimensionMetadata { /** * Optional. The dialogflow playbook display name. */ playbookDisplayName?: string; /** * Optional. The dialogflow playbook ID. */ playbookId?: string; } /** * Metadata about the Conversational Agents tool dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionConversationalAgentsToolDimensionMetadata { /** * Optional. The dialogflow tool display name. */ toolDisplayName?: string; /** * Optional. The dialogflow tool ID. */ toolId?: string; } /** * Metadata about the conversation profile dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionConversationProfileDimensionMetadata { /** * Optional. The conversation profile ID. */ conversationProfileId?: string; } /** * Metadata about the issue dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionIssueDimensionMetadata { /** * The issue display name. */ issueDisplayName?: string; /** * The issue ID. */ issueId?: string; /** * The parent issue model ID. */ issueModelId?: string; } /** * Metadata about conversation labels. */ export interface GoogleCloudContactcenterinsightsV1DimensionLabelDimensionMetadata { /** * Optional. The label key. */ labelKey?: string; /** * Optional. The label value. */ labelValue?: string; } /** * Metadata about the conversation medium dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionMediumDimensionMetadata { /** * Optional. The conversation medium. Currently supports : PHONE_CALL, CHAT. */ medium?: string; } /** * Metadata about the QA question-answer dimension. This is useful for showing * the answer distribution for questions for a given scorecard. */ export interface GoogleCloudContactcenterinsightsV1DimensionQaQuestionAnswerDimensionMetadata { /** * Optional. The full body of the question. */ answerValue?: string; /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA question dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionQaQuestionDimensionMetadata { /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA scorecard dimension. */ export interface GoogleCloudContactcenterinsightsV1DimensionQaScorecardDimensionMetadata { /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; } /** * A customer-managed encryption key specification that can be applied to all * created resources (e.g. `Conversation`). */ export interface GoogleCloudContactcenterinsightsV1EncryptionSpec { /** * Required. The name of customer-managed encryption key that is used to * secure a resource and its sub-resources. If empty, the resource is secured * by our default encryption key. Only the key in the same location as this * resource is allowed to be used for encryption. Format: * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{key}` */ kmsKey?: string; /** * Immutable. The resource name of the encryption key specification resource. * Format: projects/{project}/locations/{location}/encryptionSpec */ name?: string; } /** * The data for an entity annotation. Represents a phrase in the conversation * that is a known entity, such as a person, an organization, or location. */ export interface GoogleCloudContactcenterinsightsV1Entity { /** * The representative name for the entity. */ displayName?: string; /** * Metadata associated with the entity. For most entity types, the metadata * is a Wikipedia URL (`wikipedia_url`) and Knowledge Graph MID (`mid`), if * they are available. For the metadata associated with other entity types, * see the Type table below. */ metadata?: { [key: string]: string }; /** * The salience score associated with the entity in the [0, 1.0] range. The * salience score for an entity provides information about the importance or * centrality of that entity to the entire document text. Scores closer to 0 * are less salient, while scores closer to 1.0 are highly salient. */ salience?: number; /** * The aggregate sentiment expressed for this entity in the conversation. */ sentiment?: GoogleCloudContactcenterinsightsV1SentimentData; /** * The entity type. */ type?: | "TYPE_UNSPECIFIED" | "PERSON" | "LOCATION" | "ORGANIZATION" | "EVENT" | "WORK_OF_ART" | "CONSUMER_GOOD" | "OTHER" | "PHONE_NUMBER" | "ADDRESS" | "DATE" | "NUMBER" | "PRICE"; } /** * The data for an entity mention annotation. This represents a mention of an * `Entity` in the conversation. */ export interface GoogleCloudContactcenterinsightsV1EntityMentionData { /** * The key of this entity in conversation entities. Can be used to retrieve * the exact `Entity` this mention is attached to. */ entityUniqueId?: string; /** * Sentiment expressed for this mention of the entity. */ sentiment?: GoogleCloudContactcenterinsightsV1SentimentData; /** * The type of the entity mention. */ type?: | "MENTION_TYPE_UNSPECIFIED" | "PROPER" | "COMMON"; } /** * Exact match configuration. */ export interface GoogleCloudContactcenterinsightsV1ExactMatchConfig { /** * Whether to consider case sensitivity when performing an exact match. */ caseSensitive?: boolean; } /** * Metadata for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1ExportInsightsDataMetadata { /** * The number of conversations that were exported successfully. */ completedExportCount?: number; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The number of conversations that failed to be exported. */ failedExportCount?: number; /** * Partial errors during export operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for export. */ request?: GoogleCloudContactcenterinsightsV1ExportInsightsDataRequest; } /** * The request to export insights. */ export interface GoogleCloudContactcenterinsightsV1ExportInsightsDataRequest { /** * Specified if sink is a BigQuery table. */ bigQueryDestination?: GoogleCloudContactcenterinsightsV1ExportInsightsDataRequestBigQueryDestination; /** * Optional. Version of the export schema. */ exportSchemaVersion?: | "EXPORT_SCHEMA_VERSION_UNSPECIFIED" | "EXPORT_V1" | "EXPORT_V2" | "EXPORT_V3" | "EXPORT_V4" | "EXPORT_V5" | "EXPORT_V6" | "EXPORT_V7" | "EXPORT_V8" | "EXPORT_V9" | "EXPORT_V10" | "EXPORT_V11" | "EXPORT_V12" | "EXPORT_V13" | "EXPORT_V14" | "EXPORT_VERSION_LATEST_AVAILABLE"; /** * A filter to reduce results to a specific subset. Useful for exporting * conversations with specific properties. */ filter?: string; /** * A fully qualified KMS key name for BigQuery tables protected by CMEK. * Format: * projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}/cryptoKeyVersions/{version} */ kmsKey?: string; /** * Required. The parent resource to export data from. */ parent?: string; /** * Options for what to do if the destination table already exists. */ writeDisposition?: | "WRITE_DISPOSITION_UNSPECIFIED" | "WRITE_TRUNCATE" | "WRITE_APPEND"; } /** * A BigQuery Table Reference. */ export interface GoogleCloudContactcenterinsightsV1ExportInsightsDataRequestBigQueryDestination { /** * Required. The name of the BigQuery dataset that the snapshot result should * be exported to. If this dataset does not exist, the export call returns an * INVALID_ARGUMENT error. */ dataset?: string; /** * A project ID or number. If specified, then export will attempt to write * data to this project instead of the resource project. Otherwise, the * resource project will be used. */ projectId?: string; /** * The BigQuery table name to which the insights data should be written. If * this table does not exist, the export call returns an INVALID_ARGUMENT * error. */ table?: string; } /** * Response for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1ExportInsightsDataResponse { } /** * Metadata used for export issue model. */ export interface GoogleCloudContactcenterinsightsV1ExportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original export request. */ request?: GoogleCloudContactcenterinsightsV1ExportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1ExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1ExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1ExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to export an issue model. */ export interface GoogleCloudContactcenterinsightsV1ExportIssueModelRequest { /** * Google Cloud Storage URI to export the issue model to. */ gcsDestination?: GoogleCloudContactcenterinsightsV1ExportIssueModelRequestGcsDestination; /** * Required. The issue model to export. */ name?: string; } /** * Google Cloud Storage Object URI to save the issue model to. */ export interface GoogleCloudContactcenterinsightsV1ExportIssueModelRequestGcsDestination { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from export issue model */ export interface GoogleCloudContactcenterinsightsV1ExportIssueModelResponse { } /** * Agent Assist frequently-asked-question answer data. */ export interface GoogleCloudContactcenterinsightsV1FaqAnswerData { /** * The piece of text from the `source` knowledge base document. */ answer?: string; /** * The system's confidence score that this answer is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the FAQ answer and the document that it * originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The corresponding FAQ question. */ question?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document}. */ source?: string; } /** * Represents a conversation, resource, and label provided by the user. Can * take the form of a string label or a QaAnswer label. QaAnswer labels are used * for Quality AI example conversations. String labels are used for Topic * Modeling. AgentAssistSummary labels are used for Agent Assist Summarization. */ export interface GoogleCloudContactcenterinsightsV1FeedbackLabel { /** * Output only. Create time of the label. */ readonly createTime?: Date; /** * String label used for Topic Modeling. */ label?: string; /** * Name of the resource to be labeled. Supported resources are: * * `projects/{project}/locations/{location}/qaScorecards/{scorecard}/revisions/{revision}/qaQuestions/{question}` * * `projects/{project}/locations/{location}/issueModels/{issue_model}` * * `projects/{project}/locations/{location}/generators/{generator_id}` */ labeledResource?: string; /** * Immutable. Resource name of the FeedbackLabel. Format: * projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ name?: string; /** * QaAnswer label used for Quality AI example conversations. */ qaAnswerLabel?: GoogleCloudContactcenterinsightsV1QaAnswerAnswerValue; /** * Output only. Update time of the label. */ readonly updateTime?: Date; } /** * The message to finalize an assessment. Finalizing makes an assessment and * its notes immutable. */ export interface GoogleCloudContactcenterinsightsV1FinalizeAssessmentRequest { } /** * A Cloud Storage source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1GcsSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Immutable. Cloud Storage URI that points to a file that contains the * conversation transcript. */ transcriptUri?: string; } /** * The data for a hold annotation. */ export interface GoogleCloudContactcenterinsightsV1HoldData { } /** * Metadata used for import issue model. */ export interface GoogleCloudContactcenterinsightsV1ImportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original import request. */ request?: GoogleCloudContactcenterinsightsV1ImportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1ImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1ImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1ImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to import an issue model. */ export interface GoogleCloudContactcenterinsightsV1ImportIssueModelRequest { /** * Optional. If set to true, will create an issue model from the imported * file with randomly generated IDs for the issue model and corresponding * issues. Otherwise, replaces an existing model with the same ID as the file. */ createNewModel?: boolean; /** * Google Cloud Storage source message. */ gcsSource?: GoogleCloudContactcenterinsightsV1ImportIssueModelRequestGcsSource; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * Google Cloud Storage Object URI to get the issue model file from. */ export interface GoogleCloudContactcenterinsightsV1ImportIssueModelRequestGcsSource { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from import issue model */ export interface GoogleCloudContactcenterinsightsV1ImportIssueModelResponse { /** * The issue model that was imported. */ issueModel?: GoogleCloudContactcenterinsightsV1IssueModel; } /** * The metadata for an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Statistics for IngestConversations operation. */ readonly ingestConversationsStats?: GoogleCloudContactcenterinsightsV1IngestConversationsMetadataIngestConversationsStats; /** * Output only. Partial errors during ingest operation that might cause the * operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for ingest. */ readonly request?: GoogleCloudContactcenterinsightsV1IngestConversationsRequest; /** * Output only. Stores the conversation resources produced by ingest sampling * operations. */ readonly sampledConversations?: string[]; } /** * Statistics for IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsMetadataIngestConversationsStats { /** * Output only. The number of objects skipped because another conversation * with the same transcript uri had already been ingested. */ readonly duplicatesSkippedCount?: number; /** * Output only. The number of objects which were unable to be ingested due to * errors. The errors are populated in the partial_errors field. */ readonly failedIngestCount?: number; /** * Output only. The number of objects processed during the ingest operation. */ readonly processedObjectCount?: number; /** * Output only. The number of new conversations added during this ingest * operation. */ readonly successfulIngestCount?: number; } /** * The request to ingest conversations. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsRequest { /** * Configuration that applies to all conversations. */ conversationConfig?: GoogleCloudContactcenterinsightsV1IngestConversationsRequestConversationConfig; /** * A cloud storage bucket source. Note that any previously ingested objects * from the source will be skipped to avoid duplication. */ gcsSource?: GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource; /** * Required. The parent resource for new conversations. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Optional, will default to * the config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1RedactionConfig; /** * Optional. If set, this fields indicates the number of objects to ingest * from the Cloud Storage bucket. If empty, the entire bucket will be * ingested. Unless they are first deleted, conversations produced through * sampling won't be ingested by subsequent ingest requests. */ sampleSize?: number; /** * Optional. Default Speech-to-Text configuration. Optional, will default to * the config specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1SpeechConfig; /** * Configuration for when `source` contains conversation transcripts. */ transcriptObjectConfig?: GoogleCloudContactcenterinsightsV1IngestConversationsRequestTranscriptObjectConfig; } /** * Configuration that applies to all conversations. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsRequestConversationConfig { /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ agentChannel?: number; /** * Optional. An opaque, user-specified string representing a human agent who * handled all conversations in the import. Note that this will be overridden * if per-conversation metadata is provided through the `metadata_bucket_uri`. */ agentId?: string; /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ customerChannel?: number; } /** * Configuration for Cloud Storage bucket sources. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource { /** * Optional. The Cloud Storage path to the conversation audio file. Note * that: [1] Audio files will be transcribed if not already. [2] Audio files * and transcript files must be in separate buckets / folders. [3] A source * file and its corresponding audio file must share the same name to be * properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and * `gs://bucket/audio/conversation1.mp3`. */ audioBucketUri?: string; /** * Optional. Specifies the type of the objects in `bucket_uri`. Avoid passing * this. This is inferred from the `transcript_bucket_uri`, * `audio_bucket_uri`. */ bucketObjectType?: | "BUCKET_OBJECT_TYPE_UNSPECIFIED" | "TRANSCRIPT" | "AUDIO"; /** * Optional. The Cloud Storage bucket containing source objects. Avoid * passing this. Pass this through one of `transcript_bucket_uri` or * `audio_bucket_uri`. */ bucketUri?: string; /** * Optional. Custom keys to extract as conversation labels from metadata * files in `metadata_bucket_uri`. Keys not included in this field will be * ignored. Note that there is a limit of 100 labels per conversation. */ customMetadataKeys?: string[]; /** * Optional. The Cloud Storage path to the conversation metadata. Note that: * [1] Metadata files are expected to be in JSON format. [2] Metadata and * source files (transcripts or audio) must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ metadataBucketUri?: string; /** * Optional. The Cloud Storage path to the conversation transcripts. Note * that: [1] Transcript files are expected to be in JSON format. [2] * Transcript, audio, metadata files must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ transcriptBucketUri?: string; } /** * Configuration for processing transcript objects. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsRequestTranscriptObjectConfig { /** * Required. The medium transcript objects represent. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; } /** * The response to an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1IngestConversationsResponse { } /** * Metadata for initializing a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1InitializeEncryptionSpecMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Partial errors during initializing operation that might cause the * operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for initialization. */ readonly request?: GoogleCloudContactcenterinsightsV1InitializeEncryptionSpecRequest; } /** * The request to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1InitializeEncryptionSpecRequest { /** * Required. The encryption spec used for CMEK encryption. It is required * that the kms key is in the same region as the endpoint. The same key will * be used for all provisioned resources, if encryption is available. If the * `kms_key_name` field is left empty, no encryption will be enforced. */ encryptionSpec?: GoogleCloudContactcenterinsightsV1EncryptionSpec; } /** * The response to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1InitializeEncryptionSpecResponse { } /** * The data for an intent. Represents a detected intent in the conversation, * for example MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1Intent { /** * The human-readable name of the intent. */ displayName?: string; /** * The unique identifier of the intent. */ id?: string; } /** * The data for an intent match. Represents an intent match for a text segment * in the conversation. A text segment can be part of a sentence, a complete * sentence, or an utterance with multiple sentences. */ export interface GoogleCloudContactcenterinsightsV1IntentMatchData { /** * The id of the matched intent. Can be used to retrieve the corresponding * intent information. */ intentUniqueId?: string; } /** * The data for an interruption annotation. */ export interface GoogleCloudContactcenterinsightsV1InterruptionData { } /** * The issue resource. */ export interface GoogleCloudContactcenterinsightsV1Issue { /** * Output only. The time at which this issue was created. */ readonly createTime?: Date; /** * Representative description of the issue. */ displayDescription?: string; /** * The representative name for the issue. */ displayName?: string; /** * Immutable. The resource name of the issue. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ name?: string; /** * Output only. Resource names of the sample representative utterances that * match to this issue. */ readonly sampleUtterances?: string[]; /** * Output only. The most recent time that this issue was updated. */ readonly updateTime?: Date; } /** * Information about the issue. */ export interface GoogleCloudContactcenterinsightsV1IssueAssignment { /** * Immutable. Display name of the assigned issue. This field is set at time * of analysis and immutable since then. */ displayName?: string; /** * Resource name of the assigned issue. */ issue?: string; /** * Score indicating the likelihood of the issue assignment. currently bounded * on [0,1]. */ score?: number; } /** * The data for an issue match annotation. */ export interface GoogleCloudContactcenterinsightsV1IssueMatchData { /** * Information about the issue's assignment. */ issueAssignment?: GoogleCloudContactcenterinsightsV1IssueAssignment; } /** * The issue model resource. */ export interface GoogleCloudContactcenterinsightsV1IssueModel { /** * Output only. The time at which this issue model was created. */ readonly createTime?: Date; /** * The representative name for the issue model. */ displayName?: string; /** * Configs for the input data that used to create the issue model. */ inputDataConfig?: GoogleCloudContactcenterinsightsV1IssueModelInputDataConfig; /** * Output only. Number of issues in this issue model. */ readonly issueCount?: bigint; /** * Language of the model. */ languageCode?: string; /** * Type of the model. */ modelType?: | "MODEL_TYPE_UNSPECIFIED" | "TYPE_V1" | "TYPE_V2"; /** * Immutable. The resource name of the issue model. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ name?: string; /** * Output only. State of the model. */ readonly state?: | "STATE_UNSPECIFIED" | "UNDEPLOYED" | "DEPLOYING" | "DEPLOYED" | "UNDEPLOYING" | "DELETING"; /** * Output only. Immutable. The issue model's label statistics on its training * data. */ readonly trainingStats?: GoogleCloudContactcenterinsightsV1IssueModelLabelStats; /** * Output only. The most recent time at which the issue model was updated. */ readonly updateTime?: Date; } /** * Configs for the input data used to create the issue model. */ export interface GoogleCloudContactcenterinsightsV1IssueModelInputDataConfig { /** * A filter to reduce the conversations used for training the model to a * specific subset. Refer to * https://cloud.google.com/contact-center/insights/docs/filtering for * details. */ filter?: string; /** * Medium of conversations used in training data. This field is being * deprecated. To specify the medium to be used in training a new issue model, * set the `medium` field on `filter`. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Output only. Number of conversations used in training. Output only. */ readonly trainingConversationsCount?: bigint; } /** * Aggregated statistics about an issue model. */ export interface GoogleCloudContactcenterinsightsV1IssueModelLabelStats { /** * Number of conversations the issue model has analyzed at this point in * time. */ analyzedConversationsCount?: bigint; /** * Statistics on each issue. Key is the issue's resource name. */ issueStats?: { [key: string]: GoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats }; /** * Number of analyzed conversations for which no issue was applicable at this * point in time. */ unclassifiedConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1IssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1IssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? String(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, serializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? String(data["unclassifiedConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1IssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1IssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? BigInt(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, deserializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? BigInt(data["unclassifiedConversationsCount"]) : undefined, }; } /** * Aggregated statistics about an issue. */ export interface GoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats { /** * Display name of the issue. */ displayName?: string; /** * Issue resource. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ issue?: string; /** * Number of conversations attached to the issue at this point in time. */ labeledConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? String(data["labeledConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1IssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? BigInt(data["labeledConversationsCount"]) : undefined, }; } /** * Issue Modeling result on a conversation. */ export interface GoogleCloudContactcenterinsightsV1IssueModelResult { /** * Issue model that generates the result. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ issueModel?: string; /** * All the matched issues. */ issues?: GoogleCloudContactcenterinsightsV1IssueAssignment[]; } /** * The response for listing all feedback labels. */ export interface GoogleCloudContactcenterinsightsV1ListAllFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1FeedbackLabel[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response to list analyses. */ export interface GoogleCloudContactcenterinsightsV1ListAnalysesResponse { /** * The analyses that match the request. */ analyses?: GoogleCloudContactcenterinsightsV1Analysis[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response of listing views. */ export interface GoogleCloudContactcenterinsightsV1ListAnalysisRulesResponse { /** * The analysis_rule that match the request. */ analysisRules?: GoogleCloudContactcenterinsightsV1AnalysisRule[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response of listing assessment rules. */ export interface GoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse { /** * The assessment rules that match the request. */ assessmentRules?: GoogleCloudContactcenterinsightsV1AssessmentRule[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } function serializeGoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse(data: any): GoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse { return { ...data, assessmentRules: data["assessmentRules"] !== undefined ? data["assessmentRules"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1AssessmentRule(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse(data: any): GoogleCloudContactcenterinsightsV1ListAssessmentRulesResponse { return { ...data, assessmentRules: data["assessmentRules"] !== undefined ? data["assessmentRules"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1AssessmentRule(item))) : undefined, }; } /** * The response of listing assessments. */ export interface GoogleCloudContactcenterinsightsV1ListAssessmentsResponse { /** * The assessments that match the request. */ assessments?: GoogleCloudContactcenterinsightsV1Assessment[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response from a ListAuthorizedViewSet request. */ export interface GoogleCloudContactcenterinsightsV1ListAuthorizedViewSetsResponse { /** * The AuthorizedViewSets under the parent. */ authorizedViewSets?: GoogleCloudContactcenterinsightsV1AuthorizedViewSet[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response from a ListAuthorizedViews request. */ export interface GoogleCloudContactcenterinsightsV1ListAuthorizedViewsResponse { /** * The AuthorizedViews under the parent. */ authorizedViews?: GoogleCloudContactcenterinsightsV1AuthorizedView[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response of listing conversations. */ export interface GoogleCloudContactcenterinsightsV1ListConversationsResponse { /** * The conversations that match the request. */ conversations?: GoogleCloudContactcenterinsightsV1Conversation[]; /** * A token which can be sent as `page_token` to retrieve the next page. If * this field is set, it means there is another page available. If it is not * set, it means no other pages are available. */ nextPageToken?: string; } function serializeGoogleCloudContactcenterinsightsV1ListConversationsResponse(data: any): GoogleCloudContactcenterinsightsV1ListConversationsResponse { return { ...data, conversations: data["conversations"] !== undefined ? data["conversations"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1Conversation(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ListConversationsResponse(data: any): GoogleCloudContactcenterinsightsV1ListConversationsResponse { return { ...data, conversations: data["conversations"] !== undefined ? data["conversations"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1Conversation(item))) : undefined, }; } /** * The response to list datasets. */ export interface GoogleCloudContactcenterinsightsV1ListDatasetsResponse { /** * The datasets that match the request. */ datasets?: GoogleCloudContactcenterinsightsV1Dataset[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } function serializeGoogleCloudContactcenterinsightsV1ListDatasetsResponse(data: any): GoogleCloudContactcenterinsightsV1ListDatasetsResponse { return { ...data, datasets: data["datasets"] !== undefined ? data["datasets"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1Dataset(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ListDatasetsResponse(data: any): GoogleCloudContactcenterinsightsV1ListDatasetsResponse { return { ...data, datasets: data["datasets"] !== undefined ? data["datasets"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1Dataset(item))) : undefined, }; } /** * The response for listing feedback labels. */ export interface GoogleCloudContactcenterinsightsV1ListFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1FeedbackLabel[]; /** * The next page token. */ nextPageToken?: string; } /** * The response of listing issue models. */ export interface GoogleCloudContactcenterinsightsV1ListIssueModelsResponse { /** * The issue models that match the request. */ issueModels?: GoogleCloudContactcenterinsightsV1IssueModel[]; } /** * The response of listing issues. */ export interface GoogleCloudContactcenterinsightsV1ListIssuesResponse { /** * The issues that match the request. */ issues?: GoogleCloudContactcenterinsightsV1Issue[]; } /** * The response of listing notes. */ export interface GoogleCloudContactcenterinsightsV1ListNotesResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The notes that match the request. */ notes?: GoogleCloudContactcenterinsightsV1Note[]; } /** * The response of listing phrase matchers. */ export interface GoogleCloudContactcenterinsightsV1ListPhraseMatchersResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The phrase matchers that match the request. */ phraseMatchers?: GoogleCloudContactcenterinsightsV1PhraseMatcher[]; } /** * The response from a ListQaQuestions request. */ export interface GoogleCloudContactcenterinsightsV1ListQaQuestionsResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The QaQuestions under the parent. */ qaQuestions?: GoogleCloudContactcenterinsightsV1QaQuestion[]; } function serializeGoogleCloudContactcenterinsightsV1ListQaQuestionsResponse(data: any): GoogleCloudContactcenterinsightsV1ListQaQuestionsResponse { return { ...data, qaQuestions: data["qaQuestions"] !== undefined ? data["qaQuestions"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1QaQuestion(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ListQaQuestionsResponse(data: any): GoogleCloudContactcenterinsightsV1ListQaQuestionsResponse { return { ...data, qaQuestions: data["qaQuestions"] !== undefined ? data["qaQuestions"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1QaQuestion(item))) : undefined, }; } /** * The response from a ListQaQuestionTags request. */ export interface GoogleCloudContactcenterinsightsV1ListQaQuestionTagsResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The parent resource of the questions. */ qaQuestionTags?: GoogleCloudContactcenterinsightsV1QaQuestionTag[]; } /** * The response from a ListQaScorecardRevisions request. */ export interface GoogleCloudContactcenterinsightsV1ListQaScorecardRevisionsResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The QaScorecards under the parent. */ qaScorecardRevisions?: GoogleCloudContactcenterinsightsV1QaScorecardRevision[]; } /** * The response from a ListQaScorecards request. */ export interface GoogleCloudContactcenterinsightsV1ListQaScorecardsResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The QaScorecards under the parent. */ qaScorecards?: GoogleCloudContactcenterinsightsV1QaScorecard[]; } /** * The response of listing views. */ export interface GoogleCloudContactcenterinsightsV1ListViewsResponse { /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; /** * The views that match the request. */ views?: GoogleCloudContactcenterinsightsV1View[]; } /** * The analysis resource. */ export interface GoogleCloudContactcenterinsightsV1mainAnalysis { /** * Output only. The result of the analysis, which is populated when the * analysis finishes. */ readonly analysisResult?: GoogleCloudContactcenterinsightsV1mainAnalysisResult; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelector; /** * Output only. The time at which the analysis was created, which occurs when * the long-running operation completes. */ readonly createTime?: Date; /** * Immutable. The resource name of the analysis. Format: * projects/{project}/locations/{location}/conversations/{conversation}/analyses/{analysis} */ name?: string; /** * Output only. The time at which the analysis was requested. */ readonly requestTime?: Date; } /** * The result of an analysis. */ export interface GoogleCloudContactcenterinsightsV1mainAnalysisResult { /** * Call-specific metadata created by the analysis. */ callAnalysisMetadata?: GoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata; /** * The time at which the analysis ended. */ endTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1mainAnalysisResult(data: any): GoogleCloudContactcenterinsightsV1mainAnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainAnalysisResult(data: any): GoogleCloudContactcenterinsightsV1mainAnalysisResult { return { ...data, callAnalysisMetadata: data["callAnalysisMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata(data["callAnalysisMetadata"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Call-specific metadata created during analysis. */ export interface GoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata { /** * A list of call annotations that apply to this call. */ annotations?: GoogleCloudContactcenterinsightsV1mainCallAnnotation[]; /** * All the entities in the call. */ entities?: { [key: string]: GoogleCloudContactcenterinsightsV1mainEntity }; /** * All the matched intents in the call. */ intents?: { [key: string]: GoogleCloudContactcenterinsightsV1mainIntent }; /** * Overall conversation-level issue modeling result. */ issueModelResult?: GoogleCloudContactcenterinsightsV1mainIssueModelResult; /** * All the matched phrase matchers in the call. */ phraseMatchers?: { [key: string]: GoogleCloudContactcenterinsightsV1mainPhraseMatchData }; /** * Results of scoring QaScorecards. */ qaScorecardResults?: GoogleCloudContactcenterinsightsV1mainQaScorecardResult[]; /** * Overall conversation-level sentiment for each channel of the call. */ sentiments?: GoogleCloudContactcenterinsightsV1mainConversationLevelSentiment[]; /** * Overall conversation-level silence during the call. */ silence?: GoogleCloudContactcenterinsightsV1mainConversationLevelSilence; } function serializeGoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainConversationLevelSilence(data["silence"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata(data: any): GoogleCloudContactcenterinsightsV1mainAnalysisResultCallAnalysisMetadata { return { ...data, silence: data["silence"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainConversationLevelSilence(data["silence"]) : undefined, }; } /** * A point in a conversation that marks the start or the end of an annotation. */ export interface GoogleCloudContactcenterinsightsV1mainAnnotationBoundary { /** * The index in the sequence of transcribed pieces of the conversation where * the boundary is located. This index starts at zero. */ transcriptIndex?: number; /** * The word index of this boundary with respect to the first word in the * transcript piece. This index starts at zero. */ wordIndex?: number; } /** * Selector of all available annotators and phrase matchers to run. */ export interface GoogleCloudContactcenterinsightsV1mainAnnotatorSelector { /** * The issue model to run. If not provided, the most recently deployed topic * model will be used. The provided issue model will only be used for * inference if the issue model is deployed and if run_issue_model_annotator * is set to true. If more than one issue model is provided, only the first * provided issue model will be used for inference. */ issueModels?: string[]; /** * The list of phrase matchers to run. If not provided, all active phrase * matchers will be used. If inactive phrase matchers are provided, they will * not be used. Phrase matchers will be run only if * run_phrase_matcher_annotator is set to true. Format: * projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher} */ phraseMatchers?: string[]; /** * Configuration for the QA annotator. */ qaConfig?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorQaConfig; /** * Whether to run the entity annotator. */ runEntityAnnotator?: boolean; /** * Whether to run the intent annotator. */ runIntentAnnotator?: boolean; /** * Whether to run the interruption annotator. */ runInterruptionAnnotator?: boolean; /** * Whether to run the issue model annotator. A model should have already been * deployed for this to take effect. */ runIssueModelAnnotator?: boolean; /** * Whether to run the active phrase matcher annotator(s). */ runPhraseMatcherAnnotator?: boolean; /** * Whether to run the QA annotator. */ runQaAnnotator?: boolean; /** * Whether to run the sentiment annotator. */ runSentimentAnnotator?: boolean; /** * Whether to run the silence annotator. */ runSilenceAnnotator?: boolean; /** * Whether to run the summarization annotator. */ runSummarizationAnnotator?: boolean; /** * Configuration for the summarization annotator. */ summarizationConfig?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorSummarizationConfig; } /** * Configuration for the QA feature. */ export interface GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorQaConfig { /** * A manual list of scorecards to score. */ scorecardList?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorQaConfigScorecardList; } /** * Container for a list of scorecards. */ export interface GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorQaConfigScorecardList { /** * List of QaScorecardRevisions. */ qaScorecardRevisions?: string[]; } /** * Configuration for summarization. */ export interface GoogleCloudContactcenterinsightsV1mainAnnotatorSelectorSummarizationConfig { /** * Resource name of the Dialogflow conversation profile. Format: * projects/{project}/locations/{location}/conversationProfiles/{conversation_profile} */ conversationProfile?: string; /** * The resource name of the existing created generator. Format: * projects//locations//generators/ */ generator?: string; /** * Default summarization model to be used. */ summarizationModel?: | "SUMMARIZATION_MODEL_UNSPECIFIED" | "BASELINE_MODEL" | "BASELINE_MODEL_V2_0"; } /** * The feedback that the customer has about a certain answer in the * conversation. */ export interface GoogleCloudContactcenterinsightsV1mainAnswerFeedback { /** * Indicates whether an answer or item was clicked by the human agent. */ clicked?: boolean; /** * The correctness level of an answer. */ correctnessLevel?: | "CORRECTNESS_LEVEL_UNSPECIFIED" | "NOT_CORRECT" | "PARTIALLY_CORRECT" | "FULLY_CORRECT"; /** * Indicates whether an answer or item was displayed to the human agent in * the agent desktop UI. */ displayed?: boolean; } /** * Agent Assist Article Suggestion data. */ export interface GoogleCloudContactcenterinsightsV1mainArticleSuggestionData { /** * The system's confidence score that this article is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Article Suggestion and the document * that it originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document} */ source?: string; /** * Article title. */ title?: string; /** * Article URI. */ uri?: string; } /** * The metadata for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsMetadata { /** * The number of requested analyses that have completed successfully so far. */ completedAnalysesCount?: number; /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The number of requested analyses that have failed so far. */ failedAnalysesCount?: number; /** * Output only. Partial errors during bulk analyze operation that might cause * the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk analyze. */ request?: GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsRequest; /** * Total number of analyses requested. Computed by the number of * conversations returned by `filter` multiplied by `analysis_percentage` in * the request. */ totalRequestedAnalysesCount?: number; } function serializeGoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to analyze conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsRequest { /** * Required. Percentage of selected conversation to analyze, between [0, * 100]. */ analysisPercentage?: number; /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelector; /** * Required. Filter used to select the subset of conversations to analyze. */ filter?: string; /** * Required. The parent resource to create analyses in. */ parent?: string; } /** * The response for a bulk analyze conversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainBulkAnalyzeConversationsResponse { /** * Count of failed analyses. */ failedAnalysisCount?: number; /** * Count of successful analyses. */ successfulAnalysisCount?: number; } /** * The metadata for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * Partial errors during bulk delete conversations operation that might cause * the operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for bulk delete. */ request?: GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsRequest; } function serializeGoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsMetadata(data: any): GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * The request to delete conversations in bulk. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsRequest { /** * Filter used to select the subset of conversations to delete. */ filter?: string; /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; /** * Maximum number of conversations to delete. */ maxDeleteCount?: number; /** * Required. The parent resource to delete conversations from. Format: * projects/{project}/locations/{location} */ parent?: string; } /** * The response for a bulk delete conversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteConversationsResponse { } /** * Metadata for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteFeedbackLabelsMetadata { /** * Partial errors during deletion operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for delete. */ readonly request?: GoogleCloudContactcenterinsightsV1mainBulkDeleteFeedbackLabelsRequest; } /** * Request for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteFeedbackLabelsRequest { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Supported fields: * * `issue_model_id` * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Required. The parent resource for new feedback labels. */ parent?: string; } /** * Response for the BulkDeleteFeedbackLabels endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDeleteFeedbackLabelsResponse { } /** * Metadata for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. Statistics for BulkDownloadFeedbackLabels operation. */ readonly downloadStats?: GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsMetadataDownloadStats; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Partial errors during ingest operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for download. */ readonly request?: GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest; } /** * Statistics for BulkDownloadFeedbackLabels operation. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsMetadataDownloadStats { /** * Output only. Full name of the files written to Cloud storage. */ readonly fileNames?: string[]; /** * The number of objects processed during the download operation. */ processedObjectCount?: number; /** * The number of new feedback labels downloaded during this operation. * Different from "processed" because some labels might not be downloaded * because an error. */ successfulDownloadCount?: number; /** * Total number of files written to the provided Cloud Storage bucket. */ totalFilesWritten?: number; } /** * Request for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest { /** * Optional. Filter parent conversations to download feedback labels for. * When specified, the feedback labels will be downloaded for the * conversations that match the filter. If `template_qa_scorecard_id` is set, * all the conversations that match the filter will be paired with the * questions under the scorecard for labeling. */ conversationFilter?: string; /** * Optional. The type of feedback labels that will be downloaded. */ feedbackLabelType?: | "FEEDBACK_LABEL_TYPE_UNSPECIFIED" | "QUALITY_AI" | "TOPIC_MODELING" | "AGENT_ASSIST_SUMMARY"; /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Supported fields: * * `issue_model_id` * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * A cloud storage bucket destination. */ gcsDestination?: GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination; /** * Optional. Limits the maximum number of feedback labels that will be * downloaded. The first `N` feedback labels will be downloaded. */ maxDownloadCount?: number; /** * Required. The parent resource for new feedback labels. */ parent?: string; /** * A sheets document destination. */ sheetsDestination?: GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestSheetsDestination; /** * Optional. If set, a template for labeling conversations and scorecard * questions will be created from the conversation_filter and the questions * under the scorecard(s). The feedback label `filter` will be ignored. */ templateQaScorecardId?: string[]; } function serializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest(data: any): GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest { return { ...data, gcsDestination: data["gcsDestination"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination(data["gcsDestination"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest(data: any): GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequest { return { ...data, gcsDestination: data["gcsDestination"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination(data["gcsDestination"]) : undefined, }; } /** * Google Cloud Storage Object details to write the feedback labels to. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination { /** * Optional. Add whitespace to the JSON file. Makes easier to read, but * increases file size. Only applicable for JSON format. */ addWhitespace?: boolean; /** * Optional. Always print fields with no presence. This is useful for * printing fields that are not set, like implicit 0 value or empty * lists/maps. Only applicable for JSON format. */ alwaysPrintEmptyFields?: boolean; /** * Required. File format in which the labels will be exported. */ format?: | "FORMAT_UNSPECIFIED" | "CSV" | "JSON"; /** * Required. The Google Cloud Storage URI to write the feedback labels to. * The file name will be used as a prefix for the files written to the bucket * if the output needs to be split across multiple files, otherwise it will be * used as is. The file extension will be appended to the file name based on * the format selected. E.g. `gs://bucket_name/object_uri_prefix` */ objectUri?: string; /** * Optional. The number of records per file. Applicable for either format. */ recordsPerFileCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination(data: any): GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination { return { ...data, recordsPerFileCount: data["recordsPerFileCount"] !== undefined ? String(data["recordsPerFileCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination(data: any): GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestGcsDestination { return { ...data, recordsPerFileCount: data["recordsPerFileCount"] !== undefined ? BigInt(data["recordsPerFileCount"]) : undefined, }; } /** * Google Sheets document details to write the feedback labels to. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsRequestSheetsDestination { /** * Optional. The title of the new sheet to write the feedback labels to. */ sheetTitle?: string; /** * Required. The Google Sheets document to write the feedback labels to. * Retrieved from Google Sheets URI. E.g. * `https://docs.google.com/spreadsheets/d/1234567890` The spreadsheet must be * shared with the Insights P4SA. The spreadsheet ID written to will be * returned as `file_names` in the BulkDownloadFeedbackLabelsMetadata. */ spreadsheetUri?: string; } /** * Response for the BulkDownloadFeedbackLabel endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainBulkDownloadFeedbackLabelsResponse { } /** * A piece of metadata that applies to a window of a call. */ export interface GoogleCloudContactcenterinsightsV1mainCallAnnotation { /** * The boundary in the conversation where the annotation ends, inclusive. */ annotationEndBoundary?: GoogleCloudContactcenterinsightsV1mainAnnotationBoundary; /** * The boundary in the conversation where the annotation starts, inclusive. */ annotationStartBoundary?: GoogleCloudContactcenterinsightsV1mainAnnotationBoundary; /** * The channel of the audio where the annotation occurs. For single-channel * audio, this field is not populated. */ channelTag?: number; /** * Data specifying an entity mention. */ entityMentionData?: GoogleCloudContactcenterinsightsV1mainEntityMentionData; /** * Data specifying a hold. */ holdData?: GoogleCloudContactcenterinsightsV1mainHoldData; /** * Data specifying an intent match. */ intentMatchData?: GoogleCloudContactcenterinsightsV1mainIntentMatchData; /** * Data specifying an interruption. */ interruptionData?: GoogleCloudContactcenterinsightsV1mainInterruptionData; /** * Data specifying an issue match. */ issueMatchData?: GoogleCloudContactcenterinsightsV1mainIssueMatchData; /** * Data specifying a phrase match. */ phraseMatchData?: GoogleCloudContactcenterinsightsV1mainPhraseMatchData; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1mainSentimentData; /** * Data specifying silence. */ silenceData?: GoogleCloudContactcenterinsightsV1mainSilenceData; } /** * The conversation resource. */ export interface GoogleCloudContactcenterinsightsV1mainConversation { /** * An opaque, user-specified string representing the human agent who handled * the conversation. */ agentId?: string; /** * Call-specific metadata. */ callMetadata?: GoogleCloudContactcenterinsightsV1mainConversationCallMetadata; /** * Output only. The time at which the conversation was created. */ readonly createTime?: Date; /** * The source of the audio and transcription for the conversation. */ dataSource?: GoogleCloudContactcenterinsightsV1mainConversationDataSource; /** * Output only. All the matched Dialogflow intents in the call. The key * corresponds to a Dialogflow intent, format: * projects/{project}/agent/{agent}/intents/{intent} */ readonly dialogflowIntents?: { [key: string]: GoogleCloudContactcenterinsightsV1mainDialogflowIntent }; /** * Output only. The duration of the conversation. */ readonly duration?: number /* Duration */; /** * The time at which this conversation should expire. After this time, the * conversation data and any associated analyses will be deleted. */ expireTime?: Date; /** * A map for the user to specify any custom fields. A maximum of 100 labels * per conversation is allowed, with a maximum of 256 characters per entry. */ labels?: { [key: string]: string }; /** * A user-specified language code for the conversation. */ languageCode?: string; /** * Output only. The conversation's latest analysis, if one exists. */ readonly latestAnalysis?: GoogleCloudContactcenterinsightsV1mainAnalysis; /** * Output only. Latest summary of the conversation. */ readonly latestSummary?: GoogleCloudContactcenterinsightsV1mainConversationSummarizationSuggestionData; /** * Immutable. The conversation medium, if unspecified will default to * PHONE_CALL. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Input only. JSON metadata encoded as a string. This field is primarily * used by Insights integrations with various telephony systems and must be in * one of Insight's supported formats. */ metadataJson?: string; /** * Immutable. The resource name of the conversation. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ name?: string; /** * Obfuscated user ID which the customer sent to us. */ obfuscatedUserId?: string; /** * Conversation metadata related to quality management. */ qualityMetadata?: GoogleCloudContactcenterinsightsV1mainConversationQualityMetadata; /** * Output only. The annotations that were generated during the customer and * agent interaction. */ readonly runtimeAnnotations?: GoogleCloudContactcenterinsightsV1mainRuntimeAnnotation[]; /** * The time at which the conversation started. */ startTime?: Date; /** * Output only. The conversation transcript. */ readonly transcript?: GoogleCloudContactcenterinsightsV1mainConversationTranscript; /** * Input only. The TTL for this resource. If specified, then this TTL will be * used to calculate the expire time. */ ttl?: number /* Duration */; /** * Output only. The number of turns in the conversation. */ readonly turnCount?: number; /** * Output only. The most recent time at which the conversation was updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1mainConversation(data: any): GoogleCloudContactcenterinsightsV1mainConversation { return { ...data, expireTime: data["expireTime"] !== undefined ? data["expireTime"].toISOString() : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainConversationQualityMetadata(data["qualityMetadata"]) : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversation(data: any): GoogleCloudContactcenterinsightsV1mainConversation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, duration: data["duration"] !== undefined ? data["duration"] : undefined, expireTime: data["expireTime"] !== undefined ? new Date(data["expireTime"]) : undefined, qualityMetadata: data["qualityMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainConversationQualityMetadata(data["qualityMetadata"]) : undefined, runtimeAnnotations: data["runtimeAnnotations"] !== undefined ? data["runtimeAnnotations"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1mainRuntimeAnnotation(item))) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, transcript: data["transcript"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscript(data["transcript"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Call-specific metadata. */ export interface GoogleCloudContactcenterinsightsV1mainConversationCallMetadata { /** * The audio channel that contains the agent. */ agentChannel?: number; /** * The audio channel that contains the customer. */ customerChannel?: number; } /** * The conversation source, which is a combination of transcript and audio. */ export interface GoogleCloudContactcenterinsightsV1mainConversationDataSource { /** * The source when the conversation comes from Dialogflow. */ dialogflowSource?: GoogleCloudContactcenterinsightsV1mainDialogflowSource; /** * A Cloud Storage location specification for the audio and transcript. */ gcsSource?: GoogleCloudContactcenterinsightsV1mainGcsSource; /** * Cloud Storage URI that points to a file that contains the conversation * metadata. */ metadataUri?: string; } /** * One channel of conversation-level sentiment data. */ export interface GoogleCloudContactcenterinsightsV1mainConversationLevelSentiment { /** * The channel of the audio that the data applies to. */ channelTag?: number; /** * Data specifying sentiment. */ sentimentData?: GoogleCloudContactcenterinsightsV1mainSentimentData; } /** * Conversation-level silence data. */ export interface GoogleCloudContactcenterinsightsV1mainConversationLevelSilence { /** * Amount of time calculated to be in silence. */ silenceDuration?: number /* Duration */; /** * Percentage of the total conversation spent in silence. */ silencePercentage?: number; } function serializeGoogleCloudContactcenterinsightsV1mainConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1mainConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversationLevelSilence(data: any): GoogleCloudContactcenterinsightsV1mainConversationLevelSilence { return { ...data, silenceDuration: data["silenceDuration"] !== undefined ? data["silenceDuration"] : undefined, }; } /** * The call participant speaking for a given utterance. */ export interface GoogleCloudContactcenterinsightsV1mainConversationParticipant { /** * Deprecated. Use `dialogflow_participant_name` instead. The name of the * Dialogflow participant. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipant?: string; /** * The name of the participant provided by Dialogflow. Format: * projects/{project}/locations/{location}/conversations/{conversation}/participants/{participant} */ dialogflowParticipantName?: string; /** * Obfuscated user ID from Dialogflow. */ obfuscatedExternalUserId?: string; /** * The role of the participant. */ role?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * A user-specified ID representing the participant. */ userId?: string; } /** * Conversation metadata related to quality management. */ export interface GoogleCloudContactcenterinsightsV1mainConversationQualityMetadata { /** * Information about agents involved in the call. */ agentInfo?: GoogleCloudContactcenterinsightsV1mainConversationQualityMetadataAgentInfo[]; /** * An arbitrary integer value indicating the customer's satisfaction rating. */ customerSatisfactionRating?: number; /** * Input only. The feedback labels associated with the conversation. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1mainFeedbackLabel[]; /** * An arbitrary string value specifying the menu path the customer took. */ menuPath?: string; /** * The amount of time the customer waited to connect with an agent. */ waitDuration?: number /* Duration */; } function serializeGoogleCloudContactcenterinsightsV1mainConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1mainConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversationQualityMetadata(data: any): GoogleCloudContactcenterinsightsV1mainConversationQualityMetadata { return { ...data, waitDuration: data["waitDuration"] !== undefined ? data["waitDuration"] : undefined, }; } /** * Information about an agent involved in the conversation. */ export interface GoogleCloudContactcenterinsightsV1mainConversationQualityMetadataAgentInfo { /** * A user-specified string representing the agent. */ agentId?: string; /** * The agent type, e.g. HUMAN_AGENT. */ agentType?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * The agent's deployment display name. Only applicable to automated agents. */ deploymentDisplayName?: string; /** * The agent's deployment ID. Only applicable to automated agents. */ deploymentId?: string; /** * The agent's name. */ displayName?: string; /** * A user-provided string indicating the outcome of the agent's segment of * the call. */ dispositionCode?: string; /** * The agent's location. */ location?: string; /** * A user-specified string representing the agent's team. Deprecated in favor * of the `teams` field. */ team?: string; /** * User-specified strings representing the agent's teams. */ teams?: string[]; /** * The agent's version display name. Only applicable to automated agents. */ versionDisplayName?: string; /** * The agent's version ID. Only applicable to automated agents. */ versionId?: string; } /** * Conversation summarization suggestion data. */ export interface GoogleCloudContactcenterinsightsV1mainConversationSummarizationSuggestionData { /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ answerRecord?: string; /** * The confidence score of the summarization. */ confidence?: number; /** * The name of the model that generates this summary. Format: * projects/{project}/locations/{location}/conversationModels/{conversation_model} */ conversationModel?: string; /** * Agent Assist generator ID. */ generatorId?: string; /** * A map that contains metadata about the summarization and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The summarization content that is concatenated into one string. */ text?: string; /** * The summarization content that is divided into sections. The key is the * section's name and the value is the section's content. There is no specific * format for the key or value. */ textSections?: { [key: string]: string }; } /** * A message representing the transcript of a conversation. */ export interface GoogleCloudContactcenterinsightsV1mainConversationTranscript { /** * A list of sequential transcript segments that comprise the conversation. */ transcriptSegments?: GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment[]; } function serializeGoogleCloudContactcenterinsightsV1mainConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscript(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscript { return { ...data, transcriptSegments: data["transcriptSegments"] !== undefined ? data["transcriptSegments"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment(item))) : undefined, }; } /** * A segment of a full transcript. */ export interface GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment { /** * For conversations derived from multi-channel audio, this is the channel * number corresponding to the audio from that channel. For audioChannelCount * = N, its output values can range from '1' to 'N'. A channel tag of 0 * indicates that the audio is mono. */ channelTag?: number; /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this segment. * A default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * CCAI metadata relating to the current transcript segment. */ dialogflowSegmentMetadata?: GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata; /** * The language code of this segment as a * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. * Example: "en-US". */ languageCode?: string; /** * The time that the message occurred, if provided. */ messageTime?: Date; /** * The participant of this segment. */ segmentParticipant?: GoogleCloudContactcenterinsightsV1mainConversationParticipant; /** * The sentiment for this transcript segment. */ sentiment?: GoogleCloudContactcenterinsightsV1mainSentimentData; /** * The text of this segment. */ text?: string; /** * A list of the word-specific information for each word in the segment. */ words?: GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo[]; } function serializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? data["messageTime"].toISOString() : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegment { return { ...data, messageTime: data["messageTime"] !== undefined ? new Date(data["messageTime"]) : undefined, words: data["words"] !== undefined ? data["words"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo(item))) : undefined, }; } /** * Metadata from Dialogflow relating to the current transcript segment. */ export interface GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentDialogflowSegmentMetadata { /** * Whether the transcript segment was covered under the configured smart * reply allowlist in Agent Assist. */ smartReplyAllowlistCovered?: boolean; } /** * Word-level info for words in a transcript. */ export interface GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo { /** * A confidence estimate between 0.0 and 1.0 of the fidelity of this word. A * default value of 0.0 indicates that the value is unset. */ confidence?: number; /** * Time offset of the end of this word relative to the beginning of the total * conversation. */ endOffset?: number /* Duration */; /** * Time offset of the start of this word relative to the beginning of the * total conversation. */ startOffset?: number /* Duration */; /** * The word itself. Includes punctuation marks that surround the word. */ word?: string; } function serializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo(data: any): GoogleCloudContactcenterinsightsV1mainConversationTranscriptTranscriptSegmentWordInfo { return { ...data, endOffset: data["endOffset"] !== undefined ? data["endOffset"] : undefined, startOffset: data["startOffset"] !== undefined ? data["startOffset"] : undefined, }; } /** * Metadata for a create analysis operation. */ export interface GoogleCloudContactcenterinsightsV1mainCreateAnalysisOperationMetadata { /** * Output only. The annotator selector used for the analysis (if any). */ readonly annotatorSelector?: GoogleCloudContactcenterinsightsV1mainAnnotatorSelector; /** * Output only. The Conversation that this Analysis Operation belongs to. */ readonly conversation?: string; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; } /** * Metadata for creating an issue. */ export interface GoogleCloudContactcenterinsightsV1mainCreateIssueMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1mainCreateIssueRequest; } /** * Metadata for creating an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainCreateIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for creation. */ request?: GoogleCloudContactcenterinsightsV1mainCreateIssueModelRequest; } /** * The request to create an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainCreateIssueModelRequest { /** * Required. The issue model to create. */ issueModel?: GoogleCloudContactcenterinsightsV1mainIssueModel; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * The request to create an issue. */ export interface GoogleCloudContactcenterinsightsV1mainCreateIssueRequest { /** * Required. The values for the new issue. */ issue?: GoogleCloudContactcenterinsightsV1mainIssue; /** * Required. The parent resource of the issue. */ parent?: string; } /** * Dataset resource represents a collection of conversations that may be * bounded (Static Dataset, e.g. golden dataset for training), or unbounded * (Dynamic Dataset, e.g. live traffic, or agent training traffic) */ export interface GoogleCloudContactcenterinsightsV1mainDataset { /** * Output only. Dataset create time. */ readonly createTime?: Date; /** * Dataset description. */ description?: string; /** * Display name for the dataaset */ displayName?: string; /** * Immutable. Identifier. Resource name of the dataset. Format: * projects/{project}/locations/{location}/datasets/{dataset} */ name?: string; /** * Optional. Option TTL for the dataset. */ ttl?: number /* Duration */; /** * Dataset usage type. */ type?: | "TYPE_UNSPECIFIED" | "EVAL" | "LIVE"; /** * Output only. Dataset update time. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1mainDataset(data: any): GoogleCloudContactcenterinsightsV1mainDataset { return { ...data, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainDataset(data: any): GoogleCloudContactcenterinsightsV1mainDataset { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, ttl: data["ttl"] !== undefined ? data["ttl"] : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Metadata for deleting an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainDeleteIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deletion. */ request?: GoogleCloudContactcenterinsightsV1mainDeleteIssueModelRequest; } /** * The request to delete an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainDeleteIssueModelRequest { /** * Required. The name of the issue model to delete. */ name?: string; } /** * The metadata for deleting a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1mainDeleteQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1mainDeleteQaQuestionTagRequest; } /** * The request for deleting a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1mainDeleteQaQuestionTagRequest { /** * Required. The name of the QaQuestionTag to delete. */ name?: string; } /** * Metadata for deploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainDeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for deployment. */ request?: GoogleCloudContactcenterinsightsV1mainDeployIssueModelRequest; } /** * The request to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainDeployIssueModelRequest { /** * Required. The issue model to deploy. */ name?: string; } /** * The response to deploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainDeployIssueModelResponse { } /** * The data for a Dialogflow intent. Represents a detected intent in the * conversation, e.g. MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1mainDialogflowIntent { /** * The human-readable name of the intent. */ displayName?: string; } /** * Dialogflow interaction data. */ export interface GoogleCloudContactcenterinsightsV1mainDialogflowInteractionData { /** * The confidence of the match ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidence?: number; /** * The Dialogflow intent resource path. Format: * projects/{project}/agent/{agent}/intents/{intent} */ dialogflowIntentId?: string; } /** * A Dialogflow source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1mainDialogflowSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Output only. The name of the Dialogflow conversation that this * conversation resource is derived from. Format: * projects/{project}/locations/{location}/conversations/{conversation} */ readonly dialogflowConversation?: string; } /** * A dimension determines the grouping key for the query. In SQL terms, these * would be part of both the "SELECT" and "GROUP BY" clauses. */ export interface GoogleCloudContactcenterinsightsV1mainDimension { /** * Output only. Metadata about the agent dimension. */ readonly agentDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionAgentDimensionMetadata; /** * Output only. Metadata about the client sentiment category dimension. */ readonly clientSentimentCategoryDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionClientSentimentCategoryDimensionMetadata; /** * Output only. Metadata about the Conversational Agents playbook dimension. */ readonly conversationalAgentsPlaybookDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionConversationalAgentsPlaybookDimensionMetadata; /** * Output only. Metadata about the Conversational Agents tool dimension. */ readonly conversationalAgentsToolDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionConversationalAgentsToolDimensionMetadata; /** * Output only. Metadata about the conversation profile dimension. */ readonly conversationProfileDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionConversationProfileDimensionMetadata; /** * The key of the dimension. */ dimensionKey?: | "DIMENSION_KEY_UNSPECIFIED" | "ISSUE" | "ISSUE_NAME" | "AGENT" | "AGENT_TEAM" | "QA_QUESTION_ID" | "QA_QUESTION_ANSWER_VALUE" | "QA_SCORECARD_ID" | "CONVERSATION_PROFILE_ID" | "MEDIUM" | "CONVERSATIONAL_AGENTS_PLAYBOOK_ID" | "CONVERSATIONAL_AGENTS_PLAYBOOK_NAME" | "CONVERSATIONAL_AGENTS_TOOL_ID" | "CONVERSATIONAL_AGENTS_TOOL_NAME" | "CLIENT_SENTIMENT_CATEGORY" | "AGENT_VERSION_ID" | "AGENT_DEPLOYMENT_ID" | "AGENT_ASSIST_SUPERVISOR_ID" | "LABEL_KEY" | "LABEL_VALUE" | "LABEL_KEY_AND_VALUE"; /** * Output only. Metadata about the issue dimension. */ readonly issueDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionIssueDimensionMetadata; /** * Output only. Metadata about conversation labels. */ readonly labelDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionLabelDimensionMetadata; /** * Output only. Metadata about the conversation medium dimension. */ readonly mediumDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionMediumDimensionMetadata; /** * Output only. Metadata about the QA question-answer dimension. */ readonly qaQuestionAnswerDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionQaQuestionAnswerDimensionMetadata; /** * Output only. Metadata about the QA question dimension. */ readonly qaQuestionDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionQaQuestionDimensionMetadata; /** * Output only. Metadata about the QA scorecard dimension. */ readonly qaScorecardDimensionMetadata?: GoogleCloudContactcenterinsightsV1mainDimensionQaScorecardDimensionMetadata; } /** * Metadata about the agent dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionAgentDimensionMetadata { /** * Optional. The agent's deployment display name. Only applicable to * automated agents. This will be populated for AGENT_DEPLOYMENT_ID * dimensions. */ agentDeploymentDisplayName?: string; /** * Optional. The agent's deployment ID. Only applicable to automated agents. * This will be populated for AGENT and AGENT_DEPLOYMENT_ID dimensions. */ agentDeploymentId?: string; /** * Optional. The agent's name This will be populated for AGENT, AGENT_TEAM, * AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID dimensions. */ agentDisplayName?: string; /** * Optional. A user-specified string representing the agent. This will be * populated for AGENT, AGENT_TEAM, AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentId?: string; /** * Optional. A user-specified string representing the agent's team. */ agentTeam?: string; /** * Optional. The agent's version display name. Only applicable to automated * agents. This will be populated for AGENT_VERSION_ID, and * AGENT_DEPLOYMENT_ID dimensions. */ agentVersionDisplayName?: string; /** * Optional. The agent's version ID. Only applicable to automated agents. * This will be populated for AGENT_VERSION_ID, and AGENT_DEPLOYMENT_ID * dimensions. */ agentVersionId?: string; } /** * Metadata about the client sentiment category dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionClientSentimentCategoryDimensionMetadata { /** * Optional. The client sentiment category. */ sentimentCategory?: string; } /** * Metadata about the Conversational Agents playbook dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionConversationalAgentsPlaybookDimensionMetadata { /** * Optional. The dialogflow playbook display name. */ playbookDisplayName?: string; /** * Optional. The dialogflow playbook ID. */ playbookId?: string; } /** * Metadata about the Conversational Agents tool dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionConversationalAgentsToolDimensionMetadata { /** * Optional. The dialogflow tool display name. */ toolDisplayName?: string; /** * Optional. The dialogflow tool ID. */ toolId?: string; } /** * Metadata about the conversation profile dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionConversationProfileDimensionMetadata { /** * Optional. The conversation profile ID. */ conversationProfileId?: string; } /** * Metadata about the issue dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionIssueDimensionMetadata { /** * The issue display name. */ issueDisplayName?: string; /** * The issue ID. */ issueId?: string; /** * The parent issue model ID. */ issueModelId?: string; } /** * Metadata about conversation labels. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionLabelDimensionMetadata { /** * Optional. The label key. */ labelKey?: string; /** * Optional. The label value. */ labelValue?: string; } /** * Metadata about the conversation medium dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionMediumDimensionMetadata { /** * Optional. The conversation medium. Currently supports : PHONE_CALL, CHAT. */ medium?: string; } /** * Metadata about the QA question-answer dimension. This is useful for showing * the answer distribution for questions for a given scorecard. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionQaQuestionAnswerDimensionMetadata { /** * Optional. The full body of the question. */ answerValue?: string; /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA question dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionQaQuestionDimensionMetadata { /** * Optional. The QA question ID. */ qaQuestionId?: string; /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; /** * Optional. The full body of the question. */ questionBody?: string; } /** * Metadata about the QA scorecard dimension. */ export interface GoogleCloudContactcenterinsightsV1mainDimensionQaScorecardDimensionMetadata { /** * Optional. The QA scorecard ID. */ qaScorecardId?: string; } /** * A customer-managed encryption key specification that can be applied to all * created resources (e.g. `Conversation`). */ export interface GoogleCloudContactcenterinsightsV1mainEncryptionSpec { /** * Required. The name of customer-managed encryption key that is used to * secure a resource and its sub-resources. If empty, the resource is secured * by our default encryption key. Only the key in the same location as this * resource is allowed to be used for encryption. Format: * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{key}` */ kmsKey?: string; /** * Immutable. The resource name of the encryption key specification resource. * Format: projects/{project}/locations/{location}/encryptionSpec */ name?: string; } /** * The data for an entity annotation. Represents a phrase in the conversation * that is a known entity, such as a person, an organization, or location. */ export interface GoogleCloudContactcenterinsightsV1mainEntity { /** * The representative name for the entity. */ displayName?: string; /** * Metadata associated with the entity. For most entity types, the metadata * is a Wikipedia URL (`wikipedia_url`) and Knowledge Graph MID (`mid`), if * they are available. For the metadata associated with other entity types, * see the Type table below. */ metadata?: { [key: string]: string }; /** * The salience score associated with the entity in the [0, 1.0] range. The * salience score for an entity provides information about the importance or * centrality of that entity to the entire document text. Scores closer to 0 * are less salient, while scores closer to 1.0 are highly salient. */ salience?: number; /** * The aggregate sentiment expressed for this entity in the conversation. */ sentiment?: GoogleCloudContactcenterinsightsV1mainSentimentData; /** * The entity type. */ type?: | "TYPE_UNSPECIFIED" | "PERSON" | "LOCATION" | "ORGANIZATION" | "EVENT" | "WORK_OF_ART" | "CONSUMER_GOOD" | "OTHER" | "PHONE_NUMBER" | "ADDRESS" | "DATE" | "NUMBER" | "PRICE"; } /** * The data for an entity mention annotation. This represents a mention of an * `Entity` in the conversation. */ export interface GoogleCloudContactcenterinsightsV1mainEntityMentionData { /** * The key of this entity in conversation entities. Can be used to retrieve * the exact `Entity` this mention is attached to. */ entityUniqueId?: string; /** * Sentiment expressed for this mention of the entity. */ sentiment?: GoogleCloudContactcenterinsightsV1mainSentimentData; /** * The type of the entity mention. */ type?: | "MENTION_TYPE_UNSPECIFIED" | "PROPER" | "COMMON"; } /** * Metadata for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1mainExportInsightsDataMetadata { /** * The number of conversations that were exported successfully. */ completedExportCount?: number; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The number of conversations that failed to be exported. */ failedExportCount?: number; /** * Partial errors during export operation that might cause the operation * output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * The original request for export. */ request?: GoogleCloudContactcenterinsightsV1mainExportInsightsDataRequest; } /** * The request to export insights. */ export interface GoogleCloudContactcenterinsightsV1mainExportInsightsDataRequest { /** * Specified if sink is a BigQuery table. */ bigQueryDestination?: GoogleCloudContactcenterinsightsV1mainExportInsightsDataRequestBigQueryDestination; /** * Optional. Version of the export schema. */ exportSchemaVersion?: | "EXPORT_SCHEMA_VERSION_UNSPECIFIED" | "EXPORT_V1" | "EXPORT_V2" | "EXPORT_V3" | "EXPORT_V4" | "EXPORT_V5" | "EXPORT_V6" | "EXPORT_V7" | "EXPORT_V8" | "EXPORT_V9" | "EXPORT_V10" | "EXPORT_V11" | "EXPORT_V12" | "EXPORT_V13" | "EXPORT_V14" | "EXPORT_VERSION_LATEST_AVAILABLE"; /** * A filter to reduce results to a specific subset. Useful for exporting * conversations with specific properties. */ filter?: string; /** * A fully qualified KMS key name for BigQuery tables protected by CMEK. * Format: * projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}/cryptoKeyVersions/{version} */ kmsKey?: string; /** * Required. The parent resource to export data from. */ parent?: string; /** * Options for what to do if the destination table already exists. */ writeDisposition?: | "WRITE_DISPOSITION_UNSPECIFIED" | "WRITE_TRUNCATE" | "WRITE_APPEND"; } /** * A BigQuery Table Reference. */ export interface GoogleCloudContactcenterinsightsV1mainExportInsightsDataRequestBigQueryDestination { /** * Required. The name of the BigQuery dataset that the snapshot result should * be exported to. If this dataset does not exist, the export call returns an * INVALID_ARGUMENT error. */ dataset?: string; /** * A project ID or number. If specified, then export will attempt to write * data to this project instead of the resource project. Otherwise, the * resource project will be used. */ projectId?: string; /** * The BigQuery table name to which the insights data should be written. If * this table does not exist, the export call returns an INVALID_ARGUMENT * error. */ table?: string; } /** * Response for an export insights operation. */ export interface GoogleCloudContactcenterinsightsV1mainExportInsightsDataResponse { } /** * Metadata used for export issue model. */ export interface GoogleCloudContactcenterinsightsV1mainExportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original export request. */ request?: GoogleCloudContactcenterinsightsV1mainExportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1mainExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1mainExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainExportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1mainExportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to export an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainExportIssueModelRequest { /** * Google Cloud Storage URI to export the issue model to. */ gcsDestination?: GoogleCloudContactcenterinsightsV1mainExportIssueModelRequestGcsDestination; /** * Required. The issue model to export. */ name?: string; } /** * Google Cloud Storage Object URI to save the issue model to. */ export interface GoogleCloudContactcenterinsightsV1mainExportIssueModelRequestGcsDestination { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from export issue model */ export interface GoogleCloudContactcenterinsightsV1mainExportIssueModelResponse { } /** * Agent Assist frequently-asked-question answer data. */ export interface GoogleCloudContactcenterinsightsV1mainFaqAnswerData { /** * The piece of text from the `source` knowledge base document. */ answer?: string; /** * The system's confidence score that this answer is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the FAQ answer and the document that it * originates from. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The corresponding FAQ question. */ question?: string; /** * The knowledge document that this answer was extracted from. Format: * projects/{project}/knowledgeBases/{knowledge_base}/documents/{document}. */ source?: string; } /** * Represents a conversation, resource, and label provided by the user. Can * take the form of a string label or a QaAnswer label. QaAnswer labels are used * for Quality AI example conversations. String labels are used for Topic * Modeling. AgentAssistSummary labels are used for Agent Assist Summarization. */ export interface GoogleCloudContactcenterinsightsV1mainFeedbackLabel { /** * Output only. Create time of the label. */ readonly createTime?: Date; /** * String label used for Topic Modeling. */ label?: string; /** * Name of the resource to be labeled. Supported resources are: * * `projects/{project}/locations/{location}/qaScorecards/{scorecard}/revisions/{revision}/qaQuestions/{question}` * * `projects/{project}/locations/{location}/issueModels/{issue_model}` * * `projects/{project}/locations/{location}/generators/{generator_id}` */ labeledResource?: string; /** * Immutable. Resource name of the FeedbackLabel. Format: * projects/{project}/locations/{location}/conversations/{conversation}/feedbackLabels/{feedback_label} */ name?: string; /** * QaAnswer label used for Quality AI example conversations. */ qaAnswerLabel?: GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerValue; /** * Output only. Update time of the label. */ readonly updateTime?: Date; } /** * A Cloud Storage source of conversation data. */ export interface GoogleCloudContactcenterinsightsV1mainGcsSource { /** * Cloud Storage URI that points to a file that contains the conversation * audio. */ audioUri?: string; /** * Immutable. Cloud Storage URI that points to a file that contains the * conversation transcript. */ transcriptUri?: string; } /** * The data for a hold annotation. */ export interface GoogleCloudContactcenterinsightsV1mainHoldData { } /** * Metadata used for import issue model. */ export interface GoogleCloudContactcenterinsightsV1mainImportIssueModelMetadata { /** * The time the operation was created. */ createTime?: Date; /** * The time the operation finished running. */ endTime?: Date; /** * The original import request. */ request?: GoogleCloudContactcenterinsightsV1mainImportIssueModelRequest; } function serializeGoogleCloudContactcenterinsightsV1mainImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1mainImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainImportIssueModelMetadata(data: any): GoogleCloudContactcenterinsightsV1mainImportIssueModelMetadata { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, }; } /** * Request to import an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainImportIssueModelRequest { /** * Optional. If set to true, will create an issue model from the imported * file with randomly generated IDs for the issue model and corresponding * issues. Otherwise, replaces an existing model with the same ID as the file. */ createNewModel?: boolean; /** * Google Cloud Storage source message. */ gcsSource?: GoogleCloudContactcenterinsightsV1mainImportIssueModelRequestGcsSource; /** * Required. The parent resource of the issue model. */ parent?: string; } /** * Google Cloud Storage Object URI to get the issue model file from. */ export interface GoogleCloudContactcenterinsightsV1mainImportIssueModelRequestGcsSource { /** * Required. Format: `gs:///` */ objectUri?: string; } /** * Response from import issue model */ export interface GoogleCloudContactcenterinsightsV1mainImportIssueModelResponse { /** * The issue model that was imported. */ issueModel?: GoogleCloudContactcenterinsightsV1mainIssueModel; } /** * The metadata for an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Statistics for IngestConversations operation. */ readonly ingestConversationsStats?: GoogleCloudContactcenterinsightsV1mainIngestConversationsMetadataIngestConversationsStats; /** * Output only. Partial errors during ingest operation that might cause the * operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for ingest. */ readonly request?: GoogleCloudContactcenterinsightsV1mainIngestConversationsRequest; /** * Output only. Stores the conversation resources produced by ingest sampling * operations. */ readonly sampledConversations?: string[]; } /** * Statistics for IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsMetadataIngestConversationsStats { /** * Output only. The number of objects skipped because another conversation * with the same transcript uri had already been ingested. */ readonly duplicatesSkippedCount?: number; /** * Output only. The number of objects which were unable to be ingested due to * errors. The errors are populated in the partial_errors field. */ readonly failedIngestCount?: number; /** * Output only. The number of objects processed during the ingest operation. */ readonly processedObjectCount?: number; /** * Output only. The number of new conversations added during this ingest * operation. */ readonly successfulIngestCount?: number; } /** * The request to ingest conversations. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsRequest { /** * Configuration that applies to all conversations. */ conversationConfig?: GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestConversationConfig; /** * A cloud storage bucket source. Note that any previously ingested objects * from the source will be skipped to avoid duplication. */ gcsSource?: GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestGcsSource; /** * Required. The parent resource for new conversations. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Optional, will default to * the config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1mainRedactionConfig; /** * Optional. If set, this fields indicates the number of objects to ingest * from the Cloud Storage bucket. If empty, the entire bucket will be * ingested. Unless they are first deleted, conversations produced through * sampling won't be ingested by subsequent ingest requests. */ sampleSize?: number; /** * Optional. Default Speech-to-Text configuration. Optional, will default to * the config specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1mainSpeechConfig; /** * Configuration for when `source` contains conversation transcripts. */ transcriptObjectConfig?: GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestTranscriptObjectConfig; } /** * Configuration that applies to all conversations. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestConversationConfig { /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ agentChannel?: number; /** * Optional. An opaque, user-specified string representing a human agent who * handled all conversations in the import. Note that this will be overridden * if per-conversation metadata is provided through the `metadata_bucket_uri`. */ agentId?: string; /** * Optional. Indicates which of the channels, 1 or 2, contains the agent. * Note that this must be set for conversations to be properly displayed and * analyzed. */ customerChannel?: number; } /** * Configuration for Cloud Storage bucket sources. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestGcsSource { /** * Optional. The Cloud Storage path to the conversation audio file. Note * that: [1] Audio files will be transcribed if not already. [2] Audio files * and transcript files must be in separate buckets / folders. [3] A source * file and its corresponding audio file must share the same name to be * properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and * `gs://bucket/audio/conversation1.mp3`. */ audioBucketUri?: string; /** * Optional. Specifies the type of the objects in `bucket_uri`. Avoid passing * this. This is inferred from the `transcript_bucket_uri`, * `audio_bucket_uri`. */ bucketObjectType?: | "BUCKET_OBJECT_TYPE_UNSPECIFIED" | "TRANSCRIPT" | "AUDIO"; /** * Optional. The Cloud Storage bucket containing source objects. Avoid * passing this. Pass this through one of `transcript_bucket_uri` or * `audio_bucket_uri`. */ bucketUri?: string; /** * Optional. Custom keys to extract as conversation labels from metadata * files in `metadata_bucket_uri`. Keys not included in this field will be * ignored. Note that there is a limit of 100 labels per conversation. */ customMetadataKeys?: string[]; /** * Optional. The Cloud Storage path to the conversation metadata. Note that: * [1] Metadata files are expected to be in JSON format. [2] Metadata and * source files (transcripts or audio) must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ metadataBucketUri?: string; /** * Optional. The Cloud Storage path to the conversation transcripts. Note * that: [1] Transcript files are expected to be in JSON format. [2] * Transcript, audio, metadata files must be in separate buckets / folders. * [3] A source file and its corresponding metadata file must share the same * name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` * and `gs://bucket/metadata/conversation1.json`. */ transcriptBucketUri?: string; } /** * Configuration for processing transcript objects. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsRequestTranscriptObjectConfig { /** * Required. The medium transcript objects represent. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; } /** * The response to an IngestConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainIngestConversationsResponse { } /** * Metadata for initializing a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1mainInitializeEncryptionSpecMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Partial errors during initializing operation that might cause the * operation output to be incomplete. */ partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for initialization. */ readonly request?: GoogleCloudContactcenterinsightsV1mainInitializeEncryptionSpecRequest; } /** * The request to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1mainInitializeEncryptionSpecRequest { /** * Required. The encryption spec used for CMEK encryption. It is required * that the kms key is in the same region as the endpoint. The same key will * be used for all provisioned resources, if encryption is available. If the * `kms_key_name` field is left empty, no encryption will be enforced. */ encryptionSpec?: GoogleCloudContactcenterinsightsV1mainEncryptionSpec; } /** * The response to initialize a location-level encryption specification. */ export interface GoogleCloudContactcenterinsightsV1mainInitializeEncryptionSpecResponse { } /** * The data for an intent. Represents a detected intent in the conversation, * for example MAKES_PROMISE. */ export interface GoogleCloudContactcenterinsightsV1mainIntent { /** * The human-readable name of the intent. */ displayName?: string; /** * The unique identifier of the intent. */ id?: string; } /** * The data for an intent match. Represents an intent match for a text segment * in the conversation. A text segment can be part of a sentence, a complete * sentence, or an utterance with multiple sentences. */ export interface GoogleCloudContactcenterinsightsV1mainIntentMatchData { /** * The id of the matched intent. Can be used to retrieve the corresponding * intent information. */ intentUniqueId?: string; } /** * The data for an interruption annotation. */ export interface GoogleCloudContactcenterinsightsV1mainInterruptionData { } /** * The issue resource. */ export interface GoogleCloudContactcenterinsightsV1mainIssue { /** * Output only. The time at which this issue was created. */ readonly createTime?: Date; /** * Representative description of the issue. */ displayDescription?: string; /** * The representative name for the issue. */ displayName?: string; /** * Immutable. The resource name of the issue. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ name?: string; /** * Output only. Resource names of the sample representative utterances that * match to this issue. */ readonly sampleUtterances?: string[]; /** * Output only. The most recent time that this issue was updated. */ readonly updateTime?: Date; } /** * Information about the issue. */ export interface GoogleCloudContactcenterinsightsV1mainIssueAssignment { /** * Immutable. Display name of the assigned issue. This field is set at time * of analysis and immutable since then. */ displayName?: string; /** * Resource name of the assigned issue. */ issue?: string; /** * Score indicating the likelihood of the issue assignment. currently bounded * on [0,1]. */ score?: number; } /** * The data for an issue match annotation. */ export interface GoogleCloudContactcenterinsightsV1mainIssueMatchData { /** * Information about the issue's assignment. */ issueAssignment?: GoogleCloudContactcenterinsightsV1mainIssueAssignment; } /** * The issue model resource. */ export interface GoogleCloudContactcenterinsightsV1mainIssueModel { /** * Output only. The time at which this issue model was created. */ readonly createTime?: Date; /** * The representative name for the issue model. */ displayName?: string; /** * Configs for the input data that used to create the issue model. */ inputDataConfig?: GoogleCloudContactcenterinsightsV1mainIssueModelInputDataConfig; /** * Output only. Number of issues in this issue model. */ readonly issueCount?: bigint; /** * Language of the model. */ languageCode?: string; /** * Type of the model. */ modelType?: | "MODEL_TYPE_UNSPECIFIED" | "TYPE_V1" | "TYPE_V2"; /** * Immutable. The resource name of the issue model. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ name?: string; /** * Output only. State of the model. */ readonly state?: | "STATE_UNSPECIFIED" | "UNDEPLOYED" | "DEPLOYING" | "DEPLOYED" | "UNDEPLOYING" | "DELETING"; /** * Output only. Immutable. The issue model's label statistics on its training * data. */ readonly trainingStats?: GoogleCloudContactcenterinsightsV1mainIssueModelLabelStats; /** * Output only. The most recent time at which the issue model was updated. */ readonly updateTime?: Date; } /** * Configs for the input data used to create the issue model. */ export interface GoogleCloudContactcenterinsightsV1mainIssueModelInputDataConfig { /** * A filter to reduce the conversations used for training the model to a * specific subset. Refer to * https://cloud.google.com/contact-center/insights/docs/filtering for * details. */ filter?: string; /** * Medium of conversations used in training data. This field is being * deprecated. To specify the medium to be used in training a new issue model, * set the `medium` field on `filter`. */ medium?: | "MEDIUM_UNSPECIFIED" | "PHONE_CALL" | "CHAT"; /** * Output only. Number of conversations used in training. Output only. */ readonly trainingConversationsCount?: bigint; } /** * Aggregated statistics about an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainIssueModelLabelStats { /** * Number of conversations the issue model has analyzed at this point in * time. */ analyzedConversationsCount?: bigint; /** * Statistics on each issue. Key is the issue's resource name. */ issueStats?: { [key: string]: GoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats }; /** * Number of analyzed conversations for which no issue was applicable at this * point in time. */ unclassifiedConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1mainIssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? String(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, serializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? String(data["unclassifiedConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStats(data: any): GoogleCloudContactcenterinsightsV1mainIssueModelLabelStats { return { ...data, analyzedConversationsCount: data["analyzedConversationsCount"] !== undefined ? BigInt(data["analyzedConversationsCount"]) : undefined, issueStats: data["issueStats"] !== undefined ? Object.fromEntries(Object.entries(data["issueStats"]).map(([k, v]: [string, any]) => ([k, deserializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats(v)]))) : undefined, unclassifiedConversationsCount: data["unclassifiedConversationsCount"] !== undefined ? BigInt(data["unclassifiedConversationsCount"]) : undefined, }; } /** * Aggregated statistics about an issue. */ export interface GoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats { /** * Display name of the issue. */ displayName?: string; /** * Issue resource. Format: * projects/{project}/locations/{location}/issueModels/{issue_model}/issues/{issue} */ issue?: string; /** * Number of conversations attached to the issue at this point in time. */ labeledConversationsCount?: bigint; } function serializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? String(data["labeledConversationsCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats(data: any): GoogleCloudContactcenterinsightsV1mainIssueModelLabelStatsIssueStats { return { ...data, labeledConversationsCount: data["labeledConversationsCount"] !== undefined ? BigInt(data["labeledConversationsCount"]) : undefined, }; } /** * Issue Modeling result on a conversation. */ export interface GoogleCloudContactcenterinsightsV1mainIssueModelResult { /** * Issue model that generates the result. Format: * projects/{project}/locations/{location}/issueModels/{issue_model} */ issueModel?: string; /** * All the matched issues. */ issues?: GoogleCloudContactcenterinsightsV1mainIssueAssignment[]; } /** * The response for listing all feedback labels. */ export interface GoogleCloudContactcenterinsightsV1mainListAllFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1mainFeedbackLabel[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The response for listing feedback labels. */ export interface GoogleCloudContactcenterinsightsV1mainListFeedbackLabelsResponse { /** * The feedback labels that match the request. */ feedbackLabels?: GoogleCloudContactcenterinsightsV1mainFeedbackLabel[]; /** * The next page token. */ nextPageToken?: string; } /** * The data for a matched phrase matcher. Represents information identifying a * phrase matcher for a given match. */ export interface GoogleCloudContactcenterinsightsV1mainPhraseMatchData { /** * The human-readable name of the phrase matcher. */ displayName?: string; /** * The unique identifier (the resource name) of the phrase matcher. */ phraseMatcher?: string; } /** * An answer to a QaQuestion. */ export interface GoogleCloudContactcenterinsightsV1mainQaAnswer { /** * List of all individual answers given to the question. */ answerSources?: GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerSource[]; /** * The main answer value, incorporating any manual edits if they exist. */ answerValue?: GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerValue; /** * The conversation the answer applies to. */ conversation?: string; /** * The QaQuestion answered by this answer. */ qaQuestion?: string; /** * Question text. E.g., "Did the agent greet the customer?" */ questionBody?: string; /** * User-defined list of arbitrary tags. Matches the value from * QaScorecard.ScorecardQuestion.tags. Used for grouping/organization and for * weighting the score of each answer. */ tags?: string[]; } /** * A question may have multiple answers from varying sources, one of which * becomes the "main" answer above. AnswerSource represents each individual * answer. */ export interface GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerSource { /** * The answer value from this source. */ answerValue?: GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerValue; /** * What created the answer. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED" | "MANUAL_EDIT"; } /** * Message for holding the value of a QaAnswer. QaQuestion.AnswerChoice defines * the possible answer values for a question. */ export interface GoogleCloudContactcenterinsightsV1mainQaAnswerAnswerValue { /** * Boolean value. */ boolValue?: boolean; /** * A short string used as an identifier. Matches the value used in * QaQuestion.AnswerChoice.key. */ key?: string; /** * A value of "Not Applicable (N/A)". Should only ever be `true`. */ naValue?: boolean; /** * Output only. Normalized score of the questions. Calculated as score / * potential_score. */ readonly normalizedScore?: number; /** * Numerical value. */ numValue?: number; /** * Output only. The maximum potential score of the question. */ readonly potentialScore?: number; /** * Output only. Numerical score of the answer. */ readonly score?: number; /** * Output only. A value of "Skip". If provided, this field may only be set to * `true`. If a question receives this answer, it will be excluded from any * score calculations. This would mean that the question was not evaluated. */ readonly skipValue?: boolean; /** * String value. */ strValue?: string; } /** * A tag is a resource which aims to categorize a set of questions across * multiple scorecards, e.g., "Customer Satisfaction","Billing", etc. */ export interface GoogleCloudContactcenterinsightsV1mainQaQuestionTag { /** * Output only. The time at which the question tag was created. */ readonly createTime?: Date; /** * Required. A user-specified display name for the tag. */ displayName?: string; /** * Identifier. Resource name for the QaQuestionTag Format * projects/{project}/locations/{location}/qaQuestionTags/{qa_question_tag} In * the above format, the last segment, i.e., qa_question_tag, is a * server-generated ID corresponding to the tag resource. */ name?: string; /** * Optional. The list of Scorecard Question IDs that the tag applies to. Each * QaQuestionId is represented as a full resource name containing the Question * ID. Lastly, Since a tag may not necessarily be referenced by any Scorecard * Questions, we treat this field as optional. */ qaQuestionIds?: string[]; /** * Output only. The most recent time at which the question tag was updated. */ readonly updateTime?: Date; } /** * The results of scoring a single conversation against a QaScorecard. Contains * a collection of QaAnswers and aggregate score. */ export interface GoogleCloudContactcenterinsightsV1mainQaScorecardResult { /** * ID of the agent that handled the conversation. */ agentId?: string; /** * The conversation scored by this result. */ conversation?: string; /** * Output only. The timestamp that the revision was created. */ readonly createTime?: Date; /** * Identifier. The name of the scorecard result. Format: * projects/{project}/locations/{location}/qaScorecardResults/{qa_scorecard_result} */ name?: string; /** * The normalized score, which is the score divided by the potential score. * Any manual edits are included if they exist. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Set of QaAnswers represented in the result. */ qaAnswers?: GoogleCloudContactcenterinsightsV1mainQaAnswer[]; /** * The QaScorecardRevision scored by this result. */ qaScorecardRevision?: string; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1mainQaScorecardResultQaTagResult[]; /** * The overall numerical score of the result, incorporating any manual edits * if they exist. */ score?: number; /** * List of all individual score sets. */ scoreSources?: GoogleCloudContactcenterinsightsV1mainQaScorecardResultScoreSource[]; } /** * Tags and their corresponding results. */ export interface GoogleCloudContactcenterinsightsV1mainQaScorecardResultQaTagResult { /** * The normalized score the tag applies to. */ normalizedScore?: number; /** * The potential score the tag applies to. */ potentialScore?: number; /** * The score the tag applies to. */ score?: number; /** * The tag the score applies to. */ tag?: string; } /** * A scorecard result may have multiple sets of scores from varying sources, * one of which becomes the "main" answer above. A ScoreSource represents each * individual set of scores. */ export interface GoogleCloudContactcenterinsightsV1mainQaScorecardResultScoreSource { /** * The normalized score, which is the score divided by the potential score. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1mainQaScorecardResultQaTagResult[]; /** * The overall numerical score of the result. */ score?: number; /** * What created the score. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED_ONLY" | "INCLUDES_MANUAL_EDITS"; } /** * The metadata from querying metrics. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsMetadata { /** * Whether the result rows were truncated because the result row size is too * large to materialize. */ resultIsTruncated?: boolean; } /** * The response for querying metrics. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponse { /** * Required. The location of the data. * "projects/{project}/locations/{location}" */ location?: string; /** * The macro average slice contains aggregated averages across all selected * dimensions. i.e. if group_by agent and scorecard_id is specified, this * field will contain the average across all agents and all scorecards. This * field is only populated if the request specifies a Dimension. */ macroAverageSlice?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice; /** * A slice contains a total and (if the request specified a time granularity) * a time series of metric values. Each slice contains a unique combination of * the cardinality of dimensions from the request. */ slices?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice[]; /** * The metrics last update time. */ updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? data["updateTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * A slice contains a total and (if the request specified a time granularity) a * time series of metric values. Each slice contains a unique combination of the * cardinality of dimensions from the request. For example, if the request * specifies a single ISSUE dimension and it has a cardinality of 2 (i.e. the * data used to compute the metrics has 2 issues in total), the response will * have 2 slices: * Slice 1 -> dimensions=[Issue 1] * Slice 2 -> * dimensions=[Issue 2] */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice { /** * A unique combination of dimensions that this slice represents. */ dimensions?: GoogleCloudContactcenterinsightsV1mainDimension[]; /** * A time series of metric values. This is only populated if the request * specifies a time granularity other than NONE. */ timeSeries?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries; /** * The total metric value. The interval of this data point is [starting * create time, ending create time) from the request. */ total?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint; } function serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } /** * A data point contains the metric values mapped to an interval. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint { /** * The measure related to conversations. */ conversationMeasure?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure; /** * The interval that this data point represents. * If this is the total data * point, the interval is [starting create time, ending create time) from the * request. * If this a data point from the time series, the interval is * [time, time + time granularity from the request). */ interval?: GoogleTypeInterval; } function serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? serializeGoogleTypeInterval(data["interval"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? deserializeGoogleTypeInterval(data["interval"]) : undefined, }; } /** * The measure related to conversations. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure { /** * The average agent's sentiment score. */ averageAgentSentimentScore?: number; /** * The average client's sentiment score. */ averageClientSentimentScore?: number; /** * The average customer satisfaction rating. */ averageCustomerSatisfactionRating?: number; /** * The average duration. */ averageDuration?: number /* Duration */; /** * The average normalized QA score for a scorecard. When computing the * average across a set of conversations, if a conversation has been evaluated * with multiple revisions of a scorecard, only the latest revision results * will be used. Will exclude 0's in average calculation. Will be only * populated if the request specifies a dimension of QA_SCORECARD_ID. */ averageQaNormalizedScore?: number; /** * Average QA normalized score averaged for questions averaged across all * revisions of the parent scorecard. Will be only populated if the request * specifies a dimension of QA_QUESTION_ID. */ averageQaQuestionNormalizedScore?: number; /** * The average silence percentage. */ averageSilencePercentage?: number; /** * The average turn count. */ averageTurnCount?: number; /** * The conversation count. */ conversationCount?: number; /** * Average QA normalized score for all the tags. */ qaTagScores?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasureQaTagScore[]; } function serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } /** * Average QA normalized score for the tag. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPointConversationMeasureQaTagScore { /** * Average tag normalized score per tag. */ averageTagNormalizedScore?: number; /** * Tag name. */ tag?: string; } /** * A time series of metric values. */ export interface GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries { /** * The data points that make up the time series . */ dataPoints?: GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint[]; } function serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1mainQueryMetricsResponseSliceDataPoint(item))) : undefined, }; } /** * The metadata for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1mainQueryPerformanceOverviewMetadata { } /** * The response for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1mainQueryPerformanceOverviewResponse { /** * The summary text of the performance. */ summaryText?: string; } /** * DLP resources used for redaction while ingesting conversations. DLP settings * are applied to conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint or the Dialogflow / Agent Assist runtime * integrations. When using Dialogflow / Agent Assist runtime integrations, * redaction should be performed in Dialogflow / Agent Assist. */ export interface GoogleCloudContactcenterinsightsV1mainRedactionConfig { /** * The fully-qualified DLP deidentify template resource name. Format: * `projects/{project}/deidentifyTemplates/{template}` */ deidentifyTemplate?: string; /** * The fully-qualified DLP inspect template resource name. Format: * `projects/{project}/locations/{location}/inspectTemplates/{template}` */ inspectTemplate?: string; } /** * An annotation that was generated during the customer and agent interaction. */ export interface GoogleCloudContactcenterinsightsV1mainRuntimeAnnotation { /** * The unique identifier of the annotation. Format: * projects/{project}/locations/{location}/conversationDatasets/{dataset}/conversationDataItems/{data_item}/conversationAnnotations/{annotation} */ annotationId?: string; /** * The feedback that the customer has about the answer in `data`. */ answerFeedback?: GoogleCloudContactcenterinsightsV1mainAnswerFeedback; /** * Agent Assist Article Suggestion data. */ articleSuggestion?: GoogleCloudContactcenterinsightsV1mainArticleSuggestionData; /** * Conversation summarization suggestion data. */ conversationSummarizationSuggestion?: GoogleCloudContactcenterinsightsV1mainConversationSummarizationSuggestionData; /** * The time at which this annotation was created. */ createTime?: Date; /** * Dialogflow interaction data. */ dialogflowInteraction?: GoogleCloudContactcenterinsightsV1mainDialogflowInteractionData; /** * The boundary in the conversation where the annotation ends, inclusive. */ endBoundary?: GoogleCloudContactcenterinsightsV1mainAnnotationBoundary; /** * Agent Assist FAQ answer data. */ faqAnswer?: GoogleCloudContactcenterinsightsV1mainFaqAnswerData; /** * Agent Assist Smart Compose suggestion data. */ smartComposeSuggestion?: GoogleCloudContactcenterinsightsV1mainSmartComposeSuggestionData; /** * Agent Assist Smart Reply data. */ smartReply?: GoogleCloudContactcenterinsightsV1mainSmartReplyData; /** * The boundary in the conversation where the annotation starts, inclusive. */ startBoundary?: GoogleCloudContactcenterinsightsV1mainAnnotationBoundary; /** * Explicit input used for generating the answer */ userInput?: GoogleCloudContactcenterinsightsV1mainRuntimeAnnotationUserInput; } function serializeGoogleCloudContactcenterinsightsV1mainRuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1mainRuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainRuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1mainRuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, }; } /** * Explicit input used for generating the answer */ export interface GoogleCloudContactcenterinsightsV1mainRuntimeAnnotationUserInput { /** * The resource name of associated generator. Format: * `projects//locations//generators/` */ generatorName?: string; /** * Query text. Article Search uses this to store the input query used to * generate the search results. */ query?: string; /** * Query source for the answer. */ querySource?: | "QUERY_SOURCE_UNSPECIFIED" | "AGENT_QUERY" | "SUGGESTED_QUERY"; } /** * The metadata for an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainSampleConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Partial errors during sample conversations operation that * might cause the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for sample conversations to dataset. */ readonly request?: GoogleCloudContactcenterinsightsV1mainSampleConversationsRequest; /** * Output only. Statistics for SampleConversations operation. */ readonly sampleConversationsStats?: GoogleCloudContactcenterinsightsV1mainSampleConversationsMetadataSampleConversationsStats; } /** * Statistics for SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainSampleConversationsMetadataSampleConversationsStats { /** * Output only. The number of objects which were unable to be sampled due to * errors. The errors are populated in the partial_errors field. */ readonly failedSampleCount?: number; /** * Output only. The number of new conversations added during this sample * operation. */ readonly successfulSampleCount?: number; } /** * The request to sample conversations to a dataset. */ export interface GoogleCloudContactcenterinsightsV1mainSampleConversationsRequest { /** * The dataset resource to copy the sampled conversations to. */ destinationDataset?: GoogleCloudContactcenterinsightsV1mainDataset; /** * Required. The parent resource of the dataset. */ parent?: string; /** * Optional. The sample rule used for sampling conversations. */ sampleRule?: GoogleCloudContactcenterinsightsV1mainSampleRule; } function serializeGoogleCloudContactcenterinsightsV1mainSampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1mainSampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainDataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainSampleRule(data["sampleRule"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainSampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1mainSampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainDataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainSampleRule(data["sampleRule"]) : undefined, }; } /** * The response to an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1mainSampleConversationsResponse { } /** * Message for sampling conversations. */ export interface GoogleCloudContactcenterinsightsV1mainSampleRule { /** * To specify the filter for the conversions that should apply this sample * rule. An empty filter means this sample rule applies to all conversations. */ conversationFilter?: string; /** * Optional. Group by dimension to sample the conversation. If no dimension * is provided, the sampling will be applied to the project level. Current * supported dimensions is 'quality_metadata.agent_info.agent_id'. */ dimension?: string; /** * Percentage of conversations that we should sample based on the dimension * between [0, 100]. */ samplePercentage?: number; /** * Number of the conversations that we should sample based on the dimension. */ sampleRow?: bigint; } function serializeGoogleCloudContactcenterinsightsV1mainSampleRule(data: any): GoogleCloudContactcenterinsightsV1mainSampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? String(data["sampleRow"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainSampleRule(data: any): GoogleCloudContactcenterinsightsV1mainSampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? BigInt(data["sampleRow"]) : undefined, }; } /** * The data for a sentiment annotation. */ export interface GoogleCloudContactcenterinsightsV1mainSentimentData { /** * A non-negative number from 0 to infinity which represents the absolute * magnitude of sentiment regardless of score. */ magnitude?: number; /** * The sentiment score between -1.0 (negative) and 1.0 (positive). */ score?: number; } /** * The data for a silence annotation. */ export interface GoogleCloudContactcenterinsightsV1mainSilenceData { } /** * Agent Assist Smart Compose suggestion data. */ export interface GoogleCloudContactcenterinsightsV1mainSmartComposeSuggestionData { /** * The system's confidence score that this suggestion is a good match for * this conversation, ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Compose suggestion and the * document from which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the suggestion. */ suggestion?: string; } /** * Agent Assist Smart Reply data. */ export interface GoogleCloudContactcenterinsightsV1mainSmartReplyData { /** * The system's confidence score that this reply is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Reply and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the reply. */ reply?: string; } /** * Speech-to-Text configuration. Speech-to-Text settings are applied to * conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint. */ export interface GoogleCloudContactcenterinsightsV1mainSpeechConfig { /** * The fully-qualified Speech Recognizer resource name. Format: * `projects/{project_id}/locations/{location}/recognizer/{recognizer}` */ speechRecognizer?: string; } /** * Metadata for undeploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainUndeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for undeployment. */ request?: GoogleCloudContactcenterinsightsV1mainUndeployIssueModelRequest; } /** * The request to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainUndeployIssueModelRequest { /** * Required. The issue model to undeploy. */ name?: string; } /** * The response to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1mainUndeployIssueModelResponse { } /** * The metadata for updating a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest; } /** * The request for updating a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest { /** * Required. The QaQuestionTag to update. */ qaQuestionTag?: GoogleCloudContactcenterinsightsV1mainQaQuestionTag; /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `qa_question_tag_name` - the name of the tag * * `qa_question_ids` - the list of questions the tag applies to */ updateMask?: string /* FieldMask */; } function serializeGoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1mainUpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * The metadata for an `UploadConversation` operation. */ export interface GoogleCloudContactcenterinsightsV1mainUploadConversationMetadata { /** * Output only. The operation name for a successfully created analysis * operation, if any. */ readonly analysisOperation?: string; /** * Output only. The redaction config applied to the uploaded conversation. */ readonly appliedRedactionConfig?: GoogleCloudContactcenterinsightsV1mainRedactionConfig; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1mainUploadConversationRequest; } /** * Request to upload a conversation. */ export interface GoogleCloudContactcenterinsightsV1mainUploadConversationRequest { /** * Required. The conversation resource to create. */ conversation?: GoogleCloudContactcenterinsightsV1mainConversation; /** * Optional. A unique ID for the new conversation. This ID will become the * final component of the conversation's resource name. If no ID is specified, * a server-generated ID will be used. This value should be 4-64 characters * and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters * are `a-z-` */ conversationId?: string; /** * Required. The parent resource of the conversation. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Will default to the * config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1mainRedactionConfig; /** * Optional. Speech-to-Text configuration. Will default to the config * specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1mainSpeechConfig; } function serializeGoogleCloudContactcenterinsightsV1mainUploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1mainUploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1mainConversation(data["conversation"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1mainUploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1mainUploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1mainConversation(data["conversation"]) : undefined, }; } /** * The conversation assessment note resource. */ export interface GoogleCloudContactcenterinsightsV1Note { /** * The note is associated to the entire parent assessment. */ assessmentNote?: GoogleCloudContactcenterinsightsV1NoteAssessmentNote; /** * The note content. */ content?: string; /** * The note is associated with a conversation turn. */ conversationTurnNote?: GoogleCloudContactcenterinsightsV1NoteConversationTurnNote; /** * Output only. The time at which the note was created. */ readonly createTime?: Date; /** * Identifier. The resource name of the note. Format: * projects/{project}/locations/{location}/conversations/{conversation}/assessments/{assessment}/notes/{note} */ name?: string; /** * Output only. The user that created the note. */ readonly noteCreator?: GoogleCloudContactcenterinsightsV1UserInfo; /** * The note is associated with a QA question in one of the conversation's * scorecard results. */ qaQuestionNote?: GoogleCloudContactcenterinsightsV1NoteQaQuestionNote; /** * Output only. The time at which the note was last updated. */ readonly updateTime?: Date; } /** * A note about the entire parent assessment. */ export interface GoogleCloudContactcenterinsightsV1NoteAssessmentNote { } /** * A note about a conversation turn. */ export interface GoogleCloudContactcenterinsightsV1NoteConversationTurnNote { /** * The conversation turn index that the note is associated with. */ turnIndex?: number; } /** * A note about a QA question. */ export interface GoogleCloudContactcenterinsightsV1NoteQaQuestionNote { /** * The question resource that the note is associated with. */ qaQuestion?: string; } /** * The data for a matched phrase matcher. Represents information identifying a * phrase matcher for a given match. */ export interface GoogleCloudContactcenterinsightsV1PhraseMatchData { /** * The human-readable name of the phrase matcher. */ displayName?: string; /** * The unique identifier (the resource name) of the phrase matcher. */ phraseMatcher?: string; } /** * The phrase matcher resource. */ export interface GoogleCloudContactcenterinsightsV1PhraseMatcher { /** * Output only. The most recent time at which the activation status was * updated. */ readonly activationUpdateTime?: Date; /** * Applies the phrase matcher only when it is active. */ active?: boolean; /** * The human-readable name of the phrase matcher. */ displayName?: string; /** * The resource name of the phrase matcher. Format: * projects/{project}/locations/{location}/phraseMatchers/{phrase_matcher} */ name?: string; /** * A list of phase match rule groups that are included in this matcher. */ phraseMatchRuleGroups?: GoogleCloudContactcenterinsightsV1PhraseMatchRuleGroup[]; /** * Output only. The timestamp of when the revision was created. It is also * the create time when a new matcher is added. */ readonly revisionCreateTime?: Date; /** * Output 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 */ readonly revisionId?: string; /** * The 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. */ roleMatch?: | "ROLE_UNSPECIFIED" | "HUMAN_AGENT" | "AUTOMATED_AGENT" | "END_USER" | "ANY_AGENT"; /** * Required. The type of this phrase matcher. */ type?: | "PHRASE_MATCHER_TYPE_UNSPECIFIED" | "ALL_OF" | "ANY_OF"; /** * Output only. The most recent time at which the phrase matcher was updated. */ readonly updateTime?: Date; /** * The customized version tag to use for the phrase matcher. If not * specified, it will default to `revision_id`. */ versionTag?: string; } /** * The data for a phrase match rule. */ export interface GoogleCloudContactcenterinsightsV1PhraseMatchRule { /** * Provides additional information about the rule that specifies how to apply * the rule. */ config?: GoogleCloudContactcenterinsightsV1PhraseMatchRuleConfig; /** * Specifies whether the phrase must be missing from the transcript segment * or present in the transcript segment. */ negated?: boolean; /** * Required. The phrase to be matched. */ query?: string; } /** * Configuration information of a phrase match rule. */ export interface GoogleCloudContactcenterinsightsV1PhraseMatchRuleConfig { /** * The configuration for the exact match rule. */ exactMatchConfig?: GoogleCloudContactcenterinsightsV1ExactMatchConfig; /** * The configuration for the regex match rule. */ regexMatchConfig?: GoogleCloudContactcenterinsightsV1RegexMatchConfig; } /** * A message representing a rule in the phrase matcher. */ export interface GoogleCloudContactcenterinsightsV1PhraseMatchRuleGroup { /** * A list of phrase match rules that are included in this group. */ phraseMatchRules?: GoogleCloudContactcenterinsightsV1PhraseMatchRule[]; /** * Required. The type of this phrase match rule group. */ type?: | "PHRASE_MATCH_RULE_GROUP_TYPE_UNSPECIFIED" | "ALL_OF" | "ANY_OF"; } /** * The message to publish an assessment. Draft and appealed assessments can be * published. Publishing simply changes the state of the assessment to * published, allowing the console and authorized views to filter on the state. */ export interface GoogleCloudContactcenterinsightsV1PublishAssessmentRequest { } /** * An answer to a QaQuestion. */ export interface GoogleCloudContactcenterinsightsV1QaAnswer { /** * List of all individual answers given to the question. */ answerSources?: GoogleCloudContactcenterinsightsV1QaAnswerAnswerSource[]; /** * The main answer value, incorporating any manual edits if they exist. */ answerValue?: GoogleCloudContactcenterinsightsV1QaAnswerAnswerValue; /** * The conversation the answer applies to. */ conversation?: string; /** * The QaQuestion answered by this answer. */ qaQuestion?: string; /** * Question text. E.g., "Did the agent greet the customer?" */ questionBody?: string; /** * User-defined list of arbitrary tags. Matches the value from * QaScorecard.ScorecardQuestion.tags. Used for grouping/organization and for * weighting the score of each answer. */ tags?: string[]; } /** * A question may have multiple answers from varying sources, one of which * becomes the "main" answer above. AnswerSource represents each individual * answer. */ export interface GoogleCloudContactcenterinsightsV1QaAnswerAnswerSource { /** * The answer value from this source. */ answerValue?: GoogleCloudContactcenterinsightsV1QaAnswerAnswerValue; /** * What created the answer. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED" | "MANUAL_EDIT"; } /** * Message for holding the value of a QaAnswer. QaQuestion.AnswerChoice defines * the possible answer values for a question. */ export interface GoogleCloudContactcenterinsightsV1QaAnswerAnswerValue { /** * Boolean value. */ boolValue?: boolean; /** * A short string used as an identifier. Matches the value used in * QaQuestion.AnswerChoice.key. */ key?: string; /** * A value of "Not Applicable (N/A)". Should only ever be `true`. */ naValue?: boolean; /** * Output only. Normalized score of the questions. Calculated as score / * potential_score. */ readonly normalizedScore?: number; /** * Numerical value. */ numValue?: number; /** * Output only. The maximum potential score of the question. */ readonly potentialScore?: number; /** * Output only. Numerical score of the answer. */ readonly score?: number; /** * Output only. A value of "Skip". If provided, this field may only be set to * `true`. If a question receives this answer, it will be excluded from any * score calculations. This would mean that the question was not evaluated. */ readonly skipValue?: boolean; /** * String value. */ strValue?: string; } /** * A single question to be scored by the Insights QA feature. */ export interface GoogleCloudContactcenterinsightsV1QaQuestion { /** * Short, descriptive string, used in the UI where it's not practical to * display the full question body. E.g., "Greeting". */ abbreviation?: string; /** * A list of valid answers to the question, which the LLM must choose from. */ answerChoices?: GoogleCloudContactcenterinsightsV1QaQuestionAnswerChoice[]; /** * Instructions describing how to determine the answer. */ answerInstructions?: string; /** * Output only. The time at which this question was created. */ readonly createTime?: Date; /** * Metrics of the underlying tuned LLM over a holdout/test set while fine * tuning the underlying LLM for the given question. This field will only be * populated if and only if the question is part of a scorecard revision that * has been tuned. */ metrics?: GoogleCloudContactcenterinsightsV1QaQuestionMetrics; /** * Identifier. The resource name of the question. Format: * projects/{project}/locations/{location}/qaScorecards/{qa_scorecard}/revisions/{revision}/qaQuestions/{qa_question} */ name?: string; /** * Defines the order of the question within its parent scorecard revision. */ order?: number; /** * The configuration of the predefined question. This field will only be set * if the Question Type is predefined. */ predefinedQuestionConfig?: GoogleCloudContactcenterinsightsV1QaQuestionPredefinedQuestionConfig; /** * Question text. E.g., "Did the agent greet the customer?" */ questionBody?: string; /** * The type of question. */ questionType?: | "QA_QUESTION_TYPE_UNSPECIFIED" | "CUSTOMIZABLE" | "PREDEFINED"; /** * Questions are tagged for categorization and scoring. Tags can either be: - * Default Tags: These are predefined categories. They are identified by their * string value (e.g., "BUSINESS", "COMPLIANCE", and "CUSTOMER"). - Custom * Tags: These are user-defined categories. They are identified by their full * resource name (e.g., * projects/{project}/locations/{location}/qaQuestionTags/{qa_question_tag}). * Both default and custom tags are used to group questions and to influence * the scoring of each question. */ tags?: string[]; /** * Metadata about the tuning operation for the question.This field will only * be populated if and only if the question is part of a scorecard revision * that has been tuned. */ tuningMetadata?: GoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata; /** * Output only. The most recent time at which the question was updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1QaQuestion(data: any): GoogleCloudContactcenterinsightsV1QaQuestion { return { ...data, tuningMetadata: data["tuningMetadata"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata(data["tuningMetadata"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QaQuestion(data: any): GoogleCloudContactcenterinsightsV1QaQuestion { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, tuningMetadata: data["tuningMetadata"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata(data["tuningMetadata"]) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Message representing a possible answer to the question. */ export interface GoogleCloudContactcenterinsightsV1QaQuestionAnswerChoice { /** * Boolean value. */ boolValue?: boolean; /** * A short string used as an identifier. */ key?: string; /** * A value of "Not Applicable (N/A)". If provided, this field may only be set * to `true`. If a question receives this answer, it will be excluded from any * score calculations. */ naValue?: boolean; /** * Numerical value. */ numValue?: number; /** * Numerical score of the answer, used for generating the overall score of a * QaScorecardResult. If the answer uses na_value, this field is unused. */ score?: number; /** * String value. */ strValue?: string; } /** * A wrapper representing metrics calculated against a test-set on a LLM that * was fine tuned for this question. */ export interface GoogleCloudContactcenterinsightsV1QaQuestionMetrics { /** * Output only. Accuracy of the model. Measures the percentage of correct * answers the model gave on the test set. */ readonly accuracy?: number; } /** * Configuration for a predefined question. This field will only be set if the * Question Type is predefined. */ export interface GoogleCloudContactcenterinsightsV1QaQuestionPredefinedQuestionConfig { /** * The type of the predefined question. */ type?: | "PREDEFINED_QUESTION_TYPE_UNSPECIFIED" | "CONVERSATION_OUTCOME" | "CONVERSATION_OUTCOME_ESCALATION_INITIATOR_ROLE"; } /** * A tag is a resource which aims to categorize a set of questions across * multiple scorecards, e.g., "Customer Satisfaction","Billing", etc. */ export interface GoogleCloudContactcenterinsightsV1QaQuestionTag { /** * Output only. The time at which the question tag was created. */ readonly createTime?: Date; /** * Required. A user-specified display name for the tag. */ displayName?: string; /** * Identifier. Resource name for the QaQuestionTag Format * projects/{project}/locations/{location}/qaQuestionTags/{qa_question_tag} In * the above format, the last segment, i.e., qa_question_tag, is a * server-generated ID corresponding to the tag resource. */ name?: string; /** * Optional. The list of Scorecard Question IDs that the tag applies to. Each * QaQuestionId is represented as a full resource name containing the Question * ID. Lastly, Since a tag may not necessarily be referenced by any Scorecard * Questions, we treat this field as optional. */ qaQuestionIds?: string[]; /** * Output only. The most recent time at which the question tag was updated. */ readonly updateTime?: Date; } /** * Metadata about the tuning operation for the question. Will only be set if a * scorecard containing this question has been tuned. */ export interface GoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata { /** * A list of any applicable data validation warnings about the question's * feedback labels. */ datasetValidationWarnings?: | "DATASET_VALIDATION_WARNING_UNSPECIFIED" | "TOO_MANY_INVALID_FEEDBACK_LABELS" | "INSUFFICIENT_FEEDBACK_LABELS" | "INSUFFICIENT_FEEDBACK_LABELS_PER_ANSWER" | "ALL_FEEDBACK_LABELS_HAVE_THE_SAME_ANSWER"[]; /** * Total number of valid labels provided for the question at the time of * tuining. */ totalValidLabelCount?: bigint; /** * Error status of the tuning operation for the question. Will only be set if * the tuning operation failed. */ tuningError?: string; } function serializeGoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata(data: any): GoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata { return { ...data, totalValidLabelCount: data["totalValidLabelCount"] !== undefined ? String(data["totalValidLabelCount"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata(data: any): GoogleCloudContactcenterinsightsV1QaQuestionTuningMetadata { return { ...data, totalValidLabelCount: data["totalValidLabelCount"] !== undefined ? BigInt(data["totalValidLabelCount"]) : undefined, }; } /** * A QaScorecard represents a collection of questions to be scored during * analysis. */ export interface GoogleCloudContactcenterinsightsV1QaScorecard { /** * Output only. The time at which this scorecard was created. */ readonly createTime?: Date; /** * A text description explaining the intent of the scorecard. */ description?: string; /** * The user-specified display name of the scorecard. */ displayName?: string; /** * Whether the scorecard is the default one for the project. A default * scorecard cannot be deleted and will always appear first in scorecard * selector. */ isDefault?: boolean; /** * Identifier. The scorecard name. Format: * projects/{project}/locations/{location}/qaScorecards/{qa_scorecard} */ name?: string; /** * Output only. The source of the scorecard. */ readonly source?: | "QA_SCORECARD_SOURCE_UNSPECIFIED" | "QA_SCORECARD_SOURCE_CUSTOMER_DEFINED" | "QA_SCORECARD_SOURCE_DISCOVERY_ENGINE"; /** * Output only. The most recent time at which the scorecard was updated. */ readonly updateTime?: Date; } /** * The results of scoring a single conversation against a QaScorecard. Contains * a collection of QaAnswers and aggregate score. */ export interface GoogleCloudContactcenterinsightsV1QaScorecardResult { /** * ID of the agent that handled the conversation. */ agentId?: string; /** * The conversation scored by this result. */ conversation?: string; /** * Output only. The timestamp that the revision was created. */ readonly createTime?: Date; /** * Identifier. The name of the scorecard result. Format: * projects/{project}/locations/{location}/qaScorecardResults/{qa_scorecard_result} */ name?: string; /** * The normalized score, which is the score divided by the potential score. * Any manual edits are included if they exist. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Set of QaAnswers represented in the result. */ qaAnswers?: GoogleCloudContactcenterinsightsV1QaAnswer[]; /** * The QaScorecardRevision scored by this result. */ qaScorecardRevision?: string; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1QaScorecardResultQaTagResult[]; /** * The overall numerical score of the result, incorporating any manual edits * if they exist. */ score?: number; /** * List of all individual score sets. */ scoreSources?: GoogleCloudContactcenterinsightsV1QaScorecardResultScoreSource[]; } /** * Tags and their corresponding results. */ export interface GoogleCloudContactcenterinsightsV1QaScorecardResultQaTagResult { /** * The normalized score the tag applies to. */ normalizedScore?: number; /** * The potential score the tag applies to. */ potentialScore?: number; /** * The score the tag applies to. */ score?: number; /** * The tag the score applies to. */ tag?: string; } /** * A scorecard result may have multiple sets of scores from varying sources, * one of which becomes the "main" answer above. A ScoreSource represents each * individual set of scores. */ export interface GoogleCloudContactcenterinsightsV1QaScorecardResultScoreSource { /** * The normalized score, which is the score divided by the potential score. */ normalizedScore?: number; /** * The maximum potential overall score of the scorecard. Any questions * answered using `na_value` are excluded from this calculation. */ potentialScore?: number; /** * Collection of tags and their scores. */ qaTagResults?: GoogleCloudContactcenterinsightsV1QaScorecardResultQaTagResult[]; /** * The overall numerical score of the result. */ score?: number; /** * What created the score. */ sourceType?: | "SOURCE_TYPE_UNSPECIFIED" | "SYSTEM_GENERATED_ONLY" | "INCLUDES_MANUAL_EDITS"; } /** * A revision of a QaScorecard. Modifying published scorecard fields would * invalidate existing scorecard results — the questions may have changed, or * the score weighting will make existing scores impossible to understand. So * changes must create a new revision, rather than modifying the existing * resource. */ export interface GoogleCloudContactcenterinsightsV1QaScorecardRevision { /** * Output only. Alternative IDs for this revision of the scorecard, e.g., * `latest`. */ readonly alternateIds?: string[]; /** * Output only. The timestamp that the revision was created. */ readonly createTime?: Date; /** * Identifier. The name of the scorecard revision. Format: * projects/{project}/locations/{location}/qaScorecards/{qa_scorecard}/revisions/{revision} */ name?: string; /** * The snapshot of the scorecard at the time of this revision's creation. */ snapshot?: GoogleCloudContactcenterinsightsV1QaScorecard; /** * Output only. State of the scorecard revision, indicating whether it's * ready to be used in analysis. */ readonly state?: | "STATE_UNSPECIFIED" | "EDITABLE" | "TRAINING" | "TRAINING_FAILED" | "READY" | "DELETING" | "TRAINING_CANCELLED"; } /** * A time window for querying conversations. */ export interface GoogleCloudContactcenterinsightsV1QueryInterval { /** * Required. The end time of the time window. */ endTime?: Date; /** * Required. The start time of the time window. */ startTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1QueryInterval(data: any): GoogleCloudContactcenterinsightsV1QueryInterval { return { ...data, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryInterval(data: any): GoogleCloudContactcenterinsightsV1QueryInterval { return { ...data, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, }; } /** * The metadata from querying metrics. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsMetadata { /** * Whether the result rows were truncated because the result row size is too * large to materialize. */ resultIsTruncated?: boolean; } /** * The request for querying metrics. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsRequest { /** * The dimensions that determine the grouping key for the query. Defaults to * no dimension if this field is unspecified. If a dimension is specified, its * key must also be specified. Each dimension's key must be unique. If a time * granularity is also specified, metric values in the dimension will be * bucketed by this granularity. Up to one dimension is supported for now. */ dimensions?: GoogleCloudContactcenterinsightsV1Dimension[]; /** * Required. Filter to select a subset of conversations to compute the * metrics. Must specify a window of the conversation create time to compute * the metrics. The returned metrics will be from the range [DATE(starting * create time), DATE(ending create time)). */ filter?: string; /** * Measures to return. Defaults to all measures if this field is unspecified. * A valid mask should traverse from the `measure` field from the response. * For example, a path from a measure mask to get the conversation count is * "conversation_measure.count". */ measureMask?: string /* FieldMask */; /** * The time granularity of each data point in the time series. Defaults to * NONE if this field is unspecified. */ timeGranularity?: | "TIME_GRANULARITY_UNSPECIFIED" | "NONE" | "DAILY" | "HOURLY" | "PER_MINUTE" | "PER_5_MINUTES" | "MONTHLY"; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsRequest(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsRequest { return { ...data, measureMask: data["measureMask"] !== undefined ? data["measureMask"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsRequest(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsRequest { return { ...data, measureMask: data["measureMask"] !== undefined ? data["measureMask"] : undefined, }; } /** * The response for querying metrics. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponse { /** * Required. The location of the data. * "projects/{project}/locations/{location}" */ location?: string; /** * The macro average slice contains aggregated averages across all selected * dimensions. i.e. if group_by agent and scorecard_id is specified, this * field will contain the average across all agents and all scorecards. This * field is only populated if the request specifies a Dimension. */ macroAverageSlice?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice; /** * A slice contains a total and (if the request specified a time granularity) * a time series of metric values. Each slice contains a unique combination of * the cardinality of dimensions from the request. */ slices?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice[]; /** * The metrics last update time. */ updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? data["updateTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponse(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponse { return { ...data, macroAverageSlice: data["macroAverageSlice"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(data["macroAverageSlice"]) : undefined, slices: data["slices"] !== undefined ? data["slices"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(item))) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * A slice contains a total and (if the request specified a time granularity) a * time series of metric values. Each slice contains a unique combination of the * cardinality of dimensions from the request. For example, if the request * specifies a single ISSUE dimension and it has a cardinality of 2 (i.e. the * data used to compute the metrics has 2 issues in total), the response will * have 2 slices: * Slice 1 -> dimensions=[Issue 1] * Slice 2 -> * dimensions=[Issue 2] */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice { /** * A unique combination of dimensions that this slice represents. */ dimensions?: GoogleCloudContactcenterinsightsV1Dimension[]; /** * A time series of metric values. This is only populated if the request * specifies a time granularity other than NONE. */ timeSeries?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries; /** * The total metric value. The interval of this data point is [starting * create time, ending create time) from the request. */ total?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSlice { return { ...data, timeSeries: data["timeSeries"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries(data["timeSeries"]) : undefined, total: data["total"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(data["total"]) : undefined, }; } /** * A data point contains the metric values mapped to an interval. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint { /** * The measure related to conversations. */ conversationMeasure?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure; /** * The interval that this data point represents. * If this is the total data * point, the interval is [starting create time, ending create time) from the * request. * If this a data point from the time series, the interval is * [time, time + time granularity from the request). */ interval?: GoogleTypeInterval; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? serializeGoogleTypeInterval(data["interval"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint { return { ...data, conversationMeasure: data["conversationMeasure"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure(data["conversationMeasure"]) : undefined, interval: data["interval"] !== undefined ? deserializeGoogleTypeInterval(data["interval"]) : undefined, }; } /** * The measure related to conversations. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure { /** * The average agent's sentiment score. */ averageAgentSentimentScore?: number; /** * The average client's sentiment score. */ averageClientSentimentScore?: number; /** * The average customer satisfaction rating. */ averageCustomerSatisfactionRating?: number; /** * The average duration. */ averageDuration?: number /* Duration */; /** * The average normalized QA score for a scorecard. When computing the * average across a set of conversations, if a conversation has been evaluated * with multiple revisions of a scorecard, only the latest revision results * will be used. Will exclude 0's in average calculation. Will be only * populated if the request specifies a dimension of QA_SCORECARD_ID. */ averageQaNormalizedScore?: number; /** * Average QA normalized score averaged for questions averaged across all * revisions of the parent scorecard. Will be only populated if the request * specifies a dimension of QA_QUESTION_ID. */ averageQaQuestionNormalizedScore?: number; /** * The average silence percentage. */ averageSilencePercentage?: number; /** * The average turn count. */ averageTurnCount?: number; /** * The conversation count. */ conversationCount?: number; /** * Average QA normalized score for all the tags. */ qaTagScores?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasureQaTagScore[]; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasure { return { ...data, averageDuration: data["averageDuration"] !== undefined ? data["averageDuration"] : undefined, }; } /** * Average QA normalized score for the tag. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPointConversationMeasureQaTagScore { /** * Average tag normalized score per tag. */ averageTagNormalizedScore?: number; /** * Tag name. */ tag?: string; } /** * A time series of metric values. */ export interface GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries { /** * The data points that make up the time series . */ dataPoints?: GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint[]; } function serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (serializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(item))) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries(data: any): GoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceTimeSeries { return { ...data, dataPoints: data["dataPoints"] !== undefined ? data["dataPoints"].map((item: any) => (deserializeGoogleCloudContactcenterinsightsV1QueryMetricsResponseSliceDataPoint(item))) : undefined, }; } /** * The metadata for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewMetadata { } /** * The request for summarizing performance according to different metrics for * conversations over a specified time window. */ export interface GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest { /** * Conversations are from a single agent. */ agentPerformanceSource?: GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequestAgentSource; /** * The time window of the conversations to compare the performance to. */ comparisonQueryInterval?: GoogleCloudContactcenterinsightsV1QueryInterval; /** * Optional. Filter to select a subset of conversations to compute the * performance overview. Supports the same filters as the filter field in * QueryMetricsRequest. The source and query interval/comparison query * interval should not be included here. */ filter?: string; /** * Required. The time window of the conversations to derive performance stats * from. */ queryInterval?: GoogleCloudContactcenterinsightsV1QueryInterval; } function serializeGoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest(data: any): GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest { return { ...data, comparisonQueryInterval: data["comparisonQueryInterval"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryInterval(data["comparisonQueryInterval"]) : undefined, queryInterval: data["queryInterval"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1QueryInterval(data["queryInterval"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest(data: any): GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequest { return { ...data, comparisonQueryInterval: data["comparisonQueryInterval"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryInterval(data["comparisonQueryInterval"]) : undefined, queryInterval: data["queryInterval"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1QueryInterval(data["queryInterval"]) : undefined, }; } /** * The entity whose performance is being queried is a single agent. */ export interface GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewRequestAgentSource { /** * Required. Agent id to query performance overview for. */ agentId?: string; } /** * The response for querying performance overview. */ export interface GoogleCloudContactcenterinsightsV1QueryPerformanceOverviewResponse { /** * The summary text of the performance. */ summaryText?: string; } /** * DLP resources used for redaction while ingesting conversations. DLP settings * are applied to conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint or the Dialogflow / Agent Assist runtime * integrations. When using Dialogflow / Agent Assist runtime integrations, * redaction should be performed in Dialogflow / Agent Assist. */ export interface GoogleCloudContactcenterinsightsV1RedactionConfig { /** * The fully-qualified DLP deidentify template resource name. Format: * `projects/{project}/deidentifyTemplates/{template}` */ deidentifyTemplate?: string; /** * The fully-qualified DLP inspect template resource name. Format: * `projects/{project}/locations/{location}/inspectTemplates/{template}` */ inspectTemplate?: string; } /** * Regex match configuration. */ export interface GoogleCloudContactcenterinsightsV1RegexMatchConfig { } /** * An annotation that was generated during the customer and agent interaction. */ export interface GoogleCloudContactcenterinsightsV1RuntimeAnnotation { /** * The unique identifier of the annotation. Format: * projects/{project}/locations/{location}/conversationDatasets/{dataset}/conversationDataItems/{data_item}/conversationAnnotations/{annotation} */ annotationId?: string; /** * The feedback that the customer has about the answer in `data`. */ answerFeedback?: GoogleCloudContactcenterinsightsV1AnswerFeedback; /** * Agent Assist Article Suggestion data. */ articleSuggestion?: GoogleCloudContactcenterinsightsV1ArticleSuggestionData; /** * Conversation summarization suggestion data. */ conversationSummarizationSuggestion?: GoogleCloudContactcenterinsightsV1ConversationSummarizationSuggestionData; /** * The time at which this annotation was created. */ createTime?: Date; /** * Dialogflow interaction data. */ dialogflowInteraction?: GoogleCloudContactcenterinsightsV1DialogflowInteractionData; /** * The boundary in the conversation where the annotation ends, inclusive. */ endBoundary?: GoogleCloudContactcenterinsightsV1AnnotationBoundary; /** * Agent Assist FAQ answer data. */ faqAnswer?: GoogleCloudContactcenterinsightsV1FaqAnswerData; /** * Agent Assist Smart Compose suggestion data. */ smartComposeSuggestion?: GoogleCloudContactcenterinsightsV1SmartComposeSuggestionData; /** * Agent Assist Smart Reply data. */ smartReply?: GoogleCloudContactcenterinsightsV1SmartReplyData; /** * The boundary in the conversation where the annotation starts, inclusive. */ startBoundary?: GoogleCloudContactcenterinsightsV1AnnotationBoundary; /** * Explicit input used for generating the answer */ userInput?: GoogleCloudContactcenterinsightsV1RuntimeAnnotationUserInput; } function serializeGoogleCloudContactcenterinsightsV1RuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1RuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? data["createTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1RuntimeAnnotation(data: any): GoogleCloudContactcenterinsightsV1RuntimeAnnotation { return { ...data, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, }; } /** * Explicit input used for generating the answer */ export interface GoogleCloudContactcenterinsightsV1RuntimeAnnotationUserInput { /** * The resource name of associated generator. Format: * `projects//locations//generators/` */ generatorName?: string; /** * Query text. Article Search uses this to store the input query used to * generate the search results. */ query?: string; /** * Query source for the answer. */ querySource?: | "QUERY_SOURCE_UNSPECIFIED" | "AGENT_QUERY" | "SUGGESTED_QUERY"; } /** * The metadata for an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1SampleConversationsMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. Partial errors during sample conversations operation that * might cause the operation output to be incomplete. */ readonly partialErrors?: GoogleRpcStatus[]; /** * Output only. The original request for sample conversations to dataset. */ readonly request?: GoogleCloudContactcenterinsightsV1SampleConversationsRequest; /** * Output only. Statistics for SampleConversations operation. */ readonly sampleConversationsStats?: GoogleCloudContactcenterinsightsV1SampleConversationsMetadataSampleConversationsStats; } /** * Statistics for SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1SampleConversationsMetadataSampleConversationsStats { /** * Output only. The number of objects which were unable to be sampled due to * errors. The errors are populated in the partial_errors field. */ readonly failedSampleCount?: number; /** * Output only. The number of new conversations added during this sample * operation. */ readonly successfulSampleCount?: number; } /** * The request to sample conversations to a dataset. */ export interface GoogleCloudContactcenterinsightsV1SampleConversationsRequest { /** * The dataset resource to copy the sampled conversations to. */ destinationDataset?: GoogleCloudContactcenterinsightsV1Dataset; /** * Required. The parent resource of the dataset. */ parent?: string; /** * Optional. The sample rule used for sampling conversations. */ sampleRule?: GoogleCloudContactcenterinsightsV1SampleRule; } function serializeGoogleCloudContactcenterinsightsV1SampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1SampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1Dataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1SampleRule(data["sampleRule"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1SampleConversationsRequest(data: any): GoogleCloudContactcenterinsightsV1SampleConversationsRequest { return { ...data, destinationDataset: data["destinationDataset"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1Dataset(data["destinationDataset"]) : undefined, sampleRule: data["sampleRule"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1SampleRule(data["sampleRule"]) : undefined, }; } /** * The response to an SampleConversations operation. */ export interface GoogleCloudContactcenterinsightsV1SampleConversationsResponse { } /** * Message for sampling conversations. */ export interface GoogleCloudContactcenterinsightsV1SampleRule { /** * To specify the filter for the conversions that should apply this sample * rule. An empty filter means this sample rule applies to all conversations. */ conversationFilter?: string; /** * Optional. Group by dimension to sample the conversation. If no dimension * is provided, the sampling will be applied to the project level. Current * supported dimensions is 'quality_metadata.agent_info.agent_id'. */ dimension?: string; /** * Percentage of conversations that we should sample based on the dimension * between [0, 100]. */ samplePercentage?: number; /** * Number of the conversations that we should sample based on the dimension. */ sampleRow?: bigint; } function serializeGoogleCloudContactcenterinsightsV1SampleRule(data: any): GoogleCloudContactcenterinsightsV1SampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? String(data["sampleRow"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1SampleRule(data: any): GoogleCloudContactcenterinsightsV1SampleRule { return { ...data, sampleRow: data["sampleRow"] !== undefined ? BigInt(data["sampleRow"]) : undefined, }; } /** * Message for schedule info. */ export interface GoogleCloudContactcenterinsightsV1ScheduleInfo { /** * End time of the schedule. If not specified, will keep scheduling new * pipelines for execution util the schedule is no longer active or deleted. */ endTime?: Date; /** * The groc expression. Format: `every number [synchronized]` Time units can * be: minutes, hours Synchronized is optional and indicates that the schedule * should be synchronized to the start of the interval: every 5 minutes * synchronized means 00:00, 00:05 ... Otherwise the start time is random * within the interval. Example: `every 5 minutes` could be 00:02, 00:07, * 00:12, ... */ schedule?: string; /** * Start time of the schedule. If not specified, will start as soon as the * schedule is created. */ startTime?: Date; /** * The timezone to use for the groc expression. If not specified, defaults to * UTC. */ timeZone?: string; } function serializeGoogleCloudContactcenterinsightsV1ScheduleInfo(data: any): GoogleCloudContactcenterinsightsV1ScheduleInfo { return { ...data, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1ScheduleInfo(data: any): GoogleCloudContactcenterinsightsV1ScheduleInfo { return { ...data, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, }; } /** * The response from a ListAuthorizedViews request. */ export interface GoogleCloudContactcenterinsightsV1SearchAuthorizedViewsResponse { /** * The AuthorizedViews under the parent. */ authorizedViews?: GoogleCloudContactcenterinsightsV1AuthorizedView[]; /** * A token, which can be sent as `page_token` to retrieve the next page. If * this field is omitted, there are no subsequent pages. */ nextPageToken?: string; } /** * The data for a sentiment annotation. */ export interface GoogleCloudContactcenterinsightsV1SentimentData { /** * A non-negative number from 0 to infinity which represents the absolute * magnitude of sentiment regardless of score. */ magnitude?: number; /** * The sentiment score between -1.0 (negative) and 1.0 (positive). */ score?: number; } /** * The CCAI Insights project wide settings. Use these settings to configure the * behavior of Insights. View these settings with * [`getsettings`](https://cloud.google.com/contact-center/insights/docs/reference/rest/v1/projects.locations/getSettings) * and change the settings with * [`updateSettings`](https://cloud.google.com/contact-center/insights/docs/reference/rest/v1/projects.locations/updateSettings). */ export interface GoogleCloudContactcenterinsightsV1Settings { /** * Default analysis settings. */ analysisConfig?: GoogleCloudContactcenterinsightsV1SettingsAnalysisConfig; /** * The default TTL for newly-created conversations. If a conversation has a * specified expiration, that value will be used instead. Changing this value * will not change the expiration of existing conversations. Conversations * with no expire time persist until they are deleted. */ conversationTtl?: number /* Duration */; /** * Output only. The time at which the settings was created. */ readonly createTime?: Date; /** * A language code to be applied to each transcript segment unless the * segment already specifies a language code. Language code defaults to * "en-US" if it is neither specified on the segment nor here. */ languageCode?: string; /** * Immutable. The resource name of the settings resource. Format: * projects/{project}/locations/{location}/settings */ name?: string; /** * A map that maps a notification trigger to a Pub/Sub topic. Each time a * specified trigger occurs, Insights will notify the corresponding Pub/Sub * topic. Keys are notification triggers. Supported keys are: * * "all-triggers": Notify each time any of the supported triggers occurs. * * "create-analysis": Notify each time an analysis is created. * * "create-conversation": Notify each time a conversation is created. * * "export-insights-data": Notify each time an export is complete. * * "ingest-conversations": Notify each time an IngestConversations LRO is * complete. * "update-conversation": Notify each time a conversation is * updated via UpdateConversation. * "upload-conversation": Notify when an * UploadConversation LRO is complete. * "update-or-analyze-conversation": * Notify when an analysis for a conversation is completed or when the * conversation is updated. The message will contain the conversation with * transcript, analysis and other metadata. Values are Pub/Sub topics. The * format of each Pub/Sub topic is: projects/{project}/topics/{topic} */ pubsubNotificationSettings?: { [key: string]: string }; /** * Default DLP redaction resources to be applied while ingesting * conversations. This applies to conversations ingested from the * `UploadConversation` and `IngestConversations` endpoints, including * conversations coming from CCAI Platform. */ redactionConfig?: GoogleCloudContactcenterinsightsV1RedactionConfig; /** * Optional. The path to a Cloud Storage bucket containing conversation * screen recordings. If provided, Insights will search in the bucket for a * screen recording file matching the conversation data source object name * prefix. If matches are found, these file URIs will be stored in the * conversation screen recordings field. */ screenRecordingBucketUri?: string; /** * Optional. Default Speech-to-Text resources to use while ingesting audio * files. Optional, CCAI Insights will create a default if not provided. This * applies to conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversations coming from CCAI * Platform. */ speechConfig?: GoogleCloudContactcenterinsightsV1SpeechConfig; /** * Output only. The time at which the settings were last updated. */ readonly updateTime?: Date; } function serializeGoogleCloudContactcenterinsightsV1Settings(data: any): GoogleCloudContactcenterinsightsV1Settings { return { ...data, conversationTtl: data["conversationTtl"] !== undefined ? data["conversationTtl"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1Settings(data: any): GoogleCloudContactcenterinsightsV1Settings { return { ...data, conversationTtl: data["conversationTtl"] !== undefined ? data["conversationTtl"] : undefined, createTime: data["createTime"] !== undefined ? new Date(data["createTime"]) : undefined, updateTime: data["updateTime"] !== undefined ? new Date(data["updateTime"]) : undefined, }; } /** * Default configuration when creating Analyses in Insights. */ export interface GoogleCloudContactcenterinsightsV1SettingsAnalysisConfig { /** * To select the annotators to run and the phrase matchers to use (if any). * If not specified, all annotators will be run. */ annotatorSelector?: GoogleCloudContactcenterinsightsV1AnnotatorSelector; /** * Percentage of conversations created using Dialogflow runtime integration * to analyze automatically, between [0, 100]. */ runtimeIntegrationAnalysisPercentage?: number; /** * Percentage of conversations created using the UploadConversation endpoint * to analyze automatically, between [0, 100]. */ uploadConversationAnalysisPercentage?: number; } /** * The data for a silence annotation. */ export interface GoogleCloudContactcenterinsightsV1SilenceData { } /** * Agent Assist Smart Compose suggestion data. */ export interface GoogleCloudContactcenterinsightsV1SmartComposeSuggestionData { /** * The system's confidence score that this suggestion is a good match for * this conversation, ranging from 0.0 (completely uncertain) to 1.0 * (completely certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Compose suggestion and the * document from which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the suggestion. */ suggestion?: string; } /** * Agent Assist Smart Reply data. */ export interface GoogleCloudContactcenterinsightsV1SmartReplyData { /** * The system's confidence score that this reply is a good match for this * conversation, ranging from 0.0 (completely uncertain) to 1.0 (completely * certain). */ confidenceScore?: number; /** * Map that contains metadata about the Smart Reply and the document from * which it originates. */ metadata?: { [key: string]: string }; /** * The name of the answer record. Format: * projects/{project}/locations/{location}/answerRecords/{answer_record} */ queryRecord?: string; /** * The content of the reply. */ reply?: string; } /** * Speech-to-Text configuration. Speech-to-Text settings are applied to * conversations ingested from the `UploadConversation` and * `IngestConversations` endpoints, including conversation coming from CCAI * Platform. They are not applied to conversations ingested from the * `CreateConversation` endpoint. */ export interface GoogleCloudContactcenterinsightsV1SpeechConfig { /** * The fully-qualified Speech Recognizer resource name. Format: * `projects/{project_id}/locations/{location}/recognizer/{recognizer}` */ speechRecognizer?: string; } /** * Request for TuneQaScorecardRevision endpoint. */ export interface GoogleCloudContactcenterinsightsV1TuneQaScorecardRevisionRequest { /** * Required. Filter for selecting the feedback labels that needs to be used * for training. This filter can be used to limit the feedback labels used for * tuning to a feedback labels created or updated for a specific time-window * etc. */ filter?: string; /** * Optional. Run in validate only mode, no fine tuning will actually run. * Data quality validations like training data distributions will run. Even * when set to false, the data quality validations will still run but once the * validations complete we will proceed with the fine tune, if applicable. */ validateOnly?: boolean; } /** * Metadata for undeploying an issue model. */ export interface GoogleCloudContactcenterinsightsV1UndeployIssueModelMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * The original request for undeployment. */ request?: GoogleCloudContactcenterinsightsV1UndeployIssueModelRequest; } /** * The request to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1UndeployIssueModelRequest { /** * Required. The issue model to undeploy. */ name?: string; } /** * The response to undeploy an issue model. */ export interface GoogleCloudContactcenterinsightsV1UndeployIssueModelResponse { } /** * The request to undeploy a QaScorecardRevision */ export interface GoogleCloudContactcenterinsightsV1UndeployQaScorecardRevisionRequest { } /** * The metadata for updating a QaQuestionTag Resource. */ export interface GoogleCloudContactcenterinsightsV1UpdateQaQuestionTagMetadata { /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest; } /** * The request for updating a QaQuestionTag. */ export interface GoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest { /** * Required. The QaQuestionTag to update. */ qaQuestionTag?: GoogleCloudContactcenterinsightsV1QaQuestionTag; /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `qa_question_tag_name` - the name of the tag * * `qa_question_ids` - the list of questions the tag applies to */ updateMask?: string /* FieldMask */; } function serializeGoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest(data: any): GoogleCloudContactcenterinsightsV1UpdateQaQuestionTagRequest { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * The metadata for an `UploadConversation` operation. */ export interface GoogleCloudContactcenterinsightsV1UploadConversationMetadata { /** * Output only. The operation name for a successfully created analysis * operation, if any. */ readonly analysisOperation?: string; /** * Output only. The redaction config applied to the uploaded conversation. */ readonly appliedRedactionConfig?: GoogleCloudContactcenterinsightsV1RedactionConfig; /** * Output only. The time the operation was created. */ readonly createTime?: Date; /** * Output only. The time the operation finished running. */ readonly endTime?: Date; /** * Output only. The original request. */ readonly request?: GoogleCloudContactcenterinsightsV1UploadConversationRequest; } /** * Request to upload a conversation. */ export interface GoogleCloudContactcenterinsightsV1UploadConversationRequest { /** * Required. The conversation resource to create. */ conversation?: GoogleCloudContactcenterinsightsV1Conversation; /** * Optional. A unique ID for the new conversation. This ID will become the * final component of the conversation's resource name. If no ID is specified, * a server-generated ID will be used. This value should be 4-64 characters * and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters * are `a-z-` */ conversationId?: string; /** * Required. The parent resource of the conversation. */ parent?: string; /** * Optional. DLP settings for transcript redaction. Will default to the * config specified in Settings. */ redactionConfig?: GoogleCloudContactcenterinsightsV1RedactionConfig; /** * Optional. Speech-to-Text configuration. Will default to the config * specified in Settings. */ speechConfig?: GoogleCloudContactcenterinsightsV1SpeechConfig; } function serializeGoogleCloudContactcenterinsightsV1UploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1UploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? serializeGoogleCloudContactcenterinsightsV1Conversation(data["conversation"]) : undefined, }; } function deserializeGoogleCloudContactcenterinsightsV1UploadConversationRequest(data: any): GoogleCloudContactcenterinsightsV1UploadConversationRequest { return { ...data, conversation: data["conversation"] !== undefined ? deserializeGoogleCloudContactcenterinsightsV1Conversation(data["conversation"]) : undefined, }; } /** * Information about a user. */ export interface GoogleCloudContactcenterinsightsV1UserInfo { /** * The user's username. */ username?: string; } /** * The View resource. */ export interface GoogleCloudContactcenterinsightsV1View { /** * Output only. The time at which this view was created. */ readonly createTime?: Date; /** * The human-readable display name of the view. */ displayName?: string; /** * Immutable. The resource name of the view. Format: * projects/{project}/locations/{location}/views/{view} */ name?: string; /** * Output only. The most recent time at which the view was updated. */ readonly updateTime?: Date; /** * A filter to reduce conversation results to a specific subset. Refer to * https://cloud.google.com/contact-center/insights/docs/filtering for * details. */ value?: string; } /** * Specifies the audit configuration for a service. The configuration * determines which permission types are logged, and what identities, if any, * are exempted from logging. An AuditConfig must have one or more * AuditLogConfigs. If there are AuditConfigs for both `allServices` and a * specific service, the union of the two AuditConfigs is used for that service: * the log_types specified in each AuditConfig are enabled, and the * exempted_members in each AuditLogConfig are exempted. Example Policy with * multiple AuditConfigs: { "audit_configs": [ { "service": "allServices", * "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ * "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, { "log_type": * "ADMIN_READ" } ] }, { "service": "sampleservice.googleapis.com", * "audit_log_configs": [ { "log_type": "DATA_READ" }, { "log_type": * "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For * sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ * logging. It also exempts `jose@example.com` from DATA_READ logging, and * `aliya@example.com` from DATA_WRITE logging. */ export interface GoogleIamV1AuditConfig { /** * The configuration for logging of each type of permission. */ auditLogConfigs?: GoogleIamV1AuditLogConfig[]; /** * Specifies a service that will be enabled for audit logging. For example, * `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a * special value that covers all services. */ service?: string; } /** * Provides the configuration for logging a type of permissions. Example: { * "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ * "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" } ] } This enables * 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from * DATA_READ logging. */ export interface GoogleIamV1AuditLogConfig { /** * Specifies the identities that do not cause logging for this type of * permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; /** * The log type that this config enables. */ logType?: | "LOG_TYPE_UNSPECIFIED" | "ADMIN_READ" | "DATA_WRITE" | "DATA_READ"; } /** * Associates `members`, or principals, with a `role`. */ export interface GoogleIamV1Binding { /** * The condition that is associated with this binding. If the condition * evaluates to `true`, then this binding applies to the current request. If * the condition evaluates to `false`, then this binding does not apply to the * current request. However, a different role binding might grant the same * role to one or more of the principals in this binding. To learn which * resources support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ condition?: GoogleTypeExpr; /** * Specifies the principals requesting access for a Google Cloud resource. * `members` can have the following values: * `allUsers`: A special identifier * that represents anyone who is on the internet; with or without a Google * account. * `allAuthenticatedUsers`: A special identifier that represents * anyone who is authenticated with a Google account or a service account. * Does not include identities that come from external identity providers * (IdPs) through identity federation. * `user:{emailid}`: An email address * that represents a specific Google account. For example, `alice@example.com` * . * `serviceAccount:{emailid}`: An email address that represents a Google * service account. For example, `my-other-app@appspot.gserviceaccount.com`. * * `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An * identifier for a [Kubernetes service * account](https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts). * For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. * * `group:{emailid}`: An email address that represents a Google group. For * example, `admins@example.com`. * `domain:{domain}`: The G Suite domain * (primary) that represents all the users of that domain. For example, * `google.com` or `example.com`. * * `principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/subject/{subject_attribute_value}`: * A single identity in a workforce identity pool. * * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/group/{group_id}`: * All workforce identities in a group. * * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/attribute.{attribute_name}/{attribute_value}`: * All workforce identities with a specific attribute value. * * `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/*`: * All identities in a workforce identity pool. * * `principal://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/subject/{subject_attribute_value}`: * A single identity in a workload identity pool. * * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/group/{group_id}`: * A workload identity pool group. * * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}`: * All identities in a workload identity pool with a certain attribute. * * `principalSet://iam.googleapis.com/projects/{project_number}/locations/global/workloadIdentityPools/{pool_id}/*`: * All identities in a workload identity pool. * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique * identifier) representing a user that has been recently deleted. For * example, `alice@example.com?uid=123456789012345678901`. If the user is * recovered, this value reverts to `user:{emailid}` and the recovered user * retains the role in the binding. * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus * unique identifier) representing a service account that has been recently * deleted. For example, * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If * the service account is undeleted, this value reverts to * `serviceAccount:{emailid}` and the undeleted service account retains the * role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email * address (plus unique identifier) representing a Google group that has been * recently deleted. For example, * `admins@example.com?uid=123456789012345678901`. If the group is recovered, * this value reverts to `group:{emailid}` and the recovered group retains the * role in the binding. * * `deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/subject/{subject_attribute_value}`: * Deleted single identity in a workforce identity pool. For example, * `deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-pool-id/subject/my-subject-attribute-value`. */ members?: string[]; /** * Role that is assigned to the list of `members`, or principals. For * example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview * of the IAM roles and permissions, see the [IAM * documentation](https://cloud.google.com/iam/docs/roles-overview). For a * list of the available pre-defined roles, see * [here](https://cloud.google.com/iam/docs/understanding-roles). */ role?: string; } /** * An Identity and Access Management (IAM) policy, which specifies access * controls for Google Cloud resources. A `Policy` is a collection of * `bindings`. A `binding` binds one or more `members`, or principals, to a * single `role`. Principals can be user accounts, service accounts, Google * groups, and domains (such as G Suite). A `role` is a named list of * permissions; each `role` can be an IAM predefined role or a user-created * custom role. For some types of Google Cloud resources, a `binding` can also * specify a `condition`, which is a logical expression that allows access to a * resource only if the expression evaluates to `true`. A condition can add * constraints based on attributes of the request, the resource, or both. To * learn which resources support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). * **JSON example:** ``` { "bindings": [ { "role": * "roles/resourcemanager.organizationAdmin", "members": [ * "user:mike@example.com", "group:admins@example.com", "domain:google.com", * "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role": * "roles/resourcemanager.organizationViewer", "members": [ * "user:eve@example.com" ], "condition": { "title": "expirable access", * "description": "Does not grant access after Sep 2020", "expression": * "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag": * "BwWWja0YfJA=", "version": 3 } ``` **YAML example:** ``` bindings: - members: * - user:mike@example.com - group:admins@example.com - domain:google.com - * serviceAccount:my-project-id@appspot.gserviceaccount.com role: * roles/resourcemanager.organizationAdmin - members: - user:eve@example.com * role: roles/resourcemanager.organizationViewer condition: title: expirable * access description: Does not grant access after Sep 2020 expression: * request.time < timestamp('2020-10-01T00:00:00.000Z') etag: BwWWja0YfJA= * version: 3 ``` For a description of IAM and its features, see the [IAM * documentation](https://cloud.google.com/iam/docs/). */ export interface GoogleIamV1Policy { /** * Specifies cloud audit logging configuration for this policy. */ auditConfigs?: GoogleIamV1AuditConfig[]; /** * Associates a list of `members`, or principals, with a `role`. Optionally, * may specify a `condition` that determines how and when the `bindings` are * applied. Each of the `bindings` must contain at least one principal. The * `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 of * these principals can be Google groups. Each occurrence of a principal * counts towards these limits. For example, if the `bindings` grant 50 * different roles to `user:alice@example.com`, and not to any other * principal, then you can add another 1,450 principals to the `bindings` in * the `Policy`. */ bindings?: GoogleIamV1Binding[]; /** * `etag` is used for optimistic concurrency control as a way to help prevent * simultaneous updates of a policy from overwriting each other. It is * strongly suggested that systems make use of the `etag` in the * read-modify-write cycle to perform policy updates in order to avoid race * conditions: An `etag` is returned in the response to `getIamPolicy`, and * systems are expected to put that etag in the request to `setIamPolicy` to * ensure that their change will be applied to the same version of the policy. * **Important:** If you use IAM Conditions, you must include the `etag` field * whenever you call `setIamPolicy`. If you omit this field, then IAM allows * you to overwrite a version `3` policy with a version `1` policy, and all of * the conditions in the version `3` policy are lost. */ etag?: Uint8Array; /** * Specifies the format of the policy. Valid values are `0`, `1`, and `3`. * Requests that specify an invalid value are rejected. Any operation that * affects conditional role bindings must specify version `3`. This * requirement applies to the following operations: * Getting a policy that * includes a conditional role binding * Adding a conditional role binding to * a policy * Changing a conditional role binding in a policy * Removing any * role binding, with or without a condition, from a policy that includes * conditions **Important:** If you use IAM Conditions, you must include the * `etag` field whenever you call `setIamPolicy`. If you omit this field, then * IAM allows you to overwrite a version `3` policy with a version `1` policy, * and all of the conditions in the version `3` policy are lost. If a policy * does not include any conditions, operations on that policy may specify any * valid version or leave the field unset. To learn which resources support * conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ version?: number; } function serializeGoogleIamV1Policy(data: any): GoogleIamV1Policy { return { ...data, etag: data["etag"] !== undefined ? encodeBase64(data["etag"]) : undefined, }; } function deserializeGoogleIamV1Policy(data: any): GoogleIamV1Policy { return { ...data, etag: data["etag"] !== undefined ? decodeBase64(data["etag"] as string) : undefined, }; } /** * Request message for `SetIamPolicy` method. */ export interface GoogleIamV1SetIamPolicyRequest { /** * REQUIRED: The complete policy to be applied to the `resource`. The size of * the policy is limited to a few 10s of KB. An empty policy is a valid policy * but certain Google Cloud services (such as Projects) might reject them. */ policy?: GoogleIamV1Policy; /** * OPTIONAL: A FieldMask specifying which fields of the policy to modify. * Only the fields in the mask will be modified. If no mask is provided, the * following default mask is used: `paths: "bindings, etag"` */ updateMask?: string /* FieldMask */; } function serializeGoogleIamV1SetIamPolicyRequest(data: any): GoogleIamV1SetIamPolicyRequest { return { ...data, policy: data["policy"] !== undefined ? serializeGoogleIamV1Policy(data["policy"]) : undefined, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeGoogleIamV1SetIamPolicyRequest(data: any): GoogleIamV1SetIamPolicyRequest { return { ...data, policy: data["policy"] !== undefined ? deserializeGoogleIamV1Policy(data["policy"]) : undefined, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Request message for `TestIamPermissions` method. */ export interface GoogleIamV1TestIamPermissionsRequest { /** * The set of permissions to check for the `resource`. Permissions with * wildcards (such as `*` or `storage.*`) are not allowed. For more * information see [IAM * Overview](https://cloud.google.com/iam/docs/overview#permissions). */ permissions?: string[]; } /** * Response message for `TestIamPermissions` method. */ export interface GoogleIamV1TestIamPermissionsResponse { /** * A subset of `TestPermissionsRequest.permissions` that the caller is * allowed. */ permissions?: string[]; } /** * The response message for Operations.ListOperations. */ export interface GoogleLongrunningListOperationsResponse { /** * The standard List next-page token. */ nextPageToken?: string; /** * A list of operations that matches the specified filter in the request. */ operations?: GoogleLongrunningOperation[]; /** * Unordered list. Unreachable resources. Populated when the request sets * `ListOperationsRequest.return_partial_success` and reads across * collections. For example, when attempting to list all resources across all * supported locations. */ unreachable?: string[]; } /** * This resource represents a long-running operation that is the result of a * network API call. */ export interface GoogleLongrunningOperation { /** * If the value is `false`, it means the operation is still in progress. If * `true`, the operation is completed, and either `error` or `response` is * available. */ done?: boolean; /** * The error result of the operation in case of failure or cancellation. */ error?: GoogleRpcStatus; /** * Service-specific metadata associated with the operation. It typically * contains progress information and common metadata such as create time. Some * services might not provide such metadata. Any method that returns a * long-running operation should document the metadata type, if any. */ metadata?: { [key: string]: any }; /** * The server-assigned name, which is only unique within the same service * that originally returns it. If you use the default HTTP mapping, the `name` * should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** * The normal, successful response of the operation. If the original method * returns no data on success, such as `Delete`, the response is * `google.protobuf.Empty`. If the original method is standard * `Get`/`Create`/`Update`, the response should be the resource. For other * methods, the response should have the type `XxxResponse`, where `Xxx` is * the original method name. For example, if the original method name is * `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. */ response?: { [key: string]: any }; } /** * A generic empty message that you can re-use to avoid defining duplicated * empty messages in your APIs. A typical example is to use it as the request or * the response type of an API method. For instance: service Foo { rpc * Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } */ export interface GoogleProtobufEmpty { } /** * The `Status` type defines a logical error model that is suitable for * different programming environments, including REST APIs and RPC APIs. It is * used by [gRPC](https://github.com/grpc). Each `Status` message contains three * pieces of data: error code, error message, and error details. You can find * out more about this error model and how to work with it in the [API Design * Guide](https://cloud.google.com/apis/design/errors). */ export interface GoogleRpcStatus { /** * The status code, which should be an enum value of google.rpc.Code. */ code?: number; /** * A list of messages that carry the error details. There is a common set of * message types for APIs to use. */ details?: { [key: string]: any }[]; /** * A developer-facing error message, which should be in English. Any * user-facing error message should be localized and sent in the * google.rpc.Status.details field, or localized by the client. */ message?: string; } /** * Represents a textual expression in the Common Expression Language (CEL) * syntax. CEL is a C-like expression language. The syntax and semantics of CEL * are documented at https://github.com/google/cel-spec. Example (Comparison): * title: "Summary size limit" description: "Determines if a summary is less * than 100 chars" expression: "document.summary.size() < 100" Example * (Equality): title: "Requestor is owner" description: "Determines if requestor * is the document owner" expression: "document.owner == * request.auth.claims.email" Example (Logic): title: "Public documents" * description: "Determine whether the document should be publicly visible" * expression: "document.type != 'private' && document.type != 'internal'" * Example (Data Manipulation): title: "Notification string" description: * "Create a notification string with a timestamp." expression: "'New message * received at ' + string(document.create_time)" The exact variables and * functions that may be referenced within an expression are determined by the * service that evaluates it. See the service documentation for additional * information. */ export interface GoogleTypeExpr { /** * Optional. Description of the expression. This is a longer text which * describes the expression, e.g. when hovered over it in a UI. */ description?: string; /** * Textual representation of an expression in Common Expression Language * syntax. */ expression?: string; /** * Optional. String indicating the location of the expression for error * reporting, e.g. a file name and a position in the file. */ location?: string; /** * Optional. Title for the expression, i.e. a short string describing its * purpose. This can be used e.g. in UIs which allow to enter the expression. */ title?: string; } /** * Represents a time interval, encoded as a Timestamp start (inclusive) and a * Timestamp end (exclusive). The start must be less than or equal to the end. * When the start equals the end, the interval is empty (matches no time). When * both start and end are unspecified, the interval matches any time. */ export interface GoogleTypeInterval { /** * Optional. Exclusive end of the interval. If specified, a Timestamp * matching this interval will have to be before the end. */ endTime?: Date; /** * Optional. Inclusive start of the interval. If specified, a Timestamp * matching this interval will have to be the same or after the start. */ startTime?: Date; } function serializeGoogleTypeInterval(data: any): GoogleTypeInterval { return { ...data, endTime: data["endTime"] !== undefined ? data["endTime"].toISOString() : undefined, startTime: data["startTime"] !== undefined ? data["startTime"].toISOString() : undefined, }; } function deserializeGoogleTypeInterval(data: any): GoogleTypeInterval { return { ...data, endTime: data["endTime"] !== undefined ? new Date(data["endTime"]) : undefined, startTime: data["startTime"] !== undefined ? new Date(data["startTime"]) : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAnalysisRulesList. */ export interface ProjectsLocationsAnalysisRulesListOptions { /** * Optional. The maximum number of analysis rule to return in the response. * If this value is zero, the service will select a default size. A call may * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAnalysisRulesResponse`; * indicates that this is a continuation of a prior `ListAnalysisRules` call * and the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAnalysisRulesPatch. */ export interface ProjectsLocationsAnalysisRulesPatchOptions { /** * Optional. The list of fields to be updated. If the update_mask is not * provided, the update will be applied to all fields. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAnalysisRulesPatchOptions(data: any): ProjectsLocationsAnalysisRulesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAnalysisRulesPatchOptions(data: any): ProjectsLocationsAnalysisRulesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAssessmentRulesCreate. */ export interface ProjectsLocationsAssessmentRulesCreateOptions { /** * Optional. A unique ID for the new AssessmentRule. This ID will become the * final component of the AssessmentRule's resource name. If no ID is * specified, a server-generated ID will be used. This value should be 4-64 * characters and must match the regular expression * `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. */ assessmentRuleId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAssessmentRulesList. */ export interface ProjectsLocationsAssessmentRulesListOptions { /** * Optional. The maximum number of assessment rule to return in the response. * If this value is zero, the service will select a default size. A call may * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAssessmentRulesResponse`; * indicates that this is a continuation of a prior `ListAssessmentRules` call * and the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAssessmentRulesPatch. */ export interface ProjectsLocationsAssessmentRulesPatchOptions { /** * Optional. The list of fields to be updated. If the update_mask is not * provided, the update will be applied to all fields. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAssessmentRulesPatchOptions(data: any): ProjectsLocationsAssessmentRulesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAssessmentRulesPatchOptions(data: any): ProjectsLocationsAssessmentRulesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsDelete. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsDeleteOptions { /** * Optional. If set to true, all of this assessment's notes will also be * deleted. Otherwise, the request will only succeed if it has no notes. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supported * filters include: * `state` - The state of the assessment * * `agent_info.agent_id` - The ID of the agent the assessment is for */ filter?: string; /** * The maximum number of assessments to list. If zero, the service will * select a default size. A call may return fewer objects than requested. A * non-empty `next_page_token` in the response indicates that more data is * available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAssessmentRulesResponse`; * indicates that this is a continuation of a prior `ListAssessmentRules` call * and the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesListOptions { /** * Optional. The maximum number of notes to return in the response. If zero * the service will select a default size. A call might return fewer objects * than requested. A non-empty `next_page_token` in the response indicates * that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListNotesResponse`. This value * indicates that this is a continuation of a prior `ListNotes` call and that * the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatch. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions { /** * Optional. The list of fields to be updated. If the update_mask is empty, * all updateable fields will be updated. Acceptable fields include: * * `content` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsAssessmentsNotesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsCalculateStats. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsCalculateStatsOptions { /** * A filter to reduce results to a specific subset. This field is useful for * getting statistics about conversations with specific properties. */ filter?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsDelete. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsDeleteOptions { /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsCreate. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsCreateOptions { /** * Optional. The ID of the feedback label to create. If one is not specified * it will be generated by the server. */ feedbackLabelId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Automatically sorts by * conversation ID. To sort by all feedback labels in a project see * ListAllFeedbackLabels. Supported fields: * `issue_model_id` * * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Optional. The maximum number of feedback labels to return in the response. * A valid page size ranges from 0 to 100,000 inclusive. If the page size is * zero or unspecified, a default page size of 100 will be chosen. Note that a * call might return fewer results than the requested page size. */ pageSize?: number; /** * Optional. The value returned by the last `ListFeedbackLabelsResponse`. * This value indicates that this is a continuation of a prior * `ListFeedbackLabels` call and that the system should return the next page * of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatch. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions { /** * Required. The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsGet. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsGetOptions { /** * The level of details of the conversation. Default is `FULL`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsConversationsListOptions { /** * A filter to reduce results to a specific subset. Useful for querying * conversations with specific properties. */ filter?: string; /** * Optional. The attribute by which to order conversations in the response. * If empty, conversations will be ordered by descending creation time. * Supported values are one of the following: * create_time * * customer_satisfaction_rating * duration * latest_analysis * start_time * * turn_count The default sort order is ascending. To specify order, append * `asc` or `desc` (`create_time desc`). For more details, see [Google AIPs * Ordering](https://google.aip.dev/132#ordering). */ orderBy?: string; /** * The maximum number of conversations to return in the response. A valid * page size ranges from 0 to 100,000 inclusive. If the page size is zero or * unspecified, a default page size of 100 will be chosen. Note that a call * might return fewer results than the requested page size. */ pageSize?: number; /** * The value returned by the last `ListConversationsResponse`. This value * indicates that this is a continuation of a prior `ListConversations` call * and that the system should return the next page of data. */ pageToken?: string; /** * The level of details of the conversation. Default is `BASIC`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsCreate. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsCreateOptions { /** * Optional. A unique ID for the new AuthorizedView. This ID will become the * final component of the AuthorizedView's resource name. If no ID is * specified, a server-generated ID will be used. This value should be 4-64 * characters and must match the regular expression * `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. See * https://google.aip.dev/122#resource-id-segments */ authorizedViewId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsGetIamPolicy. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsGetIamPolicyOptions { /** * Optional. The maximum policy version that will be used to format the * policy. Valid values are 0, 1, and 3. Requests specifying an invalid value * will be rejected. Requests for policies with any conditional role bindings * must specify version 3. Policies with no conditional role bindings may * specify any valid value or leave the field unset. The policy in the * response might use the policy version that you specified, or it might use a * lower policy version. For example, if you specify version 3, but the policy * has no conditional role bindings, the response uses version 1. To learn * which resources support conditions in their IAM policies, see the [IAM * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ ["options.requestedPolicyVersion"]?: number; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsListOptions { /** * Optional. The filter expression to filter authorized views listed in the * response. */ filter?: string; /** * Optional. The order by expression to order authorized views listed in the * response. */ orderBy?: string; /** * Optional. The maximum number of view to return in the response. If the * value is zero, the service will select a default size. A call might return * fewer objects than requested. A non-empty `next_page_token` in the response * indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAuthorizedViewsResponse`. * This value indicates that this is a continuation of a prior * `ListAuthorizedViews` call and that the system should return the next page * of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsList. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsOperationsListOptions { /** * The standard list filter. */ filter?: string; /** * The standard list page size. */ pageSize?: number; /** * The standard list page token. */ pageToken?: string; /** * When set to `true`, operations that are reachable are returned as normal, * and those that are unreachable are returned in the * ListOperationsResponse.unreachable field. This can only be `true` when * reading across collections. For example, when `parent` is set to * `"projects/example/locations/-"`. This field is not supported by default * and will result in an `UNIMPLEMENTED` error if set unless explicitly * documented otherwise in service or product specific documentation. */ returnPartialSuccess?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsPatch. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions { /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `conversation_filter` * `display_name` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsAuthorizedViewsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsAuthorizedViewsSearch. */ export interface ProjectsLocationsAuthorizedViewSetsAuthorizedViewsSearchOptions { /** * Optional. The order by expression to order authorized views listed in the * response. */ orderBy?: string; /** * Optional. The maximum number of view to return in the response. If the * value is zero, the service will select a default size. A call might return * fewer objects than requested. A non-empty `next_page_token` in the response * indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAuthorizedViewsResponse`. * This value indicates that this is a continuation of a prior * `ListAuthorizedViews` call and that the system should return the next page * of data. */ pageToken?: string; /** * Optional. The query expression to search authorized views. */ query?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsCreate. */ export interface ProjectsLocationsAuthorizedViewSetsCreateOptions { /** * Optional. A unique ID for the new AuthorizedViewSet. This ID will become * the final component of the AuthorizedViewSet's resource name. If no ID is * specified, a server-generated ID will be used. This value should be 4-64 * characters and must match the regular expression * `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. See * https://google.aip.dev/122#resource-id-segments */ authorizedViewSetId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsDelete. */ export interface ProjectsLocationsAuthorizedViewSetsDeleteOptions { /** * Optional. If set to true, all of this AuthorizedViewSet's child resources * will also be deleted. Otherwise, the request will only succeed if it has * none. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsList. */ export interface ProjectsLocationsAuthorizedViewSetsListOptions { /** * Optional. The filter expression to filter authorized view sets listed in * the response. */ filter?: string; /** * Optional. The order by expression to order authorized view sets listed in * the response. */ orderBy?: string; /** * Optional. The maximum number of view sets to return in the response. If * the value is zero, the service will select a default size. A call might * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAuthorizedViewSetsResponse`. * This value indicates that this is a continuation of a prior * `ListAuthorizedViewSets` call and that the system should return the next * page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsAuthorizedViewSetsPatch. */ export interface ProjectsLocationsAuthorizedViewSetsPatchOptions { /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `display_name` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsAuthorizedViewSetsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsAuthorizedViewSetsPatchOptions(data: any): ProjectsLocationsAuthorizedViewSetsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsAnalysesList. */ export interface ProjectsLocationsConversationsAnalysesListOptions { /** * A filter to reduce results to a specific subset. Useful for querying * conversations with specific properties. */ filter?: string; /** * The maximum number of analyses to return in the response. If this value is * zero, the service will select a default size. A call might return fewer * objects than requested. A non-empty `next_page_token` in the response * indicates that more data is available. */ pageSize?: number; /** * The value returned by the last `ListAnalysesResponse`; indicates that this * is a continuation of a prior `ListAnalyses` call and the system should * return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsAssessmentsDelete. */ export interface ProjectsLocationsConversationsAssessmentsDeleteOptions { /** * Optional. If set to true, all of this assessment's notes will also be * deleted. Otherwise, the request will only succeed if it has no notes. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsAssessmentsList. */ export interface ProjectsLocationsConversationsAssessmentsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supported * filters include: * `state` - The state of the assessment * * `agent_info.agent_id` - The ID of the agent the assessment is for */ filter?: string; /** * The maximum number of assessments to list. If zero, the service will * select a default size. A call may return fewer objects than requested. A * non-empty `next_page_token` in the response indicates that more data is * available. */ pageSize?: number; /** * Optional. The value returned by the last `ListAssessmentRulesResponse`; * indicates that this is a continuation of a prior `ListAssessmentRules` call * and the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsAssessmentsNotesList. */ export interface ProjectsLocationsConversationsAssessmentsNotesListOptions { /** * Optional. The maximum number of notes to return in the response. If zero * the service will select a default size. A call might return fewer objects * than requested. A non-empty `next_page_token` in the response indicates * that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListNotesResponse`. This value * indicates that this is a continuation of a prior `ListNotes` call and that * the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsAssessmentsNotesPatch. */ export interface ProjectsLocationsConversationsAssessmentsNotesPatchOptions { /** * Optional. The list of fields to be updated. If the update_mask is empty, * all updateable fields will be updated. Acceptable fields include: * * `content` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsConversationsAssessmentsNotesPatchOptions(data: any): ProjectsLocationsConversationsAssessmentsNotesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsConversationsAssessmentsNotesPatchOptions(data: any): ProjectsLocationsConversationsAssessmentsNotesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsCalculateStats. */ export interface ProjectsLocationsConversationsCalculateStatsOptions { /** * A filter to reduce results to a specific subset. This field is useful for * getting statistics about conversations with specific properties. */ filter?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsCreate. */ export interface ProjectsLocationsConversationsCreateOptions { /** * A unique ID for the new conversation. This ID will become the final * component of the conversation's resource name. If no ID is specified, a * server-generated ID will be used. This value should be 4-64 characters and * must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters are * `a-z-` */ conversationId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsDelete. */ export interface ProjectsLocationsConversationsDeleteOptions { /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsFeedbackLabelsCreate. */ export interface ProjectsLocationsConversationsFeedbackLabelsCreateOptions { /** * Optional. The ID of the feedback label to create. If one is not specified * it will be generated by the server. */ feedbackLabelId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsFeedbackLabelsList. */ export interface ProjectsLocationsConversationsFeedbackLabelsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Automatically sorts by * conversation ID. To sort by all feedback labels in a project see * ListAllFeedbackLabels. Supported fields: * `issue_model_id` * * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Optional. The maximum number of feedback labels to return in the response. * A valid page size ranges from 0 to 100,000 inclusive. If the page size is * zero or unspecified, a default page size of 100 will be chosen. Note that a * call might return fewer results than the requested page size. */ pageSize?: number; /** * Optional. The value returned by the last `ListFeedbackLabelsResponse`. * This value indicates that this is a continuation of a prior * `ListFeedbackLabels` call and that the system should return the next page * of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsFeedbackLabelsPatch. */ export interface ProjectsLocationsConversationsFeedbackLabelsPatchOptions { /** * Required. The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsGet. */ export interface ProjectsLocationsConversationsGetOptions { /** * The level of details of the conversation. Default is `FULL`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsList. */ export interface ProjectsLocationsConversationsListOptions { /** * A filter to reduce results to a specific subset. Useful for querying * conversations with specific properties. */ filter?: string; /** * Optional. The attribute by which to order conversations in the response. * If empty, conversations will be ordered by descending creation time. * Supported values are one of the following: * create_time * * customer_satisfaction_rating * duration * latest_analysis * start_time * * turn_count The default sort order is ascending. To specify order, append * `asc` or `desc` (`create_time desc`). For more details, see [Google AIPs * Ordering](https://google.aip.dev/132#ordering). */ orderBy?: string; /** * The maximum number of conversations to return in the response. A valid * page size ranges from 0 to 100,000 inclusive. If the page size is zero or * unspecified, a default page size of 100 will be chosen. Note that a call * might return fewer results than the requested page size. */ pageSize?: number; /** * The value returned by the last `ListConversationsResponse`. This value * indicates that this is a continuation of a prior `ListConversations` call * and that the system should return the next page of data. */ pageToken?: string; /** * The level of details of the conversation. Default is `BASIC`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsConversationsPatch. */ export interface ProjectsLocationsConversationsPatchOptions { /** * Optional. Defaults to false. If set to true, and the conversation is not * found, a new conversation will be created. In this situation, `update_mask` * is ignored. */ allowMissing?: boolean; /** * The list of fields to be updated. All possible fields can be updated by * passing `*`, or a subset of the following updateable fields can be * provided: * `agent_id` * `language_code` * `labels` * `metadata` * * `quality_metadata` * `call_metadata` * `start_time` * `expire_time` or * `ttl` * `data_source.gcs_source.audio_uri` or * * `data_source.dialogflow_source.audio_uri` * `data_source.screen_recordings` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsConversationsPatchOptions(data: any): ProjectsLocationsConversationsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsConversationsPatchOptions(data: any): ProjectsLocationsConversationsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsDelete. */ export interface ProjectsLocationsDatasetsConversationsDeleteOptions { /** * If set to true, all of this conversation's analyses will also be deleted. * Otherwise, the request will only succeed if the conversation has no * analyses. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsFeedbackLabelsCreate. */ export interface ProjectsLocationsDatasetsConversationsFeedbackLabelsCreateOptions { /** * Optional. The ID of the feedback label to create. If one is not specified * it will be generated by the server. */ feedbackLabelId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsFeedbackLabelsList. */ export interface ProjectsLocationsDatasetsConversationsFeedbackLabelsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supports * disjunctions (OR) and conjunctions (AND). Automatically sorts by * conversation ID. To sort by all feedback labels in a project see * ListAllFeedbackLabels. Supported fields: * `issue_model_id` * * `qa_question_id` * `qa_scorecard_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Optional. The maximum number of feedback labels to return in the response. * A valid page size ranges from 0 to 100,000 inclusive. If the page size is * zero or unspecified, a default page size of 100 will be chosen. Note that a * call might return fewer results than the requested page size. */ pageSize?: number; /** * Optional. The value returned by the last `ListFeedbackLabelsResponse`. * This value indicates that this is a continuation of a prior * `ListFeedbackLabels` call and that the system should return the next page * of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsFeedbackLabelsPatch. */ export interface ProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions { /** * Required. The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions(data: any): ProjectsLocationsDatasetsConversationsFeedbackLabelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsGet. */ export interface ProjectsLocationsDatasetsConversationsGetOptions { /** * The level of details of the conversation. Default is `FULL`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsConversationsList. */ export interface ProjectsLocationsDatasetsConversationsListOptions { /** * A filter to reduce results to a specific subset. Useful for querying * conversations with specific properties. */ filter?: string; /** * Optional. The attribute by which to order conversations in the response. * If empty, conversations will be ordered by descending creation time. * Supported values are one of the following: * create_time * * customer_satisfaction_rating * duration * latest_analysis * start_time * * turn_count The default sort order is ascending. To specify order, append * `asc` or `desc` (`create_time desc`). For more details, see [Google AIPs * Ordering](https://google.aip.dev/132#ordering). */ orderBy?: string; /** * The maximum number of conversations to return in the response. A valid * page size ranges from 0 to 100,000 inclusive. If the page size is zero or * unspecified, a default page size of 100 will be chosen. Note that a call * might return fewer results than the requested page size. */ pageSize?: number; /** * The value returned by the last `ListConversationsResponse`. This value * indicates that this is a continuation of a prior `ListConversations` call * and that the system should return the next page of data. */ pageToken?: string; /** * The level of details of the conversation. Default is `BASIC`. */ view?: | "CONVERSATION_VIEW_UNSPECIFIED" | "FULL" | "BASIC"; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsCreate. */ export interface ProjectsLocationsDatasetsCreateOptions { /** * Optional. The ID to use for the dataset. */ datasetId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsDatasetsListAllFeedbackLabels. */ export interface ProjectsLocationsDatasetsListAllFeedbackLabelsOptions { /** * Optional. A filter to reduce results to a specific subset in the entire * project. Supports disjunctions (OR) and conjunctions (AND). Supported * fields: * `issue_model_id` * `qa_question_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Optional. The maximum number of feedback labels to return in the response. * A valid page size ranges from 0 to 100,000 inclusive. If the page size is * zero or unspecified, a default page size of 100 will be chosen. Note that a * call might return fewer results than the requested page size. */ pageSize?: number; /** * Optional. The value returned by the last `ListAllFeedbackLabelsResponse`. * This value indicates that this is a continuation of a prior * `ListAllFeedbackLabels` call and that the system should return the next * page of data. */ pageToken?: string; } /** * Additional options for ContactCenterInsights#projectsLocationsDatasetsList. */ export interface ProjectsLocationsDatasetsListOptions { /** * Optional. A filter to reduce results to a specific subset. Useful for * querying datasets with specific properties. Supported fields include, for * Q2 though we only support list by project: - `type` - `description` - * `project_number` */ filter?: string; /** * Optional. The maximum number of datasets to return in the response. If * this value is zero, the service will select a default size. A call might * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListDatasetsResponse`; indicates * that this is a continuation of a prior `ListDatasets` call and the system * should return the next page of data. */ pageToken?: string; } /** * Additional options for ContactCenterInsights#projectsLocationsDatasetsPatch. */ export interface ProjectsLocationsDatasetsPatchOptions { /** * Optional. The list of fields to update. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsDatasetsPatchOptions(data: any): ProjectsLocationsDatasetsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsDatasetsPatchOptions(data: any): ProjectsLocationsDatasetsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsIssueModelsIssuesPatch. */ export interface ProjectsLocationsIssueModelsIssuesPatchOptions { /** * The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsIssueModelsIssuesPatchOptions(data: any): ProjectsLocationsIssueModelsIssuesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsIssueModelsIssuesPatchOptions(data: any): ProjectsLocationsIssueModelsIssuesPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsIssueModelsPatch. */ export interface ProjectsLocationsIssueModelsPatchOptions { /** * The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsIssueModelsPatchOptions(data: any): ProjectsLocationsIssueModelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsIssueModelsPatchOptions(data: any): ProjectsLocationsIssueModelsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsListAllFeedbackLabels. */ export interface ProjectsLocationsListAllFeedbackLabelsOptions { /** * Optional. A filter to reduce results to a specific subset in the entire * project. Supports disjunctions (OR) and conjunctions (AND). Supported * fields: * `issue_model_id` * `qa_question_id` * `min_create_time` * * `max_create_time` * `min_update_time` * `max_update_time` * * `feedback_label_type`: QUALITY_AI, TOPIC_MODELING */ filter?: string; /** * Optional. The maximum number of feedback labels to return in the response. * A valid page size ranges from 0 to 100,000 inclusive. If the page size is * zero or unspecified, a default page size of 100 will be chosen. Note that a * call might return fewer results than the requested page size. */ pageSize?: number; /** * Optional. The value returned by the last `ListAllFeedbackLabelsResponse`. * This value indicates that this is a continuation of a prior * `ListAllFeedbackLabels` call and that the system should return the next * page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsOperationsList. */ export interface ProjectsLocationsOperationsListOptions { /** * The standard list filter. */ filter?: string; /** * The standard list page size. */ pageSize?: number; /** * The standard list page token. */ pageToken?: string; /** * When set to `true`, operations that are reachable are returned as normal, * and those that are unreachable are returned in the * ListOperationsResponse.unreachable field. This can only be `true` when * reading across collections. For example, when `parent` is set to * `"projects/example/locations/-"`. This field is not supported by default * and will result in an `UNIMPLEMENTED` error if set unless explicitly * documented otherwise in service or product specific documentation. */ returnPartialSuccess?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsPhraseMatchersList. */ export interface ProjectsLocationsPhraseMatchersListOptions { /** * A filter to reduce results to a specific subset. Useful for querying * phrase matchers with specific properties. */ filter?: string; /** * The maximum number of phrase matchers to return in the response. If this * value is zero, the service will select a default size. A call might return * fewer objects than requested. A non-empty `next_page_token` in the response * indicates that more data is available. */ pageSize?: number; /** * The value returned by the last `ListPhraseMatchersResponse`. This value * indicates that this is a continuation of a prior `ListPhraseMatchers` call * and that the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsPhraseMatchersPatch. */ export interface ProjectsLocationsPhraseMatchersPatchOptions { /** * The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsPhraseMatchersPatchOptions(data: any): ProjectsLocationsPhraseMatchersPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsPhraseMatchersPatchOptions(data: any): ProjectsLocationsPhraseMatchersPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaQuestionTagsCreate. */ export interface ProjectsLocationsQaQuestionTagsCreateOptions { /** * Optional. A unique ID for the new QaQuestionTag. This ID will become the * final component of the QaQuestionTag's resource name. If no ID is * specified, a server-generated ID will be used. This value should be 4-64 * characters and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid * characters are `a-z-`. */ qaQuestionTagId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaQuestionTagsList. */ export interface ProjectsLocationsQaQuestionTagsListOptions { /** * Optional. A filter to reduce results to a specific subset. Supports * conjunctions (ie. AND operators). Supported fields include the following: * * `project_id` - id of the project to list tags for * `qa_scorecard_id` - id * of the scorecard to list tags for * `revision_id` - id of the scorecard * revision to list tags for` * `qa_question_id - id of the question to list * tags for` */ filter?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaQuestionTagsPatch. */ export interface ProjectsLocationsQaQuestionTagsPatchOptions { /** * Optional. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `qa_question_tag_name` - the name of the tag * * `qa_question_ids` - the list of questions the tag applies to */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsQaQuestionTagsPatchOptions(data: any): ProjectsLocationsQaQuestionTagsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsQaQuestionTagsPatchOptions(data: any): ProjectsLocationsQaQuestionTagsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsCreate. */ export interface ProjectsLocationsQaScorecardsCreateOptions { /** * Optional. A unique ID for the new QaScorecard. This ID will become the * final component of the QaScorecard's resource name. If no ID is specified, * a server-generated ID will be used. This value should be 4-64 characters * and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters * are `a-z-`. */ qaScorecardId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsDelete. */ export interface ProjectsLocationsQaScorecardsDeleteOptions { /** * Optional. If set to true, all of this QaScorecard's child resources will * also be deleted. Otherwise, the request will only succeed if it has none. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsList. */ export interface ProjectsLocationsQaScorecardsListOptions { /** * Optional. The maximum number of scorecards to return in the response. If * the value is zero, the service will select a default size. A call might * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListQaScorecardsResponse`. This * value indicates that this is a continuation of a prior `ListQaScorecards` * call and that the system should return the next page of data. */ pageToken?: string; /** * Optional. The source of scorecards are based on how those Scorecards were * created, e.g., a customer-defined scorecard, a predefined scorecard, etc. * This field is used to retrieve Scorecards of one or more sources. */ qaScorecardSources?: | "QA_SCORECARD_SOURCE_UNSPECIFIED" | "QA_SCORECARD_SOURCE_CUSTOMER_DEFINED" | "QA_SCORECARD_SOURCE_DISCOVERY_ENGINE"; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsPatch. */ export interface ProjectsLocationsQaScorecardsPatchOptions { /** * Required. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `description` * `display_name` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsQaScorecardsPatchOptions(data: any): ProjectsLocationsQaScorecardsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsQaScorecardsPatchOptions(data: any): ProjectsLocationsQaScorecardsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsCreate. */ export interface ProjectsLocationsQaScorecardsRevisionsCreateOptions { /** * Optional. A unique ID for the new QaScorecardRevision. This ID will become * the final component of the QaScorecardRevision's resource name. If no ID is * specified, a server-generated ID will be used. This value should be 4-64 * characters and must match the regular expression `^[a-z0-9-]{4,64}$`. Valid * characters are `a-z-`. */ qaScorecardRevisionId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsDelete. */ export interface ProjectsLocationsQaScorecardsRevisionsDeleteOptions { /** * Optional. If set to true, all of this QaScorecardRevision's child * resources will also be deleted. Otherwise, the request will only succeed if * it has none. */ force?: boolean; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsList. */ export interface ProjectsLocationsQaScorecardsRevisionsListOptions { /** * Optional. A filter to reduce results to a specific subset. Useful for * querying scorecard revisions with specific properties. */ filter?: string; /** * Optional. The maximum number of scorecard revisions to return in the * response. If the value is zero, the service will select a default size. A * call might return fewer objects than requested. A non-empty * `next_page_token` in the response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last * `ListQaScorecardRevisionsResponse`. This value indicates that this is a * continuation of a prior `ListQaScorecardRevisions` call and that the system * should return the next page of data. */ pageToken?: string; /** * Optional. The source of scorecards are based on how those Scorecards were * created, e.g., a customer-defined scorecard, a predefined scorecard, etc. * This field is used to retrieve Scorecards Revisions from Scorecards of one * or more sources. */ qaScorecardSources?: | "QA_SCORECARD_SOURCE_UNSPECIFIED" | "QA_SCORECARD_SOURCE_CUSTOMER_DEFINED" | "QA_SCORECARD_SOURCE_DISCOVERY_ENGINE"; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsQaQuestionsCreate. */ export interface ProjectsLocationsQaScorecardsRevisionsQaQuestionsCreateOptions { /** * Optional. A unique ID for the new question. This ID will become the final * component of the question's resource name. If no ID is specified, a * server-generated ID will be used. This value should be 4-64 characters and * must match the regular expression `^[a-z0-9-]{4,64}$`. Valid characters are * `a-z-`. */ qaQuestionId?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsQaQuestionsList. */ export interface ProjectsLocationsQaScorecardsRevisionsQaQuestionsListOptions { /** * Optional. The maximum number of questions to return in the response. If * the value is zero, the service will select a default size. A call might * return fewer objects than requested. A non-empty `next_page_token` in the * response indicates that more data is available. */ pageSize?: number; /** * Optional. The value returned by the last `ListQaQuestionsResponse`. This * value indicates that this is a continuation of a prior `ListQaQuestions` * call and that the system should return the next page of data. */ pageToken?: string; } /** * Additional options for * ContactCenterInsights#projectsLocationsQaScorecardsRevisionsQaQuestionsPatch. */ export interface ProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions { /** * Required. The list of fields to be updated. All possible fields can be * updated by passing `*`, or a subset of the following updateable fields can * be provided: * `abbreviation` * `answer_choices` * `answer_instructions` * * `order` * `question_body` * `tags` */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions(data: any): ProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions(data: any): ProjectsLocationsQaScorecardsRevisionsQaQuestionsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for * ContactCenterInsights#projectsLocationsUpdateSettings. */ export interface ProjectsLocationsUpdateSettingsOptions { /** * Required. The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsUpdateSettingsOptions(data: any): ProjectsLocationsUpdateSettingsOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsUpdateSettingsOptions(data: any): ProjectsLocationsUpdateSettingsOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } /** * Additional options for ContactCenterInsights#projectsLocationsViewsList. */ export interface ProjectsLocationsViewsListOptions { /** * The maximum number of views to return in the response. If this value is * zero, the service will select a default size. A call may return fewer * objects than requested. A non-empty `next_page_token` in the response * indicates that more data is available. */ pageSize?: number; /** * The value returned by the last `ListViewsResponse`; indicates that this is * a continuation of a prior `ListViews` call and the system should return the * next page of data. */ pageToken?: string; } /** * Additional options for ContactCenterInsights#projectsLocationsViewsPatch. */ export interface ProjectsLocationsViewsPatchOptions { /** * The list of fields to be updated. */ updateMask?: string /* FieldMask */; } function serializeProjectsLocationsViewsPatchOptions(data: any): ProjectsLocationsViewsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function deserializeProjectsLocationsViewsPatchOptions(data: any): ProjectsLocationsViewsPatchOptions { return { ...data, updateMask: data["updateMask"] !== undefined ? data["updateMask"] : undefined, }; } function decodeBase64(b64: string): Uint8Array { const binString = atob(b64); const size = binString.length; const bytes = new Uint8Array(size); for (let i = 0; i < size; i++) { bytes[i] = binString.charCodeAt(i); } return bytes; } const base64abc = ["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","0","1","2","3","4","5","6","7","8","9","+","/"]; /** * CREDIT: https://gist.github.com/enepomnyaschih/72c423f727d395eeaa09697058238727 * Encodes a given Uint8Array, ArrayBuffer or string into RFC4648 base64 representation * @param data */ function encodeBase64(uint8: Uint8Array): string { let result = "", i; const l = uint8.length; for (i = 2; i < l; i += 3) { result += base64abc[uint8[i - 2] >> 2]; result += base64abc[((uint8[i - 2] & 0x03) << 4) | (uint8[i - 1] >> 4)]; result += base64abc[((uint8[i - 1] & 0x0f) << 2) | (uint8[i] >> 6)]; result += base64abc[uint8[i] & 0x3f]; } if (i === l + 1) { // 1 octet yet to write result += base64abc[uint8[i - 2] >> 2]; result += base64abc[(uint8[i - 2] & 0x03) << 4]; result += "=="; } if (i === l) { // 2 octets yet to write result += base64abc[uint8[i - 2] >> 2]; result += base64abc[((uint8[i - 2] & 0x03) << 4) | (uint8[i - 1] >> 4)]; result += base64abc[(uint8[i - 1] & 0x0f) << 2]; result += "="; } return result; }