ophis
by njayp·★ 85·Score 47
Ophis transforms Cobra CLI commands into MCP servers, enabling Claude Desktop, VSCode, and Cursor integration.
Overview
Ophis is a Go-based tool that automatically converts Cobra CLI commands into MCP tools. It provides a seamless bridge between command-line interfaces and AI assistants. The tool exposes CLI commands as MCP tools through protocol implementations, allowing AI models to interact with command-line applications. It supports streaming over HTTP for remote access and offers configuration options to selectively expose commands and flags as MCP tools.
Try asking AI
After installing, here are 5 things you can ask your AI assistant:
When to choose this
Choose Ophis when you have an existing Cobra-based CLI tool that you want to expose as MCP resources without rewriting it as a native MCP server.
When NOT to choose this
Don't choose Ophis if you're starting a new project from scratch, as there are more direct MCP implementations; also avoid if your CLI has complex state management that subprocess execution can't properly handle.
Comparable tools
Installation
go get github.com/njayp/ophisAdd to your CLI:
rootCmd.AddCommand(ophis.Command(nil))Enable in Claude Desktop:
./my-cli mcp claude enableRestart Claude Desktop after enabling.
FAQ
- Does Ophis work with any CLI framework?
- Ophis specifically works with Cobra-based CLI applications. It's designed to convert Cobra commands into MCP tools.
- Can I selectively expose only certain commands as MCP tools?
- Yes, Ophis provides configuration options with selectors to control which commands and flags are exposed as MCP tools.
On Hacker News
Recent discussion from the developer community.
- Story by njayp · 2025-07-11
Compare ophis with
Last updated · Auto-generated from public README + GitHub signals.