Use okdata with ChatGPT: desktop app, MCP and GPT Actions
Which ChatGPT surfaces can use your okdata key in November 2026, and how to set up the one that works: the desktop app, a custom MCP server or a GPT Action.
The goal: every morning you ask ChatGPT "what's on the Weibo and Douyin hot lists today, and which topics touch our category?" and get a short list with links, from live data rather than the model's memory. ChatGPT changed a lot this autumn, and not every part of it can send your okdata key yet, so this page starts with what works where, as of November 2026.
What works where
| Where | Can it make paid okdata calls? |
|---|---|
| ChatGPT desktop app, through its MCP servers | Yes. Recommended. |
| ChatGPT on the web, custom MCP server (Business, Enterprise, Edu; limited on Pro) | Only the free lookups. ChatGPT can't send an API key to a custom MCP server; it supports OAuth or no authentication. |
| A custom GPT with an Action | Yes, but personal plans (Free, Go, Plus, Pro) can no longer create GPTs, and OpenAI retires custom GPTs on December 11, 2026. |
Before you start
- An API key from okdata, starting with
okd_. New keys come with $0.10 of credit. The quickstart explains how to get one. - For the desktop app: the key in the
OKDATA_API_KEYenvironment variable (on a Mac,export OKDATA_API_KEY="okd_..."in~/.zshrc).
Way 1: the ChatGPT desktop app
The desktop app, the Codex CLI and the Codex IDE extension share one MCP configuration file, and that file can send a bearer token read from an environment variable.
- Open
~/.codex/config.toml(create it if missing) and add:
[mcp_servers.okdata]
url = "https://api.okdata.online/mcp"
bearer_token_env_var = "OKDATA_API_KEY"
- In the app, open Settings, then MCP servers.
okdatashould be listed; select Restart if the app asks. - Start a new chat and type
/mcpin the composer. You should seeokdatawith four tools:find,describe,callandaccount.
The Codex page covers the details, including what to do when an app opened from the Dock can't see your environment variable.
Way 2: a custom MCP server on ChatGPT web
On Business, Enterprise and Edu workspaces, admins and owners (and, on Enterprise and Edu, members they authorize) can go to Plugins, select the plus button, then Add custom MCP server, and enter https://api.okdata.online/mcp under Connection. Choose no authentication, tick I understand and want to continue, then Create as a plugin.
Be clear about what you get: ChatGPT can then use find and describe to browse all 51 endpoints and their prices, which is handy for planning a task, but every call comes back unauthorized, because ChatGPT does not present API keys to custom MCP servers. For actual data, use way 1 or 3.
Way 3: a custom GPT with an Action (until December 11)
Only for a workspace that can still create or edit GPTs. When a GPT is migrated to a plugin, its Actions do not come along, so treat this as a stopgap.
- Open the GPT in the editor, go to the Actions section and select Create new action.
- Import the schema from the URL
https://okdata.online/openapi.json, or paste the file's contents. - Under authentication choose API key, set the auth type to Bearer, and paste your key.
- Test in Preview: "What's on the Weibo hot search list right now?"
- Sharing it beyond your workspace needs a privacy policy URL; okdata's is
https://okdata.online/privacy/.
Two catches. People in OpenAI's forum report that one Action accepts at most 30 operations; okdata's schema has 51 endpoints plus three free catalog routes, so if the import complains, download openapi.json and delete the paths you don't need. And every person who uses the GPT spends your balance, so share it only with people you'd hand the key to.
A first prompt to try
Using okdata, get today's Weibo hot search list and the Douyin hot search
list. Pick the five topics most related to skincare, and for each give the
rank, the heat and one line on why it might matter to a skincare brand.
What it costs
find, describe and account are free (in a GPT Action, the free catalog routes are too). A hot list costs $0.002 on Weibo and $0.002 on Douyin, so the prompt above is {{cost:weibo.trends.list1+douyin.trends.list1}}, or about {{cost:weibo.trends.list30+douyin.trends.list30}} if you ask every day for a month. Searches cost more: a page of Xiaohongshu note search is $0.02. Failed calls are free.
When something goes wrong
unauthorized(401). In the desktop app, the variable isn't visible to the app (see the Codex page). In a GPT, re-enter the key under the Action's authentication and check the type is Bearer. On ChatGPT web with a custom MCP server this is expected, as explained above.insufficient_balance(402). Not enough balance for the call. Nothing was charged. Top up and ask again; prices are on the pricing page.rate_limited(429). Too many calls in a short time. The reply includesretry_after_seconds; ask ChatGPT to wait that long and try the same call again. No charge.- No tools, or the Action shows no operations. Desktop app: check the TOML section name
[mcp_servers.okdata]and restart the app. GPT: re-import the schema and read the validation errors under it; the operation limit above is the usual cause.
Read next
- The MCP server: the four tools and what to tell the agent.
- Weibo hot search: fields and price.
Updated 2026-11-12