From efdec392541bf14a05b1a970c7360d1249f7b712 Mon Sep 17 00:00:00 2001 From: Thorfinn <136994453+miloudbelarebia@users.noreply.github.com> Date: Sat, 21 Feb 2026 18:26:48 +0100 Subject: [PATCH] fix: correct MiniMax M2.5 pricing (was ~50x too high) (openclaw#22755) thanks @miloudbelarebia Verified: - pnpm build - pnpm check - pnpm test:macmini Co-authored-by: miloudbelarebia <136994453+miloudbelarebia@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com> --- CHANGELOG.md | 1 + src/agents/models-config.providers.ts | 10 +++++----- src/commands/onboard-auth.models.ts | 10 +++++----- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a1983ad17a3..97a01ac572a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -46,6 +46,7 @@ Docs: https://docs.openclaw.ai - Providers/Copilot: add `claude-sonnet-4.6` and `claude-sonnet-4.5` to the default GitHub Copilot model catalog and add coverage for model-list/definition helpers. (#20270, fixes #20091) Thanks @Clawborn. - Auto-reply/WebChat: avoid defaulting inbound runtime channel labels to unrelated providers (for example `whatsapp`) for webchat sessions so channel-specific formatting guidance stays accurate. (#21534) Thanks @lbo728. - Status: include persisted `cacheRead`/`cacheWrite` in session summaries so compact `/status` output consistently shows cache hit percentages from real session data. +- Models/MiniMax: correct default M2.5 API pricing for input/output/cache token costs in onboarding and provider config defaults, fixing inflated usage cost reporting. (#21792) - Heartbeat/Cron: restore interval heartbeat behavior so missing `HEARTBEAT.md` no longer suppresses runs (only effectively empty files skip), preserving prompt-driven and tagged-cron execution paths. - WhatsApp/Cron/Heartbeat: enforce allowlisted routing for implicit scheduled/system delivery by merging pairing-store + configured `allowFrom` recipients, selecting authorized recipients when last-route context points to a non-allowlisted chat, and preventing heartbeat fan-out to recent unauthorized chats. - Heartbeat/Active hours: constrain active-hours `24` sentinel parsing to `24:00` in time validation so invalid values like `24:30` are rejected early. (#21410) thanks @adhitShet. diff --git a/src/agents/models-config.providers.ts b/src/agents/models-config.providers.ts index b272921c9bd..92787f60556 100644 --- a/src/agents/models-config.providers.ts +++ b/src/agents/models-config.providers.ts @@ -53,12 +53,12 @@ const MINIMAX_DEFAULT_VISION_MODEL_ID = "MiniMax-VL-01"; const MINIMAX_DEFAULT_CONTEXT_WINDOW = 200000; const MINIMAX_DEFAULT_MAX_TOKENS = 8192; const MINIMAX_OAUTH_PLACEHOLDER = "minimax-oauth"; -// Pricing: MiniMax doesn't publish public rates. Override in models.json for accurate costs. +// Pricing per 1M tokens (USD) — https://platform.minimaxi.com/document/Price const MINIMAX_API_COST = { - input: 15, - output: 60, - cacheRead: 2, - cacheWrite: 10, + input: 0.3, + output: 1.2, + cacheRead: 0.03, + cacheWrite: 0.12, }; type ProviderModelConfig = NonNullable[number]; diff --git a/src/commands/onboard-auth.models.ts b/src/commands/onboard-auth.models.ts index 30d418892e7..2087827fcf9 100644 --- a/src/commands/onboard-auth.models.ts +++ b/src/commands/onboard-auth.models.ts @@ -42,12 +42,12 @@ export function resolveZaiBaseUrl(endpoint?: string): string { } } -// Pricing: MiniMax doesn't publish public rates. Override in models.json for accurate costs. +// Pricing per 1M tokens (USD) — https://platform.minimaxi.com/document/Price export const MINIMAX_API_COST = { - input: 15, - output: 60, - cacheRead: 2, - cacheWrite: 10, + input: 0.3, + output: 1.2, + cacheRead: 0.03, + cacheWrite: 0.12, }; export const MINIMAX_HOSTED_COST = { input: 0,