Skip to content

Xeift/CatDesk

Repository files navigation

CatDesk

An open-source tool that turns ChatGPT Web into a coding agent. No reverse engineering, no API, no Codex. A ChatGPT Plus subscription is enough.

CatDesk in ChatGPT Web
CatDesk in ChatGPT Web

Disclaimer

This is an independent open-source project and is not affiliated with or endorsed by OpenAI. I built it as a personal tool and decided to open-source it. Some features are still buggy and may cause unexpected behavior. Use it at your own risk. I am not responsible for any loss caused by this tool. It is strongly recommended to run it inside a VM or container.

Why CatDesk?

Codex has a very generous weekly quota (2x usage + reset usage frequently) compared to Antigravity and Claude Code (3 Opus prompts then 5h quota is gone lol), that's why I love OpenAI so much.

Codex reset usage frequently🙏
Codex reset usage frequently🙏

However, the quota runs out very quickly if you work on a large project.

I used up my Codex quota on the first day after it reset
I used up my Codex quota on the first day after it reset

Then you need to wait another 7 days. What are you going to do for the rest of the week?

Here's the solution: most people with a Plus subscription do not use even 10% of their weekly thinking messages.

So why not use your 3,000 weekly messages for coding?

That's the idea behind CatDesk! It gives ChatGPT Web tools like write and run_command to edit files on your computer.

How does this work?

  1. A ChatGPT Plus or above subscription is required.
  2. CatDesk runs as a local MCP server on your computer. It has the ability to run commands and edit files, just like Codex.
  3. You can connect ChatGPT Web to CatDesk using a Custom Connector, which is a feature available only to Plus and Pro users.
  4. Done! Now ChatGPT Web can control your computer and code on it.

In short,

ChatGPT Web + CatDesk
= a stripped-down version of Codex
= OpenClaw without cron and other active utilities

I tried this with GPT-5.2 before, and the results were poor. However, GPT-5.4 Thinking is now really good at tool calling and computer use. The first time I tried it with GPT-5.4, I was honestly surprised by how well it worked.

Differences between ChatGPT + CatDesk, Codex, and the API (let's say Plus plan)

ChatGPT + CatDesk Codex OpenAI API
Usage 3,000 messages/week Generous weekly quota Pay as you go
Pros Stable, no extra fee, and nearly unlimited* quota Stable and no extra fee Stable
Cons Not as smooth as native Codex Runs out very quickly Tokens are expensive

*Let's say you sleep 6 hours a day and use CatDesk every day. In that case, you can send 3,000 / (24 - 6) / 7 = 23.8 messages per hour. Since thinking and tool calls take time, it is very difficult to use up your weekly 3,000 message limit.

Who needs this?

  • People who used up their Codex quota on the first few day after it reset (me🥺)
  • People who are working on web development and crawlers. (CatDesk enables ChatGPT Web to read elements and control your browser tab through chrome-devtools-mcp integration.)

Quickstart

Caution

This tool is very powerful and can potentially wipe your whole disk or produce unexpected results. Run it inside a VM or container (DevContainer is a good option). Treat it like OpenClaw, keep it containerized and isolated.

  1. Install CatDesk globally with npm.

    npm install -g catdesk

    The npm package downloads a prebuilt CatDesk binary for your platform. You do not need a Rust toolchain.

  2. Run CatDesk from any terminal directory.

    catdesk

    By default, CatDesk listens on port 3200, as defined in main(). You can override it with PORT. The workspace root defaults to the current working directory and can be overridden with WORKSPACE_ROOT, also in main().

    On macOS Terminal.app, CatDesk manages a dedicated CatDesk Terminal profile automatically. If the current Terminal tab is not already using that profile, CatDesk applies it, closes any temporary helper window, and asks you to run the same command again in that tab. It only starts immediately when the current tab is already using CatDesk. Set CATDESK_SKIP_MACOS_TERMINAL_PROFILE=1 if you want to keep the current Terminal session untouched.

  3. Wait for the TUI to show the MCP Server URL.

  4. Open ChatGPT connector settings.

  5. Click Create app.

  6. Fill in the connector form. Use:

    • Name: CatDesk or any name you like
    • MCP Server URL: the full URL shown by CatDesk
    • Authentication: None

    These values come directly from the in-app guide in guide_lines.

  7. Click I understand and want to continue.

  8. Click Create.

  9. Add this to your ChatGPT Custom instructions:

CatDesk is a coding tool and a custom connector. Always use CatDesk if the user wants to do anything related to file operations. Always call `catdesk_instruction` after `list_resources`, and follow the instructions it contains.
  1. Start using the connector from ChatGPT Web. Some important tips:
  • I recommend let ChatGPT to decide which connector automatically. You can manually selecting the connector using / or @. This way, ChatGPT can only access the connector you selected, which may improve stability. However, the downside is, web.search and web.open will be disabled. Which means it can't search latest info. The web tool and a custom connector cannot be used at the same time.
Select CatDesk from the slash command menu
Select CatDesk manually with /
Select CatDesk from the at-sign menu
Select CatDesk manually with @
  • To improve performance and avoid high memory usage, I strongly recommend opening a new session for every small feature. If you need context, you can ask ChatGPT to create a handoff note and paste it into the new session. It will become extremely laggy after 50+ tool calls.

3.9 GB Memory usage🥹
3.9 GB Memory usage🥹

  • Use 5.5 with Standard thinking effort for CatDesk. It‘s smoother and faster, and produces better code quality than Extended(at least in my experience).

Tools

CatDesk has two local tool modes: multi-tools exposes 7 tools, and read-only exposes 3 tools.

CatDesk's local tools in multi-tools mode are:

Tool Type What it does
catdesk_instruction Guide Returns CatDesk usage instructions and render Binagotchy
read Read Reads a text file from the workspace
search Read Searches workspace text with rg, grep, or built-in search
write Write Creates or overwrites a file
edit Write Replaces exact text inside a file
delete Write Deletes a file or directory
run_command Shell Runs a shell command inside the workspace.

If browser mode is enabled, CatDesk can also expose extra browser/devtools tools. Those are provided by the browser bridge, so the exact list depends on your environment.

search uses rg when it is available, falls back to grep, then falls back to CatDesk's built-in scanner. Installing ripgrep is optional, but gives the best search performance and behavior.

Context window

According to the blog and the code, the context window in ChatGPT web is different from Codex.

Tier CatDesk + ChatGPT Web (in + out = sum) Codex CLI (sum)
Plus 128K + 128K = 256K 258K (1M experimental)
Pro 272K + 128K = 400K 258K (1M experimental)

FAQ

Can I turn off the red CSP button?

The red CSP button shown in tool calls
The red CSP button
Advanced connector settings with Enforce CSP in developer mode
Enforce CSP in developer mode in Advanced connector settings

Yes. Open Advanced connector settings and turn on Enforce CSP in developer mode. That setting removes the red button. CatDesk automatically adds the current ngrok domain to the widget CSP, so the widget should keep working with CSP enforcement enabled.

Can I skip approval, like with --yolo or --dangerously-skip-permissions?

Approval required for sensitive operations
Approval required for sensitive operations

No. This restriction comes from the ChatGPT Web side. There is not much CatDesk can do about it. ChatGPT Web probably uses an LLM or some internal policy layer to detect high-risk operations and require manual approval. Sensitive filenames and sensitive content can both trigger manual approval. It is not only about which tool is being used. For example:

write("api_key.txt", content: "")
⚠️ Approval required

write("Xeift.txt", content: "api_key")
⚠️ Approval required

write("i_luv_catgirl.txt", content: "")
✅ No approval required

Sometimes this is annoying, but there is no good workaround right now. This is one of the reasons I say CatDesk is not as smooth as native Codex.

I've already connected. Why do I need to connect again and again?

There doesn't seem to be any obvious pattern for when the connector triggers Connect. I'm sure it's not triggered by the tool call count, but I don't know the exact reason.

Connector asks to connect again
Connector asks to connect again
Connector asks to connect again (After you click Continue)
Connector asks to connect again (After you click Continue)

I know it’s annoying. I’m trying to find a solution now.

Can CatDesk be used in other apps?

No. CatDesk is built around ChatGPT Web and its Custom Connector (They call it Apps now, but to prevent confusion with Application, I still prefer call it Connector) flow. In practice, that means this project is not just a plain standalone MCP server. Also, there still are not many AI apps that support custom remote MCP servers well. Even if they support, they probably does not provide such generous (3000 messages) weekly quota.

For Claude, web and Claude Code share same quota, so just simply use Claude Code, no need to use CatDesk.

How does the input/output token be calculated?

CatDesk does not get official token usage numbers from ChatGPT Web. It estimates them locally with o200k_base, the same tokenizer family used by GPT-5.5-style models, so the numbers are useful, but still only estimates.

Field Symbol What it means Price
inputTokens Tool input ≈ LLM output $30.00 / 1M output tokens
outputTokens Tool output ≈ LLM input $5.00 / 1M input tokens
totalTokens Σ inputTokens + outputTokens input price + output price

CatDesk does not count:

  • the full ChatGPT conversation
  • hidden prompts or reasoning tokens
  • other internal tokens on OpenAI's side

The loading animation is only a visual effect. ChatGPT Web does not stream partial MCP tool input/output into CatDesk, so the widget animates locally first and then locks to the estimated values when the real tool result arrives.

What is workspace?

Workspace is the root directory CatDesk is allowed to work in.

By default, it is the directory where you launch CatDesk. You can also override it with WORKSPACE_ROOT.

File tools use this directory as their base path, and paths outside the workspace are rejected.

Where to put my AGENTS.md?

You can put it in 3 places.

  1. Workspace root
  2. ~/.catdesk/AGENTS.md
  3. ~/.codex/AGENTS.md

CatDesk checks these locations for AGENTS.md in this order. This happens every time catdesk_instruction is called. You can also manually choose which AGENTS.md to use.

Set AGENTS.md manually
Set AGENTS.md manually

What to do if the widget is blank?

Empty widget/function call
Empty widget/function call

  1. Simply refresh the page and reconnect the connector.
  2. Stop the response and send the message again.

This is a bug on ChatGPT's side. There is nothing I can do about it, and changing the code will not solve the issue. This bug was probably introduced on Apr 15th.

Safety

Caution

Do NOT share the MCP Server URL with anyone. Anyone with the URL can access your computer.

The URL is made of these parts:

Part Example What it means
Public URL https://xxxx.ngrok-free.app The temporary ngrok address
Random path /Ab3kL9xQ2pTm7VhC A random per-run path added by CatDesk
MCP endpoint /mcp The actual MCP endpoint

So the full URL looks like this:

https://xxxx.ngrok-free.app/Ab3kL9xQ2pTm7VhC/mcp

The URL changes every time you start CatDesk (both Public URL and Random path). ChatGPT Web does not provide an edit button for Custom Connectors, so you need to delete the old connector and create a new one with the new URL.

About Binagotchy

Binagotchy!
Binagotchy!

The character is a cute shark-cat! I actually made this before CatDesk and decided to put it in the project.

By default, CatDesk will generate a random Binagotchy every time you start it. If you see a cute one, you can set it as your partner on the launch screen. The system will also automatically save every Binagotchy in ~/.catdesk/binagotchy. You can download it too (or, to be accurate, export it)! Both .png and .gif are supported. Feel free to use it anywhere. This project and Binagotchy are both under the MIT License. By the way, Binagotchy is generated using pure scripts and does not use any text-to-image or diffusion model.

About

An open-source tool that turns ChatGPT Web into a coding agent. No reverse engineering, no API, no Codex. A ChatGPT Plus subscription is enough.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors