CLI Commands
v3.5.10Command-line interface for YAKMESH nodes
Manage your YAKMESH node from the terminal. Initialize, start, monitor, and connect to the mesh network.
Quick Reference
All commands are available via npx yakmesh or
yakmesh if installed globally.
# Install globally for easier access
npm install -g yakmesh
Command Categories
$ Core Commands
yakmesh init
Initialize a new node
Creates a new YAKMESH node with post-quantum identity, configuration file, and data directory.
Options
| Option | Description | Default |
|---|---|---|
--name |
Human-readable node name | Auto-generated |
--region |
Geographic region identifier | Auto-detected |
--port |
HTTP API port | 3000 |
--ws-port |
WebSocket port for P2P | 9001 |
--bootstrap |
Bootstrap peer address | None |
Examples
# Basic initialization
yakmesh init
# Named node with custom ports
yakmesh init --name "himalaya-node-1" --port 8080 --ws-port 9002
# Initialize with bootstrap peer
yakmesh init --bootstrap wss://seed.yakmesh.dev:9001
# Full configuration
yakmesh init \
--name "everest-gateway" \
--region "asia-south" \
--port 3080 \
--ws-port 9001 \
--bootstrap wss://peer.example.com:9001
yakmesh start
Start the node
Starts the YAKMESH node with all services: HTTP API, WebSocket P2P, and mesh networking.
Options
| Option | Description | Default |
|---|---|---|
--config |
Path to configuration file | ./yakmesh.config.js |
--daemon |
Run as background daemon | false |
Examples
# Start with default config
yakmesh start
# Start with custom config
yakmesh start --config /etc/yakmesh/node.config.js
# Start as daemon (background process)
yakmesh start --daemon
Expected Output
Starting Yakmesh Node...
Securing codebase...
Codebase locked: 65 files protected
Initializing Oracle System...
Annex channel initialized
Yakmesh Node is running!
Network: factor-primitive-bose
Network ID: pq-EqU8
Dashboard: http://localhost:3080/dashboard
yakmesh upgrade
Apply a release package in place
Overlays an upgrade package onto the current install — the supported way to update a
running deployment. data/, node_modules/, models/,
and .git/ are never touched: persistentId, machine seed, KARMA, keys, and
your personal setup ride through untouched. Every overwritten file is backed up to
data/rollback-<ts>/, and files deleted between versions are quarantined
so the codebase fingerprint stays exact. Uses the same engine as ACT self-updates.
The same flow is on the dashboard (⬆️ Updates card): stage a package with
POST /api/update/stage, apply with POST /api/update/apply —
loopback only.
Options
| Option | Description | Default |
|---|---|---|
<package> |
Path to upgrade package — .zip (ACT package) or .tgz (npm tarball) |
required |
--dry-run |
List what would be overlaid without applying | false |
Examples
# Stop the node, then apply the downloaded package in place
yakmesh upgrade yakmesh-3.5.10.tgz
# Windows
node cli\index.js upgrade C:\share\yakmesh-3.5.10.tgz
# Preview the file list first
yakmesh upgrade yakmesh-3.5.10.tgz --dry-run
yakmesh migrate
Carry identity forward on upgrade
Copies identity and state (node key, machine seed, KARMA, manifest, content) from a
previous install into the new one — the supported way to upgrade into a fresh directory
instead of hand-linking data/ with mklink/symlinks. Verifies the
persistentId survives the copy. Same machine only —
machine-seed.json is encrypted to the hardware that created it; data migrated
to a different machine will fail to decrypt. For in-place upgrades on the same install,
prefer yakmesh upgrade.
Options
| Option | Description | Default |
|---|---|---|
<source> |
Previous install dir or its data/ dir |
required |
--to |
Target data directory | ./data |
--force |
Overwrite existing identity in target | false |
--dry-run |
List what would be copied without copying | false |
Examples
# Upgrade: unpack new version, then carry identity forward
yakmesh migrate ../yakmesh-3.5.9
# Works on the data dir directly too
yakmesh migrate C:\share\yakmesh-3.5.10-rc23\data --to .\data
# Preview first
yakmesh migrate ../old-node --dry-run
yakmesh status
Show node status
Displays the current status of your running YAKMESH node including health, peers, and network info.
Example
yakmesh status
╔══════════════════════════════════════════════════╗
║ YAKMESH NODE STATUS ║
╠══════════════════════════════════════════════════╣
║ Status: 🟢 ONLINE ║
║ Network: factor-primitive-bose ║
║ Network ID: pq-EqU8 ║
║ Uptime: 2h 34m 12s ║
║ Peers: 7 connected ║
║ Algorithm: ML-DSA-65 ║
╚══════════════════════════════════════════════════╝
yakmesh peers
List connected peers
Lists all currently connected peers with their node IDs, endpoints, and connection status.
Example Output
Connected Peers (7):
┌──────────────────────────────────────────────────────────────┐
│ ID │ Endpoint │ Latency │ Trust │
├──────────────────────────────────────────────────────────────┤
│ node-a7f3...2b1e │ wss://peer1:9001 │ 12ms │ 0.95 │
│ node-c4d8...9f2a │ wss://peer2:9001 │ 45ms │ 0.87 │
│ node-b2e6...1c4f │ 192.168.1.5:9001 │ 2ms │ 0.99 │
└──────────────────────────────────────────────────────────────┘
yakmesh info
Show detailed node info
Displays comprehensive information about your node including identity, capabilities, and configuration.
Example Output
🦬 Node Information:
Identity:
Node ID: node-walk-forest-infinity-pq-xwEL
Name: himalaya-node-1
Region: local
Algorithm: ML-DSA-65 (NIST Level 3)
Created: 2026-09-21T15:01:22.000Z
Capabilities:
• SHERPA
• NAKPAK
• GEO_PROOF
Replication:
Log entries: 12
Peer states: 1
Tables: dokos, attestations
Public Key (ML-DSA-65):
8f3a2b1ec4d8a2f9b1ce5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b...
yakmesh join <endpoint>
Connect the running node to a peer
Connects your running node to a peer over its WebSocket endpoint
(ws:// or
wss://).
The handshake includes NAMCHE identity verification and the ANNEX
post-quantum session; SAMUHA admission may return ADMIT, HOLD, or
REDIRECT depending on the peer's capacity.
Examples
# Connect to a peer on the LAN
yakmesh join ws://192.168.1.100:9080
# Against a node on a non-default HTTP port
yakmesh join ws://192.168.1.100:9080 -p 3081
# Join at startup instead — bootstrap peers via env or config:
YAKMESH_BOOTSTRAP=ws://192.168.1.100:9080 yakmesh start
# bootstrapPeers: ['ws://192.168.1.100:9080']
Output
✓ Connected to ws://192.168.1.100:9080
# or, if the peer cannot be reached / rejects:
✗ Failed to connect: <reason>
$ Protocol Commands
Manage the yak:// protocol handler for system-wide mesh URL support.
yakmesh protocol register
Register yak:// protocol
Registers the yak:// protocol with your operating system.
Enables clicking yak:// links in browsers and applications.
Example
yakmesh protocol register
✓ Protocol yak:// registered successfully
Handler: /usr/local/bin/yakmesh
Test with: yakmesh protocol test yak://hello
Note: On Windows, this modifies the registry. On macOS/Linux, it updates protocol handlers. May require elevated permissions.
yakmesh protocol unregister
Unregister protocol
Removes the yak:// protocol handler from your system.
yakmesh protocol unregister
✓ Protocol yak:// unregistered
yakmesh protocol test <url>
Test yak:// URL
Parses and validates a yak:// URL without executing it. Useful for debugging.
Examples
# Test a simple URL
yakmesh protocol test yak://node-a7f3/resource
# Test with query parameters
yakmesh protocol test "yak://gateway.local/api/status?format=json"
{
"valid": true,
"parsed": {
"protocol": "yak:",
"host": "node-a7f3",
"path": "/resource",
"query": {}
}
}
yakmesh protocol open <url>
Open yak:// URL
Opens a yak:// URL, routing through the mesh network to the target resource.
Examples
# Open a mesh resource
yakmesh protocol open yak://peer-node/dashboard
# Open with path
yakmesh protocol open yak://gateway/api/health
$ Bookmark Commands
Save and manage yak:// bookmarks for quick access to frequently used mesh resources.
yakmesh protocol bookmark add <name> <target>
Add a bookmark
Creates a named shortcut to a yak:// URL or mesh resource.
Examples
# Bookmark a dashboard
yakmesh protocol bookmark add dashboard yak://local/dashboard
# Bookmark an API endpoint
yakmesh protocol bookmark add health-check yak://gateway/api/health
# Bookmark external node
yakmesh protocol bookmark add main-peer yak://node-a7f3.yakmesh.dev/
✓ Bookmark 'dashboard' added → yak://local/dashboard
yakmesh protocol bookmark remove <name>
Remove a bookmark
yakmesh protocol bookmark remove dashboard
✓ Bookmark 'dashboard' removed
yakmesh protocol bookmark list
List all bookmarks
yakmesh protocol bookmark list
Bookmarks:
┌────────────────┬─────────────────────────────────────┐
│ Name │ Target │
├────────────────┼─────────────────────────────────────┤
│ dashboard │ yak://local/dashboard │
│ health-check │ yak://gateway/api/health │
│ main-peer │ yak://node-a7f3.yakmesh.dev/ │
└────────────────┴─────────────────────────────────────┘
yakmesh protocol bookmark get <name>
Get bookmark target
yakmesh protocol bookmark get dashboard
yak://local/dashboard
$ Geographic Commands
Manage geographic proof of location using speed-of-light verification. See Geographic Proof documentation for details.
yakmesh geo status
Geographic proof status
Shows the current geographic verification status and location proof.
yakmesh geo status
Geographic Proof Status:
Verified: ✓ Yes
Region: asia-south
Confidence: 94.2%
Last Proof: 2024-01-15T10:30:00Z
Landmarks Used: 4
Triangulation:
• Singapore (12ms) ✓
• Tokyo (45ms) ✓
• Sydney (89ms) ✓
• Mumbai (8ms) ✓
yakmesh geo landmarks
List landmarks
Lists all known geographic landmarks used for triangulation.
Known Landmarks (12):
┌──────────────────┬──────────────────┬─────────┬──────────┐
│ Name │ Location │ Status │ Latency │
├──────────────────┼──────────────────┼─────────┼──────────┤
│ landmark-sgp │ Singapore │ 🟢 Up │ 12ms │
│ landmark-tyo │ Tokyo │ 🟢 Up │ 45ms │
│ landmark-syd │ Sydney │ 🟢 Up │ 89ms │
│ landmark-mum │ Mumbai │ 🟢 Up │ 8ms │
│ landmark-fra │ Frankfurt │ 🟢 Up │ 156ms │
│ landmark-nyc │ New York │ 🟡 Slow │ 234ms │
└──────────────────┴──────────────────┴─────────┴──────────┘
yakmesh geo zones
List exclusion zones
Lists configured geographic exclusion zones where connections are restricted.
yakmesh geo zones
yakmesh geo prove
Generate geographic proof
Initiates a new geographic proof generation by triangulating against known landmarks.
yakmesh geo prove
🌍 Generating geographic proof...
Pinging landmark-sgp... 12ms ✓
Pinging landmark-tyo... 45ms ✓
Pinging landmark-syd... 89ms ✓
Pinging landmark-mum... 8ms ✓
✓ Proof generated successfully
Region: asia-south
Confidence: 94.2%
Proof ID: geo-proof-7f3a2b1e
yakmesh geo verify <nodeId>
Verify another node
Requests and verifies the geographic proof from another node.
yakmesh geo verify node-a7f3
🔍 Verifying geographic proof for node-a7f3...
Claimed region: europe-west
Verification landmarks: 3
✓ Location verified
Confidence: 91.7%
Distance to claimed: ~50km
Proof valid: Yes
yakmesh geo add-landmark
Add a landmark
Adds a new landmark server for geographic triangulation.
yakmesh geo add-landmark --name "my-landmark" --endpoint "wss://landmark.example.com:9001" --location "40.7128,-74.0060"
yakmesh geo physics
Show speed-of-light constants
Displays the physical constants used for geographic proof calculations.
yakmesh geo physics
{
"speedOfLight": 299792458,
"fiberRefractionIndex": 1.47,
"effectiveSpeed": 203940108,
"minTriangulationPoints": 3,
"maxAcceptableDeviation": 0.15,
"units": {
"speed": "m/s",
"distance": "km",
"time": "ms"
}
}
How it works: Geographic proof uses the speed of light through fiber optic cables to verify that a node's claimed location is physically consistent with its measured latencies.
Continue Exploring
- REST API Reference — HTTP endpoints for programmatic access
- YAK:// Protocol — Custom URL scheme details
- Geographic Proof — Speed-of-light verification
- Configuration — Full config file reference
Provenance full version history →
Introduced in v1.0.2 — Initial CLI.
- v2.1.0 — Bookmark CLI commands
- v2.2.0 — Remote bookmark + domain transfer commands