zeronews-mcp
v0.1.6ZeroNews MCP connector (stdio) — wraps the zeronews CLI for Cursor / WorkBuddy
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
install_client
Detect or install ZeroNews client. If missing: download from ZERONEWS_DOWNLOAD_BASE (override env). If already installed: control-plane upgrade precheck (device download-resolve when logged in, else official download/latest); may update binary from CP download_url or send remote device upgrade when must_upgrade and client is online. Set download_install=false to probe only (no download/upgrade). Requires ZERONEWS_CONTROL_PLANE_URL in production.
| Parameter | Type | Description |
|---|---|---|
download_install | boolean | Download official client when missing (default true) |
executable | string | Optional absolute path to zeronews binary |
workdir | string | Optional absolute workdir override |
prompt_auth_token
Legacy alias: install if needed, then open browser login (same as login). MCP does not use Auth Token / authtoken for binding.
configure_auth
Legacy alias: install if needed, then open browser login (same as login). MCP does not use Auth Token / authtoken for binding.
auth_status
Whether the client appears configured (disk + status --json).
client_status
Runtime probe plus zeronews status --json.
expose_local_service
Create a tunnel only after the user picked a port (Questions) or explicitly named a port/URL. Agents: vague requests like「代理本地服务」without a port → list_local_listeners + Questions first; never auto-call with a guessed port. Requires port for create. ensure runs automatically; omit port to get step needs_port. No port form.
| Parameter | Type | Description |
|---|---|---|
bw | integer | Bandwidth limit in Mbps (CLI --bw; default 1 when omitted) |
local_ip | string | Override local IP; usually inferred from listener address |
port | number | Local port from user Questions selection or explicit user message. Agents must not pass a port the user did not choose. Omit → needs_port; use list_local_listeners + Questions instead. |
tunnel_kind | string | https (default), tcp, tls |
list_local_listeners
First step when exposing a local service without a named port: ensure logged-in running client, then return choices[].label for host Questions (AskQuestion). Do not call expose_local_service until the user selects one option. mapped/unmapped labels included.
| Parameter | Type | Description |
|---|---|---|
workdir | string | Optional workdir to read custom local API port from prg_runtime |
list_account_tunnels
List tunnels on the logged-in account (zeronews show tunnels --json). Requires login. Use items[].id for delete_tunnel.
| Parameter | Type | Description |
|---|---|---|
page | integer | Page number (default 1) |
size | integer | Page size (default 20, max 200) |
workspace_id | string | Optional workspace filter |
list_account_domains
List platform/self-hosted domains on the account (zeronews show domains --json). Requires login.
| Parameter | Type | Description |
|---|---|---|
page | integer | Page number (default 1) |
size | integer | Page size (default 20, max 200) |
workspace_id | string | Optional workspace filter |
list_account_clients
List client devices bound to the account (zeronews show devices --json). Requires login.
| Parameter | Type | Description |
|---|---|---|
page | integer | Page number (default 1) |
size | integer | Page size (default 20, max 200) |
workspace_id | string | Optional workspace filter |
add_domain
Create a platform domain (zeronews add domain --subdomain … --json). Requires login. If subdomain omitted: needs_subdomain — 4 random 8-char options (B–E) + Cursor Other for custom prefix; use ask_question.options; call again with subdomain.
| Parameter | Type | Description |
|---|---|---|
subdomain | string | Subdomain prefix: 6–12 lowercase letters and digits. Omit to get input + random prefix choices in Questions UI. |
workspace_id | string | Optional workspace ID |
delete_tunnel
Delete a tunnel by ID (zeronews delete tunnel <id> --json). Requires login. If tunnel_id is omitted, returns choices for Questions UI. After the user picks a tunnel, you MUST get explicit confirmation (yes / 确认删除) in a separate step — picker selection is NOT confirmation — then call again with tunnel_id and user_confirmed: true.
| Parameter | Type | Description |
|---|---|---|
tunnel_id | string | Tunnel ID from list_account_tunnels or delete_tunnel choices[].tunnel_id after user picks |
user_confirmed | boolean | Must be true on the final delete call after explicit user confirmation. Omit or false returns step needs_user_confirmation. |
workspace_id | string | When listing tunnels for picker, optional workspace filter |
delete_domain
Delete a platform domain by ID (zeronews delete domain <id> --json). Requires login. Domain must have no ports. Picker then separate explicit confirmation; final call needs user_confirmed: true.
| Parameter | Type | Description |
|---|---|---|
domain_id | string | Domain ID from list_account_domains or delete_domain choices[].domain_id |
user_confirmed | boolean | Must be true after explicit user confirmation before delete executes. |
workspace_id | string | Optional workspace filter when listing for picker |
delete_port
Delete a domain port by ID (zeronews delete port <id> --json). Requires login. Picker then separate explicit confirmation; final call needs user_confirmed: true.
| Parameter | Type | Description |
|---|---|---|
domain_id | string | When listing ports for picker, only ports under this domain ID |
port_id | string | Port ID from list_account_domains page.items[].ports[].id or delete_port choices[].port_id |
user_confirmed | boolean | Must be true after explicit user confirmation before delete executes. |
workspace_id | string | Optional workspace filter when listing for picker |
delete_client
Delete a client device by ID (zeronews delete client <id> --json). Requires login. Picker then separate explicit confirmation; final call needs user_confirmed: true.
| Parameter | Type | Description |
|---|---|---|
client_id | string | Client ID from list_account_clients or delete_client choices[].client_id |
user_confirmed | boolean | Must be true after explicit user confirmation before delete executes. |
workspace_id | string | Optional workspace filter when listing for picker |
enable_tunnel
Enable a tunnel by ID (zeronews tunnel enable <id> --json). Requires login. If tunnel_id is omitted, returns tunnel choices for Questions UI. Confirm with the user when appropriate.
| Parameter | Type | Description |
|---|---|---|
tunnel_id | string | Tunnel ID from list_account_tunnels or choices[].tunnel_id |
workspace_id | string | Optional workspace filter when listing for picker |
disable_tunnel
Disable a tunnel by ID (zeronews tunnel disable <id> --json). Requires login. If tunnel_id is omitted, returns tunnel choices for Questions UI. Confirm with the user when appropriate.
| Parameter | Type | Description |
|---|---|---|
tunnel_id | string | Tunnel ID from list_account_tunnels or choices[].tunnel_id |
workspace_id | string | Optional workspace filter when listing for picker |
enable_client
Enable a client device by ID (zeronews device enable <id> --json). Requires login. If client_id is omitted, returns client choices for Questions UI.
| Parameter | Type | Description |
|---|---|---|
client_id | string | Client ID from list_account_clients or choices[].client_id |
workspace_id | string | Optional workspace filter when listing for picker |
disable_client
Disable a client device by ID (zeronews device disable <id> --json). Requires login. If client_id is omitted, returns client choices for Questions UI. Confirm before disabling.
| Parameter | Type | Description |
|---|---|---|
client_id | string | Client ID from list_account_clients or choices[].client_id |
workspace_id | string | Optional workspace filter when listing for picker |
upgrade_client
Remote client upgrade (console-equivalent): precheck via zeronews device download-resolve --json; skips if already latest. Then zeronews device upgrade. Requires login. Target must be online. Omit client_id for online-device Questions picker.
| Parameter | Type | Description |
|---|---|---|
client_id | string | Client ID from list_account_clients or choices[].client_id |
workspace_id | string | Optional workspace filter when listing for picker |
list_endpoints
List ZeroNews public endpoints (zeronews endpoints --json; Local API fallback when CLI fails).
add_tunnel
Create a tunnel via zeronews add --json. Auto-installs client if missing; uses browser login when not bound. Use tunnel_kind=lfs for file share. Optional bw (Mbps) sets tunnel bandwidth limit.
| Parameter | Type | Description |
|---|---|---|
admin_password | string | |
admin_username | string | |
bw | integer | Bandwidth limit in Mbps (CLI --bw, default 1) |
domain | string | |
feature | string | |
feature_config | object | |
local_ip | string | |
mode | string | |
port | number | |
root_path | string | |
tunnel_kind | string | |
type | string |
service_install
Install zeronews as an OS service (zeronews service install).
service_start
Start the zeronews OS service (zeronews service start).
service_stop
Stop the zeronews OS service (zeronews service stop).
service_uninstall
Uninstall the zeronews OS service (zeronews service uninstall). Destructive — confirm with user first.
service_restart
Restart the zeronews OS service (zeronews service restart).
service_status
Check zeronews OS service status (zeronews service status).
client_reload
Reload client runtime (zeronews reload --json; may fallback to POST /api/v1/reconnect).
login
Open a browser confirm page (zeronews login). Installs the client if missing. Returns immediately with login_pending; then poll client_status.