CLI Reference
The meshive command groups read operations into a handful of subcommands. Run meshive with no arguments (or meshive --help) to print usage.
meshive --versionmeshive me # current API key's ownermeshive workspaces # list workspacesmeshive pods <workspace> # list pods in a workspacemeshive pods --all # list pods across every workspacemeshive pod <workspace> <pod> # show a single podmeshive machines # list your machines (as a host)meshive machine <id> # show a single machineGlobal options
Section titled “Global options”Every subcommand (except --version) accepts these:
| Option | Description |
|---|---|
--api-key <key> | Meshive API key. Overrides MESHIVE_API_KEY and the saved login. |
--json | Emit the raw API JSON instead of the formatted table. Disables color. |
Authentication commands
Section titled “Authentication commands”meshive login
Section titled “meshive login”Prompts for your API key (hidden input), verifies it against the API, and saves it to ~/.meshive/credentials.json. Accepts --api-key to skip the prompt.
meshive loginmeshive logout
Section titled “meshive logout”Removes the saved credentials file.
meshive logoutSee Authentication for key resolution.
meshive me
Section titled “meshive me”Shows the owner of the current API key — email, username, and role. Alias: whoami.
meshive meemail: you@example.comusername: yourole: usermeshive workspaces
Section titled “meshive workspaces”Lists the workspaces you can access. Alias: ws.
meshive workspacesColumns: NAME (display label), ID (namespace name — the value you pass to pods/pod), STATUS, PODS (pod count), PRICE/HR.
meshive pods
Section titled “meshive pods”Lists pods in a workspace, or across all workspaces with --all.
meshive pods <workspace> # one workspace (by ID)meshive pods --all # every workspace (adds a WORKSPACE column)Columns: NAME, ID, (WORKSPACE with --all), STATUS, RENTAL, PRICE/HR, CREATED. Price is shown only for running pods (stopped/waiting pods aren’t billed).
Filters
Section titled “Filters”Filtering is client-side — the API returns the full list and the CLI narrows it.
| Flag | Description |
|---|---|
--status | Filter by status. Repeatable or comma-separated, e.g. --status running,error. |
--rental | spot or demand. |
--name | Substring match on the display name (alias). |
meshive pods <workspace> --status runningmeshive pods <workspace> --status running,error # comma-separated…meshive pods <workspace> --status running --status error # …or repeatedmeshive pods <workspace> --rental spotmeshive pods <workspace> --name llamaValid pod statuses (an unknown value is rejected with the list, rather than silently returning nothing):
pending creating running waiting stoppingstopped error unreachable terminating terminatedmeshive pod
Section titled “meshive pod”Shows a single pod in detail.
meshive pod <workspace> <pod>Both arguments are IDs — the workspace’s namespace name and the pod’s name (the ID column from meshive pods), not the display aliases. Output includes name, id, workspace, status, rental, price/hr, created time, and a maintenance notice when the pod is under maintenance.
meshive machines
Section titled “meshive machines”Lists the machines you contribute to the network as a host. No workspace is needed — a host owns its machines directly. Alias: m.
meshive machinesColumns: NAME, ID, TYPE, STATUS, GPU (e.g. 8x NVIDIA H100), EARN/HR, UPTIME.
Filters
Section titled “Filters”| Flag | Description |
|---|---|
--type | gpu, cpu, or storage. |
--status | Filter by status (repeatable or comma-separated), e.g. online,offline. |
--name | Substring match on the display name. |
meshive machines --status onlinemeshive machines --type gpumeshive machines --name node-ameshive machine
Section titled “meshive machine”Shows a single machine in detail.
meshive machine <id>The argument is the machine ID (the ID column from meshive machines). Output includes name, id, type, status, gpu, earn/hr, uptime, and host tier.
IDs vs names
Section titled “IDs vs names”List output shows two columns, and the distinction matters:
- ID — the canonical identifier (
namespace_namefor workspaces,pod_namefor pods, the machine id for machines). This is what you pass tomeshive pods <id>/meshive pod <id> <id>/meshive machine <id>. It is unique and stable. - NAME — the display alias you set. It is a label, not a key: it is not guaranteed unique and can change. Use
--nameto filter by it, but always address resources by their ID.
Exit codes
Section titled “Exit codes”| Code | Meaning |
|---|---|
0 | Success. |
1 | An API/auth error, or a missing/invalid API key. |
2 | Bad arguments (e.g. an unknown --status, or both a workspace and --all). |