Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

feat(quota): show remaining percentage with decimals (also ask: can the API return decimals?)

未关闭
#249 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
55/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
活跃
技术栈
typescript
领域
api, cli

调研方向

从 mmx quota 命令开始,追踪 GET /v1/token_plan/remains 返回的 current_weekly_remaining_percent 和 current_interval_remaining_percent 是如何格式化的。确认当前输出,并添加至少两位小数的覆盖;由于此仓库不负责该端点,API 精度请求必须转交给服务所有者或支持渠道。

由索引模型根据 Issue 内容生成。

描述

Summary

The Token Plan quota endpoint returns current_weekly_remaining_percent and current_interval_remaining_percent as integers, which loses a lot of useful precision at the low end (e.g. 2.8% left is rendered as 3%). I'd like:

  1. The API to return decimals (ideally with several fractional digits).
  2. The CLI (mmx quota) to render at least 2 decimal places, regardless of (1).

API

Endpoint:

GET https://www.minimax.io/v1/token_plan/remains
Authorization: Bearer ${MINIMAX_API_KEY}
Content-Type: application/json

Today:

{
  "current_weekly_remaining_percent": 97,
  "current_interval_remaining_percent": 85
}

What I'd like to see (any of these would be a strict improvement):

{
  "current_weekly_remaining_percent": 97.85,
  "current_interval_remaining_percent": 85.31
}

…or, ideally, full precision:

{
  "current_weekly_remaining_percent": 97.8532,
  "current_interval_remaining_percent": 85.3117385248
}
Note: this repo doesn't own the API

I know MiniMax-AI/cli is the CLI, not the API service. If a maintainer can either:

  • forward this request to whoever owns /v1/token_plan/remains, or
  • point me at the right repo / contact / support channel for API changes,

…I'd really appreciate it. If the answer is "file it at ", I'll happily move the conversation there.

CLI

Even before (1) lands, the CLI can stop rounding. Today:

╭──────────────────────────────────────────────────────────────────────────────╮
│ MINIMAX  TokenPlan Quota                       Week: 2026-08-31 — 2026-09-07 │
├────────────────────────────────────────────────────────────┬─────────────────┤
│ general  Left             85%   Wk left             97%    │ 5h Reset 36m    │
├────────────────────────────────────────────────────────────┼─────────────────┤
│ video    Left            3 / 3  Wk left            21 / 21 │ 1d Reset 4h 36m │
╰────────────────────────────────────────────────────────────┴─────────────────╯

Expected:

╭──────────────────────────────────────────────────────────────────────────────╮
│ MINIMAX  TokenPlan Quota                       Week: 2026-08-31 — 2026-09-07 │
├────────────────────────────────────────────────────────────┬─────────────────┤
│ general  Left            85.58% Wk left            97.01%  │  5h Reset 36m   │
├────────────────────────────────────────────────────────────┼─────────────────┤
│ video    Left            3 / 3  Wk left            21 / 21 │ 1d Reset 4h 36m │
╰────────────────────────────────────────────────────────────┴─────────────────╯

A --no-color / --no-decimals flag for users who prefer the old look would be a nice extra, but the default should change.

Thanks! 🙏

主要语言
TypeScript
星标
2.2k
派生
185
平均合并
6 小时 46 分钟
30 天内合并 PR
7

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

MiniMax-AI/cli 的其他 Issue

查看 MiniMax-AI/cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。