Skip to content

fix(minimax): align request body with selected transport#2705

Open
rixzkiye wants to merge 1 commit into
decolua:masterfrom
rixzkiye:fix/minimax-transport-protocol
Open

fix(minimax): align request body with selected transport#2705
rixzkiye wants to merge 1 commit into
decolua:masterfrom
rixzkiye:fix/minimax-transport-protocol

Conversation

@rixzkiye

@rixzkiye rixzkiye commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Summary

  • select multi-endpoint provider transport from model-preferred target format when present
  • keep translated request body, endpoint, and authentication protocol aligned
  • avoid injecting OpenAI-only reasoning_content into Anthropic Messages requests
  • add MiniMax global/China, M2.7/M3, and reasoning-injection regression coverage

Problem

MiniMax-M3 declares Claude as its target format. For OpenAI-format clients, transport selection previously used client source format while translation used model target format. This could send an Anthropic-shaped body and tool schema to MiniMax Chat Completions, causing 400 invalid tool type responses.

Verification

  • cd tests && npx vitest run unit/minimax-transport-protocol.test.js unit/reasoningContentInjector.test.js unit/openai-to-claude-tools-no-type.test.js — 22 tests passed
  • npx eslint open-sse/executors/default.js open-sse/handlers/chatCore.js open-sse/services/provider.js tests/unit/minimax-transport-protocol.test.js
  • git diff --check origin/master...HEAD
  • production Next.js build passed during implementation verification

No live MiniMax credentials were used; protocol behavior is covered with focused unit tests.

Related issues

Fixes #1939
Fixes #2435
Fixes #2509

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

I cant use minimax/MiniMax-M3 invalid tool type [ERROR] [400] when using minimax token plan

1 participant