Skip to content

Connect Cost Sources: AI APIs, Datadog, Snowflake, Databricks, Cloudflare, MongoDB Atlas, Confluent and Cursor

Cost sources bring spend that never appears on a cloud bill into Xplorr. Once connected, a source shows up in every cost view, budget and anomaly check, next to your cloud accounts.

Connector Category What it brings in
OpenAI AI APIs Model spend with tokens and requests per project and model
Anthropic AI APIs Model spend with tokens per workspace and model
Datadog Observability Monitoring and logging spend per product
Snowflake Data platforms Warehouse spend per account, region and service
Databricks Data platforms Lakehouse spend per workspace and SKU
MongoDB Atlas Data platforms Database spend per SKU, project and cluster
Confluent Cloud Data platforms Streaming spend per product and cluster
Cloudflare Edge and network Usage spend per product and zone
Cursor Developer platforms AI coding usage spend per model and person

Every connector is read only and needs an admin or billing credential from the provider. Nothing is fetched until you connect one.

These connectors need the Growth or Enterprise plan, and each one counts as a connected account against your plan limit. GitHub, which has its own guide, can be connected on every plan.

Open Cost Sources in the console. Adding, editing and removing sources requires the admin role.

  1. Pick a connector and click Connect.
  2. Give the source a display name and fill in the credentials.
  3. Click Test connection. Xplorr calls the provider immediately and tells you whether the credentials work.
  4. Save. Credentials are tested again before they are stored, so a bad credential never gets saved.

Credentials are encrypted with AES-256-GCM before storage and are never shown again. When you edit a source, secret fields show a “Stored” placeholder; leave them blank to keep the existing value, or enter a new value to replace it.

After the first save, Xplorr immediately backfills the last 30 days. That can take a few minutes.

What to create: an organization Admin API key. Only organization owners can create one, in Organization settings, Admin keys. Project API keys are rejected by the endpoints Xplorr uses.

Field: Admin API key, beginning sk-admin-.

Admin keys have no scopes. Xplorr only calls read endpoints for organization projects, usage and costs.

Xplorr reads usage for completions, embeddings, moderations, images, audio, vector stores and code interpreter sessions, grouped by project and model, plus the organization cost report. It captures input tokens, output tokens, cached input tokens and request counts.

What to create: an organization Admin API key, in Claude Console, Settings, Admin keys. Only organization members with the admin role can create one, and the Admin API is not available for individual accounts, so the key must belong to an organization. Workspace API keys are rejected.

Field: Admin API key, beginning sk-ant-admin01-.

Xplorr reads the organization usage report grouped by workspace and model, and the cost report. Usage that is not attributed to a workspace is recorded as Default workspace.

What to create: an API key and an Application key, both belonging to the parent organization. Child organization keys are rejected. The application key owner needs the usage_read and billing_read permissions, which the Datadog Admin role grants by default. A scoped key carrying just those two scopes also works. Usage Metering is available on Pro and Enterprise plans.

Fields: Datadog site (defaults to us1), API key, Application key.

Xplorr reads estimated cost and converts the running month to date totals into daily amounts.

Limitation to plan around: Datadog estimated cost only covers the current and previous month. Dates before that are skipped, and Xplorr records a warning saying so. Figures can lag by up to 72 hours, and costs are always recorded in USD.

What to create: a service user with key pair authentication and a role that can read organization billing.

CREATE ROLE xplorr_billing_role;
GRANT DATABASE ROLE SNOWFLAKE.ORGANIZATION_BILLING_VIEWER TO ROLE xplorr_billing_role;
GRANT USAGE ON WAREHOUSE <warehouse> TO ROLE xplorr_billing_role;
GRANT ROLE xplorr_billing_role TO USER <user>;

Run the grants in the organization account, or an account with ORGADMIN enabled, where ACCOUNTADMIN has access by default.

Generate a key pair and set the public key on the user:

Terminal window
openssl genrsa 2048 | openssl pkcs8 -topk8 -inform PEM -out rsa_key.p8 -nocrypt

Then ALTER USER <user> SET RSA_PUBLIC_KEY = '<public key>';

Fields: Account identifier (as MYORG-MYACCOUNT), User, Private key in PKCS#8 PEM, optional Private key passphrase, Warehouse, optional Role, and Data source.

Data source picks which view Xplorr reads:

  • USAGE_IN_CURRENCY_DAILY, the default, with full history
  • FOCUS_COST_USAGE_V1_3, which adds effective (amortized) and list cost but only holds data from 1 January 2026

An X-Small warehouse is enough to run the queries.

What to create: a principal that can read Unity Catalog system tables, and access to a SQL warehouse.

GRANT USE CATALOG ON CATALOG system TO `<principal>`;
GRANT USE SCHEMA ON SCHEMA system.billing TO `<principal>`;
GRANT SELECT ON SCHEMA system.billing TO `<principal>`;

