> ## Documentation Index
> Fetch the complete documentation index at: https://evolink.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Seed Messages — API リファレンス

> - Anthropic Messages 形式で Seed を呼び出せます。Claude Code などの対応ツールでも利用できます。
- ステートレスなため、毎回全履歴を送り、assistant の思考ブロックはそのまま返してください。
- テキスト・画像・文書に対応します。Lite の音声入力には Chat Completions または Responses を使用してください。
- 思考は既定で有効です。`thinking` で無効化し、`output_config.effort` で深さを調整できます。
- 全モデルが関数呼び出しに対応します。Seed 2.1 と `doubao-seed-evolving` はウェブ検索にも対応します。 (`web_search_20250305`)
- JSON Object または JSON Schema 形式の構造化出力に対応します。 (`output_config.format`)
- 長い共通接頭辞にヒットすると自動でヒット料金が適用されます。`cache_control` は不要です。ヒット数は `usage.cache_read_input_tokens` で確認できます。
- `stream=true` では Anthropic SSE イベントが `message_start` → `content_block_start` / `content_block_delta` / `content_block_stop` → `message_delta` → `message_stop` の順に届きます。最終使用量は `message_delta` に含まれます。
- **Seed 2.0 の旧モデル名**：`doubao-seed-2.0-pro` / `doubao-seed-2.0-lite` は現在 `doubao-seed-2-1-lite`、`doubao-seed-2.0-code` は `doubao-seed-evolving` に転送されます。パラメータの動作は新しいモデルに準じます。新規連携では新しいモデル名を使用してください。`doubao-seed-2.0-mini` は変わりません
- [クイックスタート](/ja/api-manual/language-series/doubao-seed-2.0/doubao-seed-2.0-messages-quickstart)

> [!NOTE]
>
> **BaseURL**：デフォルトの BaseURL は `https://direct.evolink.ai` で、テキストモデルへの対応が優れており、長時間接続をサポートします。`https://api.evolink.ai` はマルチモーダルの主力エンドポイントで、テキストモデルに対しては代替アドレスとして使用されます。

