Method: projects.locations.userEvents.import

Impor massal peristiwa pengguna. Pemrosesan permintaan mungkin bersifat sinkron. Acara yang sudah ada akan dilewati. Gunakan metode ini untuk mengisi ulang peristiwa pengguna historis.

Operation.response berjenis ImportResponse. Perhatikan bahwa sebagian item dapat berhasil disisipkan. Operation.metadata berjenis ImportMetadata.

Permintaan HTTP

POST https://discoveryengine.googleapis.com/v1beta/{parent=projects/*/locations/*}/userEvents:import

URL menggunakan sintaks gRPC Transcoding.

Parameter jalur

Parameter
parent

string

Wajib. Nama resource DataStore induk, dalam bentuk projects/{project}/locations/{location}/collections/{collection}/dataStores/{dataStore}

Isi permintaan

Isi permintaan memuat data dengan struktur berikut:

Representasi JSON
{
  "errorConfig": {
    object (ImportErrorConfig)
  },

  // The following is a list of mutually exclusive fields. At most one of the
  // fields will be set in a response:
  "inlineSource": {
    object (InlineSource)
  },
  "gcsSource": {
    object (GcsSource)
  },
  "bigquerySource": {
    object (BigQuerySource)
  }
  // End of mutually exclusive fields.
}
Kolom
errorConfig

object (ImportErrorConfig)

Lokasi yang diinginkan untuk error yang terjadi selama Impor. Tidak dapat ditetapkan untuk impor peristiwa pengguna inline.

Wajib - Sumber input yang diinginkan dari data peristiwa pengguna. Berikut adalah daftar kolom yang bersifat eksklusif satu sama lain. Maksimal satu kolom akan ditetapkan dalam respons:
inlineSource

object (InlineSource)

Sumber Inline untuk konten input untuk UserEvents.

gcsSource

object (GcsSource)

Lokasi Cloud Storage untuk konten input.

bigquerySource

object (BigQuerySource)

Sumber input BigQuery.

Akhir kolom yang saling eksklusif.

Isi respons

Jika berhasil, isi respons akan memuat instance Operation.

Cakupan otorisasi

Memerlukan salah satu cakupan OAuth berikut:

  • https://www.googleapis.com/auth/cloud-platform
  • https://www.googleapis.com/auth/discoveryengine.assist.readwrite
  • https://www.googleapis.com/auth/discoveryengine.readwrite
  • https://www.googleapis.com/auth/discoveryengine.serving.readwrite

Untuk mengetahui informasi selengkapnya, lihat Authentication Overview.

Izin IAM

Memerlukan izin IAM berikut pada resource parent:

  • discoveryengine.userEvents.import

Untuk mengetahui informasi selengkapnya, lihat dokumentasi IAM.