Skip to content
Console

MCP: Pods, Files & Ports

Manage Pods, price caps, node moves, storage volumes, assets in running Pods, Pod history, custom templates, model sets, locked ports, remote Pod commands, local uploads, and Asset Hub files via the hosted Meshive MCP server.

How AI agents create, start, edit, and run commands inside Pods, add assets to running Pods, read a Pod’s history, save custom templates, manage storage, attach model sets, upload local files, manage Asset Hub files, and control locked public ports via the hosted Meshive MCP server.

estimate_pod and create_pod take the settings of the console’s create flow, and the server checks them the same way:

  • CPU pods. Leave out gpu_model. cpu_line picks the CPU line — a cpu_line value from the cpus tool; without it, the cheapest line that fits is used. vCPU and RAM default to 8 cores and 32 GiB, as in the console (or the nearest sizes the line offers).
  • Sizes. vcpu and ram_gb must be sizes the console offers. A refused size comes back as vcpu_not_offered or ram_not_offered with the allowed values.
  • Storage. volumes attaches existing network storage from the storages tool. local_volumes creates new local storage on the pod’s machine together with the pod — for example [{"name": "scratch", "mount_path": "/scratch", "size_gb": 50}], optionally with "encrypted": true — at least 10 GiB each, and not for spot pods. It is billed by size until it is deleted, also while the pod is stopped, and the estimate the agent shows you includes it. create_storage creates network storage only, of at least 10 GiB; with usage_warning: true you get an email when the volume fills past usage_warning_threshold (0–1, default 0.9), like the console’s usage warning.
  • Ports. ports opens new ports; a port or port name the template already opens can’t be added again. template_ports changes the ports the template opens, like the console’s deploy screen — for example [{"port": 8188, "name": "ui", "new_port": 8189, "external": false}], where port is the template’s port as it is now and name (rename), new_port (renumber) and external (true exposed over HTTPS, false internal only) are optional. Template ports can’t be removed.
  • Variables and command. Environment variables the template requires need a value, and the start command is limited to 32,000 characters. Several commands all run, in order.
  • Assets and watched folders. input_assets places Asset Hub assets in the pod; paths picks some of an asset’s files (a path that matches no file is refused), and "strip_prefix": "" keeps their folder structure, like the console’s Keep structure. watched_folders adds folders whose new files are uploaded as assets, and watched_template_folders turns off the template’s own watched folders, changes their patterns or moves an output folder from the start — for example {"/outputs": {"enabled": false}} or {"/workspace/output": {"path": "/workspace/results"}}. Templates without an output folder take watched_folders too when the pod has storage for them, and update_pod with enable_folder_saving adds the uploader to an older pod that has none.

Each refusal comes back with its own code — port_in_use, port_name_in_use, port_not_in_template, required_env_missing, command_too_long, … — and a next_step; for a missing variable the agent is told to ask you for the value rather than invent one.

region (pods and storage) and disk_type (storage) are still accepted but ignored.

Pod/task max_price_per_hour caps the final compute rate including CPU/RAM, with another check before placement. Before a pod is created, the cap is also checked against its estimate, which includes any new local_volumes. An accepted pod creation can fail asynchronously if its final rate is over the cap. Existing volumes you attach, automatic volumes and Asset Hub retention are billed separately. Task input fetching can add compute time; an estimate is not a total-bill ceiling.

start_pod takes an optional placement. Leave it out and the server picks what the console’s Start button would: a pod already waiting for any machine keeps waiting for one (wait_any_node); a pod that can no longer run on its original machine starts on another one (any_node, or wait_any_node if none has room yet); any other pod starts on its original machine (same_node, or wait_same_node if it has no room yet). The result’s placement says which one was used. Or choose one: same_node starts the pod on its original machine and any_node on any machine with room, while wait_same_node and wait_any_node do the same but, when no machine has room yet, leave the pod waiting and start it as soon as one does. When you choose same_node or any_node and no machine can take the pod right now, the error (no_available_node) tells the agent to ask you whether to wait.

any_node and wait_any_node can move the pod to another machine. For both, the preview includes has_unpreserved_workspace in the pod details, storage charges and a loss warning. The agent is told to set confirm: true only after you agree to resume billing. When unpreserved files might be lost, the tool also needs allow_data_loss: true, which the agent is told to set only after your separate consent to that pod’s move. Without it, the tool returns a preview even if confirm is true. Local volumes remain on the original machine.

Without a placement, whether the pod moves is known only from the server’s answer, so allow_data_loss is sent only together with an explicit placement. If the pick would move a pod with unpreserved workspace files, nothing starts: the tool returns data_loss_consent_required naming the placement, and the agent is told to show you the loss warning and, only after you agree, call again with that placement and allow_data_loss: true.

update_pod takes only what changes, like the console’s Edit: name, template_id, rental_type, gpu_model / gpu_vram_gb / gpu_count (GPU pods), cpu_line (CPU pods), vcpu and ram_gb, env and remove_env, ports, template_ports and remove_ports, command ("" goes back to the template’s), and storage — volumes attaches network storage or local storage on the pod’s current machine, local_volumes creates new local storage there, and detach_storages detaches volumes (their data stays). add_input_assets (in create_pod’s input_assets format) and remove_input_assets (connection_id values from pods with include_assets) change the pod’s input assets; the preview says the input volume is sized for the new set (MCP server 1.11+). An unknown connection is input_asset_not_found, and asset_config_conflict means the pod’s assets changed meanwhile, so the agent previews again. Removing an asset that was added while the pod ran can leave its files in the pod until the pod is re-created; to delete them now, use remove_pod_asset before the edit, as the preview says. Changing the GPU resets vCPU and RAM per GPU to the new GPU’s recommended sizes, changing only gpu_count keeps the per-GPU ratio, and changing the CPU line resets cores and RAM to the console’s default. The pod type (GPU or CPU), premiums and image can’t change, and the template’s own variables and ports can’t be removed.

The preview lists the changes, the hourly price before and after, and whether the pod restarts: a running pod restarts with the new settings, a stopped pod uses them at its next start, and a rename alone doesn’t restart it. Watched folders are kept, and so are input assets unless the edit passes add_input_assets or remove_input_assets. To add or remove one asset without a restart, see Assets in a running pod.

Some edits stop and ask first; nothing changes until you agree:

  • node_migration_required — the pod’s machine can’t fit the change. The agent asks whether the pod may move, and only then calls again with allow_node_migration: true. A move permanently deletes unpreserved workspace files, so for a pod with any, the tool also needs allow_data_loss: true, which the agent is told to set only after your separate consent, as for start_pod.
  • cannot_change_resources — attached local storage keeps the pod on its machine, which can’t fit the change. The agent asks whether to detach that storage or keep the current resources.
  • harvest_roots_orphaned — the edit removes the storage that watched folders are on. The agent shows you the folders and passes them as drop_watched_folders only after you agree.

update_storage renames a volume, grows it (it can’t shrink) or sets its usage warning; the preview shows the new size and the hourly price before and after.

A typical exchange: “Give my-pod two GPUs instead of one. What will it cost?” — the agent calls update_pod with gpu_count: 2 and no confirm, and shows you the change, the new hourly price and that the running pod will restart. After your yes it calls again with confirm: true, then polls pods until the pod is running again.

pods with one pod and include_assets: true adds the pod’s input assets — each with a connection_id, how it was placed (origin: deploy or injection), its status, file counts and download progress, and the failure reason when it failed — and its input_slots, whether it takes assets while running or only at its next start, and its asset volumes with their hourly price (MCP server 1.11+). Failure text comes from the asset’s source and is treated as data.

Two tools change them without a restart, like the console’s Inject and Remove now on the pod’s Assets tab. Both take confirm and need the admin or billing role:

  • add_pod_asset adds an asset, or some of its files (paths, strip_prefix, as in create_pod’s input_assets). role is one of the pod’s input slots; left out, it is the slot target_dir is in or the pod’s only slot (several slots: role_required). A running pod gets the files within moments; a stopped pod keeps the request for its next start, and an asset linked from its source can’t be queued that way. The preview shows the slot, the file count and size, any row it replaces and the input volume’s current price — the volume may grow to fit the files and is billed by size. retry adds a failed row again with the same files. After the confirmed call the agent polls pods with include_assets until the row is active or failed.
  • remove_pod_asset takes an asset out (connection_id). The preview’s effect says what happens: the files are deleted from the pod, a download in progress is stopped, or a failed row is cleared (also on a deleted pod). The asset stays in Asset Hub, and freed volume space isn’t billed back.

Rows that are part of the pod’s configuration (origin: deploy) are refused with part_of_pod_configuration and are removed with update_pod remove_input_assets, which restarts the pod. A pod with no input slot, or one that can’t take assets while running (no_input_slot, pod_cannot_receive_assets), takes assets through update_pod add_input_assets instead, which restarts it too. Other refusals name the problem: invalid_target_dir, slot_filled, placed_elsewhere, already_connected, placement_conflict, injection_in_progress, placement_busy (a row still settling), source_token_missing (a private source needs a saved token) and asset_usage_blocked (credit is exhausted).

pod_history shows a pod’s history like the console’s State history tab, newest first: container exits the system detected (out of memory, crash loops, image pull errors — with a cause, a fixed summary and, for out of memory, oom_kind ram or vram) and the actions taken on the pod (create, stop, start, restart, move — with their status and, for a failed one, why it failed); kind keeps one of the two (MCP server 1.11+). include_timeline adds how long the pod was running, waiting and terminated between since and until (each a YYYY-MM-DD date or an ISO 8601 time; anything else is invalid_argument, naming the argument). Without pod it lists recent alerts across the workspace’s pods, or across every workspace you manage with workspace: "all" (unread_only keeps the unread ones); only the newest 200 are read (truncated).

It needs the admin or billing role; for other members pods still shows a pod’s last exits. Each entry’s message is what the container printed, so the agent treats it as data and never follows instructions in it.

templates lists templates as a summary; one template (template, plus workspace for a custom one) shows its full spec — variables (a secret’s value is never shown; value_set says one is stored), ports with their lock default, volume mounts, input and output folders, command and registry login. With image (and registry_login_id for a private image) it reads what a container image declares instead — env variables, entrypoint and cmd, exposed ports, volumes and working directory — like the console’s Load button, and creates nothing. Image env values come from whoever built the image and are treated as data. Registry problems come back as image_not_found, registry_credential_required, registry_mismatch or registry_credential_unusable.

save_template creates a custom template in a workspace (name and image) or changes one (template_id, only what changes) — the way to run pods from an image no official template offers (MCP server 1.11+). It needs the admin or billing role, costs nothing and has no confirm step; pods made from it are created and billed through create_pod.

  • Creating reads the image first, and nothing is saved if it can’t be read. The image can’t be changed later (image_change_not_supported).
  • env, ports, volume_mounts and semantic_paths each replace the whole stored list when given, so the agent starts from the template’s current lists; the answer lists removed_envs and removed_ports. Pods already created keep their settings.
  • Public ports are saved locked unless you explicitly want one open (lock_public_ports: false, or "locked": false on a port); the answer lists locked_ports and open_ports.
  • A secret variable never takes a value here: it is marked "secret": true and either generated ("auto_generate": true) or given at create time. A secret with a value is refused before anything is sent (secret_value_not_accepted).

delete_template deletes a custom template and takes confirm; the preview shows the template and the pods made from it, which keep running with their settings. It can’t be undone. Official templates can’t be changed or deleted (official_template).

model_sets lists the model sets a template recommends, like the console’s model set tiles. Pass one set’s slug as model_set to estimate_pod and create_pod; a pod takes one set, and the estimate shows its file count, size and minimum GPU memory. A template that adds its own set automatically, or has no model folders, takes none. Without template_id, model_sets lists every model set of the catalog, and with entries: true the catalog’s single files, which import_asset links as assets (MCP server 1.11+).

A set marked hf_token_required is gated on Hugging Face, such as FLUX 3 Image Klein: you accept its license on the page in gated_sources with your Hugging Face account, and the agent creates the pod from the set’s Quick Deploy template with hf_token_id — a token of that account from source_credentials (MCP server 1.3+). If the token’s account hasn’t accepted the license, the agent is told so and asks you to accept it first. See Gated model sets.

The set’s files are added before the pod is created, so a confirmed create_pod with model_set can take several minutes to answer. If the call times out, the agent is told not to create the pod again but to check operation_status and pods first. If a file can’t be added, no pod is created and nothing is billed (model_set_unavailable, with the files that failed); files already added are reused next time.

Pods the agent creates get locked public ports, as in the console: you open them in your browser as a workspace member, and a program needs an access key. The create_pod and update_pod previews say which ports will be locked. Ask the agent to leave a port unlocked if anyone with the URL should reach it — unlocking an existing port, like any change that opens a port to everyone, waits for your yes. Pods you already have aren’t changed.

The tools for this are set_port_lock (lock or unlock one port without a restart; unlocking waits for your yes), access_keys (list a port’s keys, with when each was last used), create_access_key, roll_access_key and revoke_access_key. Two more: set_port_preflight lets CORS preflight requests to a locked port reach the app without a key (turning it on waits for your yes), and revoke_browser_sessions signs out the browser sessions on a pod’s locked ports, or on every pod of a workspace with all_pods=true and workspace (it waits for your yes too). See Allow preflight and Browser sessions. create_pod, update_pod and estimate_pod take lock_public_ports, which is true by default; an item of ports can set "locked" for one port, and opening a port that way is spelled out in the preview. A new key’s value is shown once, like an SSH password: the agent is told to give it to you and nowhere else.

