Google Cloud Vertex AI

Download 0
Last updated Feb 20, 2026

vertex-ai-usage

Query Vertex AI token usage from GCP Cloud Monitoring.

vertex-ai-usage [profile=NAME] [from=DATETIME] [to=DATETIME] [duration=PERIOD] [span=SPAN]
profile=NAME
Optional. GCP Vertex AI connect profile name
from=DATETIME
Optional. Start time (yyyyMMddHHmmss)
to=DATETIME
Optional. End time (yyyyMMddHHmmss)
duration=PERIOD
Optional. Relative duration (e.g. 7d, 30d)
span=SPAN
Optional. Alignment period (e.g. 10s, 1m, 5m, 10m, 1h, 1d). Auto-selected based on query range if omitted.

Output Fields

FieldTypeNameDescription
_timeDateTimeInterval start time (alias of start_time)
profileStringProfileConnect profile name
project_idStringProject IDGCP project ID
locationStringLocationGCP region (e.g. global, us-central1)
publisherStringPublisherModel publisher (e.g. google)
modelStringModelModel ID (e.g. gemini-2.0-flash-exp, imagen-3.0-generate-002)
token_typeStringToken TypeToken type (e.g. input, output)
countLongCountToken count
request_typeStringRequest TypeRequest type (e.g. shared)
durationLongDuration (s)Interval duration in seconds
start_timeDateStart TimeInterval start time
end_timeDateEnd TimeInterval end time