Skip to content

feat(providers): Add Moonshot AI provider#225

Merged
edenreich merged 13 commits intomainfrom
claude/issue-224-20251217-1715
Jan 22, 2026
Merged

feat(providers): Add Moonshot AI provider#225
edenreich merged 13 commits intomainfrom
claude/issue-224-20251217-1715

Conversation

@edenreich
Copy link
Copy Markdown
Contributor

@edenreich edenreich commented Dec 17, 2025

Summary

Moonshot AI provider has been successfully added to the inference gateway.

Changes

  • Added moonshot to Provider enum in OpenAPI spec
  • Configured Moonshot with base URL https://api.moonshot.ai/v1
  • Generated provider types and registry entries
  • Updated REST-API examples with Moonshot endpoints
  • Documented MOONSHOT_API_URL and MOONSHOT_API_KEY env vars
  • Support bearer token authentication

Testing

To test this integration:

export MOONSHOT_API_KEY="your-api-key"
curl -X POST http://localhost:8080/v1/chat/completions -d '{"model":"moonshot/moonshot-v1-8k","messages":[{"role":"user","content":"Hi"}]}'

Closes #224

🤖 Generated with Claude Code

- Add moonshot to Provider enum in OpenAPI spec
- Configure Moonshot with base URL https://api.moonshot.cn/v1
- Generate provider types and registry entries
- Update REST-API examples with Moonshot endpoints
- Document MOONSHOT_API_URL and MOONSHOT_API_KEY env vars
- Support bearer token authentication

Co-authored-by: Eden Reich <edenreich@users.noreply.github.com>
@edenreich
Copy link
Copy Markdown
Contributor Author

@claude Please fix the CI.

@claude
Copy link
Copy Markdown
Contributor

claude bot commented Dec 17, 2025

Claude finished @edenreich's task in 3m 17s —— View job


CI Fixes Complete! ✅

I've successfully identified and fixed the CI failures for this PR.

Todo List

  • Check CI status and identify failing jobs
  • Analyze failure logs
  • Fix identified issues
  • Commit and push fixes
  • Verify fixes

Analysis

The CI was failing because the config tests expected a specific set of providers. The new Moonshot provider needed to be added to three test cases in config/config_test.go:

  1. Success_Defaults - expects all providers with default configuration ✅
  2. Success_AllEnvVariablesSet - expects all providers with some custom env vars ✅
  3. PartialEnvVariables - expects all providers with partial env vars ✅

Moonshot Provider Configuration

  • ID: moonshot
  • Base URL: https://api.moonshot.cn/v1
  • Auth Type: Bearer token
  • Supports Vision: false
  • Models endpoint: /models
  • Chat endpoint: /chat/completions

Changes Made

  • ✅ Added Moonshot provider configuration to all three test cases in config/config_test.go
  • ✅ Committed changes to the branch

The tests should now pass. The CI will automatically run on the new commit to verify the fix.

--- |

claude bot and others added 2 commits December 17, 2025 19:55
Updated the three config test cases to include the Moonshot provider
configuration to match the new provider added to the system.

Co-authored-by: Eden Reich <edenreich@users.noreply.github.com>
@edenreich edenreich changed the title feat(providers): Add Moonshot AI as a provider feat(providers): Add Moonshot AI provider Jan 7, 2026
@edenreich edenreich merged commit 43e5816 into main Jan 22, 2026
1 check passed
@edenreich edenreich deleted the claude/issue-224-20251217-1715 branch January 22, 2026 21:10
ig-semantic-release-bot bot added a commit that referenced this pull request Jan 22, 2026
## [0.23.0](v0.22.10...v0.23.0) (2026-01-22)

### ✨ Features

* **providers:** Add Moonshot AI provider ([#225](#225)) ([43e5816](43e5816))

### 🔧 Miscellaneous

* **deps:** Bump hono in /examples/docker-compose/mcp/pizza-server ([#228](#228)) ([16200aa](16200aa))
@ig-semantic-release-bot
Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.23.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Add Moonshot AI as a provider

1 participant