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

# miniMax-M3

> 调用 MiniMax OpenAI 兼容聊天模型。当前稳定模型为 `MiniMax-M3`。



## OpenAPI

````yaml api-reference/zh-Hans/zmodelChat/minimax/miniMax-M3.json POST /v1/chat/completions
openapi: 3.0.1
info:
  title: MiniMax-M3
  version: 1.0.0
  description: >-
    MiniMax（`type=35`）通道对话能力文档。公开统一入口为 `/v1/chat/completions`，当前网关会将请求转发到上游
    `POST /v1/text/chatcompletion_v2`，并沿用 OpenAI Chat Completions 兼容的请求与响应结构。


    本文档只描述当前网关已稳定透传且与 MiniMax OpenAI
    兼容能力一致的字段子集：`model`、`messages`、`temperature`、`top_p`、`max_tokens`、`stream`、`stop`。
servers:
  - url: https://api.powertokens.ai
    description: Baze API 服务地址
security: []
tags:
  - name: MiniMax Chat
    description: MiniMax OpenAI 兼容对话能力
paths:
  /v1/chat/completions:
    post:
      tags:
        - MiniMax Chat
      summary: MiniMax-M3
      description: 调用 MiniMax OpenAI 兼容聊天模型。当前稳定模型为 `MiniMax-M3`。
      operationId: minimaxChatCompletions
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ChatCompletionRequest'
            examples:
              basic:
                summary: 非流式对话
                value:
                  model: MiniMax-M3
                  messages:
                    - role: system
                      content: 你是一个简洁的助手。
                    - role: user
                      content: 请用一句话介绍巴黎。
                  temperature: 0.3
              stream:
                summary: 流式对话
                value:
                  model: MiniMax-M3
                  messages:
                    - role: user
                      content: Count from one to five.
                  stream: true
      responses:
        '200':
          description: 调用成功。非流式返回 OpenAI 兼容 JSON；流式返回 OpenAI 兼容 SSE 事件流。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChatCompletionResponse'
            text/event-stream:
              schema:
                type: string
                description: >-
                  SSE 数据流。每个 `data:` 事件都可按 OpenAI Chat Completions Chunk
                  解析；结束时通常返回 `data: [DONE]`。
        '400':
          description: 请求参数错误。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - BearerAuth: []
components:
  schemas:
    ChatCompletionRequest:
      type: object
      required:
        - model
        - messages
      properties:
        model:
          type: string
          enum:
            - MiniMax-M3
        messages:
          type: array
          items:
            $ref: '#/components/schemas/ChatMessage'
        temperature:
          type: number
          minimum: 0
          maximum: 1
          default: 0.7
        top_p:
          type: number
          minimum: 0
          maximum: 1
          default: 0.95
        max_tokens:
          type: integer
          maximum: 2048
          minimum: 1
        stream:
          type: boolean
          default: true
        stop:
          oneOf:
            - type: string
            - type: array
              items:
                type: string
    ChatCompletionResponse:
      type: object
      properties:
        id:
          type: string
        object:
          type: string
        created:
          type: integer
        model:
          type: string
        choices:
          type: array
          items:
            type: object
        usage:
          type: object
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          $ref: '#/components/schemas/ErrorObject'
    ChatMessage:
      type: object
      required:
        - role
        - content
      properties:
        role:
          type: string
          enum:
            - system
            - user
            - assistant
            - user_system
            - group
            - sample_message_user
            - sample_message_ai
          description: |-
            消息发送者的角色system: 设定模型的角色和行为
            user: 用户的输入
            assistant: 模型的历史回复
            user_system: 设定用户的角色和人设
            group: 对话的名称
            sample_message_user: 示例的用户输入
            sample_message_ai: 示例的模型输出
        content:
          oneOf:
            - type: string
            - type: array
              description: 多模态消息内容块。MiniMax-M3 支持文本、图片和视频输入。
              items:
                type: object
                required:
                  - type
                description: 多模态消息内容块。每个内容块通过 `type` 声明类型，仅填写与该类型匹配的字段。
                properties:
                  type:
                    type: string
                    enum:
                      - text
                      - image_url
                      - video_url
                    description: |-
                      内容块类型：
                      - `text`：文本块
                      - `image_url`：图片输入
                      - `video_url`：视频输入
                  text:
                    type: string
                    description: 文本内容（当 `type` 为 `text` 时）。
                  image_url:
                    type: object
                    description: >-
                      图片输入（当 `type` 为 `image_url` 时）。单张图片最大 10 MB。支持
                      JPEG、PNG、GIF、WEBP 格式。
                    required:
                      - url
                    properties:
                      url:
                        type: string
                        description: 图片 URL 或 Base64 data URL。
                      detail:
                        type: string
                        enum:
                          - low
                          - default
                          - high
                        default: default
                        description: 控制图片解析分辨率，默认值为 default。
                  video_url:
                    type: object
                    description: 视频输入（当 `type` 为 `video_url` 时）。支持 MP4、AVI、MOV、MKV 格式。
                    required:
                      - url
                    properties:
                      url:
                        type: string
                        description: >-
                          视频 URL、Base64 data URL，或形如 `mm_file://{file_id}` 的
                          Files API 引用。URL 或 Base64 视频最大 50 MB；Files API 视频最大
                          512 MB。
                      detail:
                        type: string
                        enum:
                          - low
                          - default
                          - high
                        default: default
                        description: 控制视频抽帧分辨率，默认值为 default。
                      fps:
                        type: number
                        minimum: 0.2
                        maximum: 5
                        default: 1
                        description: >-
                          视频抽帧频率。默认值为 1，范围 [0.2, 5]。取值越高对画面变化越敏感，token 花费高；取值越低
                          token 花费少，但对画面变化迟钝。
          description: 发送者的名称。若同一类型的角色有多个，须提供具体名称以区分
    ErrorObject:
      type: object
      required:
        - message
        - type
        - param
        - code
      properties:
        message:
          type: string
        type:
          type: string
        param:
          type: string
        code:
          type: string
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Token
      description: '在请求头中传入 `Authorization: Bearer <token>`。'

````