Skip to main content

Antigravity CLI usage and quota monitor

Project description

agy-usage

Antigravity CLI usage and quota monitor. It mirrors the small ccusage, gemini-cli-usage, and codex-cli-usage tools: dependency-free Python, terminal output, JSON output, statusline output, and a cache-refresh daemon.

Example output

Project: agy-usage
Model: Gemini 3.5 Flash (High)

GEMINI MODELS
  Models within this group: Gemini Flash, Gemini Pro
  Weekly Limit    95.0% remaining  resets 6d19h
  Five Hour Limit 62.5% remaining  resets 7m

CLAUDE AND GPT MODELS
  Models within this group: Claude Opus, Claude Sonnet, GPT-OSS
  Weekly Limit    100.0% remaining  quota available
  Five Hour Limit 100.0% remaining  quota available
History: 24 entries, latest 2026-06-29T22:53:01+00:00

Statusline:

q:62.5%left reset:7m model:Gemini_3.5_Flash_(High)

Install

uv tool install agy-usage

For local development from a checkout:

uv tool install .

Commands

Command Description
agy-usage Show current usage
agy-usage status Same as above
agy-usage json Print raw JSON
agy-usage statusline Compact statusline output
agy-usage refresh Force a fresh fetch, rewrite cache, and print status
agy-usage daemon [-i SECS] Keep the cache fresh in the foreground
agy-usage install Print setup instructions

Data sources

  • Antigravity settings: ~/.gemini/antigravity-cli/settings.json
  • Antigravity OAuth token: ~/.gemini/antigravity-cli/antigravity-oauth-token
  • Antigravity command history: ~/.gemini/antigravity-cli/history.jsonl
  • Cache written by this tool: ~/.gemini/antigravity-cli/usage-limits.json

Quota lookup first uses the local Antigravity CLI language-server RPC, which is the source behind agy's grouped "Models & Quota" display. Keep an agy session running for the closest match, or set AGY_RPC_URL to a known local RPC base URL.

If the local RPC is unavailable, agy-usage falls back to the raw Code Assist quota flow Antigravity logs mention: loadCodeAssist followed by retrieveUserQuota.

Options

usage: agy-usage [-h] [--root ROOT] [-i INTERVAL] [--max-age MAX_AGE]
                 [--refresh]
                 {status,json,daemon,statusline,refresh,install}
  • --root ROOT: inspect a different project root instead of the current directory
  • --max-age MAX_AGE: cache TTL for statusline
  • --refresh: ignore the cache and rebuild fresh data where applicable

Environment overrides:

  • AGY_USAGE_FILE: alternate cache path
  • AGY_RPC_URL: local Antigravity RPC base URL, for example http://127.0.0.1:42683
  • AGY_ACCESS_TOKEN: provide an access token instead of reading Antigravity state
  • AGY_CODE_ASSIST_BASE_URL: alternate Code Assist base URL

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agy_usage-0.1.1.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agy_usage-0.1.1-py3-none-any.whl (8.9 kB view details)

Uploaded Python 3

File details

Details for the file agy_usage-0.1.1.tar.gz.

File metadata

  • Download URL: agy_usage-0.1.1.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for agy_usage-0.1.1.tar.gz
Algorithm Hash digest
SHA256 36186eecf63bf73716c0d43487b1f563a7b57f6e064ede3894dae14c94ef88c1
MD5 ba436ef400d67f88a6adbe1c5d3a5e7f
BLAKE2b-256 ba7d263d5edce72da26a7f4ae893a38cf8bb19130b9c3092e4018b3978a88bc1

See more details on using hashes here.

File details

Details for the file agy_usage-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: agy_usage-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 8.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for agy_usage-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0c1a8ef312ecc518056d5c9f91aefaba75ae052baf185d7de0269af576f99b3b
MD5 21a7e3177278bdc7363ae3cf66302ce5
BLAKE2b-256 623325250d26d2092d2dd8452bbff3892570547aaf1c1a0c681cf1f7143b17cf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page