3 Ways to Monitor Spending on Your OpenAI Account

Keeping tabs on spending in your OpenAI account can save you from surprise bills and wasted credits. It’s easy to lose track when multiple projects, API keys, and models run at once.
I’ll walk you through three practical ways to monitor usage, set budgets, and use the billing dashboard, alerts, and quotas so you don’t get hit with an unexpected charge.
Table of Contents
Use OpenAI’s UI
Here, you’ll use the OpenAI web console to view, filter, and export your account usage and invoices so you can track spending without touching the API.
Open the Usage dashboard
- Sign in to the OpenAI dashboard and go to the Usage page (
platform.openai.com/account/usage
). - The page shows a cost chart and a summary of recent charges, which is the quickest place to spot spikes.
Pick the date range and basic filters
- Use the date selector to choose today, last 7 days, the current billing cycle, or a custom range.
- If you want monthly reports, set the custom range to the billing period.
- Look at the top-line totals (total spent over your selected range) to get a quick sense of where you stand.
Break down costs by model, product, or day
- Use the breakdown or filter controls to group costs by model, endpoint, or by day.
- Scan for expensive models or specific days with big jumps. That shows where to look next.
- Click a bar or row (where the UI lets you drill in) to see itemized usage for that day or model.
Export detailed usage for analysis
- From the Usage page, choose the export or download option to get a CSV of detailed usage.
- Exported CSVs typically include date, product/model, tokens or compute, and cost - use that in a spreadsheet for charts or internal reporting.
- Narrow the date range or filters before exporting if you only need a slice of data.
Review invoices and payment settings
- Open the Billing section (
platform.openai.com/account/billing/overview
) to find invoices and payment methods. - Download PDF invoices for accounting and match them to your exported usage if you need line-item detail.
- Update or add a payment method from the Billing page so charges are processed cleanly.
Communicate findings and set a routine
- Save the CSV and invoice PDFs to your finance folder and share the key numbers with stakeholders.
- Run the Usage page monthly (or weekly if spending is high) and export a short report so surprises are rare.
OpenAI’s help docs point to these same UI pages (Usage and Billing) for monitoring and exporting billing data - use those pages as your single source of truth in the console.
Use Torii
Rather than interacting with OpenAI directly, you can use Torii, a SaaS Management Platform, to keep an eye on OpenAI expenses. SMPs give teams a centralized place to manage SaaS subscriptions and integrations, making it straightforward to programmatically onboard/offboard users, review subscription details, and more.
Instead of performing the manual steps in OpenAI, Torii lets you automate the workflow so the update happens automatically when a specified trigger occurs. Triggers might include a new hire, an employee departure, a contract renewal, or similar events - which can save time when these changes happen often.
To monitor spending in OpenAI from within Torii, do the following:
1. Sign up for Torii
Contact Torii, and ask for your free two-week proof-of-concept.
2. Connect your OpenAI account to Torii
After your Torii account is active, link OpenAI to Torii (assuming you already have an OpenAI account). Here are the instructions for the OpenAI integration.

3. Create a Torii workflow for OpenAI
Inside Torii you can build automated workflows to track OpenAI spend. Go to the Workflows tab, define a trigger, and configure an action that monitors OpenAI costs. Whenever the trigger is activated, the workflow will run and update OpenAI so.