Unity Catalog must be enabled. System tables are readable by account admins who are also metastore admins. Give the principal CAN USE on the SQL warehouse.

Fields: Workspace URL, SQL warehouse ID, and either OAuth M2M (service principal client ID and secret, the default) or a personal access token.

A serverless warehouse avoids start up waits. The billing system tables are global, so any Unity Catalog enabled workspace in the account returns usage for every workspace.

Limitation to plan around: cost is calculated from the published list price. Negotiated discounts are not visible in Databricks system tables, so the figure is list price rather than what you actually pay. Usage rows with no matching list price are stored with zero cost and Xplorr records a warning.

What to create: a service account in the Atlas organization (Organization access manager, Applications, Service accounts) with the Organization Billing Viewer role and nothing else.

Fields: Organization ID (24 characters, in Organization settings), service account client ID and client secret.

Xplorr reads the organization’s closed invoices and the pending invoice for the current billing cycle, and records each line item per day, SKU, project and cluster. The cost is net of any discount on the line; the list price is kept alongside it. A line item that covers several days is spread evenly across them.

Limitation to plan around: Atlas posts charges the day after use, so the most recent day fills in on the next sync.

What to create: a Cloud API key (a resource management key, not a Kafka cluster key) owned by a user or service account with the BillingAdmin or OrganizationAdmin role.

Fields: Cloud API key and secret.

Xplorr reads the Billing API’s daily costs per product (Kafka, Connect, Flink, ksqlDB and others), line type and cluster. The amount after discounts is the cost; the original amount is kept as the list price.

Limitation to plan around: Confluent keeps a year of costs and figures can lag by up to 72 hours. Dates older than a year are skipped with a warning.

What to create: an account API token with Account, Billing, Read and no other permission.

Fields: Account ID (32 characters, on the account home page) and the API token.

Xplorr reads Cloudflare’s Billable Usage API: daily usage cost per product (Workers, R2, Images, Stream and others) and, where Cloudflare reports one, per zone.

Limitations to plan around:

  • The API covers usage based charges on Pay-as-you-go accounts. Fixed plan fees (Pro, Business) are not in it, and Cloudflare does not support Enterprise contracts in it yet.
  • Cloudflare updates the data once a day.

What to create: an Admin API key for the team, created by a team admin in the Cursor dashboard (Team settings, Advanced, Admin API keys). Available on Business and Enterprise plans.

Field: Admin API key.

Xplorr reads the team’s usage events and adds up what each was charged, per day, model and team member, so you can see AI coding spend by person and by model.

Limitation to plan around: the per seat subscription is not reported by Cursor’s API, so the figure is usage spend only.

  • All connectors sync on one daily schedule, at 04:00 UTC by default.
  • The first sync backfills 30 days.
  • Later syncs refetch a short recent window per connector, between 3 and 5 days depending on the provider, so late corrections are picked up.
  • Each sync replaces data only for the dates the provider actually returned, so a re-sync never double counts.

Admins can click Sync now on a source at any time. Manual syncs are limited to 10 per hour per user, and connection tests to 30 per 15 minutes.

There is no per source schedule setting. Every connector follows the same daily cadence.

Badge Meaning
Connected Syncing normally
Syncing A sync is running now
Waiting for first sync Connected, nothing fetched yet
Sync failed The last sync failed. The error is shown on the card.
No data returned The sync worked but the provider returned nothing
Data is stale The newest data is more than five days old

While a sync is running the page refreshes itself every 10 seconds.

Click Edit, enter the new secret, and save. Xplorr tests the new credential before storing it, and the next sync uses it. You do not need to disconnect and reconnect, which would delete history.

Disconnect deletes the stored credentials and all cost and usage data for that source from Xplorr, along with budgets and alerts scoped to it. Your account at the provider is not changed. Export anything you need first.

“rejected the credentials”

The key is wrong, revoked, or the wrong type. Each connector needs a specific credential: an organization admin key for OpenAI and Anthropic, parent organization keys for Datadog. Check the key type before regenerating.

“accepted the credentials but denied access”

The credential is valid but lacks permissions. Re-check the grants listed for that connector on its card.

“This source is already connected”

The same provider account is already a cost source in this organization. Edit the existing one rather than adding a duplicate.

No data returned after the first sync

For Datadog, confirm the range is within the current or previous month. For Snowflake and Databricks, confirm the role can actually read the billing views, and that the warehouse is reachable.

A statement did not finish in time

Snowflake and Databricks queries have time limits. A larger or serverless warehouse usually resolves it.

Are connectors read only? Yes. Each one reads usage and billing endpoints or views and nothing else.

Where does connector spend show up? Everywhere cloud spend does: cost views, budgets, anomaly detection, and reports. AI connectors additionally feed the AI Spend page.

Can I connect more than one account per provider? Yes. Use Add another on the connector card.

Can non-admins see cost sources? They can see sources for accounts they have access to, but cannot connect, edit or disconnect them.