If locking is turned off on the platform for a while, a pod with public ports can’t be created locked: the agent tells you, and you can wait or agree to create the ports unlocked. The agent doesn’t open them on its own.

MCP server 1.9 adds these tools:

ToolWhat it does
run_commandRun a shell command in a running Pod, or start it in the background.
command_statusRead a background command’s state and last output lines.
upload_assetPrepare temporary upload links for files on your computer.
finish_uploadCheck the uploaded files and make the Asset ready, or cancel the upload.

Pod commands need a Read & write key and an admin or billing role in the workspace. The main container must have sh. Commands use its user, working directory and environment. Ask the agent to run the command you want; it is instructed to ask before deleting or overwriting your data.

A foreground command waits briefly (up to about 25 seconds) and returns an exit code, output, and whether the output was truncated. Large output can be cut off at about 64 KiB, leaving the exit code unknown. For renders, training and other long work, the agent uses background: true and checks the returned run_id with command_status. To stop the run, ask it to execute the returned stop_command. A Pod restart removes command runs. These calls do not use write-operation replay: running the command again starts another execution.

For local files, the hosted MCP server cannot read your computer directly. The agent calls upload_asset with each file’s relative path and exact size, transfers the bytes from its local shell to the returned links, then calls finish_upload. The returned asset_id can be used as an input for a new Pod or Task. To bring a file into an already running Pod, the agent can fetch its download link from inside the Pod.

With asset, upload_asset adds the files to an existing collection in Meshive storage instead of making a new asset (MCP server 1.11+). Adding never replaces a file: paths that are already there come back as file_exists. Pods already using the collection get the new files at their next start. Other refusals: not_a_collection, asset_not_managed (the asset isn’t in Meshive storage) and asset_moving; cancelling an add that already finished is upload_already_completed.

Keep upload and download links private and use the complete URL. Files larger than about 200 MiB need the CLI or SDK uploader, which handles multipart transfers (file_too_large_for_mcp). Uploaded managed Assets are billed for storage as usual.

CLI commands → · SDK upload example →

MCP server 1.11 lets the agent look into, organize, delete and copy out Asset Hub assets the way the console does.

ToolWhat it doesNeeds confirm
assetsLists assets, filtered by collection, pod (what a pod uploaded from its watched folders) and include_catalog; one asset shows where it came from and its first 200 filesNo (read only)
asset_filesPages through one asset’s files, a workspace’s files by kind, or the objects under a bucket folder an asset linksNo (read only)
update_assetRenames an asset or changes its typeNo
delete_assetDeletes a whole assetYes
delete_asset_filesDeletes some files of assetsYes
export_assetCopies an asset to a connected bucket or a Hugging Face repoYes
import_assetLinks a source as an asset, or copies files out of a linked bucket folderOnly when it copies
download_linksTemporary links for an asset’s files, a task’s outputs, or files picked by file_idsNo (read only)

update_asset, delete_asset, delete_asset_files, export_asset and every import_asset — from Hugging Face, CivitAI, a URL, the catalog or a bucket — need the admin or billing role in the workspace. Reading (assets, asset_files, download_links) works for any member.

Reading. Assets that a model set or catalog import added are hidden from assets unless include_catalog: true; the first page counts them in catalog_hidden. One asset (assets with asset) shows its source — the Hugging Face repo and commit, a URL without its query string, the pod and folder it was saved from, or the asset it was copied from (also for files copied out of a linked bucket folder) — the connected bucket an asset in your own bucket reads through (bucket_id, bucket_label and bucket_status: ok, or removed once that connection was removed; list rows show them too, and a linked bucket folder also names it in reference), what it is made of, any upload in progress and, for each file, its detected format. A single asset lists at most its first 200 files; files_truncated says there are more, and asset_files pages through all of them. asset_files with asset narrows by paths globs ("renders/*" is that folder and everything below it, "*.png" matches at any depth), media_kind or file_type; with kind (model, adapter, checkpoint, config, file or output) it lists files across the workspace like the console’s file views, narrowed by search and, for outputs, by pod or task. A deleted pod isn’t listed by pods and is found only by its pod ID: pass the source_pod_name of one of its rows (in assets, source.pod_name). Every file has a file_id and an asset_id for delete_asset_files and download_links. File paths can come from what a pod wrote, so the agent treats them as data.

