Provider Connectors
DeepSeek
See what you spend on DeepSeek and who uses it. Upload the monthly usage export as your bill, and connect the usage Claude Code, Codex and your apps report.
What you can connect
DeepSeek publishes no usage or cost API. Its bill is a file you export from its platform, and the tools your team runs on DeepSeek report their own usage to LevelFour.
| What you use | Connect | What you see |
|---|---|---|
| The DeepSeek API, any use | Monthly usage export | Your bill by day, model, API key and token type |
| Claude Code pointed at DeepSeek | Claude Code usage | Who uses which model, how much, and how Claude Code is used |
| Codex pointed at DeepSeek | Codex usage | Who uses which model, how much, and how Codex is used |
| Your own apps calling DeepSeek | App usage | Each model call by app and model |
Connect any mix, in any order. The export is your bill. The tools add who used it and how.
LevelFour values what the tools report at DeepSeek's list price for the hour each request was made. DeepSeek charges twice the off-peak rate from 01:00 to 04:00 and from 06:00 to 10:00 UTC, Monday to Friday. It bills Chinese public holidays off-peak, and LevelFour prices those days as weekdays, so a holiday reads a little high.
History and what is left out
| Source | History | First data | Not included |
|---|---|---|---|
| Monthly usage export | Every month you upload | Minutes after you confirm the upload | Top-ups, the remaining balance, tax, and a wallet in CNY |
| Claude Code, Codex and app usage | From the day you add the settings | A few minutes after you verify | Developers or apps that have not added the settings |
Prerequisites
- A DeepSeek account with a wallet in US dollars. LevelFour does not read exports in CNY yet.
- Access to the Usage page of platform.deepseek.com.
- Claude Code pointed at DeepSeek's Anthropic-compatible API, with
ANTHROPIC_BASE_URLset tohttps://api.deepseek.com/anthropic.
- Codex with DeepSeek as its model provider, in a
[model_providers.deepseek]table of~/.codex/config.toml.
- An app that calls DeepSeek through the OpenAI SDK, with its base URL at
https://api.deepseek.com.
Connect
Open Connect Providers and select DeepSeek. The first time an admin opens it, Connect DeepSeek starts by itself; after that, click Add account. Pick what your team uses and click Continue. Each pick adds its own step, a review at the end lists what you connected, and you can run it again at any time to add more.
Export a month from DeepSeek
Open Usage on the DeepSeek platform and export the month you want. DeepSeek downloads a ZIP file. There is no need to unzip it.
Upload it
In Connect DeepSeek, pick DeepSeek API. On the Usage export step, click Select a file, choose the ZIP, then click Review costs. Check the dates and the totals, and click Confirm and import.
Upload one file a month into the same account. A file that covers days already imported replaces them, so uploading a month again never counts it twice.
LevelFour reads one row per day, model, API key and token type (cache hit input, cache miss input, output and requests), and matches each day and model to the total DeepSeek's cost file states. An API key shows as its name and the last four characters DeepSeek leaves unmasked. The export dates each charge by DeepSeek's own billing day, in China Standard Time.
Generate the settings
In Connect DeepSeek, pick Claude Code. On the Claude Code step, click Generate settings. LevelFour shows the same eight-entry settings block as for Claude, with a new ingest key, once.
Add it next to your DeepSeek settings
Add the eight entries to the env object that points Claude Code at DeepSeek, next to ANTHROPIC_BASE_URL: ~/.claude/settings.json for one developer, or your managed settings for everyone.
Verify
Run one prompt in Claude Code, then click Verify connection in the step.
DeepSeek serves a Claude model name on its own models: Opus on V4 Pro, every other Claude model on Flash. LevelFour stores and prices each request as the model DeepSeek served, and ignores the cost Claude Code reports, which is a Claude price. What LevelFour keeps from Claude Code applies here unchanged.
Generate the settings
In Connect DeepSeek, pick Codex. On the Codex step, click Generate settings. LevelFour shows the same [otel] table as for OpenAI, with a new ingest key, once.
Add it to the file that names DeepSeek
Add the block to ~/.codex/config.toml, the file that holds your [model_providers.deepseek] table. If it already has an [otel] table, replace that table with this one.
Verify
Run one prompt in Codex, then click Verify connection in the step.
What LevelFour keeps from Codex applies here unchanged.
Follow App usage on the OpenAI page, with two differences: generate the variables from Your apps in Connect DeepSeek, and keep the OpenAI SDK's base URL at https://api.deepseek.com. The OpenAI instrumentation labels a DeepSeek call as an OpenAI one, so LevelFour reads the vendor from the host that served it.
Who a request belongs to
Claude Code and Codex name a person only when the developer signs in to Claude or ChatGPT. With DeepSeek as the model provider, most developers sign in to neither, so each shows as a device or a machine. A developer can name themselves by setting OTEL_RESOURCE_ATTRIBUTES=levelfour.person=<their email> in the environment their tool runs in. For Claude Code that is the env object of its settings, next to the block.
What you see
DeepSeek spend appears under Costs and Usage and on its own DeepSeek board under Boards, which appears once you connect a source.
| Group by | Monthly usage export | Claude Code, Codex and app usage |
|---|---|---|
| Model | The model | The model DeepSeek served |
| Tool | Not reported | Claude Code, Codex or Apps |
| Token type | Cache hit input, Cache miss input, Output, Requests | On the board's tokens card |
| Key, person or app | API key | Person, or app for app usage |
Billed is the export. Usage value is what the tools report, priced at DeepSeek's list price, and LevelFour never adds it to a billed total.
The DeepSeek board groups its cards the way the OpenAI board does, with the activity Claude Code adds: lines of code, commits and pull requests, edits, plugins, skills and MCP connections. Its usage bands are sized to DeepSeek's prices.
Rotating or removing access
You cannot rotate an ingest key. Disconnect the usage source, keeping its data, generate the settings again, and replace the block or the variables. Disconnecting a usage source stops its key working at once.
Disconnecting the monthly usage export keeps or purges what you imported, as you choose when you disconnect.
Troubleshooting
| Symptom | What to do |
|---|---|
| The upload says the export is in CNY | LevelFour reads wallets in US dollars only for now |
| LevelFour marks the upload failed | The file is not the export DeepSeek downloads, or the download broke. Export the month again and upload the ZIP as it came |
| A month shows twice | Upload into the account that already holds it, from its Upload another month action, and the new file replaces the old one |
| Verify connection says no usage has arrived | Check the block sits in the settings the tool reads, next to its DeepSeek settings, then run one prompt |
| A developer shows as a device or a machine | Expected when they are not signed in to Claude or ChatGPT. Have them set levelfour.person |
Next
- Connect Providers lists every provider you can connect
- OpenAI and Anthropic connect the same way