meghaमेघ

Run T3 Code threads on Codex Cloud and Claude Code on the web

An open-source ACP agent for T3 Code. Your prompt starts a cloud task, and its setup log, commands, diff and answer stream back into the thread. It uses the codex and claude logins you already have.

Set up megha for me: read https://t3-megha.vercel.app/setup.md and follow it.

Paste it into Claude Code, Codex or a T3 thread. Read the full setup

Illustration of a T3 Code thread on Codex Cloud, drawn for this page. Not a screenshot.

How a cloud thread runs

T3 Code and megha run on your computer. The work runs in Codex Cloud or Claude Code on the web, on the plan you already pay for.

  1. 1

    You send a prompt in a T3 thread

    T3 starts one megha process for the thread, on your computer, and talks to it over ACP.

  2. 2

    Megha starts a cloud task

    It uses the access token your codex or claude CLI already saved. The task starts from your branch on GitHub.

  3. 3

    The cloud does the work

    In its own container it clones the repo, runs your setup script, edits files and runs commands.

  4. 4

    Progress comes back to the thread

    Megha streams the setup log, each command, the diff and the answer as they happen. A follow-up continues the same task.

Set it up with one prompt

Paste it into Claude Code, Codex or a T3 thread on your computer. The agent reads the setup file, installs megha from npm, checks that it runs, and adds two providers to T3 Code: Codex Cloud and Claude Code on the web. It backs up T3's settings first, and it never runs your logins or opens your credential files.

Set up megha for me: read https://t3-megha.vercel.app/setup.md and follow it.

Read the full setup: it's the file the agent follows, with what it runs, what it edits, and what it never touches.

Or set it up by hand

Pick your system to see its paths.

  1. Install megha and check your logins

    Terminal
    npm install -g t3-megha
    megha doctor

    The package is t3-megha; the command is megha. Use npm even if you have bun, because the next step looks in npm's global folder. The doctor checks Node, git and your logins on this computer only.

  2. Find the two paths T3 needs

    Terminal
    node -p "process.execPath"
    npm root -g

    The first prints the node path. The megha path is the second one's output followed by \t3-megha\index.mjs, for example C:\Users\you\AppData\Roaming\npm\node_modules\t3-megha\index.mjs. Check it prints a version:

    Terminal
    node "C:\Users\you\AppData\Roaming\npm\node_modules\t3-megha\index.mjs" --version
  3. Add two providers in T3 Code

    In %USERPROFILE%\.t3\userdata\settings.json, with your paths. T3 picks up the change while it runs. Or use Settings → Providers → Add provider → Local ACP command, with the same values.

    T3 Code settings.json
    {
      "providerInstances": {
        "megha-codex": {
          "driver": "acpRegistry",
          "displayName": "Codex Cloud",
          "config": {
            "source": "local",
            "commandPath": "C:\\Program Files\\nodejs\\node.exe",
            "commandArgs": ["C:\\Users\\you\\AppData\\Roaming\\npm\\node_modules\\t3-megha\\index.mjs", "--backend", "codex"]
          }
        },
        "megha-claude": {
          "driver": "acpRegistry",
          "displayName": "Claude Code on the web",
          "config": {
            "source": "local",
            "commandPath": "C:\\Program Files\\nodejs\\node.exe",
            "commandArgs": ["C:\\Users\\you\\AppData\\Roaming\\npm\\node_modules\\t3-megha\\index.mjs", "--backend", "claude"]
          }
        }
      }
    }
    Using Zed instead?

    Megha speaks ACP, so Zed can start it too. Run zed: open settings and add:

    Zed settings.json
    {
      "agent_servers": {
        "Codex Cloud": {
          "type": "custom",
          "command": "C:\\Program Files\\nodejs\\node.exe",
          "args": ["C:\\Users\\you\\AppData\\Roaming\\npm\\node_modules\\t3-megha\\index.mjs", "--backend", "codex"],
          "env": {}
        },
        "Claude Code on the web": {
          "type": "custom",
          "command": "C:\\Program Files\\nodejs\\node.exe",
          "args": ["C:\\Users\\you\\AppData\\Roaming\\npm\\node_modules\\t3-megha\\index.mjs", "--backend", "claude"],
          "env": {}
        }
      }
    }
  4. Connect each cloud to your repo

What you need

  • Codex Cloud

    A ChatGPT plan with Codex, signed in on this computer with codex login. Then connect GitHub to Codex and give it your repo. Megha creates the repo's environment on your first prompt if it has none.

  • Claude Code on the web

    A Claude subscription, signed in by running claude, then /login. Open claude.ai/code once to create your cloud environment. To get Claude's changes back here, install the Claude GitHub App on the repo.

  • Your branch on GitHub

    Both clouds start from what's pushed. With "Send local changes" on, megha sends unpushed work instead: a patch for Codex, a git bundle for Claude. A Claude session started from a bundle can't push back, so its changes stay on claude.ai.

  • Node.js 22 or newer

    T3 Code starts megha with node, once per thread. megha doctor checks Node, git and both logins on this computer, not the cloud setup. You only need the login for the cloud you use.

What works, and what doesn't

Features that work with megha, and features that don't
StatusFeatureDetails
Streaming progressSetup log, commands and the answer show up while the cloud task runs.
Follow-upsThe next message in the thread continues the same cloud task.
StopT3's stop button asks the cloud to cancel and gives you the thread back at once. The cloud can take a moment to stop; if you're not sure it did, check the task on chatgpt.com or claude.ai.
Model pickerBoth list the cloud's live models. Claude runs the one you pick; Codex Cloud may still run its default.
EnvironmentsPick the cloud environment for each thread in the composer.
Import cloud tasksList sessions → Import brings a task you started on the web into T3.
Apply diff locally: CodexTurn it on and megha applies each turn's diff to your checkout. If git can't apply it, megha saves it as a patch file instead.
Apply diff locally: ClaudeOnly when the session pushes its claude/ branch, which needs the Claude GitHub App on the repo. A session started from a git bundle can't push, so its changes stay on claude.ai.
T3's diff panelOnly after megha applies a diff to your checkout. Until then, a Codex diff or a pushed Claude branch shows in the thread.
Terminal and previewsYou can't open a shell or a preview on the cloud machine.
T3 tools in the cloudThe cloud agent can't call T3's own tools.

Unofficial, so read this first

Megha calls the same endpoints the Codex and Claude web apps use. OpenAI and Anthropic don't document them, so they can change or stop working without notice.

It reads the access token your codex and claude CLIs already saved. It sends it only to the cloud it belongs to, never refreshes it, and never writes it anywhere. Use it with your own account only.

Megha is not affiliated with or endorsed by OpenAI or Anthropic.

Start your first cloud thread

Paste the prompt into your coding agent, then pick Codex Cloud or Claude Code on the web in T3.

Set up megha for me: read https://t3-megha.vercel.app/setup.md and follow it.