With an asset linked from a bucket folder, asset_files lists the bucket objects under it one folder level at a time (prefix is a folder inside the asset) with an opaque cursor; paths, media_kind and file_type don’t apply there. If the folder’s bucket connection was removed, it fails with credential_not_found: you add the connection again in the console. Its cursor passed with another asset is invalid_argument.

pickle_flag marks files that can run code when they are loaded: the agent is told to tell you before loading them. A workspace file view from a server that doesn’t check files leaves the flag out and says so.

Renaming and retyping. update_asset changes name or asset_type (dataset, model, adapter, checkpoint, config or file) with no confirm step. Output assets keep their type, and no asset can be made an output. Names are unique among a workspace’s assets; a taken name is name_taken, and the other asset may be a hidden catalog one. Renaming the asset that collects a pod’s watched folder makes the pod’s later uploads go to a new asset named after the folder.

Deleting an asset. delete_asset’s preview shows the asset’s name, type, size, file count and where it is used, and what deleting does: files in Meshive storage are removed for good, a linked asset only loses the link, objects in your own bucket stay, and a task’s output links stop working. For Meshive storage it shows the storage freed and the monthly storage saving. An asset that is frozen, in use by a pod or an unfinished task, or can’t be edited is refused already at the preview (asset_frozen, asset_in_use, asset_not_editable), and a pod still saving into it is upload_in_progress.

Deleting files. delete_asset_files picks files by file_ids (up to 1000, from any assets of one workspace) or by asset with paths globs. The preview counts the matched, deletable, blocked and missing files, shows their size, up to 20 sample paths and the monthly storage saving, and returns an expected_file_count. The confirmed call passes that count back, and the files are matched again: if the count changed, nothing is deleted (selection_changed). Selecting every file of a collection is refused with whole_asset_delete_required, because deleting the asset is a separate decision for delete_asset. Files of an asset that is frozen or in use are skipped; the preview then shows the size of every selected file and says it includes the skipped ones. The answer lists the files deleted, skipped and failed, IDs that name no file (not_found, not to be retried), and an asset that went with its last file.

Exporting. export_asset copies an asset kept in Meshive storage to a connected bucket (bucket, optional prefix) or to a Hugging Face repo (hf_repo, a saved token with write access as hf_token_id, private, path_in_repo). The preview shows the destination and its visibility, the size and the warnings: objects with the same names in the bucket folder are overwritten, a Hugging Face repo that doesn’t exist is created — private unless private: false, and a typo makes a new repo — and the model’s license is your responsibility. The copy runs in the background and nothing reports when it finishes, so you check the bucket or repo. Assets already in your bucket or linked from a source can’t be exported (export_not_supported), and one that isn’t ready yet is asset_not_ready. Accounts without a completed payment have a daily export allowance, which export_asset and download_links report as export_limit_reached (wait until 00:00 UTC).

Importing. Besides Hugging Face, CivitAI and file URLs, import_asset takes:

  • source: "catalog:<slug>" (an entry from model_sets with entries: true) or "model_set:<slug>" (every file of a set). The answer lists each asset_id with its default role under imported, and the entries that couldn’t be linked under failed; calling again retries only those.
  • source: "bucket:<bucket_id>/<folder>". Without paths the folder is linked as one asset that can be browsed with asset_files and copied from, but can’t itself be a pod’s or task’s input_assets; with paths (object keys from buckets, up to 500) and name, just those files become an asset that can. Nothing is copied and Meshive doesn’t bill its storage; reading it can cost egress at your bucket’s provider. New errors: bucket_objects_not_found, bucket_prefix_empty.
  • source: "asset_..." of an asset linked from a bucket folder, with paths naming files from asset_files (or globs): those files are copied into a new asset in Meshive storage. This is the one case of import_asset that takes confirm, because the copy is billed per GiB-month: the preview shows the file count, size, sample paths and the estimated monthly storage cost. A selection that can’t be copied is subset_not_fetchable — also one over 200 GiB in one copy or with a file over 80 GiB. Exact paths in a folder with more files than the preview can read are bucket_objects_unchecked (not “not found”), because the preview can’t show their size and price; the console’s file picker copies those. The copy runs in the background.

download_links on a linked asset is linked_asset_not_downloadable, and on an asset linked from a bucket folder reference_asset_not_downloadable: read its objects from your bucket (asset_files lists them) or copy them with import_asset. detect_model takes asset (an Asset Hub model) as well as a Hugging Face repo, and says whether it can be served; ready is false while the asset is still uploading.