# Omega Claude CLI

> Use when the user wants to use Claude (Claude Code CLI) for analysis, codebases, or brainstorming from another agent. Uses headless Claude Code CLI scripts (no MCP). Triggers on "use Claude", "analyze with Claude", "ask Claude", "brainstorm with Claude".

- Skill: `oimiragieo/omega-claude-cli` (Agent Skill, multi-file: 23 files)
- Install (CLI): `npx skillmds@latest add oimiragieo/omega-claude-cli`
- Raw SKILL.md: https://api.skillmd.com/api/skills/oimiragieo/omega-claude-cli/raw
- Safety review: pending (external: skill-scanner PASS, skillspector CAUTION)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: oimiragieo (https://skillmd.com/u/oimiragieo)
- Updated: 2026-09-10
- Page: https://skillmd.com/skills/oimiragieo/omega-claude-cli

---


# Omega Claude CLI (headless)

This skill uses the **Claude Code CLI in headless mode** so other agents (Codex, Cursor, Copilot, etc.) can run Claude from scripts—no MCP server or MCP configuration required.

## Overview

Run Claude via the headless script: [scripts/ask-claude.mjs](./scripts/ask-claude.mjs) (from the skill root) or `.claude/skills/omega-claude-cli/scripts/ask-claude.mjs` (from the project root). It invokes `claude -p "..." --dangerously-skip-permissions` (and optional `--model`, `--json`, `--sandbox`, `--timeout-ms`) and returns the response. Requires **Node.js** and the **Claude Code CLI** to be installed. For one-time setup after copying this folder, run **/omega-claude-setup**. For install and auth, see [references/installation.md](references/installation.md) and [references/auth.md](references/auth.md).

The wrapper strips `CLAUDECODE` from the child process environment, so it also works when invoked from inside an active Claude Code session.

## First-time setup

If the user has not set up Claude Code CLI yet, direct them to run **/omega-claude-setup**. That runs the verification script (`node .claude/skills/omega-claude-cli/scripts/verify-setup.mjs`) and guides them to install Node, install Claude Code CLI, and complete one-time auth. No MCP config is needed.

## How to run Claude (headless)

From the project root (where `.claude` lives), run:

```bash
node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "USER_PROMPT"
```

Options (append to the command):

- `--model MODEL` — optional. CLI aliases: `opus` (5), `sonnet` (5), `haiku` (4.5), `fable` (5), `best`, `opusplan`, `sonnet[1m]`, `opus[1m]`, or a full `claude-*` model ID. Omit to use your account's CLI default. (Anthropic API resolutions; other providers may differ — see [model-config](https://code.claude.com/docs/en/model-config).)
- `--json` — output JSON from Claude CLI; the script prints the `.result` text field.
- `--sandbox` — run or test code in Claude's sandbox mode.
- `--timeout-ms N` — optional timeout for automation.

Examples:

- Analysis: `node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "Review @src/main.js for bugs"`
- With model: `node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "Summarize this" --model sonnet`
- Stdin: `echo "Explain recursion" | node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs`

When the user says "ask Claude for feedback" (or similar), build the prompt from their request and any @ file refs, then run the script and return the script output to the user.

## When to use this skill

- **Analysis** — Use Claude's context for code or doc review from another agent.
- **Second opinion / feedback** — User wants Claude's take on code or docs from Codex, Cursor, Copilot, etc.
- **Brainstorming** — Build a prompt that includes the challenge and optional methodology and run the script.

For full headless options and examples, see [references/headless.md](references/headless.md). For copying this skill into another project, see [references/copy-and-run.md](references/copy-and-run.md). Other surfaces: [Cursor](references/cursor.md), [Codex CLI](references/codex.md), [GitHub Copilot CLI](references/copilot-cli.md), [Antigravity IDE](references/antigravity.md), [VS Code](references/vscode.md).

## Slash commands

- **/analyze** — Run the headless script with the user's prompt (and any @ refs). Example: `/analyze summarize @README.md`.
- **/omega-claude** — Use the headless script for analysis or brainstorm as appropriate.
- **/omega-claude-setup** — Verify Node and Claude Code CLI; guide the user to install and auth. No MCP.

Natural language: "use Claude to explain index.html", "ask Claude for feedback on this function", "brainstorm with Claude using design thinking".

## Auth

One-time sign-in and auth issues: [references/auth.md](references/auth.md).

## Failure handling

- If shell execution is unavailable in the host agent (for example `@lydell/node-pty` missing binary errors), report that the Claude call is blocked by runtime setup.
- Do not present fabricated Claude output. Return the real error and troubleshooting steps instead.

## Copy and run in another project

Copy the **entire** `.claude` folder (so you have `.claude/skills/omega-claude-cli/` and `.claude/commands/`) into the target project. Open that project in your agent and run from its root. Run **/omega-claude-setup** once, then "ask Claude" works. Details: [references/copy-and-run.md](references/copy-and-run.md).

