hermes - ✅(Solved) Fix Doctor health check incorrectly uses /models endpoint for MiniMax-CN, which returns 404 [1 pull requests, 2 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
NousResearch/hermes-agent#13757Fetched 2026-04-22 08:04:20
View on GitHub
Comments
2
Participants
2
Timeline
6
Reactions
0
Author
Timeline (top)
labeled ×3commented ×2cross-referenced ×1

PR fix notes

PR #13780: fix(doctor): skip /models health check for MiniMax-CN (Closes #13757)

Description (problem / solution / changelog)

Summary

MiniMax-CN (api.minimaxi.com) does not have a /v1/models endpoint — it returns HTTP 404. The health check was incorrectly configured with a URL and _supports_health_check=True, causing a spurious failure.

Follow the same pattern as OpenCode Go: set url=None and _supports_health_check=False so hermes doctor prints (key configured) without probing a non-existent endpoint.

Changes

  • hermes_cli/doctor.py: MiniMax-CN entry changed from (url, True) to (None, False)

Testing

curl -s -o /dev/null -w "%{http_code}" "https://api.minimaxi.com/v1/models" → 404 curl -s -X POST "https://api.minimaxi.com/v1/chat/completions" ... → 200

Closes #13757

Changed files

  • hermes_cli/doctor.py (modified, +2/-1)

Code Example

# /v1/models — does not exist
$ curl -s -o /dev/null -w "%{http_code}" "https://api.minimaxi.com/v1/models"
404

# /v1/chat/completions — works fine
$ curl -s -X POST "https://api.minimaxi.com/v1/chat/completions"   -H "Authorization: Bearer $MINIMAX_CN_API_KEY"   -H "Content-Type: application/json"   -d '{"model": "MiniMax-M2.7", "messages": [{"role": "user", "content": "hi"}], "max_tokens": 5}'
{"id":"...","object":"chat.completion",...}  # 200 OK

---

("MiniMax (China)",  ("MINIMAX_CN_API_KEY",),
 "https://api.minimaxi.com/v1/models",  "MINIMAX_CN_BASE_URL", True),
RAW_BUFFERClick to expand / collapse

Bug Description

The hermes doctor command uses https://api.minimaxi.com/v1/models to health-check the MiniMax (China) provider. This endpoint does not exist and returns HTTP 404.

However, the actual MiniMax /v1/chat/completions API works perfectly fine.

What I tested

# /v1/models — does not exist
$ curl -s -o /dev/null -w "%{http_code}" "https://api.minimaxi.com/v1/models"
404

# /v1/chat/completions — works fine
$ curl -s -X POST "https://api.minimaxi.com/v1/chat/completions"   -H "Authorization: Bearer $MINIMAX_CN_API_KEY"   -H "Content-Type: application/json"   -d '{"model": "MiniMax-M2.7", "messages": [{"role": "user", "content": "hi"}], "max_tokens": 5}'
{"id":"...","object":"chat.completion",...}  # 200 OK

The problematic code

In hermes_cli/doctor.py lines 831-832:

("MiniMax (China)",  ("MINIMAX_CN_API_KEY",),
 "https://api.minimaxi.com/v1/models",  "MINIMAX_CN_BASE_URL", True),

The code comment at line 830 says:

"MiniMax: the /anthropic endpoint doesn't support /models, but the /v1 endpoint does."

This is incorrect for MiniMax-CN (api.minimaxi.com). The /v1/models endpoint does not exist there. The comment was likely written for MiniMax Global (api.minimax.io) and incorrectly applied to both.

Suggested fix

MiniMax-CN does not have a /models endpoint. The health check should either:

  1. Use a direct chat completion test (POST to /v1/chat/completions with a minimal request), or
  2. Set _supports_health_check = False for MiniMax (China) to skip the check, similar to OpenCode Go

Environment

  • Hermes version: (latest, git clone)
  • Python: 3.11.15
  • Platform: macOS
  • Provider: MiniMax-CN (api.minimaxi.com)

extent analysis

TL;DR

Update the hermes_cli/doctor.py file to either use a direct chat completion test for MiniMax-CN or set _supports_health_check = False to skip the health check.

Guidance

  • Identify the incorrect endpoint used for the MiniMax-CN health check in hermes_cli/doctor.py and consider replacing it with a working endpoint, such as /v1/chat/completions.
  • Verify the health check functionality by running the hermes doctor command after applying the suggested fix.
  • If the direct chat completion test approach is chosen, ensure to use a minimal request to avoid unnecessary resource usage.
  • Consider adding a comment or documentation to distinguish the health check behavior between MiniMax Global and MiniMax-CN providers.

Example

# Example of using a direct chat completion test for MiniMax-CN
("MiniMax (China)",  ("MINIMAX_CN_API_KEY",),
 "https://api.minimaxi.com/v1/chat/completions",  "MINIMAX_CN_BASE_URL", True),

Note: This example assumes a POST request with a minimal payload, such as {"model": "MiniMax-M2.7", "messages": [{"role": "user", "content": "hi"}], "max_tokens": 5}.

Notes

The suggested fix may require additional modifications to handle the response from the new endpoint or to implement the _supports_health_check = False approach.

Recommendation

Apply the workaround by updating the hermes_cli/doctor.py file to use a direct chat completion test for MiniMax-CN, as this approach allows for a more comprehensive health check compared to skipping the check altogether.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

hermes - ✅(Solved) Fix Doctor health check incorrectly uses /models endpoint for MiniMax-CN, which returns 404 [1 pull requests, 2 comments, 2 participants]