StarMagicStarMagic
English
简体中文简繁體中文繁EnglishEN日本語日EspañolES한국어KO
Integration Guide
MiniMax-M2.5 - 完整参数文档
StarMagicStarMagic
English
简体中文简繁體中文繁EnglishEN日本語日EspañolES한국어KO
TextMiniMaxMinimax.M2.5

MiniMax-M2.5 - Complete API Reference

  • Use OpenAI SDK format to call MiniMax-M2.5 model
  • Synchronous processing mode, real-time response
  • Text conversation: Single or multi-turn contextual dialogue
  • System prompts: Customize AI role and behavior
<Note> **BaseURL**: The default BaseURL is `https://api.starmagic.ai`, which has better support for text models and long-lived connections. `https://api.starmagic.ai` is the primary endpoint for multimodal services and serves as a fallback address for text models. </Note>

Authorization

AuthorizationstringheaderRequired

##All APIs require Bearer Token authentication## **Get API Key:** Visit [API Key Management Page](https://starmagic.ai/app/api-keys) to get your API Key **Add to request header:** ``` Authorization: Bearer YOUR_API_KEY ```

Authorization: Bearer YOUR_API_KEY

Request body

application/json
modelenum<MiniMax-M2.5>Required

Chat model name

"MiniMax-M2.5"
messagesobject[]Required

List of conversation messages, supports multi-turn dialogue

[
  {
    "role": "user",
    "content": "Please introduce yourself"
  }
]
max_tokensinteger

Maximum number of tokens for generated content, upper limit is 2048 **Note**: - Content exceeding the limit will be truncated - If generation is interrupted due to `length`, try increasing this value

2048
streamboolean

Whether to return the response in streaming mode - `true`: Stream response, return content in real-time chunks - `false`: Wait for complete response before returning

false
temperaturenumber

Sampling temperature, controls output randomness **Note**: - Lower values (e.g. 0.1): More deterministic, focused output - Higher values (e.g. 0.9): More random, creative output - Range: (0, 1], excluding 0

0.7
top_pnumber

Nucleus Sampling parameter **Note**: - Controls sampling from tokens with cumulative probability - e.g. 0.9 means selecting from tokens reaching 90% cumulative probability - Range: (0, 1], excluding 0 **Recommendation**: Do not adjust temperature and top_p simultaneously

0.9
enable_searchboolean

Whether to enable web search - `true`: Enable web search, the model will search the internet for latest information as needed - `false`: Disable web search

true
search_optionsobject

Web search options, requires `enable_search: true`

{
  "search_strategy": "max"
}

Response

application/json
成功

Response body

idstring

Unique identifier for the chat completion

"cmpl-04ea926191a14749b7f2c7a48a68abc6"
modelstring

Model name actually used

"MiniMax-M2.5"
objectenum<chat.completion>

Response type

"chat.completion"
createdinteger

Creation timestamp

1698999496
choicesobject[]

List of chat completion choices

[
  {
    "index": 0,
    "message": {
      "role": "assistant",
      "content": "Hi there! How can I help you?"
    },
    "finish_reason": "stop"
  }
]
usageobject

Token usage statistics

{
  "prompt_tokens": 8,
  "completion_tokens": 292,
  "total_tokens": 300
}
POST/v1/chat/completions
curl --request POST \
  --url https://api.starmagic.ai/v1/chat/completions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "model": "MiniMax-M2.5",
  "messages": [
    {
      "role": "user",
      "content": "Please introduce yourself"
    }
  ]
}'
Response: 成功
{
  "id": "cmpl-04ea926191a14749b7f2c7a48a68abc6",
  "model": "MiniMax-M2.5",
  "object": "chat.completion",
  "created": 1698999496,
  "choices": [
    {
      "index": 0,
      "message": {
        "role": null,
        "content": null
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 8,
    "completion_tokens": 292,
    "total_tokens": 300
  }
}

GPT-5.5 - 完整参数文档

Previous Page

MiniMax-M3 - OpenAI-Compatible API

Next Page