bigquery
Installation
SKILL.md
BigQuery
Invoice SKUs first. Bytes scanned, slot-ms, and table storage are not on the bill. Teach slots vs on-demand, open [BigQuery] BigQuery Dashboard, then allocate or optimize.
Not this if: GCP spend CUD leftover → recipes → gcp-spend-cud. Generic Explorer → query. Whole-bill "what changed" → recipes → explain-period-change.
Workflow
get_context— currency; notebq_*/user_emailif already ingested- Several organizations: if
get_contextreturns "Multiple organizations" with a list of slugs, do not pick one. Ask the user which org to use (from that list orlist_organizations), then pass thatslugtoget_contextand the following tool calls. If the user already named the org (e.g. "orgacme"), use that slug directly.
- Several organizations: if
search{ type: ["dashboards"], query: "BigQuery" }— use the template [BigQuery] BigQuery Dashboard. Org copies can differ. Never hardcode an id.getthat template for the URL. Do not walk widgets.- Teach Slots vs on-demand (two sentences): On-demand = pay per TiB scanned. Slots = pay for a pool; unused slots still cost, and bytes no longer price the job. Then the SKU table, then the caveat that matches the ask.
- Read the dashboard (order below). Branch: leftover Analysis → assignment / load jobs; storage →
TABLE_STORAGE; showback → Allocate; no labels → Jobs metadata. - Costory
queryonly after the dashboard. Persist viaquery/dashboards/virtual-dimensions. Nocreate_dashboardunless they ask to clone.
Slots vs on-demand
A slot is a unit of BigQuery compute. total_slot_ms in JOBS is how hard the query worked — it is not the invoice line unless you buy slots.