{"by":"knowsuchagency","descendants":100,"id":47305149,"kids":[47306402,47305998,47305920,47305737,47306087,47305723,47306844,47306107,47461255,47318446,47306326,47310282,47307246,47306433,47305797,47309079,47307083,47321968,47306259,47322877,47318291,47305912,47306038,47305959,47309234,47305986,47307654,47305735,47305976,47307126,47307464,47315817,47317583,47384108,47307510,47306240,47306577,47305858],"score":146,"text":"Every MCP server injects its full tool schemas into context on every turn — 30 tools costs ~3,600 tokens&#x2F;turn whether the model uses them or not. Over 25 turns with 120 tools, that&#x27;s 362,000 tokens just for schemas.<p>mcp2cli turns any MCP server or OpenAPI spec into a CLI at runtime. The LLM discovers tools on demand:<p><pre><code>    mcp2cli --mcp https:&#x2F;&#x2F;mcp.example.com&#x2F;sse --list             # ~16 tokens&#x2F;tool\n    mcp2cli --mcp https:&#x2F;&#x2F;mcp.example.com&#x2F;sse create-task --help  # ~120 tokens, once\n    mcp2cli --mcp https:&#x2F;&#x2F;mcp.example.com&#x2F;sse create-task --title &quot;Fix bug&quot;\n</code></pre>\nNo codegen, no rebuild when the server changes. Works with any LLM — it&#x27;s just a CLI the model shells out to. Also handles OpenAPI specs (JSON&#x2F;YAML, local or remote) with the same interface.<p>Token savings are real, measured with cl100k_base: 96% for 30 tools over 15 turns, 99% for 120 tools over 25 turns.<p>It also ships as an installable skill for AI coding agents (Claude Code, Cursor, Codex): `npx skills add knowsuchagency&#x2F;mcp2cli --skill mcp2cli`<p>Inspired by Kagan Yilmaz&#x27;s CLI vs MCP analysis and CLIHub.<p><a href=\"https:&#x2F;&#x2F;github.com&#x2F;knowsuchagency&#x2F;mcp2cli\" rel=\"nofollow\">https:&#x2F;&#x2F;github.com&#x2F;knowsuchagency&#x2F;mcp2cli</a>","time":1773033526,"title":"Show HN: Mcp2cli – One CLI for every API, 96-99% fewer tokens than native MCP","type":"story","url":"https://github.com/knowsuchagency/mcp2cli"}