> ## 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.

# MiniMax Messages API 레퍼런스

> - Anthropic Messages. `model`로 모델을 선택하세요.
- 요청 및 응답 구조가 Anthropic API와 호환됩니다
- `MiniMax-M4`, `MiniMax-M3.1-Flash`, `MiniMax-M3`는 이미지와 동영상을 지원합니다. `MiniMax-M2.5`는 텍스트만 지원합니다.
- **시스템 프롬프트**: 최상위 `system` 필드로 전달합니다
- `MiniMax-M4`와 `MiniMax-M3.1-Flash`는 항상 추론하며 추론 내용을 `content[type=thinking]` 블록으로 반환합니다. `MiniMax-M3`는 기본적으로 추론하지 않습니다. `thinking`을 `{"type": "adaptive"}`로 설정하면 추론을 수행하고 `thinking` 블록을 반환합니다. `MiniMax-M2.5`는 추론하지만 `thinking` 블록을 반환하지 않습니다. 추론 토큰은 `output_tokens`에 포함됩니다.
- **스트리밍**: SSE 이벤트 스트림을 지원합니다
- **도구 호출**: Anthropic `tool_use` / `tool_result` 흐름과 호환됩니다. 이 엔드포인트에서 `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat Completions](/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference)을 사용하세요.

**스트리밍 이벤트**: `message_start` → `content_block_start` → `content_block_delta` (`thinking_delta` / `signature_delta` / `text_delta` / `input_json_delta`) → `content_block_stop` → `message_delta` → `message_stop` 순서이며 중간에 `ping`이 포함될 수 있습니다. 최종 사용량은 `message_delta` 이벤트의 `usage`를 기준으로 합니다.

> [!NOTE]
>
> **BaseURL**: 기본 BaseURL은 `https://direct.evolink.ai`이며, 텍스트 모델과 장시간 연결을 더 잘 지원합니다. `https://api.evolink.ai`는 멀티모달 서비스의 기본 엔드포인트이자 텍스트 모델의 대체 주소 역할을 합니다.

> [!NOTE]
>
> `MiniMax-M4`와 `MiniMax-M3.1-Flash`는 항상 추론합니다. `output_config.effort`로 `low`, `medium`, `high`, `xhigh`, `max`(기본값) 중에서 선택하세요. `thinking.type`에 `disabled`를 지정하거나 `effort`에 `none`을 지정하면 HTTP 400이 반환됩니다. `MiniMax-M3`는 기본적으로 추론하지 않습니다. `thinking`을 `{"type": "adaptive"}`로 설정하면 추론을 수행하고 `thinking` 블록을 반환합니다. `MiniMax-M2.5`는 추론하지만 `thinking` 블록을 반환하지 않습니다. 추론 토큰은 `output_tokens`에 포함됩니다.

> [!NOTE]
>
> **최대 출력(추론 토큰 포함)** — `MiniMax-M4` 262,144, `MiniMax-M3.1-Flash` 524,288, `MiniMax-M3` 524,288, `MiniMax-M2.5` 32,768.

