Method: projects.locations.collections.engines.assistants.agents.files.import

ファイルを Agent にインポートします。 現在、サポートされているのはノーコード エージェントのみです。

HTTP リクエスト


POST https://discoveryengine.googleapis.com/v1alpha/{parent=projects/*/locations/*/collections/*/engines/*/assistants/*/agents/*}/files:import

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

パスパラメータ

パラメータ
parent

string

必須。Agent のリソース名。形式: projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}/agents/{agent}

リクエストの本文

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

JSON 表現
{
  "fileName": string,
  "mimeType": string
}
フィールド
fileName

string

必須。ファイルの名前。

mimeType

string

省略可。ファイルのコンテンツ タイプ。https://www.iana.org/assignments/media-types/media-types.xhtml をご覧ください。

データソースでコンテンツ タイプが指定されていない場合、このフィールドは必須です。

レスポンスの本文

AgentService.ImportAgentFile メソッドに対するレスポンス。

成功した場合、レスポンスの本文には次の構造のデータが含まれます。

JSON 表現
{
  "agentFile": {
    object (AgentFile)
  }
}
フィールド
agentFile

object (AgentFile)

インポートされた AgentFile。

認可スコープ

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

  • 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

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

IAM 権限

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

  • discoveryengine.agentFiles.import

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

AgentFile

エージェントが各呼び出しのコンテキストとして内部で使用するファイルについて記述します。

JSON 表現
{
  "name": string,
  "fileName": string,
  "mimeType": string
}
フィールド
name

string

ID。ファイルのリソース名。形式: projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}/agents/{agent}/files/{file}

fileName

string

必須。ファイルの名前。

mimeType

string

変更不可。ファイルのコンテンツ タイプ。