On this page
Key takeaways
- An API key is separate from a ChatGPT or Claude chat subscription; it needs its own billing.
- Create a dedicated key for analytics so you can track and cap its spend.
- Set a monthly spend limit before you connect the key anywhere.
- Treat the key like a password: never paste it into chats, docs or code repositories.
Before you start
- An API key is not a chat subscription. A ChatGPT Plus or Claude Pro subscription does not include API usage. API access is billed separately, per use.
- You need a payment method on the provider's developer platform.
- Menus change. The steps below describe the usual flow; if a menu name differs, look for "API keys", "Billing" and "Limits" in the provider's settings.
Option A: OpenAI
- Sign in to the OpenAI Platform at
platform.openai.comwith your work account. - Add billing. Open Settings, then Billing, and add a payment method or prepaid credit.
- Create a project for analytics (optional but recommended), for example "DashboardGPT". Keys and usage can then be tracked per project.
- Create a key. Go to API keys, choose "Create new secret key", give it a clear name such as
dashboardgpt-analyticsand select the project. - Copy the key once. It is shown only at creation. Paste it straight into the next step; do not save it in a document.
- Set a limit. In the billing or limits settings, set a monthly budget and an email alert for the organisation or project.
Option B: Anthropic
- Sign in to the Anthropic Console at
console.anthropic.comwith your work account. - Add billing. Open the billing settings and add a payment method or credits.
- Create a workspace for analytics (optional), for example "DashboardGPT", so usage and limits are separate.
- Create a key. Go to API keys, choose "Create Key", name it
dashboardgpt-analyticsand pick the workspace. - Copy the key once and paste it straight into the next step.
- Set a limit. In the limits settings, set a monthly spend limit for the organisation or the workspace.
Connect the key to DashboardGPT
- Sign in to your DashboardGPT workspace.
- Open the workspace settings and find the AI provider section.
- Choose your provider, paste the key and save.
- Ask a test question on your data.
- Check your provider's usage page to confirm the call appeared.
Keep the key safe
- One key per tool. If a tool is retired or compromised, revoke just that key.
- Never share keys in chat, email, tickets or documents.
- Never commit keys to code repositories.
- Rotate keys periodically, and whenever someone with access leaves.
- Revoke immediately if a key may have been exposed, then create a new one.
Pick a sensible spend limit
For a first month, set a limit you would be comfortable spending and turn on alerts at 50% and 80%. After a month of normal use, look at actual spend and adjust. Questions that name a metric, a breakdown and a window keep usage efficient, because they need fewer back-and-forth calls.
Troubleshooting
| Problem | Likely cause | Fix |
|---|---|---|
| "Invalid API key" | Key copied incompletely or revoked | Create a new key and paste it again |
| "Insufficient quota" or billing error | No payment method or credit | Add billing on the provider platform |
| Requests stop mid-month | Spend limit reached | Raise the limit or wait for the next period |
| Model not available | Account or region does not have access | Choose another model or check account access |