Connect AI vendors

Licence fees are entered by hand under Settings → AI tools. Metered usage, what the vendors bill you for API calls and Claude Code, can be read automatically every night. Connect a vendor once and the AI impact page shows usage on top of the licences.

settings-02-ai-tools

Keys go into a secret store and are never shown again; the page shows only a masked hint and the last sync. Vendor spend is part of the Enterprise plan.

Anthropic (Claude)

Reads API spend per workspace, plus Claude Code use per person (sessions, lines, commits, pull requests).

  1. In the Claude Console, open Settings → Admin keys and create an admin key. It starts with sk-ant-admin.
  2. In Agile Analytics, go to Settings → AI tools → Spend from your AI vendors, choose Anthropic and paste the key. Press Connect; Agile Analytics checks the key right away.
  3. Tick the workspaces to count: only the ones used for coding. Spend elsewhere, such as a product that calls the API, is left out of the AI cost.

Seat fees for Claude Pro, Team and Max are not in this API: keep those as licences.

OpenAI

Reads API spend per project.

  1. In the OpenAI platform, open Organization → Admin keys and create an admin key. It starts with sk-admin-.
  2. Paste it under Anthropic's neighbour, OpenAI, and press Connect.
  3. Tick the projects to count.

ChatGPT and Codex seats are not in this API: keep them as licences.

Google (Gemini)

A Gemini API key cannot read what was spent, so Agile Analytics reads your Cloud Billing export instead: Gemini API, Vertex AI and Gemini Code Assist.

  1. In the Google Cloud console, open Billing → Billing export and enable the standard usage cost export to BigQuery, if not done yet.
  2. Give Agile Analytics' service account (copy it from the page with Copy the service account) the BigQuery Data Viewer role on the export dataset, and BigQuery Job User on the project.
  3. Paste the full table name, project.dataset.gcp_billing_export_v1_…, and press Connect.
  4. Tick the services to count.

After connecting

Each vendor card shows its status (connected, needs attention, not connected), who connected it and when, the last sync and the spend of the last 90 days per scope. Sync now runs the nightly read at once. Spend is stored in the vendor's currency and converted with the European Central Bank rate of the day; the AI impact page says so when a day is still waiting for its rate.

Disconnect destroys the key and stops the sync; tick Also delete the spend we synced to remove the data too. Revoke the key at the vendor as well if nothing else uses it.