> [!NOTE]
>
> `web_search_20250305` に対応するのは Seed 2.1 と `doubao-seed-evolving` のみです。Messages は音声入力に対応しません。`doubao-seed-2-1-lite` の音声入力には [Chat Completions](https://evolink.ai/docs/ja/api-manual/language-series/doubao-seed-2.0/doubao-seed-2.0-reference.md) または [Responses](https://evolink.ai/docs/ja/api-manual/language-series/doubao-seed-2.0/doubao-seed-2.0-responses-reference.md) を使用してください。


## OpenAPI

````yaml ja/api-manual/language-series/doubao-seed-2.0/doubao-seed-2.0-messages-reference.json POST /v1/messages
openapi: 3.1.0
info:
  title: Seed Messages — API リファレンス
  description: Seed モデルで使える Messages (Anthropic) のパラメーターと詳細機能。
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://direct.evolink.ai
    description: 本番環境（推奨）
  - url: https://api.evolink.ai
    description: 代替 URL
security:
  - bearerAuth: []
tags:
  - name: Messages
    description: Anthropic Messages 互換 API
paths:
  /v1/messages:
    post:
      tags:
        - Messages
      summary: Seed Messages
      description: >-
        - Anthropic Messages 形式で Seed を呼び出せます。Claude Code などの対応ツールでも利用できます。

        - ステートレスなため、毎回全履歴を送り、assistant の思考ブロックはそのまま返してください。

        - テキスト・画像・文書に対応します。Lite の音声入力には Chat Completions または Responses
        を使用してください。

        - 思考は既定で有効です。`thinking` で無効化し、`output_config.effort` で深さを調整できます。

        - 全モデルが関数呼び出しに対応します。Seed 2.1 と `doubao-seed-evolving` はウェブ検索にも対応します。
        (`web_search_20250305`)

        - JSON Object または JSON Schema 形式の構造化出力に対応します。 (`output_config.format`)

        - 長い共通接頭辞にヒットすると自動でヒット料金が適用されます。`cache_control` は不要です。ヒット数は
        `usage.cache_read_input_tokens` で確認できます。

        - `stream=true` では Anthropic SSE イベントが `message_start` →
        `content_block_start` / `content_block_delta` / `content_block_stop` →
        `message_delta` → `message_stop` の順に届きます。最終使用量は `message_delta` に含まれます。

        - **Seed 2.0 の旧モデル名**：`doubao-seed-2.0-pro` / `doubao-seed-2.0-lite` は現在
        `doubao-seed-2-1-lite`、`doubao-seed-2.0-code` は `doubao-seed-evolving`
        に転送されます。パラメータの動作は新しいモデルに準じます。新規連携では新しいモデル名を使用してください。`doubao-seed-2.0-mini`
        は変わりません

        -
        [クイックスタート](/ja/api-manual/language-series/doubao-seed-2.0/doubao-seed-2.0-messages-quickstart)
      operationId: createMessageSeed
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateMessageRequest'
            examples:
              simple:
                summary: シングルターンテキストチャット
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  messages:
                    - role: user
                      content: 自己紹介をしてください
              system_prompt:
                summary: システムプロンプトの使用
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  system: あなたは正確さを重視する技術編集者です。日本語で簡潔に答えてください。
                  messages:
                    - role: user
                      content: コンテキストキャッシュとは何か説明してください。
              multi_turn:
                summary: 毎回すべての履歴を送る複数ターンの会話
                value:
                  model: doubao-seed-2-1-turbo
                  max_tokens: 4096
                  messages:
                    - role: user
                      content: 合言葉は RED-583 です。覚えてください。
                    - role: assistant
                      content: 覚えました。
                    - role: user
                      content: 合言葉は何ですか？合言葉だけを返してください。
              streaming:
                summary: ストリーミング出力
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  stream: true
                  messages:
                    - role: user
                      content: 秋を題材に 4 行の詩を書いてください。
              thinking_off:
                summary: 思考を無効にする
                value:
                  model: doubao-seed-2-1-turbo
                  max_tokens: 1024
                  thinking:
                    type: disabled
                  messages:
                    - role: user
                      content: 次の文を英語に訳してください。今日の会議は午後 3 時に変更されました。
              effort:
                summary: 思考の深さの調整
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 8192
                  output_config:
                    effort: low
                  messages:
                    - role: user
                      content: クイックソートとマージソートの使い分けを説明してください。
              vision:
                summary: 画像理解
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  messages:
                    - role: user
                      content:
                        - type: image
                          source:
                            type: url
                            url: https://www.gstatic.com/webp/gallery/1.jpg
                        - type: text
                          text: この画像の場面と主な要素を説明してください。
              tool_use:
                summary: Function Call
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  messages:
                    - role: user
                      content: 北京の今日の天気を調べてください。
                  tools:
                    - name: get_weather
                      description: 指定した都市の天気を取得
                      input_schema:
                        type: object
                        properties:
                          city:
                            type: string
                            description: 都市名
                        required:
                          - city
                  tool_choice:
                    type: auto
              tool_result:
                summary: 関数の実行結果を返す
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  tools:
                    - name: get_weather
                      description: 指定した都市の天気を取得
                      input_schema:
                        type: object
                        properties:
                          city:
                            type: string
                        required:
                          - city
                  messages:
                    - role: user
                      content: 北京の今日の天気を調べてください。
                    - role: assistant
                      content:
                        - type: thinking
                          thinking: 天気を調べる関数を呼び出す必要がある…
                          signature: EqQBCkgIARABGAIi...
                        - type: tool_use
                          id: call_01
                          name: get_weather
                          input:
                            city: 北京
                    - role: user
                      content:
                        - type: tool_result
                          tool_use_id: call_01
                          content: 晴れ、12～22 ℃、北の風、風力 2
              web_search:
                summary: ウェブ検索（Seed 2.1 と Evolving のみ）
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  messages:
                    - role: user
                      content: 直近 1 週間の主な技術ニュースを教えてください。
                  tools:
                    - type: web_search_20250305
                      name: web_search
                      max_uses: 2
              structured_output:
                summary: 構造化出力（JSON Schema）
                value:
                  model: doubao-seed-2-1-pro
                  max_tokens: 4096
                  output_config:
                    format:
                      type: json_schema
                      schema:
                        type: object
                        properties:
                          title:
                            type: string
                          tags:
                            type: array
                            items:
                              type: string
                        required:
                          - title
                          - tags
                        additionalProperties: false
                  messages:
                    - role: user
                      content: コンテキストキャッシュを紹介する記事のタイトルとタグを 3 つ作成してください。
      responses:
        '200':
          description: 生成に成功しました。ストリーミングでは Anthropic SSE イベントが返ります。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessageResponse'
            text/event-stream:
              schema:
                type: string
                description: >-
                  通常のイベント順序は
                  message_start、content_block_*、message_delta、message_stop です。
        '400':
          description: リクエストパラメータエラー
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 400
                  message: Invalid request parameters
                  type: invalid_request_error
        '401':
          description: 未認証、トークンが無効または期限切れ
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 401
                  message: Invalid or expired token
                  type: authentication_error
        '402':
          description: クォータ不足、チャージが必要
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 402
                  message: Insufficient quota
                  type: insufficient_quota_error
                  fallback_suggestion: https://evolink.ai/dashboard/credits
        '403':
          description: アクセス権限なし
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 403
                  message: Access denied for this model
                  type: permission_error
                  param: model
        '404':
          description: リソースが存在しません
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 404
                  message: Specified model not found
                  type: not_found_error
                  param: model
                  fallback_suggestion: doubao-seed-2-1-pro
        '429':
          description: リクエスト頻度制限超過
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 429
                  message: Rate limit exceeded
                  type: rate_limit_error
                  fallback_suggestion: retry after 60 seconds
        '500':
          description: サーバー内部エラー
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 500
                  message: Internal server error
                  type: internal_server_error
                  fallback_suggestion: try again later
        '502':
          description: モデルサービスで一時的なエラーが発生しました。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 502
                  message: Upstream AI service unavailable
                  type: upstream_error
                  fallback_suggestion: try different model
        '503':
          description: サービスが一時的に利用不可
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error:
                  code: 503
                  message: Service temporarily unavailable
                  type: service_unavailable_error
                  fallback_suggestion: retry after 30 seconds
components:
  schemas:
    CreateMessageRequest:
      type: object
      required:
        - model
        - max_tokens
        - messages
      properties:
        model:
          type: string
          description: >-
            モデルの選択


            | モデル ID | 用途 | コンテキスト長 |

            |---|---|---|

            | `doubao-seed-2-1-pro` | 複雑な推論、長文書、コードベースに適した推奨の最上位モデル | 100 万トークン
            |

            | `doubao-seed-2-1-turbo` | 対話、データ抽出、エージェント処理向けの低価格モデル | 25.6 万トークン
            |

            | `doubao-seed-2-1-lite` | Seed 2.1 で最も低価格。音声入力は Chat Completions と
            Responses のみ対応 | 100 万トークン |

            | `doubao-seed-evolving` | 新機能の評価向けに毎週更新 | 100 万トークン |

            | `doubao-seed-2.0-pro` | 旧モデル名。現在は `doubao-seed-2-1-lite` に転送されます |
            100 万トークン |

            | `doubao-seed-2.0-lite` | 旧モデル名。現在は `doubao-seed-2-1-lite` に転送されます
            | 100 万トークン |

            | `doubao-seed-2.0-mini` | 簡単なタスク向けの Seed 2.0 最速モデル | 25.6 万トークン |

            | `doubao-seed-2.0-code` | 旧モデル名。現在は `doubao-seed-evolving` に転送されます
            | 100 万トークン |


            Seed 2.1 のモデル ID はハイフン（`2-1`）、Seed 2.0 はピリオド（`2.0`）を使います。
          enum:
            - doubao-seed-2-1-pro
            - doubao-seed-2-1-turbo
            - doubao-seed-2-1-lite
            - doubao-seed-evolving
            - doubao-seed-2.0-pro
            - doubao-seed-2.0-lite
            - doubao-seed-2.0-mini
            - doubao-seed-2.0-code
          default: doubao-seed-2-1-pro
          example: doubao-seed-2-1-pro
        max_tokens:
          type: integer
          minimum: 1
          example: 4096
          description: >-
            思考と本文を合わせた最大出力トークン数。思考が有効な場合は 1024 以上を推奨します。予算を使い切ると `stop_reason` が
            `max_tokens` となり、思考だけが返る場合があります。
        messages:
          type: array
          minItems: 1
          description: 各ターンで全メッセージ履歴を送ります。assistant の思考ブロックは署名とともにそのまま返してください。
          items:
            $ref: '#/components/schemas/Message'
        system:
          description: システムプロンプト。文字列またはテキストブロックの配列で指定します。
          oneOf:
            - type: string
            - type: array
              items:
                $ref: '#/components/schemas/TextBlock'
        stream:
          type: boolean
          default: false
          description: Anthropic SSE イベントとして応答をストリーミングします。
        thinking:
          type: object
          description: 思考の有効・無効を切り替えます。
          required:
            - type
          properties:
            type:
              type: string
              enum:
                - enabled
                - disabled
              description: >-
                すべての Seed モデルで既定は `enabled` で、回答前に思考します。`disabled`
                では直接回答します。思考トークンは出力に含まれ、出力料金が適用されます。
        output_config:
          type: object
          description: 思考の深さと構造化出力の設定。
          properties:
            effort:
              type: string
              enum:
                - none
                - minimal
                - low
                - medium
                - high
                - xhigh
                - max
              description: >-
                思考の深さ。`minimal` は直接回答、`low` は速度優先、`medium` は速度と深さのバランス、`high`
                は複雑な問題の詳細な分析に適しています。


                既定値は Seed 2.1 と `doubao-seed-evolving` が `high`、Seed 2.0 が
                `medium`。`none` は `minimal`、`xhigh` と `max` は `high` として扱います。
            format:
              type: object
              description: 構造化出力の形式
              required:
                - type
              properties:
                type:
                  type: string
                  enum:
                    - json_object
                    - json_schema
                  description: >-
                    `json_object` は JSON オブジェクトを返します。プロンプトで JSON
                    出力を明示してください。`json_schema` は `schema` に従う JSON を返します。
                schema:
                  type: object
                  additionalProperties: true
                  description: JSON Schema の定義。`json_schema` の場合は必須。
        temperature:
          type: number
          minimum: 0
          maximum: 2
          description: サンプリング温度は [0, 2]。`temperature` と `top_p` は片方だけ調整してください。
        top_p:
          type: number
          minimum: 0
          maximum: 1
          description: 核サンプリングの確率しきい値。[0, 1] の範囲。
        stop_sequences:
          type: array
          items:
            type: string
          maxItems: 4
          description: 生成を終了する文字列を 4 個まで指定できます。一致した文字列は出力されません。使用前に思考を無効にしてください。
        tools:
          type: array
          description: >-
            全 Seed モデルが `name`、`description`、`input_schema` で定義する関数に対応します。Seed
            2.1 と `doubao-seed-evolving` のウェブ検索には
            `type=web_search_20250305`、`name=web_search`
            を指定します。`doubao-seed-2.0-mini` のウェブ検索や `web_fetch` など他のサーバーツールは 400
            を返します。実行した検索ごとにモデルの料金がかかります。
          items:
            oneOf:
              - $ref: '#/components/schemas/Tool'
              - $ref: '#/components/schemas/WebSearchTool'
        tool_choice:
          $ref: '#/components/schemas/ToolChoice'
    MessageResponse:
      type: object
      properties:
        id:
          type: string
          description: レスポンスの一意の識別子
          example: 0217952345678901234567890abcdef
        type:
          type: string
          enum:
            - message
          description: 常に `message`。
        role:
          type: string
          enum:
            - assistant
          description: 常に `assistant`。
        model:
          type: string
          description: このリクエストで使用したモデル。
          example: doubao-seed-2-1-pro
        content:
          type: array
          description: >-
            生成されたコンテンツブロック。思考が有効な場合、通常は `thinking` の後に `text` が続きます。本文は
            `type="text"` のブロックから読み取ります。
          items:
            oneOf:
              - $ref: '#/components/schemas/TextBlock'
              - $ref: '#/components/schemas/ThinkingBlock'
              - $ref: '#/components/schemas/ToolUseBlock'
              - $ref: '#/components/schemas/ServerToolUseBlock'
              - $ref: '#/components/schemas/WebSearchResultBlock'
          example:
            - type: thinking
              thinking: 短い自己紹介を求められている…
              signature: EqQBCkgIARABGAIi...
            - type: text
              text: こんにちは。Seed シリーズの言語モデルです。推論、文章作成、プログラミングが得意です。
        stop_reason:
          type: string
          description: |-
            生成の終了理由。

            - `end_turn`: 正常終了
            - `max_tokens`: トークン上限に到達
            - `stop_sequence`: 停止シーケンスに一致
            - `tool_use`: 関数呼び出しを要求
          enum:
            - end_turn
            - max_tokens
            - stop_sequence
            - tool_use
          example: end_turn
        stop_sequence:
          type:
            - string
            - 'null'
          description: 一致した停止シーケンス。一致しなければ `null`。
        usage:
          $ref: '#/components/schemas/MessageUsage'
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: integer
              description: HTTPステータスエラーコード
            message:
              type: string
              description: エラーの説明
            type:
              type: string
              description: エラータイプ
            param:
              type: string
              description: 関連パラメータ名
            fallback_suggestion:
              type: string
              description: エラー時の提案
    Message:
      type: object
      required:
        - role
        - content
      properties:
        role:
          type: string
          enum:
            - user
            - assistant
          description: メッセージのロール。システムプロンプトは最上位の `system` に指定します。
        content:
          description: メッセージ内容。文字列またはコンテンツブロックの配列。
          oneOf:
            - type: string
            - type: array
              items:
                $ref: '#/components/schemas/ContentBlock'
    TextBlock:
      type: object
      title: テキスト
      required:
        - type
        - text
      properties:
        type:
          type: string
          enum:
            - text
          description: 常に `text`。
        text:
          type: string
          description: テキスト内容
    Tool:
      type: object
      title: カスタム関数
      required:
        - name
        - input_schema
      properties:
        name:
          type: string
          description: 関数名
        description:
          type: string
          description: モデルが関数をいつ呼び出すか判断するための説明。
        input_schema:
          type: object
          additionalProperties: true
          description: JSON Schema で定義する関数引数。
    WebSearchTool:
      type: object
      title: ウェブ検索（Seed 2.1 と Evolving のみ）
      required:
        - type
        - name
      properties:
        type:
          type: string
          enum:
            - web_search_20250305
          description: 常に `web_search_20250305`。
        name:
          type: string
          enum:
            - web_search
          description: 常に `web_search`。
        max_uses:
          type: integer
          minimum: 1
          description: このリクエストで許可する最大検索回数。
        allowed_domains:
          type: array
          items:
            type: string
          description: これらのドメインのみを検索します。
        blocked_domains:
          type: array
          items:
            type: string
          description: これらのドメインを検索から除外します。
        user_location:
          type: object
          additionalProperties: true
          description: 検索に用いる地域。国、地域、都市など。
    ToolChoice:
      type: object
      required:
        - type
      description: ツール選択方針。先に `tools` を設定してください。
      properties:
        type:
          type: string
          enum:
            - auto
            - any
            - tool
            - none
          default: auto
          description: >-
            `auto`: モデルが判断。`any`: いずれかのツールを使用。`tool`: `name` で指定したツールを使用。`none`:
            呼び出さない。
        name:
          type: string
          description: 種別が `tool` の場合に呼び出すツール名。
        disable_parallel_tool_use:
          type: boolean
          default: false
          description: 同じターンでの並列ツール呼び出しを禁止するかどうか。
    ThinkingBlock:
      type: object
      title: 思考
      required:
        - type
        - thinking
      properties:
        type:
          type: string
          enum:
            - thinking
          description: 常に `thinking`。
        thinking:
          type: string
          description: モデルの思考内容。次のターンでは署名とともにそのまま返します。
        signature:
          type: string
          description: 思考の署名。次のターンでも署名、思考内容、ブロックの順序を保持します。
    ToolUseBlock:
      type: object
      title: ツール利用
      required:
        - type
        - id
        - name
        - input
      properties:
        type:
          type: string
          enum:
            - tool_use
          description: 常に `tool_use`。
        id:
          type: string
          description: ツール呼び出し ID。`tool_use_id` で結果を対応付けます。
        name:
          type: string
          description: モデルが呼び出しを要求した関数名。
        input:
          type: object
          additionalProperties: true
          description: モデルが生成した関数引数のオブジェクト。
    ServerToolUseBlock:
      type: object
      title: Web 検索呼び出し
      properties:
        type:
          type: string
          enum:
            - server_tool_use
          description: 常に `server_tool_use`。
        id:
          type: string
          description: サーバーツール呼び出し ID。
        name:
          type: string
          description: ツール名。ウェブ検索では `web_search`。
        input:
          type: object
          additionalProperties: true
          description: 'モデルが生成した検索パラメーター（例: `query`）。'
    WebSearchResultBlock:
      type: object
      title: ウェブ検索結果
      properties:
        type:
          type: string
          enum:
            - web_search_tool_result
          description: 常に `web_search_tool_result`。
        tool_use_id:
          type: string
          description: 対応する `server_tool_use` の ID。
        content:
          description: >-
            検索結果。失敗時は `type=web_search_tool_result_error` と `error_code`
            を含むエラーオブジェクト。
          oneOf:
            - type: array
              items:
                type: object
                properties:
                  type:
                    type: string
                    enum:
                      - web_search_result
                  title:
                    type: string
                    description: 結果のタイトル
                  url:
                    type: string
                    description: 結果の URL
                  page_age:
                    type: string
                    description: ページの経過時間
                  encrypted_content:
                    type: string
                    description: 暗号化された内容。次のターンでもそのまま返します。
            - type: object
              properties:
                type:
                  type: string
                  enum:
                    - web_search_tool_result_error
                error_code:
                  type: string
                  description: エラーコード
    MessageUsage:
      type: object
      description: トークン使用統計情報
      properties:
        input_tokens:
          type: integer
          description: キャッシュにヒットしなかった入力トークン数。`cache_read_input_tokens` は含みません。
          example: 25
        cache_read_input_tokens:
          type: integer
          description: >-
            キャッシュヒット料金が適用された入力トークン数。総入力 = `input_tokens` +
            `cache_read_input_tokens`。
          example: 0
        cache_creation_input_tokens:
          type: integer
          description: 常に 0。このエンドポイントではキャッシュ書き込みに別料金はかかりません。
          example: 0
        output_tokens:
          type: integer
          description: 思考を含む出力トークン数。
          example: 120
        server_tool_use:
          type: object
          description: ウェブ検索使用時に返る、サーバーツールの実行回数。
          properties:
            web_search_requests:
              type: integer
              description: このリクエストで実行した検索回数。検索ごとに課金されます。
              example: 1
    ContentBlock:
      description: テキスト、画像、文書、思考、関数呼び出し、関数結果のほか、次のターンに返すウェブ検索の呼び出しと結果を指定できます。
      oneOf:
        - $ref: '#/components/schemas/TextBlock'
        - $ref: '#/components/schemas/ImageBlock'
        - $ref: '#/components/schemas/DocumentBlock'
        - $ref: '#/components/schemas/ThinkingBlock'
        - $ref: '#/components/schemas/ToolUseBlock'
        - $ref: '#/components/schemas/ToolResultBlock'
        - $ref: '#/components/schemas/ServerToolUseBlock'
        - $ref: '#/components/schemas/WebSearchResultBlock'
    ImageBlock:
      type: object
      title: 画像
      required:
        - type
        - source
      properties:
        type:
          type: string
          enum:
            - image
          description: 常に `image`。
        source:
          type: object
          required:
            - type
          description: 画像ソース
          properties:
            type:
              type: string
              enum:
                - url
                - base64
              description: '`url`: 公開画像 URL。`base64`: Base64 エンコードした画像データ。'
            url:
              type: string
              description: 画像 URL。`url` の場合は必須。
            media_type:
              type: string
              enum:
                - image/jpeg
                - image/png
                - image/gif
                - image/webp
              description: 画像の MIME タイプ。`base64` の場合は必須。
            data:
              type: string
              description: 接頭辞 `data:` を除いた Base64 画像データ。`base64` の場合は必須。
    DocumentBlock:
      type: object
      title: 文書
      required:
        - type
        - source
      properties:
        type:
          type: string
          enum:
            - document
          description: 常に `document`。
        source:
          type: object
          required:
            - type
          description: 文書ソース
          properties:
            type:
              type: string
              enum:
                - url
                - base64
                - text
              description: '`url`: 公開文書 URL。`base64`: Base64 文書データ。`text`: プレーンテキスト。'
            url:
              type: string
              description: 文書 URL。`url` の場合は必須。
            media_type:
              type: string
              description: 文書の MIME タイプ。例は `application/pdf`、`text/plain`。
            data:
              type: string
              description: 文書データ。`base64` または `text` の場合は必須。
    ToolResultBlock:
      type: object
      title: 関数の結果
      required:
        - type
        - tool_use_id
        - content
      properties:
        type:
          type: string
          enum:
            - tool_result
          description: 常に `tool_result`。
        tool_use_id:
          type: string
          description: 対応する `tool_use` ブロックの ID。
        content:
          description: 関数の結果。文字列またはテキスト・画像ブロックの配列。
          oneOf:
            - type: string
            - type: array
              items:
                oneOf:
                  - $ref: '#/components/schemas/TextBlock'
                  - $ref: '#/components/schemas/ImageBlock'
        is_error:
          type: boolean
          default: false
          description: 関数の実行が失敗したかどうか。
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: |-
        ##すべてのAPIにBearer Token認証が必要です##

        **APIキーの取得：**

        [APIキー管理ページ](https://evolink.ai/dashboard/keys)にアクセスしてAPIキーを取得してください

        **リクエストヘッダーに追加：**
        ```
        Authorization: Bearer YOUR_API_KEY
        ```

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.