Vast.ai CLI skill

The official Vast.ai skill: an agent searches GPU offers, rents instances and manages them through vastai.

  • 230 ★ on the repository
  • Last commit
  • MIT
Skill

Broad access

Why this level

  • Creating instances, volumes and endpoints starts paid rental on your Vast.ai account, and `destroy instance -y` deletes data without confirmation.
  • The skill works with the account's API key and SSH keys and runs commands on rented machines.
All reasons and checks

vast-ai/vast-cli

Install

In your terminal, with SkillFoxx CLI

npx skillfoxx add skills/vast-ai-cli

Detects the agents on your machine, shows the access level and pins the version.

Other ways to install

Access and checks

How we review

Broad accessThe tool can change data, run commands or handle secrets.

  • Creating instances, volumes and endpoints starts paid rental on your Vast.ai account, and `destroy instance -y` deletes data without confirmation.
  • The skill works with the account's API key and SSH keys and runs commands on rented machines.

This is third-party code. Review the repository files before installing.

What it does

The skill teaches an agent to work with the Vast.ai GPU cloud through the `vastai` command-line client. The repository holds two SKILL.md files: `vastai/SKILL.md` for the CLI and `vastai_sdk/SKILL.md` for the Python SDK. The CLI skill's header allows only `vastai` calls, and the reference itself demands `--raw` for JSON output and sets the order of work: search offers with filters such as `gpu_name=RTX_4090 num_gpus=1`, create an instance, wait for the `running` status, get the SSH address, copy files and clean up. Further sections cover interruptible rentals, volumes, logs and running commands on an instance, serverless endpoints and deployments, templates, API keys, balance and billing, team accounts and host machine management. The SDK skill shows the same operations in Python through the `VastAI` class and the `Serverless` client for endpoint requests.

Who it is for. ML engineers and researchers who rent GPUs on Vast.ai and hand offer search, launch and shutdown of instances to an agent.

Good fit when

  • An agent picks four RTX 4090 cards by reliability and hourly price filters.
  • After training, data is copied to an instance and results are pulled back without manual console work.
  • The list of running instances has grown, and extras should be stopped or destroyed to end the charges.
  • A model is deployed as a serverless endpoint and queried from Python through `Serverless`.
  • A Vast.ai host manages its machines with the commands from the host section.

Not a fit when

  • You have no Vast.ai account or API key: no command runs without them.
  • Spending is not controlled: the agent creates paid instances and they bill until stopped.
  • Rental at another GPU cloud is needed: the skill knows only Vast.ai.
  • Work happens directly on Windows: the CLI skill header lists Linux and macOS, and on Windows the SDK via `pip install vastai` remains.

Example request

Find four RTX 4090 cards with reliability above 0.95 under two dollars an hour and show the three best offers.

Limitations

You need a Vast.ai account and an API key from the key management page; the key is stored with `vastai set api-key`. Every operation is paid: creating an instance, volume or serverless endpoint starts billing, and `vastai destroy instance` ends it. Before `create instance` register an SSH key with `vastai create ssh-key`, otherwise you cannot connect to the instance. The quick install without Python works on Linux, macOS and WSL. The skill sets no spending limits: the hourly price is capped by search filters such as `dph_total<=2.0`.

How to disable. Delete the `vastai` skill folder from the agent's skills directory. A client installed from PyPI is removed with `pip uninstall vastai`; the key the SDK reads lives in `~/.vast_api_key`.

FAQ

How do I install the Vast.ai skill in Claude Code?

Run `npx skills add vast-ai/vast-cli`. The client itself is installed separately: `curl -fsSL https://vast.ai/install.sh | bash` on Linux, macOS and WSL, or `pip install vastai` otherwise.

How do I sign in to Vast.ai from the terminal?

Get a key in the console on the key management page and run `vastai set api-key`. The login and balance show up with `vastai show user`.

Why does the agent need the --raw flag?

It switches output to machine-readable JSON. The skill requires `--raw` on every command so the agent parses replies without tables or colors.

How do I stop the charges?

Destroy the instance with `vastai destroy instance <ID> -y`: this ends all billing. The `-y` flag skips the confirmation prompt.

How does the SDK skill differ from the CLI skill?

The CLI skill teaches `vastai` commands, while the SDK skill shows the same operations in Python through `VastAI` and `Serverless`. The SDK reads the key from `~/.vast_api_key` or takes it as a parameter.

Discussion

No questions or reviews yet.

Skills

A GPU profiler for AI agents: the agent runs vLLM or SGLang under graphsignal-run, reads the metrics and tunes flags for speed

SkillExtended access276Repository stars

Cloud.ru Skills for AI Agents

Cloud.ru Skills для AI-агентов

Official

Official Cloud.ru skills: account setup, Foundation Models, ML Inference, virtual machines, RAG and Evolution AI Agents

SkillBroad access7Repository stars

Agent Skill Manager

agent-skill-manager

A universal skill manager for coding agents: finds and installs skills, scanning them for shell calls, network access and credential leaks first

CLIExtended access966Repository stars
Editors’ pick

Official Microsoft skills that ground coding agents in Azure SDKs and Foundry for Python, .NET, TypeScript, Java and Rust

SkillExtended access3.2KRepository stars
Editors’ pick

Microsoft Learn skills for nearly every Azure service: limits, configuration, security, architecture and troubleshooting with doc links

SkillExtended access807Repository stars

Agent Skills for Google products

Agent Skills for Google products and technologies

Editors’ pick

Official Google skill collection for working with Google Cloud, BigQuery, GKE, ads and analytics from an agent

SkillBroad access22.7KRepository stars

README in short

The repository holds the `vastai` command-line client, the Python SDK and a serverless endpoint client. A dedicated section for agents gives the install command and points to the two SKILL.md references. The license is MIT.

README badge

Original SKILL.md

---
name: vastai
description: Vast.ai CLI to manage GPU instances, volumes, serverless endpoints, and billing.
allowed-tools: Bash(vastai:*)
compatibility: Linux, macOS
metadata:
  author: vast-ai
---

# vastai

Manage GPU instances, templates, volumes, serverless endpoints, SSH keys, and billing on Vast.ai.

> Command is `vastai` (lowercase). Always use `--raw` for machine-readable JSON output.

## Install

```bash
# Linux/macOS (recommended, no Python required)
curl -fsSL https://vast.ai/install.sh | bash

# or via PyPI (Windows, or if you'd rather use pip)
pip install vastai
```

## Quick start

```bash
vastai set api-key <YOUR_API_KEY>                   # Authenticate (one-time); Create API Key in account at https://console.vast.ai/manage-keys/
vastai show user                                    # Verify auth + check balance
vastai create ssh-key ~/.ssh/id_ed25519.pub         # Register SSH key (do BEFORE create)
vastai search offers 'gpu_name=RTX_4090 num_gpus=1 verified=true direct_port_count>=1 rentable=true' -o 'dlperf_usd-'
# Note the offer ID from the output
vastai create instance <OFFER_ID> --image pytorch/pytorch:@vastai-automatic-tag --disk 20 --ssh --direct
# Automatically grab appropriate image tag; Response:  {"success": true, "new_contract": <INSTANCE_ID>}
vastai show instance <INSTANCE_ID>                  # Poll until actual_status == "running" (see Instance status values below)
vastai ssh-url <INSTANCE_ID>                        # Get SSH connection string
vastai copy local:./data/ <INSTANCE_ID>:/workspace/ # Upload files
vastai destroy instance <INSTANCE_ID> -y             # Clean up (stops all billing; -y skips confirmation)
```

API key: https://console.vast.ai/manage-keys/

## Global flags

Report a problem

Foxx AIVast.ai CLI
Foxx AI

I am Foxx AI and I have already vetted this tool. Ask about install, setup or anything else, and I will keep it simple.