# Upfyn-Code

**Visual AI coding interface for Claude Code, Cursor & Codex.**

Canvas whiteboard, multi-agent chat, integrated terminal, git management, voice assistant, and MCP protocol — all in one browser-based IDE.

By [Thinqmesh Technologies](https://thinqmesh.com)

---

## What is Upfyn-Code?

Upfyn-Code gives you a **visual web interface** for AI coding agents. Instead of working in a plain terminal, you get a full IDE experience with:

- **Multi-Agent Chat** — Claude Code, Cursor, Codex, and 200+ models via OpenRouter
- **Visual Canvas** — Infinite whiteboard with AI-powered blocks (Chat, Research, Code, Notes, PDF, Dashboard)
- **Integrated Terminal** — Multi-tab shell with full ANSI color support
- **File Explorer** — Browse, edit, and manage project files
- **Git Panel** — Stage, commit, push, view diffs, switch branches
- **Voice Assistant** — Talk to Upfyn hands-free
- **Task Tracker** — AI-powered task breakdown from PRDs
- **MCP Protocol** — Connect to Claude Code, Cursor, or any MCP-compatible tool
- **Dashboard** — Session analytics, usage stats, and getting-started guide
- **BYOK** — Bring Your Own API Key (Anthropic, OpenAI, Google, OpenRouter)

---

## Two ways to use it

### 1. Local mode (free, self-hosted)

Install the package and run everything on your machine. No account needed.

```bash
npm install -g upfynai-code

# Launch Claude Code + web UI
uc

# Or start the web server only
uc start
```

The server starts at `http://localhost:3001`. It auto-detects your installed AI agents and creates a local user automatically.

**What you get locally:**
- Full web UI with all features (chat, canvas, terminal, git, files, tasks)
- Direct SDK calls to your local Claude Code / Codex / Cursor
- No network round-trip — everything runs on your machine
- Works offline (except AI queries which need API access)

### 2. Cloud mode (subscription required)

Access your machine from **any browser, anywhere** via [cli.upfyn.com](https://cli.upfyn.com).

```bash
# 1. Sign up at cli.upfyn.com and get your relay token
# 2. Connect your machine
uc connect --server https://cli.upfyn.com --key upfyn_your_token
```

Once connected, your local machine is bridged to the web UI. AI prompts, terminal commands, file operations, and git — all route through an encrypted relay to your machine.

**What you need for cloud mode:**
- An active subscription at [cli.upfyn.com/pricing](https://cli.upfyn.com/pricing)
- Your relay token (provided after signup)
- The CLI installed on your machine

**Why subscribe?**
- Access your dev environment from any device (phone, tablet, another PC)
- MCP API access — connect Claude Code or Cursor to Upfyn-Code remotely
- Voice assistant with daily call allowance
- Priority support

---

## CLI Commands

| Command | Description |
|---------|-------------|
| `uc` | Launch Claude Code with Upfyn web UI |
| `uc start` | Start the local web server only |
| `uc connect --key <token>` | Connect to cli.upfyn.com (subscription required) |
| `uc config --api-key <key>` | Save your Anthropic API key |
| `uc status` | Show configuration and data locations |
| `uc install-commands` | Install `/upfynai-*` slash commands for Claude Code |
| `uc update` | Update to latest version |
| `uc help` | Show all commands |

## Slash Commands

When you run `uc`, these slash commands are automatically available inside Claude Code:

| Command | Description |
|---------|-------------|
| `/upfynai-connect` | Connect CLI session to web UI |
| `/upfynai-disconnect` | Disconnect from web UI |
| `/upfynai-status` | Show connection status |
| `/upfynai-doctor` | Run diagnostics |

## BYOK (Bring Your Own Key)

Even without a connected machine, you can use AI chat by adding your own API keys in Settings:

- **Anthropic** — Claude models (Sonnet, Opus, Haiku)
- **OpenAI** — GPT models
- **OpenRouter** — 200+ models from all providers
- **Google AI** — Gemini models

Configure via the web UI (Settings > AI Providers) or CLI:
```bash
uc config --api-key sk-ant-api03-your-key
```

## Requirements

- **Node.js 18+**
- At least one AI agent installed:
  ```bash
  npm install -g @anthropic-ai/claude-code  # Claude Code
  npm install -g @openai/codex              # OpenAI Codex
  # Cursor — install from cursor.com
  ```

## Documentation

Full documentation: [cli.upfyn.com/docs](https://cli.upfyn.com/docs)

## License

GPL-3.0 — Thinqmesh Technologies
