Oauth Cli Coder banner
codeninja codeninja

Oauth Cli Coder

Development community

Description

Seamlessly interact with CLI coders (Claude, Gemini, Codex) via tmux TUI sessions.

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

oauth-cli-coder

Drive **Claude Code**, **Gemini CLI**, and **Codex** programmatically — through the same tmux session they already run in.

No API keys. No custom auth. If you're logged in on your terminal, `oauth-cli-coder` can use it.

              ┌──────────────┐
  your code   │  tmux pane   │   AI CLI
  ─────────>  │  (headless)  │  <──── claude / gemini / codex
              └──────────────┘
                  captures
                scrollback &
              extracts response

Why?

AI CLI tools like `claude`, `gemini`, and `codex` are built for humans sitting at a terminal. They handle OAuth in the browser, show TUI prompts, and maintain rich session state. That's great — until you need to drive them from code.

**oauth-cli-coder** bridges the gap:

  • Launches the real CLI binary in a background tmux session
  • Types into it and reads back the full scrollback buffer — like a human would
  • Automatically navigates past startup dialogs, trust prompts, and upgrade nags
  • Keeps sessions alive across calls so you can build multi-turn conversations
  • Works with your existing OAuth tokens — no API keys to manage

Quick Start

pip install oauth-cli-coder

**Requires:** `tmux` installed on your system (`apt install tmux` / `brew install tmux`)

From the command line

# Ask a question
oauth-coder ask claude "explain this repo"

# Use a specific model
oauth-coder ask claude "review my code" --model opus

# Persistent session — keeps context across calls
oauth-coder ask claude "analyze this repo" --session-id my-project
oauth-coder ask claude "now suggest improvements" --session-id my-project

# Slash commands
oauth-coder slash claude /compact --session-id my-project

# Read the current screen without sending anything
oauth-coder read claude --session-id my-project

# Manage sessions
oauth-coder list
oauth-coder stop claude --session-id my-project
oauth-coder stop-all

From Python

from oauth_cl