AgentKit
Tài liệuBộ kitTham chiếu CLIỨng dụng Desktop

usage

ak usage

Xem mức dùng token cục bộ và giới hạn sử dụng theo provider.

Xem mức dùng token cục bộ và giới hạn sử dụng theo provider.

Dùng ak usage với đối số và tùy chọn dưới đây. Phần help nguyên bản giữ nguyên thuật ngữ, cú pháp, tác động và điều kiện thực thi của CLI để đối chiếu chính xác.

Dùng ak usage summary để xem tổng token của ngày, tuần hoặc tháng UTC hiện tại, và ak usage limits để xem giới hạn theo cửa sổ trượt của từng provider.

Contract và help của lệnh

Inspect local token usage and per-provider usage limits

Synopsis

Reports rolling-window token usage per coding-agent provider from the local analytics fact store, overlaid with the provider's own quota percentages. Provider polling is on by default and reuses the sign-in each official CLI already stored. To stay local-only, turn it off in the dashboard settings, or set usage_limits.advanced.enabled: false together with usage_limits.opted_out_at (an RFC 3339 time) when editing the config by hand (a false with neither opted_out_at nor ack_last_at is the legacy default and stays on), or set AGENTKIT_USAGE_LIMITS_LOCAL_ONLY=1 for one process. Use limits to inspect trailing 5-hour and week windows per provider (claude, codex, cursor, grok); both windows are always returned in one call.

Examples

  ak usage limits
  ak usage limits --provider claude --json
  ak usage limits --window week --provider codex

Options

  -h, --help             help for usage
      --json             Emit machine-readable JSON (implies --no-interactive)
      --no-interactive   Disable interactive prompts (CI-safe)
  -q, --quiet            Suppress non-error output on stderr
  -V, --verbose          Extra diagnostic output on stderr (loses to --quiet)
  -y, --yes              Assume yes for all prompts

SEE ALSO