Skip to main content

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 mirrors the Antigravity CLI's own backend calls:

  1. loadCodeAssist with {"metadata":{"ideType":"ANTIGRAVITY"}}
  2. retrieveUserQuotaSummary using the returned cloudaicompanionProject

Expired Antigravity OAuth access tokens are refreshed with the stored refresh token and the same Google OAuth client metadata used by the CLI, then written back to antigravity-oauth-token.

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_ACCESS_TOKEN: provide an access token instead of reading Antigravity state
  • AGY_CODE_ASSIST_BASE_URL: alternate Code Assist base URL

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.8.tar.gz (11.2 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.8-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: agy_usage-0.1.8.tar.gz
  • Upload date:
  • Size: 11.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","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.8.tar.gz
Algorithm Hash digest
SHA256 c27ba5ab5b13d7f52fd9d91af5532a9ffec5f86655bc8b4341f30d378af96c07
MD5 af281a1da88d300e5d1a87416a17b26f
BLAKE2b-256 93bd00e02f6b0835646c08bf413a8a9a58215305962e0d30f38c91c67bb17246

See more details on using hashes here.

File details

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

File metadata

  • Download URL: agy_usage-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","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.8-py3-none-any.whl
Algorithm Hash digest
SHA256 3e0d7623da77b00ebe3995a38734d2d7fb48ce9c96dec092a40aecefabbcedf9
MD5 b8162c4332ca3d0c05bcab8180f3bdbc
BLAKE2b-256 fc4a5545afb4519db53cf1a3d814e7463f6b95cc000feaf88e1ddf88140bc954

See more details on using hashes here.

Release history Release notifications | RSS feed

0.1.9

2 files

This release

0.1.8 This release

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page