Method: projects.locations.insightsdata.export

Export insights data to a destination defined in the request body.

HTTP request

POST https://contactcenterinsights.googleapis.com/v1/{parent=projects/*/locations/*}/insightsdata:export

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The parent resource to export data from.

Request body

The request body contains data with the following structure:

JSON representation
{
  "filter": string,
  "kmsKey": string,
  "writeDisposition": enum (WriteDisposition),

  // Union field destination can be only one of the following:
  "bigQueryDestination": {
    object (BigQueryDestination)
  }
  // End of list of possible types for union field destination.
}
Fields
filter

string

A filter to reduce results to a specific subset. Useful for exporting conversations with specific properties.

kmsKey

string

A fully qualified KMS key name for BigQuery tables protected by CMEK. Format: projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}/cryptoKeyVersions/{version}

writeDisposition

enum (WriteDisposition)

Options for what to do if the destination table already exists.

Union field destination. Exporter destination. destination can be only one of the following:
bigQueryDestination

object (BigQueryDestination)

Specified if sink is a BigQuery table.

Response body

If successful, the response body contains an instance of Operation.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

IAM Permissions

Requires the following IAM permission on the parent resource:

  • contactcenterinsights.conversations.list

For more information, see the IAM documentation.

BigQueryDestination

A BigQuery Table Reference.

JSON representation
{
  "projectId": string,
  "dataset": string,
  "table": string
}
Fields
projectId

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.

dataset

string

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.

table

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.

WriteDisposition

Specifies the action that occurs if the destination table already exists.

Enums
WRITE_DISPOSITION_UNSPECIFIED Write disposition is not specified. Defaults to WRITE_TRUNCATE.
WRITE_TRUNCATE If the table already exists, BigQuery will overwrite the table data and use the schema from the load.
WRITE_APPEND If the table already exists, BigQuery will append data to the table.