Use OpenAI’s API
Here, you’ll call OpenAI’s billing and usage endpoints to pull spending data and check remaining credits programmatically.
1. Choose the billing endpoints to call
GET /v1/usage?start_date=YYYY-MM-DD&end_date=YYYY-MM-DD
- gives usage totals over a date range and usually a per-day breakdown.GET /v1/dashboard/billing/subscription
- returns plan and billing-cycle details.GET /v1/dashboard/billing/credit_grants
- returns free-credit grants and remaining credit balances.
Use these three endpoints together to get raw spend, plan details, and any credits that reduce your net cost.
2. Make authenticated requests
- Set your API key in an environment variable, for example
OPENAI_API_KEY
.
Example curl for usage (replace dates and your env var as needed):
curl "https://api.openai.com/v1/usage?start_date=2024-07-01&end_date=2024-07-31" \
-H "Authorization: Bearer $OPENAI_API_KEY"
Example curl for subscription:
curl "https://api.openai.com/v1/dashboard/billing/subscription" \
-H "Authorization: Bearer $OPENAI_API_KEY"
Example curl for credit grants:
curl "https://api.openai.com/v1/dashboard/billing/credit_grants" \
-H "Authorization: Bearer $OPENAI_API_KEY"
3. Parse the responses and convert units
- The usage endpoint typically returns a total field and per-day entries. Confirm the field names in the OpenAI docs for your version.
- Amounts are commonly reported in cents or smallest currency units. If the endpoint returns
total_usage
in cents, convert to dollars withtotal_usage / 100
. - If the response includes a daily list, sum that list to verify the total. Example in Python to sum per-day amounts (assumes each item has
total_usage
in cents):
import requests, os
headers = {"Authorization": f"Bearer {os.environ['OPENAI_API_KEY']}"}
params = {"start_date": "2024-07-01", "end_date": "2024-07-31"}
r = requests.get("https://api.openai.com/v1/usage", headers=headers, params=params)
data = r.json()
daily = data.get("data", [])
total_cents = sum(item.get("total_usage", 0) for item in daily)
total_usd = total_cents / 100
print("Total USD:", total_usd)
4. Check credits and subscription details
- Call the subscription endpoint to see billing cycle, plan limits, and any soft limits. Use that to map usage to expected billing windows.
- Call the credit grants endpoint to see granted credit amounts and remaining credit. Subtract applicable credits from total usage to get net spend. Example:
sub = requests.get("https://api.openai.com/v1/dashboard/billing/subscription", headers=headers).json()
credits = requests.get("https://api.openai.com/v1/dashboard/billing/credit_grants", headers=headers).json()
# Inspect returned fields like granted_amount or remaining_amount per docs and apply math
5. Handle pagination and rate limits
- If the usage response paginates, follow the response’s pagination fields (for example a
has_more
flag or anext
cursor) and request until done. - Respect 429 responses: back off, then retry. Use exponential backoff for retries.
6. Automate daily checks and simple alerts
- Run the usage query for yesterday each morning to catch unexpected daily spikes. Fetch subscription and credit endpoints once per billing cycle or when values change.
- Calculate rolling totals (7-, 30-day) by querying the usage endpoint with different date ranges and compare to your budget thresholds.
- If totals exceed thresholds, trigger an alert from your system. The API calls above are the only OpenAI steps needed to get the data for those checks.
7. Verify results against the dashboard periodically
Use the same date ranges and compare the API totals to billing reports in the OpenAI docs or dashboard endpoints to confirm your parsing and unit conversions are correct. If numbers don’t match, re-check which fields represent cents vs. Dollars and whether credits were applied.
That’s the flow: call the usage endpoint for raw spend, pull subscription and credit endpoints to adjust for plan and grants, parse and convert amounts, handle pagination and rate limits, and run these checks on a schedule to catch surprises.
Frequently Asked Questions
You have three ways to track spending in your OpenAI account—review the Usage and Billing dashboards, connect the service to Torii for automated monitoring, or call the usage, subscription, and credit API endpoints programmatically.
The Usage dashboard at platform.openai.com/account/usage shows a live cost chart, date filters, and per-model breakdowns, letting you quickly spot daily spikes and total charges during the current billing cycle in seconds.
Yes. From the Usage page you can click Export to download a CSV containing date, product or model, tokens or compute, and cost fields, then load it into spreadsheets or BI tools for deeper analysis.
Call GET /v1/usage for totals, GET /v1/dashboard/billing/subscription for plan and cycle data, and GET /v1/dashboard/billing/credit_grants for remaining credits; convert cents to dollars and merge results to show net spend versus limits.
By integrating OpenAI with Torii you can create workflows that trigger on hires, departures, or renewals, automatically pull spend data, update budgets, and push alerts to stakeholders—eliminating repetitive manual checks in the OpenAI console.
Set budgets, review invoices monthly, export CSVs, compare API totals to dashboard figures, run daily usage queries, and alert when thresholds are breached; these practices catch runaway models early and prevent unwelcome OpenAI charges.