MCP server
hscli mcp serve turns the whole CLI into a Model Context Protocol
server. Point Claude (Desktop, Code, or any MCP client) at it and the agent gets one
tool per command — conv_list, docs_article_create, report_conversations — with typed
inputs and structured JSON results. No glue code, no wrapper API.
Connect it
Section titled “Connect it”The server speaks MCP over stdio: the client launches hscli mcp serve as a subprocess.
Claude Code:
claude mcp add hscli -- hscli mcp serveClaude Desktop — add to claude_desktop_config.json:
{ "mcpServers": { "hscli": { "command": "hscli", "args": ["mcp", "serve"] } }}The server runs as you — it reuses the OAuth token and Docs API key already in your OS
keychain. Run hscli auth login (and hscli docs auth for knowledge-base tools) first.
Reads by default, writes on request
Section titled “Reads by default, writes on request”By default only read-only tools are exposed (list, get, search, report, …) — an
agent can observe your help desk but not change it. To enable mutating tools
(create/update/delete/bulk), start the server with --allow-writes:
claude mcp add hscli -- hscli mcp serve --allow-writes{ "mcpServers": { "hscli": { "command": "hscli", "args": ["mcp", "serve", "--allow-writes"] } }}--allow-writes is a one-time setup choice — the agent never passes it. When enabled, every
tool is available; when not, write tools simply aren’t listed.
How it maps
Section titled “How it maps”- One tool per command.
conv:bulk-status→conv_bulk_status. The escape-hatchapicommand and the streamingconv watchare not exposed. - Flags become typed inputs. Required flags/args are required;
--status active|closedbecomes an enum; repeatable flags become arrays. Output-shaping flags (--output,--jq,--fields) are dropped — the server always requests JSON. - Structured results. A command’s JSON is returned as
structuredContent(arrays are wrapped underresults); plain-text confirmations (“Deleted article 5”) come back as text.
Try it
Section titled “Try it”Once connected, ask the agent things like:
“List the active conversations tagged billing and summarize the top themes.”
With --allow-writes on, the full loop from the home page works — the agent reads the
inbox, drafts an article, and publishes it with docs_article_create.
See the command reference for the mcp serve flags.