> [!NOTE]
>
> `MiniMax-M2.5`는 텍스트 입력만 지원하며 최대 32,768토큰을 출력합니다. 이 엔드포인트에서 `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat Completions](https://evolink.ai/docs/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference.md)을 사용하세요.


## OpenAPI

````yaml ko/api-manual/language-series/minimax/messages/messages-reference.json POST /v1/messages
openapi: 3.1.0
info:
  title: MiniMax Messages API 레퍼런스
  description: >-
    `POST /v1/messages` (Anthropic Messages). `model`로 모델을 선택하세요. `MiniMax-M4`,
    `MiniMax-M3.1-Flash`, `MiniMax-M3`는 이미지와 동영상을 지원합니다. `MiniMax-M2.5`는 텍스트만
    지원합니다. 필수 필드는 `model`, `max_tokens`, `messages`입니다.


    `system`, `temperature`, `top_p`, `stream`, `thinking`, `output_config`,
    `tools`, `tool_choice`는 선택 사항입니다. 모델별 한도와 추론 설정은 `model`, `thinking`,
    `output_config`, `max_tokens`를 참고하세요.


    이 엔드포인트는 `cache_control`을 지원하지 않으므로 생략하세요. 일치하는 접두사는 자동으로 캐시됩니다. 캐시된 토큰은
    `usage.cache_read_input_tokens`에 표시되며 캐시 적중 단가로 청구됩니다. `signature`가 포함된
    `thinking`과 `tool_use`를 비롯해 이전 어시스턴트 블록 전체를 전달하세요.
  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 프로토콜 인터페이스
paths:
  /v1/messages:
    post:
      tags:
        - Messages
      summary: MiniMax Messages API 레퍼런스 (Anthropic 호환)
      description: >-
        - Anthropic Messages. `model`로 모델을 선택하세요.

        - 요청 및 응답 구조가 Anthropic API와 호환됩니다

        - `MiniMax-M4`, `MiniMax-M3.1-Flash`, `MiniMax-M3`는 이미지와 동영상을 지원합니다.
        `MiniMax-M2.5`는 텍스트만 지원합니다.

        - **시스템 프롬프트**: 최상위 `system` 필드로 전달합니다

        - `MiniMax-M4`와 `MiniMax-M3.1-Flash`는 항상 추론하며 추론 내용을
        `content[type=thinking]` 블록으로 반환합니다. `MiniMax-M3`는 기본적으로 추론하지 않습니다.
        `thinking`을 `{"type": "adaptive"}`로 설정하면 추론을 수행하고 `thinking` 블록을 반환합니다.
        `MiniMax-M2.5`는 추론하지만 `thinking` 블록을 반환하지 않습니다. 추론 토큰은 `output_tokens`에
        포함됩니다.

        - **스트리밍**: SSE 이벤트 스트림을 지원합니다

        - **도구 호출**: Anthropic `tool_use` / `tool_result` 흐름과 호환됩니다. 이 엔드포인트에서
        `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat
        Completions](/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference)을
        사용하세요.


        **스트리밍 이벤트**: `message_start` → `content_block_start` →
        `content_block_delta` (`thinking_delta` / `signature_delta` /
        `text_delta` / `input_json_delta`) → `content_block_stop` →
        `message_delta` → `message_stop` 순서이며 중간에 `ping`이 포함될 수 있습니다. 최종 사용량은
        `message_delta` 이벤트의 `usage`를 기준으로 합니다.
      operationId: createMessageMiniMax
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateMessageRequest'
            examples:
              simple:
                summary: 최소 실행 가능 요청
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  messages:
                    - role: user
                      content: Hello! How can you help me?
              system_prompt:
                summary: 시스템 프롬프트 사용
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  system: >-
                    You are a technical editor. Keep your answers clear and
                    concise.
                  messages:
                    - role: user
                      content: >-
                        Describe the benefits of clear technical documentation
                        in three sentences.
              effort:
                summary: 추론 깊이 조절 (output_config.effort)
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  output_config:
                    effort: high
                  messages:
                    - role: user
                      content: >-
                        A bat and a ball cost 1.10 in total. The bat costs 1.00
                        more than the ball. How much does the ball cost?
              image_understanding:
                summary: 이미지 이해(멀티모달 콘텐츠 블록)
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  messages:
                    - role: user
                      content:
                        - type: text
                          text: What is shown in this image?
                        - type: image
                          source:
                            type: url
                            url: https://example.com/image.jpeg
              video_understanding:
                summary: 비디오 이해 (멀티모달 콘텐츠 블록)
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  messages:
                    - role: user
                      content:
                        - type: text
                          text: Summarize this video.
                        - type: video
                          source:
                            type: url
                            url: https://example.com/video.mp4
                            fps: 1
              tool_use:
                summary: 도구 호출(Anthropic tool_use 스타일)
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  messages:
                    - role: user
                      content: Check the stock for product demo-item-001.
                  tools:
                    - name: get_product_stock
                      description: Get the current stock level for a product.
                      input_schema:
                        type: object
                        properties:
                          product_id:
                            type: string
                            description: Product identifier.
                        required:
                          - product_id
                  tool_choice:
                    type: auto
              streaming:
                summary: 스트리밍 출력(SSE)
                value:
                  model: MiniMax-M4
                  max_tokens: 131072
                  stream: true
                  messages:
                    - role: user
                      content: Write a short poem about spring.
              m3_thinking:
                summary: '`MiniMax-M3` 추론 켜기'
                description: >-
                  `MiniMax-M3`는 기본적으로 추론하지 않습니다. `thinking`을 `{"type":
                  "adaptive"}`로 설정하면 추론을 수행하고 `thinking` 블록을 반환합니다.
                value:
                  model: MiniMax-M3
                  max_tokens: 131072
                  thinking:
                    type: adaptive
                  messages:
                    - role: user
                      content: >-
                        A bat and a ball cost 1.10 in total. The bat costs 1.00
                        more than the ball. How much does the ball cost?
              m25_text:
                summary: MiniMax-M2.5 호출 (텍스트 전용)
                description: >-
                  `MiniMax-M2.5`는 텍스트 입력만 지원하며 최대 32,768토큰을 출력합니다. 이 엔드포인트에서
                  `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat
                  Completions](/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference)을
                  사용하세요.
                value:
                  model: MiniMax-M2.5
                  max_tokens: 4096
                  messages:
                    - role: user
                      content: Explain recursion in one sentence.
      responses:
        '200':
          description: 메시지 객체
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessageResponse'
              examples:
                with_thinking:
                  summary: 추론 내용이 포함된 응답 (thinking 블록)
                  value:
                    id: example_a9e449
                    type: message
                    role: assistant
                    model: MiniMax-M3.1-Flash
                    content:
                      - thinking: Let the ball cost x. Then 2x + 1 = 1.10, so x = 0.05.
                        signature: EXAMPLE_THINKING_SIGNATURE
                        type: thinking
                      - text: '0.05'
                        type: text
                    usage:
                      input_tokens: 55
                      output_tokens: 66
                      cache_creation_input_tokens: 0
                      cache_read_input_tokens: 174
                      output_tokens_details:
                        thinking_tokens: 63
                    stop_reason: end_turn
                direct_answer:
                  summary: 직접 답변 (추론 내용 없음)
                  value:
                    id: example_ac2b01
                    type: message
                    role: assistant
                    model: MiniMax-M3.1-Flash
                    content:
                      - text: >-
                          Recursion is a technique in which a function calls
                          itself to solve smaller instances of a problem.
                        type: text
                    usage:
                      input_tokens: 23
                      output_tokens: 6
                      cache_creation_input_tokens: 0
                      cache_read_input_tokens: 184
                    stop_reason: end_turn
                tool_use:
                  summary: 도구 호출 트리거(stop_reason=tool_use)
                  value:
                    id: example_99733d
                    type: message
                    role: assistant
                    model: MiniMax-M3.1-Flash
                    content:
                      - type: tool_use
                        id: call_example_1
                        name: get_product_stock
                        input:
                          product_id: demo-item-001
                    usage:
                      input_tokens: 283
                      output_tokens: 31
                      cache_creation_input_tokens: 0
                      cache_read_input_tokens: 174
                    stop_reason: tool_use
                m25_answer:
                  summary: '`MiniMax-M2.5` 응답 (`thinking` 블록 없음)'
                  value:
                    id: chatcmpl-example
                    type: message
                    role: assistant
                    content:
                      - type: text
                        text: >-
                          Recursion is a technique in which a function calls
                          itself to solve smaller instances of a problem.
                    stop_reason: end_turn
                    model: MiniMax-M2.5
                    usage:
                      input_tokens: 44
                      cache_creation_input_tokens: 0
                      cache_read_input_tokens: 0
                      output_tokens: 101
        '400':
          description: 요청 매개변수 오류
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                request_id: req_xxx
                error:
                  type: invalid_request_error
                  message: Invalid request
        '401':
          description: 인증 오류
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                error:
                  type: authentication_error
                  message: Authentication error
        '402':
          description: 할당량 부족
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                error:
                  type: billing_error
                  message: Insufficient quota
        '403':
          description: 권한 오류
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                error:
                  type: permission_error
                  message: Permission denied
        '404':
          description: 모델 또는 리소스를 찾을 수 없음
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                error:
                  type: not_found_error
                  message: Model not found
        '429':
          description: 속도 제한 초과
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                type: error
                error:
                  type: rate_limit_error
                  message: Rate limited
        '500':
          description: 서버 내부 오류
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '502':
          description: 게이트웨이 오류
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: 서비스를 일시적으로 사용할 수 없음
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CreateMessageRequest:
      type: object
      required:
        - model
        - messages
        - max_tokens
      properties:
        model:
          type: string
          description: >-
            | 모델 | 컨텍스트(토큰) | 최대 출력(토큰) |

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

            | `MiniMax-M4` | 1,000,000 | 262,144 |

            | `MiniMax-M3.1-Flash` | 1,000,000 | 524,288 |

            | `MiniMax-M3` | 1,000,000 | 524,288 |

            | `MiniMax-M2.5` | 204,800 | 32,768 |


            `MiniMax-M4`와 `MiniMax-M3.1-Flash`는 항상 추론합니다.
            `output_config.effort`로 추론 깊이를 조정합니다. `MiniMax-M3`는 기본적으로 추론하지 않습니다.
            `thinking`을 `{"type": "adaptive"}`로 설정하면 추론을 수행하고 `thinking` 블록을
            반환합니다. `MiniMax-M3`와 `MiniMax-M2.5`는 추론 깊이를 변경할 수 없습니다.
            `MiniMax-M2.5`는 추론하지만 `thinking` 블록을 반환하지 않습니다. 추론 토큰은
            `output_tokens`에 포함됩니다. `MiniMax-M4`, `MiniMax-M3.1-Flash`,
            `MiniMax-M3`는 이미지와 동영상을 지원합니다. `MiniMax-M2.5`는 텍스트만 지원합니다. 이 엔드포인트에서
            `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat
            Completions](/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference)을
            사용하세요. 추론 토큰은 출력 한도에 포함되며 출력 단가로 청구됩니다.
          enum:
            - MiniMax-M4
            - MiniMax-M3.1-Flash
            - MiniMax-M3
            - MiniMax-M2.5
          example: MiniMax-M4
        max_tokens:
          type: integer
          description: >-
            최대 출력(추론 토큰 포함)


            | 모델 | 권장 출력 | 최대 출력 |

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

            | `MiniMax-M4` | 131,072 | 262,144 |

            | `MiniMax-M3.1-Flash` | 131,072 | 524,288 |

            | `MiniMax-M3` | 131,072 | 524,288 |

            | `MiniMax-M2.5` | 필요에 따라 설정 | 32,768 |


            출력 예산은 우선 1,024토큰 이상으로 설정하세요. 추론 단계에서 모두 소모하면 답변 본문이 없을 수
            있습니다(`stop_reason=max_tokens`).
          minimum: 1
          maximum: 524288
          example: 131072
        messages:
          type: array
          description: |-
            대화 메시지 목록, 턴마다 user / assistant 교대

            **설명**:
            - 최소 1개의 메시지를 포함해야 함
            - 마지막 메시지는 일반적으로 `role=user`
          items:
            $ref: '#/components/schemas/InputMessage'
          minItems: 1
        system:
          description: >-
            AI의 역할과 동작을 설정하는 시스템 프롬프트입니다. 문자열 또는 텍스트 콘텐츠 블록 배열을 지원하며 최상위
            `system` 필드로 전달합니다.
          oneOf:
            - type: string
              example: You are a helpful assistant.
            - type: array
              description: 콘텐츠 블록 배열 형식의 시스템 프롬프트입니다.
              items:
                type: object
                required:
                  - type
                  - text
                properties:
                  type:
                    type: string
                    enum:
                      - text
                  text:
                    type: string
        temperature:
          type: number
          description: >-
            `MiniMax-M4`, `MiniMax-M3.1-Flash`, `MiniMax-M3` — 온도는 1로 고정되며 다른 값을
            지정해도 바뀌지 않습니다. `MiniMax-M2.5`의 기본값은 1이며 조정할 수 있습니다. 온도가 낮을수록 일관된 답변이
            나옵니다. `temperature`와 `top_p` 중 하나만 조정하세요.
          default: 1
          example: 1
        top_p:
          type: number
          description: >-
            `MiniMax-M4`, `MiniMax-M3.1-Flash`, `MiniMax-M3` — 0.95로 고정됩니다. 값을
            지정할 때는 0보다 크고 1 이하인 값을 사용하세요. `MiniMax-M2.5`의 기본값은 0.95이며 조정할 수
            있습니다. `temperature`와 `top_p` 중 하나만 조정하세요.
          exclusiveMinimum: 0
          maximum: 1
          default: 0.95
          example: 0.95
        stream:
          type: boolean
          description: |-
            SSE 스트리밍으로 반환할지 여부

            - `true`: Server-Sent Events 스트리밍 반환
            - `false`: 완전한 응답 후 한 번에 반환(기본값)
          default: false
          example: false
        thinking:
          type: object
          description: >-
            - `MiniMax-M4`와 `MiniMax-M3.1-Flash`는 `thinking`을 생략하거나 `type`을
            `adaptive`로 지정하세요. `disabled`는 HTTP 400을 반환합니다.

            - `MiniMax-M3`는 기본적으로 추론하지 않습니다. `thinking`을 `{"type": "adaptive"}`로
            설정하면 추론을 수행하고 `thinking` 블록을 반환합니다. `{"type": "disabled"}`로 설정하면 추론을
            끕니다.

            - `MiniMax-M2.5`는 추론하지만 `thinking` 블록을 반환하지 않습니다. 추론 토큰은
            `output_tokens`에 포함됩니다.

            - 추론 토큰은 출력 한도에 포함되며 출력 단가로 청구됩니다.
          required:
            - type
          properties:
            type:
              type: string
              enum:
                - adaptive
                - disabled
        output_config:
          type: object
          description: 출력 설정
          properties:
            effort:
              type: string
              description: >-
                - `MiniMax-M4`, `MiniMax-M3.1-Flash` — 추론 깊이는 `low`, `medium`,
                `high`, `xhigh`, `max`(기본값) 중에서 선택합니다. `none`은 HTTP 400을 반환합니다.
                깊이가 높을수록 보통 추론 토큰과 응답 시간이 늘어납니다.

                - `MiniMax-M3`와 `MiniMax-M2.5`는 추론 깊이를 변경할 수 없습니다. 두 모델에서는 이 값을
                생략하세요.
              enum:
                - low
                - medium
                - high
                - xhigh
                - max
              example: high
        tools:
          type: array
          description: >-
            도구는 Anthropic 형식으로 정의하며 `input_schema`에는 JSON Schema 객체를 사용합니다. 이
            엔드포인트에서 `MiniMax-M2.5`는 도구 호출을 지원하지 않습니다. 도구를 호출하려면 [Chat
            Completions](/ko/api-manual/language-series/minimax/chat-completions/chat-completions-reference)을
            사용하세요.
          items:
            $ref: '#/components/schemas/Tool'
        tool_choice:
          type: object
          description: 도구 선택 전략입니다. 모델이 도구 호출 여부를 결정하는 `auto`만 지원합니다.
          required:
            - type
          properties:
            type:
              type: string
              enum:
                - auto
    MessageResponse:
      type: object
      description: Anthropic 스타일의 메시지 응답
      properties:
        id:
          type: string
          description: 메시지 고유 ID
        type:
          type: string
          enum:
            - message
          description: 응답 객체 유형
        role:
          type: string
          enum:
            - assistant
        model:
          type: string
          description: 실제 사용된 모델
          example: MiniMax-M4
        content:
          type: array
          description: >-
            응답 블록은 `thinking`(추론, 간단한 질문에서 생략될 수 있고 `MiniMax-M2.5`에서는 반환하지 않음),
            `text`(답변), `tool_use`(도구 호출)입니다.
          items:
            $ref: '#/components/schemas/OutputContentBlock'
        stop_reason:
          type: string
          description: |-
            정지 사유

            - `end_turn`: 자연스러운 종료
            - `max_tokens`: max_tokens 상한 도달
            - `tool_use`: 모델이 도구 호출을 트리거
          enum:
            - end_turn
            - max_tokens
            - tool_use
        usage:
          $ref: '#/components/schemas/AnthropicUsage'
    ErrorResponse:
      type: object
      properties:
        type:
          type: string
          enum:
            - error
        error:
          type: object
          properties:
            type:
              type: string
              description: >-
                오류 유형(예: invalid_request_error / authentication_error /
                billing_error 등)
            message:
              type: string
              description: 오류 설명
        request_id:
          type: string
          description: 요청 추적 ID
    InputMessage:
      type: object
      required:
        - role
        - content
      properties:
        role:
          type: string
          enum:
            - user
            - assistant
          description: >-
            메시지 발신자의 역할로 user와 assistant가 번갈아 사용됩니다


            - `user`: 사용자 메시지이며 `tool_result` 블록을 반환할 때도 사용합니다

            - `assistant`: 이전 어시스턴트 응답이며 `text` / `thinking` / `tool_use` 블록을
            포함할 수 있습니다


            시스템 프롬프트는 최상위 `system` 필드로 전달합니다.
        content:
          description: >-
            메시지 내용


            **설명**:

            - 순수 텍스트일 경우 문자열을 직접 전달

            - 구조화된 경우 content block 배열을 전달(`text` / `image` / `video` /
            `tool_use` / `tool_result` / `thinking`)
          oneOf:
            - type: string
            - type: array
              items:
                $ref: '#/components/schemas/ContentBlock'
    Tool:
      type: object
      required:
        - name
        - input_schema
      properties:
        name:
          type: string
          description: |-
            도구 이름

            **설명**:
            - `a-zA-Z0-9_-`만 허용
            - 최대 64자
        description:
          type: string
          description: 도구 기능 설명, 모델이 언제 호출할지 판단하도록 도움
        input_schema:
          type: object
          description: |-
            도구 입력 파라미터의 JSON Schema 객체

            **설명**:
            - `type`은 반드시 `object`여야 함
            - `properties`와 `required`를 선언해야 함
    OutputContentBlock:
      type: object
      description: 응답 내의 콘텐츠 블록
      properties:
        type:
          type: string
          enum:
            - text
            - thinking
            - tool_use
        text:
          type: string
          description: type=`text`일 때의 텍스트
        thinking:
          type: string
          description: type=`thinking`일 때의 추론 과정 텍스트
        signature:
          type: string
          description: >-
            type=`thinking`일 때의 무결성 서명, 멀티턴 컨텍스트 검증에 사용됩니다. 예제의 `signature` 값은
            자리표시자입니다. 다음 요청에서는 이전 응답에 포함된 값을 그대로 보내세요.
        id:
          type: string
          description: type=`tool_use`일 때의 도구 호출 ID
        name:
          type: string
          description: type=`tool_use`일 때의 도구 이름
        input:
          type: object
          description: type=`tool_use`일 때 모델이 생성한 JSON 입력 파라미터
    AnthropicUsage:
      type: object
      description: Token 사용 통계(Anthropic 규범)
      properties:
        input_tokens:
          type: integer
          description: 캐시에 적중하지 않은 입력 토큰 수로, `cache_read_input_tokens`는 포함하지 않습니다.
          example: 55
        output_tokens:
          type: integer
          description: 출력 token 수(thinking 포함)
          example: 66
        cache_creation_input_tokens:
          type: integer
          description: 캐시 생성에 사용된 입력 토큰 수로, 자동 캐시에서는 0입니다.
          example: 0
        cache_read_input_tokens:
          type: integer
          description: >-
            캐시에 적중한 입력 토큰 수로, 캐시 적중 요금이 적용됩니다. 전체 입력 = `input_tokens +
            cache_read_input_tokens`입니다.
          example: 174
        output_tokens_details:
          type: object
          description: 출력 token 상세 내역
          properties:
            thinking_tokens:
              type: integer
              description: 추론 과정에서 생성된 토큰 수로, `output_tokens`에 이미 포함되어 있습니다.
              example: 63
    ContentBlock:
      type: object
      description: >-
        텍스트, 이미지, 동영상에 각각 `text`, `image`, `video`를 사용합니다. 미디어는 URL이나 Base64로
        전달합니다. 도구 호출에는 `tool_use`와 `tool_result`를 사용하고 추론을 이어갈 때는 이전 `thinking`
        블록과 `signature`를 함께 보내세요. `MiniMax-M4`, `MiniMax-M3.1-Flash`,
        `MiniMax-M3`는 이미지와 동영상을 지원합니다. `MiniMax-M2.5`는 텍스트만 지원합니다. JPEG, PNG,
        GIF, WEBP를 지원하며 이미지당 최대 10MB입니다. 동영상 형식은 MP4, AVI, MOV, MKV이며 파일당 최대
        50MB, 30분입니다.
      required:
        - type
      properties:
        type:
          type: string
          enum:
            - text
            - image
            - video
            - tool_use
            - tool_result
            - thinking
        text:
          type: string
          description: type=`text`일 때의 텍스트 내용
        source:
          $ref: '#/components/schemas/MediaSource'
          description: 이미지 또는 비디오 소스로, type=`image` 또는 type=`video`에서 사용합니다.
        id:
          type: string
          description: 도구 호출 ID(tool_use 시 필수)
        name:
          type: string
          description: 도구 이름(tool_use 시 필수)
        input:
          type: object
          description: 도구 입력 파라미터(tool_use 시, JSON 객체)
        tool_use_id:
          type: string
          description: 대응하는 도구 호출 ID(tool_result 시 필수, tool_use.id에 매핑)
        content:
          description: 도구 실행 결과(tool_result), 문자열 또는 content block 배열
          oneOf:
            - type: string
            - type: array
              items:
                type: object
        thinking:
          type: string
          description: 이전 어시스턴트 메시지의 추론 내용으로, `type=thinking`에서 사용합니다.
        signature:
          type: string
          description: >-
            추론 내용의 서명입니다. 멀티턴 대화에서는 수정하지 않고 다시 전달해야 합니다. 예제의 `signature` 값은
            자리표시자입니다. 다음 요청에서는 이전 응답에 포함된 값을 그대로 보내세요.
    MediaSource:
      type: object
      description: |-
        - JPEG, PNG, GIF, WEBP를 지원하며 이미지당 최대 10MB입니다.
        - 동영상 형식은 MP4, AVI, MOV, MKV이며 파일당 최대 50MB, 30분입니다.
        - 기록을 포함해 요청당 이미지 200개, 동영상 20개까지 허용되며 본문은 최대 64MB입니다.
      required:
        - type
      properties:
        type:
          type: string
          enum:
            - base64
            - url
          description: 미디어 소스 유형
        media_type:
          type: string
          description: 'base64 입력 시 필수, 예: `image/png` 또는 `video/mp4`'
        data:
          type: string
          description: base64로 인코딩된 미디어 바이트
        url:
          type: string
          description: 이미지 또는 동영상의 공개 URL
        detail:
          type: string
          enum:
            - low
            - default
            - high
          default: default
          description: 이해 정밀도, 기본값 default. 해상도가 높을수록 token 소비가 많아짐
        fps:
          type: number
          minimum: 0.2
          maximum: 5
          default: 2
          description: >-
            초당 샘플링할 프레임 수입니다. 기본값은 2이고 범위는 0.2–5입니다. 값이 클수록 움직임을 더 자세히 포착하고 토큰을
            더 많이 사용합니다.
        max_long_side_pixel:
          type: integer
          minimum: 1
          description: 이미지 또는 비디오 프레임 최장변 픽셀 제약
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        모든 인터페이스는 Bearer Token 인증이 필요합니다


        **API Key 발급**:


        [API Key 관리 페이지](https://evolink.ai/dashboard/keys)에 방문하여 API Key를
        발급받으세요


        **요청 헤더에 추가**:

        ```

        Authorization: Bearer YOUR_API_KEY

        ```


        **참고**: EvoLink는 `/v1/messages`에 대해 Bearer Token 인증을 통일적으로 사용합니다.

````

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