Skip to content

FelixDaCraft/CLInterface

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CLInterface

Web interface for Claude CLI. Turn any browser into a gateway to Claude Code's CLI, without touching the API SDK directly.

How it works

[Browser] → prompt → [Express backend] → spawns `claude -p "..."` → [Claude CLI responds] → JSON → [Browser displays result]

The backend acts as a thin bridge: it receives a prompt via HTTP, executes the Claude CLI as a child process, and streams the result back. No Anthropic SDK, no API keys in the code — just the CLI running server-side.

Why this approach

  • Zero SDK integration — if Claude Code CLI is installed and authenticated on the machine, it just works
  • Full CLI capabilities — the prompt goes through Claude Code, which means access to its tools, context, and reasoning
  • Simple to deploy — one Express server, one HTML file, no build step
  • Decoupled from API changes — the CLI handles authentication, model selection, and rate limiting internally

Use cases

  • Content generation portal — articles, product descriptions, marketing copy via a simple web form
  • Internal tool for teams — give non-technical teammates access to Claude without CLI knowledge
  • Rapid prototyping — test prompts from a browser before integrating into a real product
  • Self-hosted AI gateway — run on a VPS, expose via reverse proxy, control who has access
  • Prompt engineering workbench — iterate on prompts with a clean UI instead of terminal back-and-forth
  • Batch content workflows — feed structured prompts and collect outputs without manual CLI usage

Tech stack

Component Technology
Backend Node.js + Express
Frontend Vanilla HTML / CSS / JS
AI engine Claude Code CLI (claude -p)
Process management Node child_process.spawn
Styling Custom dark theme, no framework

Setup

# Clone
git clone https://github.com/FelixDaCraft/CLInterface.git
cd CLInterface

# Install dependencies
npm install

# Make sure Claude CLI is installed and authenticated
claude --version

# Run
node server.js

Open http://localhost:3456 in your browser.

Configuration

Variable Default Description
PORT 3456 Server port
CLAUDE_BIN claude Path to Claude CLI binary

Project structure

CLInterface/
├── server.js          # Express backend, spawns Claude CLI
├── public/
│   └── index.html     # Frontend (prompt input + result display)
├── package.json
└── .gitignore

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors