Method: projects.locations.sampleQuerySets.sampleQueries.import

複数の SampleQuery の一括インポート。既存のサンプルクエリは削除されることがあります。

注: SampleQuery のサブセットが正常にインポートされる場合があります。

HTTP リクエスト

POST https://discoveryengine.googleapis.com/v1alpha/{parent=projects/*/locations/*/sampleQuerySets/*}/sampleQueries:import

この URL では gRPC Transcoding 構文を使用します。

パスパラメータ

パラメータ
parent

string

必須。親サンプル クエリセットのリソース名(projects/{project}/locations/{location}/sampleQuerySets/{sampleQuerySet} など)。

呼び出し元にこのサンプル クエリセットの SampleQuery を一覧表示する権限がない場合、このサンプル クエリセットが存在するかどうかにかかわらず、PERMISSION_DENIED エラーが返されます。

リクエストの本文

リクエストの本文には、次の構造のデータが含まれます。

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.
}
フィールド
errorConfig

object (ImportErrorConfig)

インポート中に発生したエラーを記録する目的の場所。

サンプルクエリのソース。以下は、相互に排他的なフィールドのリストです。レスポンスで設定されるフィールドは最大で 1 つです。
inlineSource

object (InlineSource)

サンプルクエリ エントリのインライン ソース。

gcsSource

object (GcsSource)

入力コンテンツが保存されている Cloud Storage 上の場所。

bigquerySource

object (BigQuerySource)

BigQuery 入力ソース。

相互に排他的なフィールドの終了。

レスポンスの本文

成功した場合、レスポンスの本文には Operation のインスタンスが含まれます。

認可スコープ

次の OAuth スコープのいずれかが必要です。

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

詳細については、Authentication Overview をご覧ください。

IAM 権限

parent リソースに対する次の IAM 権限が必要です。

  • discoveryengine.sampleQueries.import

詳細については、IAM のドキュメントをご覧ください。

InlineSource

SampleQuery のインライン ソース。

JSON 表現
{
  "sampleQueries": [
    {
      object (SampleQuery)
    }
  ]
}
フィールド
sampleQueries[]

object (SampleQuery)

必須。インポートする SampleQuery のリスト。最大 1,000 個のアイテム。