vyomi-tunnel 1.3.2 → 1.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -69,16 +69,49 @@ ssh -i ~/.ssh/vyomi-<instance>.pem -p 22000 ec2-user@127.0.0.1
69
69
  `GET /health` lists `"vm-tcp"` in `features` and the bridged VMs under `vms`.
70
70
  Port range: `VM_PORT_MIN` / `VM_PORT_MAX`.
71
71
 
72
- ## Agents: the Vyomi MCP server (1.3.0+)
72
+ ## Agents: the Vyomi MCP server (1.3.0+): Claude Code, Cursor, VS Code, Codex
73
73
 
74
74
  `vyomi-tunnel mcp` runs the Vyomi MCP server on stdin/stdout for Claude Code and
75
75
  other agents. The package bundles it for macOS (arm64, x64), Linux (arm64, x64) and Windows
76
76
  (x64), so there is nothing else to install:
77
77
 
78
+ Claude Code (the Vyomi plugin adds this server plus setup skills: `claude plugin install vyomi@vyomi`):
79
+
78
80
  ```bash
79
81
  claude mcp add vyomi -- vyomi-tunnel mcp
80
82
  ```
81
83
 
84
+ Cursor: `~/.cursor/mcp.json` (all projects) or `.cursor/mcp.json` (one project):
85
+
86
+ ```json
87
+ { "mcpServers": { "vyomi": { "command": "vyomi-tunnel", "args": ["mcp"] } } }
88
+ ```
89
+
90
+ VS Code (Copilot agent mode): `.vscode/mcp.json` in the project, or `code --add-mcp '{"name":"vyomi","command":"vyomi-tunnel","args":["mcp"]}'`:
91
+
92
+ ```json
93
+ { "servers": { "vyomi": { "type": "stdio", "command": "vyomi-tunnel", "args": ["mcp"] } } }
94
+ ```
95
+
96
+ The portable `.mcp.json` at the project root uses the Cursor shape (`mcpServers`) and works across tools that read it.
97
+
98
+ OpenAI Codex (CLI, IDE extension and app share `~/.codex/config.toml`):
99
+
100
+ ```bash
101
+ codex mcp add vyomi -- vyomi-tunnel mcp
102
+ ```
103
+
104
+ ```toml
105
+ [mcp_servers.vyomi]
106
+ command = "vyomi-tunnel"
107
+ args = ["mcp"]
108
+ ```
109
+
110
+ Editors started from the Dock or Start menu may not see your shell's `PATH`. If the server does not start, use the
111
+ full path from `which vyomi-tunnel` (Windows: `where vyomi-tunnel`) as `command`. Every client gets the same tools and
112
+ the same built-in instructions (including: never write `.env.vyomi` without your yes); the setup skills are Claude
113
+ Code's plugin only.
114
+
82
115
  It finds your simulator (the Nano tab through this tunnel, a local mesh, or your
83
116
  Mesh Codespace), says which one it uses, and gives SDK settings, capability levels
84
117
  and examples for it. It needs no access key; only live Mesh Codespace details do
@@ -48,7 +48,7 @@ const friendly = (portal) => ({
48
48
  Throttled: "too many requests; wait a moment and retry.",
49
49
  });
50
50
 
51
- export async function fetchSession({ creds, fetchFn = globalThis.fetch, now = () => new Date(), version = "1.3.2" }) {
51
+ export async function fetchSession({ creds, fetchFn = globalThis.fetch, now = () => new Date(), version = "1.3.3" }) {
52
52
  const path = "/api/tunnel/session", body = JSON.stringify({ client: "vyomi-tunnel/" + version });
53
53
  const date = now().toISOString().replace(/\.\d+Z$/, "Z");
54
54
  let r;
@@ -16,7 +16,7 @@ export const ALLOWED_ORIGINS = [/^https:\/\/(www\.)?vyomi\.cloud$/, /^https?:\/\
16
16
  export const originAllowed = (origin) => !origin || ALLOWED_ORIGINS.some((re) => re.test(origin));
17
17
  export const hostIsLoopback = (host) => /^(localhost|127\.0\.0\.1|\[::1\])(:\d+)?$/i.test(String(host || ""));
18
18
 
19
- export function createCredsSync({ env = process.env, fetchFn = globalThis.fetch, version = "1.3.2", log = () => {}, intervalMs = 300000, now = () => Date.now() } = {}) {
19
+ export function createCredsSync({ env = process.env, fetchFn = globalThis.fetch, version = "1.3.3", log = () => {}, intervalMs = 300000, now = () => Date.now() } = {}) {
20
20
  const home = env.VYOMI_HOME || join(homedir(), ".vyomi");
21
21
  const file = env.VYOMI_CREDENTIALS_FILE || join(home, "credentials");
22
22
  let st = { state: "unknown", key_id: "", portal: "", checked_at: 0, error: "" };
package/bin/mesh-cli.mjs CHANGED
@@ -365,7 +365,7 @@ export async function main(argv) {
365
365
  if (!cmd || ["help", "-h", "--help", "-help", "-?"].includes(cmd) || rest.some((a) => ["-h", "--help", "-help"].includes(a))) { const topic = cmd === "help" ? rest[0] : (["-h", "--help", "-help", "-?"].includes(cmd) ? undefined : cmd); const t = topic && DETAILS[topic];
366
366
  if (topic && !t) { console.error(`vyomi-tunnel: no help for "${topic}".`); process.stdout.write(HELP); return 2; }
367
367
  process.stdout.write((t || HELP) + (t ? "\n" : "")); return cmd ? 0 : 2; }
368
- if (cmd === "--version" || cmd === "-v" || cmd === "version") { console.log(process.env.VYOMI_TUNNEL_VERSION || "vyomi-tunnel 1.3.2"); return 0; }
368
+ if (cmd === "--version" || cmd === "-v" || cmd === "version") { console.log(process.env.VYOMI_TUNNEL_VERSION || "vyomi-tunnel 1.3.3"); return 0; }
369
369
  const WS = createRequire(import.meta.url)(process.env.WS_PKG || "ws");
370
370
  // Mesh over the user's own ssh session (`--codespace <name>` or VYOMI_MESH_CODESPACE): no relay, no token (mesh-ssh.mjs).
371
371
  const ci = rest.indexOf("--codespace");
@@ -447,7 +447,7 @@ export async function main(argv) {
447
447
  if (!/^[A-Za-z0-9_-]{20,64}$/.test(code)) { console.error("usage: vyomi-tunnel reset <code> (get a code in the Vyomi console: Setup Tunnel > Get install command; see `vyomi-tunnel help reset`)"); return 2; }
448
448
  const { createCredsSync } = await import("./creds-sync.mjs");
449
449
  try {
450
- const cs = createCredsSync({ version: process.env.VYOMI_TUNNEL_VERSION_NUM || "1.3.2" });
450
+ const cs = createCredsSync({ version: process.env.VYOMI_TUNNEL_VERSION_NUM || "1.3.3" });
451
451
  const st = await cs.reset(code, os.hostname());
452
452
  console.log(st.state === "ok" ? `Done. The tunnel now uses access key ${st.key_id}.` : `The new key was saved (${st.key_id}) but the portal answered: ${st.error || st.state}.`);
453
453
  try { await fetch(`http://127.0.0.1:${process.env.RELAY_PORT || 8090}/reload`, { method: "POST", signal: AbortSignal.timeout(3000) }); console.log("The running tunnel reloaded it."); }
@@ -86,7 +86,7 @@ if (process.argv[2]) {
86
86
 
87
87
  // The tunnel keeps running even when its key is missing, revoked or wrong (a service manager would crash-loop it otherwise): the state is
88
88
  // shown on /health, re-checked on a timer and when ~/.vyomi/credentials changes, and the Vyomi page can re-pair it (POST /reset).
89
- const VERSION = "1.3.2";
89
+ const VERSION = "1.3.3";
90
90
  const credsSync = createCredsSync({ version: VERSION, log: (m) => console.log("[creds] " + m) });
91
91
  const PORT = Number(process.env.RELAY_PORT || 8090);
92
92
  if (!Number.isInteger(PORT) || PORT < 1 || PORT > 65535) { console.error(`vyomi-tunnel: ${friendlyError({ code: "ERR_SOCKET_BAD_PORT" })}`); process.exit(2); }
Binary file
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vyomi-tunnel",
3
- "version": "1.3.2",
3
+ "version": "1.3.3",
4
4
  "description": "Vyomi-Nano local reverse-tunnel — reach the in-browser cloud simulator from any local SDK/CLI. The install-once, zero-cloud counterpart to the hosted Cloudflare relay; the Nano tab auto-detects it and prefers it.",
5
5
  "type": "module",
6
6
  "bin": {