Bifrost
What Plutus imports
Section titled “What Plutus imports”- Spend by model
- Spend by upstream provider (OpenAI, Anthropic, Bedrock, …)
- Spend by virtual key
- Spend by team or customer
- Input and output token counts
Connecting
Section titled “Connecting”Method: Plutus push endpoint (Plutus Bifrost collector)
Bifrost runs on a network Plutus can’t reach. Plutus doesn’t pull this data: the Plutus Bifrost collector runs inside your network, reads Bifrost’s request logs, and pushes a daily aggregate out. Plutus needs no inbound access to your gateway.
-
In Plutus, go to Sources, open the Cost tab, select Bifrost, and click Generate API Key. This requires an account admin. Plutus shows the key once, with the endpoint to push to.
-
Run the collector where it can reach Bifrost. It needs no inbound access from the internet:
Terminal window docker run -d --name plutus-bifrost-collector \-e PLUTUS_API_KEY=<the key from step 1> \-e BIFROST_BASE_URL=http://bifrost:8080 \ghcr.io/plutus-cloud/plutus-bifrost-collector:mainPin a version tag in production (v1.2.0 or later). On Kubernetes, run it as a one-replica Deployment with the same environment variables. Bifrost needs log storage enabled, with retention long enough to still hold yesterday.
-
If your Bifrost management API requires authentication, set
BIFROST_API_KEY(orBIFROST_BASIC_USERandBIFROST_BASIC_PASSWORD). The collector sends no credentials by default. -
Decide which upstream providers Plutus should count. After the first push, the Upstream providers panel lists each provider your gateway routes to. Nothing is counted until you decide, because spend a direct connector already reports (for example Anthropic) would otherwise arrive twice.
The collector pushes yesterday’s (UTC) spend once a day by default. If you can’t run it, you can
aggregate GET /api/logs yourself to one row per day, provider, model, virtual key and team, and
POST the rows to the endpoint shown with the key as a Bearer token.
The API key is scoped to the cost source it was created for. A Bifrost key can’t push to another source.
Bifrost prices each request from its own pricing catalogue, so figures are an estimate and won’t match a provider invoice to the penny. See Estimated vs. invoiced cost. Bifrost can recalculate past costs. Re-sending a day replaces it.
Token counts are recorded for every provider whatever you decide about its spend.
The collector has not been verified against a real Bifrost deployment. It was tested against a
fake Bifrost, so the log field names or management API authentication on your deployment may
differ. If figures look wrong or the push fails, field names can be overridden with
BIFROST_FIELD_<NAME> environment variables.