universal-tool-calling-protocol/code-mode/code-mode-cli
- community
Checking that the SKILL.md file is still in the repository.
Call external APIs, MCP servers, and CLI tools by writing TypeScript code that runs in a sandbox — without MCP. Use when the user wants the agent to use a tool/API/integration (e.g. "search Open Library", "read my Notion", "call this REST API") in an environment that has a shell but no MCP config and no settable environment variables (e.g. Claude Cowork sandboxes). Self-configure by writing a .utcp_config.json file, discover tools with `utcp search`, run tool-chains with `utcp run`, and complete interactive OAuth sign-ins with `utcp login`. Bootstrap with `npx @utcp/code-mode-cli prompt`.
Install
npx vskill@latest install universal-tool-calling-protocol/code-mode/code-mode-cliSKILL.md
utcp cli
utcp (npm: @utcp/code-mode-cli) lets you call UTCP tools by writing TypeScript that executes in an isolated sandbox. It needs only a shell and a working folder — no MCP, no environment variables.
Run everything via npx @utcp/code-mode-cli <command> (or utcp <command> if installed). All output is JSON on stdout.
1. Read the guide
2. Configure (write a file — no env vars)
Write .utcp_config.json in the working directory listing the manuals (APIs / MCP servers / CLIs) you need:
Transports: http (incl. OpenAPI URLs), mcp (remote/local MCP servers), cli, text, file.
3. Discover
4. Run a tool-chain
Call tools as manual.tool({ args }). Top-level await and return work. Use a heredoc for multi-line code:
Output: {"success":true,"result":<value>,"logs":[...]}.
5. Interactive OAuth (user signs into a page)
Declare an oauth2_user auth block on the manual. For a remote MCP server the block is just { "auth_type": "oauth2_user", "access_token": "${MY_TOKEN}" } — endpoints are auto-discovered. Then:
login prints NDJSON describing what to do next. Handle it like this:
- `{"action":"show_user_url","then":"poll", ...}` (device flow): show the
user the url and user_code in chat, then wait — the command polls and finishes on its own, printing {"action":"done", ...}.
- `{"action":"show_user_url","then":"rerun_with_code","next":"...", ...}`
(paste flow, used by MCP / authorization-code): show the user the url. After they sign in they are redirected to a URL that won't load (e.g. http://localhost:8765/callback?code=...). Ask them to copy that full address-bar URL and paste it to you, then run: ``bash utcp login <manual> --code "<pasted url or code>" ` It writes the token to .env`; tools are now authenticated.
Failure modes
- `Invalid CallTemplate object` → a manual in
.utcp_config.jsonis missing a
required field or uses an unknown call_template_type. Re-check against the schema (utcp prompt).
- `access_token ... is empty` / `keys` shows a missing variable → run
utcp login <manual>.
- `No pending login for '<manual>'` → run
utcp login <manual>(without
--code) first to start the flow.
- `isolated-vm` install fails on Windows → needs the VS C++ build tools.
Boundaries
- The bundled
@utcp/cliplugin can run arbitrary local commands — only register
manuals from trusted sources.
- This is for shell/sandbox agents. On an MCP client, use
@utcp/code-mode-mcp.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingcode-mode-cli/SKILL.md
Popularity
- Repository stars
- 1,501
- Repository forks
- 101
- 7-day trend score
- 37
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/universal-tool-calling-protocol/code-mode/code-mode-cli)