The apidly command does from a terminal what the console does: list prices, deploy servers, open SSH sessions, read logs, run serverless endpoints, manage storage, keys, budget and billing. It uses the public API and an API key, and covers every operation in the API. It needs Node 18 or newer and has no other dependencies.
Install and sign in
The CLI is not on the npm registry yet. Download it from this site, check it against the checksum list and install the file. You need Node 18 or newer.
curl -fsSLO https://apidly.com/downloads/SHA256SUMS
curl -fsSLO https://apidly.com/downloads/apidly-cli-0.1.35.tgz
grep -F apidly-cli-0.1.35.tgz SHA256SUMS | sha256sum -c - # macOS: shasum -a 256 -c -
npm install -g ./apidly-cli-0.1.35.tgz
apidly --version
apidly initThe checksum catches a damaged or truncated download. The file and the list come from the same site, so it is not a defence against that site itself being compromised. https://apidly.com/downloads/latest.json lists the current version and the hash of every file; to update, repeat the commands with the new file name.
npm 11 and older can also install straight from the address that always points at the newest release; npm 12 refuses remote addresses unless you add --allow-remote=root:
npm install -g --allow-remote=root https://apidly.com/downloads/apidly-cli.tgzPackages on the npm registry (@apidly/cli) and on PyPI are planned; this page will change when they exist.
apidly init is the guided first run. It says where to create a key in the console (API keys), asks for it (the text is hidden), checks it, and saves it in ~/.config/apidly/config.json, readable only by you. If you have no SSH key registered yet it offers to upload ~/.ssh/id_ed25519.pub (or the file you name with --ssh-key-file), then shows your balance and the cheapest server in stock. When stdin is not a terminal it asks nothing: pass --key KEY (or set APIDLY_API_KEY) and --upload-ssh-key if you want the key uploaded; without a key it stops with exit code 1. apidly login only saves a key. For CI, set the APIDLY_API_KEY environment variable instead. apidly logout removes the saved key.
What a command may do depends on the scope of the key: read lists and shows, servers also starts, stops and deploys, full does everything its creator may do. See API keys.
Something not working? Run apidly doctor. It checks the version, your saved key, the connection to the API, your balance and your SSH keys, and says how to fix what is wrong. apidly doctor --offline skips the checks that need the network.
From a goal to a running server
apidly up chat --hours 2
apidly up images --budget 0.50
apidly up notebook --hours 4 --yes
apidly status
apidly stop --allapidly up GOAL chooses the app and the server the same way Quick start in the console does: the goals are chat, images, notebook, train and api (also transcribe and server). It prints the server, the price per hour while it runs, the cost for the hours you asked for (--hours, default 2) and what the disk costs while the server is stopped, and asks before it starts anything (--yes skips the question). --budget is the most you want to pay per running hour, disk included; when nothing fits within it, the cheapest server that fits is shown and marked as over the budget.
The server gets an automatic stop after --hours of running (--no-auto-stop leaves it off; the disk is kept when it stops). The command then waits with one progress line and prints the address to open and the sign-in. Ctrl-C ends the waiting only: the server keeps starting, and the command prints how to stop it. --detach does not wait at all.
apidly status is one screen: balance and how long it lasts, every server with its cost so far and when it stops by itself, and what needs you: a low balance, a running server without an automatic stop, a launch that failed with "Try instead" commands for servers that are in stock.
apidly stop --all and apidly destroy --all list the servers they would touch and what keeps costing money (a stopped server still pays for its disk) before they ask. --older-than 2h keeps only servers created at least that long ago.
Deploy a server
apidly plans --available --min-vram 24 --sort price
apidly templates
apidly ssh-keys add ~/.ssh/id_ed25519.pub
apidly deploy --plan rtx-4090-1x --template pytorch --ssh-key ssh_abc123 --label training --env-file .env --wait
apidly ssh ins_abc123Before it sends anything, deploy shows the hourly price and the storage price and asks you to confirm. Add --yes to skip the question in scripts. If your organization requires approval for new servers, the command says the request is waiting; nothing is charged until an owner or admin approves it.
--env-file FILE reads KEY=VALUE lines (comments, export and quotes are understood); --env K=V overrides single values. Placement flags (--region, --hosting, --min-cpu, --min-ram, --min-down, --min-up, --min-cuda, --direct-ports) narrow which machines may be used. --wait (also on start and stop) polls until the server is running or stopped; it stops with an error if the server fails or if --timeout seconds (default 600) pass. Progress goes to stderr, so a script can still read stdout.
deploy and topup send an Idempotency-Key so a retry cannot create a second server or checkout. The command makes one up; pass --idempotency-key KEY to reuse your own.
The plan catalogue is filtered in two places. The API applies --gpu, --min-vram, --min-ram, --min-cpu, --max-price, --region, --hosting, --min-perf and --availability, and orders by recommended, price, perf, perf-per-dollar or vram. plans applies --gpus, --tier, --min-disk, --available, --limit and the remaining sort keys (price-desc, ram, cpu, gpus, name) itself on what comes back.
Several servers at once
start, stop, restart, reboot, recreate and destroy take any number of ids. They run in order, a failure does not stop the rest, and the exit code is 1 if any id failed. apidly servers start|stop|... is the same command; servers also routes create, logs, exec, ssh, scp and automation.
apidly stop ins_a ins_b ins_c
apidly destroy ins_a ins_b --yes
apidly servers --json | jq -r '.servers[] | select(.status=="stopped") | .id' | xargs apidly destroy --yesreboot is restart: the API has one restart action.
Secrets are never arguments
Values for secrets and registry tokens are read from a hidden prompt or from stdin, never from an argument, because arguments end up in shell history and the process list:
printf %s "$HF_TOKEN" | apidly secrets set HF_TOKEN
printf %s "$TOKEN" | apidly registries add ghcr.io --username meThe only secrets the CLI ever prints are the ones the API returns once, when you create them: a new API key (api-keys create) and a webhook signing secret (webhooks add). Store them then.
Command reference
| Command | What it does |
|---|---|
apidly login |
Save your API key |
apidly logout |
Remove the saved API key |
apidly whoami |
Show the organization, balance and runway |
apidly plans |
List GPU plans with price and availability, or one plan's price history |
apidly templates |
List, show, create, update or delete templates |
apidly ssh-keys |
List, add, rename or remove SSH keys |
apidly servers |
List servers, show one, rename it or read its events |
apidly deploy |
Request a new server |
apidly start |
Start stopped servers |
apidly stop |
Stop running servers (the disk is kept and still billed) |
apidly restart |
Restart servers |
apidly reboot |
Reboot servers (same as restart; --hard stops them first and starts them again) |
apidly recreate |
Erase every file on servers, /workspace included, and recreate them from a freshly pulled image (asks first) |
apidly destroy |
Delete servers and their disks (cannot be undone) |
apidly logs |
Show server logs |
apidly ssh |
Open an SSH session to a running server |
apidly usage |
What you were charged |
apidly init |
First run: save an API key, add your SSH key, see balance and prices |
apidly up |
One command from a goal to a running server (chat, images, notebook, train, api) |
apidly status |
One screen: balance and runway, running servers and their cost, anything that needs you |
apidly avoided-machines |
Never place your servers on a machine again: mark one by its server, list, remove |
apidly deployments |
List server requests, show one, cancel one, or launch one again |
apidly balance |
Show the prepaid balance, burn rate and runway |
apidly ledger |
List credits and charges, newest first |
apidly invoices |
List invoices, receipts and statements |
apidly statements |
List monthly statements, or show one month (totals, servers, volumes) |
apidly topup |
Start a checkout to add credit (prints the payment link) |
apidly team |
List the members and roles of your organization |
apidly benchmarks |
Measured performance per GPU class (our own benchmark runs) |
apidly gpus |
List GPU models with the lowest price and availability |
apidly regions |
List the regions your servers run in |
apidly webhooks |
List, add or remove webhook endpoints and read their deliveries |
apidly support |
Open, read, reply to and close support tickets |
apidly groups |
Manage server groups (a desired number of identical servers) |
apidly exec |
Run a command on a server: over your own ssh when it runs, ls/du/rm through the API when it is stopped |
apidly terminal |
Address and password of a running server's browser terminal (deploy with --web-terminal) |
apidly secrets |
List, set or delete organization secrets (values are write-only) |
apidly scp |
Copy files to or from a running server with scp |
apidly openapi |
Print the address of the OpenAPI document, or download it |
apidly config |
Read or change saved settings (api-url) and switch between saved profiles |
apidly automation |
Read, set or clear a server's automation rules |
apidly volumes |
List, show, create, price, rename or delete persistent volumes |
apidly transfers |
Copy data between servers |
apidly registries |
List, add or remove private image registry logins |
apidly api-keys |
List, create, edit, rotate or revoke API keys |
apidly endpoints |
Serverless endpoints: create, scale, pause, read metrics and call them |
apidly budget |
Show or change the monthly budget and alert levels |
apidly billing-details |
Show or change the billing name, address and tax ID |
apidly billing |
Balance, ledger, invoices, usage, top-up and billing details |
apidly activity |
Read the organization's activity trail |
apidly notifications |
Show or change notification switches |
apidly clone |
Launch a copy of a server: same plan, template, disk, keys, variables and tags |
apidly filters |
List, save or delete saved plan filters (the deploy wizard's saved searches) |
apidly watch |
Get one email when an unavailable plan is back (14-day watch) |
apidly cost |
What one server has cost, since creation and this month |
apidly ports |
Check whether each port of a running server answers |
apidly invoice |
Save one invoice as its printable HTML page |
apidly export |
Write your servers, volumes and SSH keys as an apidly.yaml file, or download usage, ledger or activity as a CSV file |
apidly refund |
Ask for a refund (opens a billing ticket; no money moves until a person decides) |
apidly promo |
Redeem a promo code (promotional credit, never refundable) |
apidly org |
Rename the organization, change its billing email or country, or its launch defaults |
apidly profile |
Show or change your display name, language and time zone |
apidly variable-sets |
Save named sets of environment variables (secret values included) and attach them to a launch (values are write-only) |
apidly plan |
Show what apidly apply would create, change or leave for an apidly.yaml file, and the price; changes nothing |
apidly apply |
Create and change what an apidly.yaml file describes, after showing the plan and asking |
apidly ssh-config |
Print SSH config entries for your running servers, or keep them in ~/.ssh/config (then ssh ID just works) |
apidly doctor |
Check your setup (version, config, key, API, balance, SSH, completion) and say how to fix what is wrong |
apidly update |
Check for a newer CLI and install it (checksum verified) |
apidly completion |
Print a shell completion script (bash, zsh or fish) |
Commands that delete or revoke something ask you to confirm on a terminal and need --yes in a script. apidly COMMAND --help prints the same usage and options as below.
Account
apidly login
Save your API key.
apidly login [--api-url URL] [--key KEY] [--profile NAME]| Option | What it does |
|---|---|
--key VALUE |
API key (otherwise asked, or read from piped stdin) |
API: GET /me.
apidly logout
Remove the saved API key.
apidly logout [--profile NAME]apidly whoami
Show the organization, balance and runway.
Also available as apidly me.
apidly whoamiAPI: GET /me.
apidly init
First run: save an API key, add your SSH key, see balance and prices.
apidly init [--key KEY] [--ssh-key-file FILE.pub | --skip-ssh-key] [--upload-ssh-key]| Option | What it does |
|---|---|
--key VALUE |
API key (asked on a terminal; required when stdin is not a terminal unless APIDLY_API_KEY is set) |
--ssh-key-file VALUE |
SSH public key to offer (default ~/.ssh/id_ed25519.pub, id_ecdsa.pub or id_rsa.pub) |
--upload-ssh-key |
Upload the SSH public key without asking when none is registered |
--skip-ssh-key |
Do not offer to upload an SSH key |
API: GET /me, GET /ssh-keys, POST /ssh-keys, GET /plans.
apidly status
One screen: balance and runway, running servers and their cost, anything that needs you.
apidly statusAPI: GET /me, GET /servers, GET /servers/{id}/billing, GET /servers/{id}/automation, GET /deployments.
apidly openapi
Print the address of the OpenAPI document, or download it.
apidly openapi [--fetch]| Option | What it does |
|---|---|
--fetch |
Download the document and print it as JSON |
API: GET /openapi.json.
apidly config
Read or change saved settings (api-url) and switch between saved profiles.
apidly config get [api-url]
apidly config set api-url URL
apidly config profiles
apidly config use NAME
apidly config profiles rm NAME [--yes]
(add a profile with `apidly login --profile NAME`; pick one per command with --profile NAME or APIDLY_PROFILE)| Option | What it does |
|---|---|
-y, --yes |
Do not ask before removing a profile |
apidly org
Rename the organization, change its billing email or country, or its launch defaults.
apidly org set [--name TEXT] [--billing-email EMAIL|none] [--country CC|none]
apidly org defaults [--ssh-key ID ...|--ssh-key none|--ssh-key unset] [--auto-stop HOURS|none|unset] [--region na|eu|ap|other|any]| Option | What it does |
|---|---|
--ssh-key VALUE (repeatable) |
defaults: SSH key preselected on every launch, repeatable; none = no key, unset = not chosen |
--auto-stop VALUE |
defaults: stop new servers after HOURS of running (1 to 720); none = no automatic stop, unset = not chosen |
--region VALUE |
defaults: preferred region for plan suggestions (na, eu, ap, other); any = no preference |
--name VALUE |
New organization name |
--billing-email VALUE |
Billing email, or none |
--country VALUE |
Two-letter country code, or none |
API: PATCH /organization, GET /organization/defaults, PATCH /organization/defaults.
apidly profile
Show or change your display name, language and time zone.
apidly profile
apidly profile set [--name TEXT] [--locale CODE] [--time-zone ZONE|utc]| Option | What it does |
|---|---|
--name VALUE |
set: display name (1 to 80 characters) |
--locale VALUE |
set: language of mail, for example de or pt-BR |
--time-zone VALUE |
set: IANA time zone for dates in mail (Europe/Berlin), or utc |
API: GET /me/profile, PATCH /me/profile.
apidly doctor
Check your setup (version, config, key, API, balance, SSH, completion) and say how to fix what is wrong.
apidly doctor [--offline] [--json]| Option | What it does |
|---|---|
--offline |
Skip the checks that need the network (version, API, key, balance, account SSH keys, servers) |
API: GET /me, GET /ssh-keys, GET /servers, GET /deployments.
apidly update
Check for a newer CLI and install it (checksum verified).
Also available as apidly upgrade.
apidly update [--yes]
apidly update --check (exit 3 when a newer version is out)
apidly update --print (print the commands instead of running them)| Option | What it does |
|---|---|
--check |
Only say whether a newer version is out (exit 3 if so) |
--print |
Print the download and install commands, run nothing |
-y, --yes |
Do not ask |
apidly completion
Print a shell completion script (bash, zsh or fish).
apidly completion bash|zsh|fishapidly __complete
Words for shell completion (used by the completion scripts).
apidly __complete profiles|servers|plansServers
apidly servers
List servers, show one, rename it or read its events.
apidly servers [--status S[,S]] [--pricing on_demand|interruptible] [--search TEXT] [--tag TAG[,TAG]] [--include-destroyed] [--limit N | --all] [--watch]
apidly servers show ID
apidly servers rename ID LABEL
apidly servers note ID "TEXT" | --clear (your own note, plain text up to 2,000 characters; never sent to the host)
apidly servers tag ID [ID...] [--add TAG ...] [--remove TAG ...] (several IDs: one call, up to 100 servers)
apidly servers bulk start|stop|restart|destroy ID [ID...] [--force] [--yes] (one call for up to 100 servers; each gets its own result)
apidly servers bulk start|stop|restart|destroy --tag TAG[,TAG] [--preview] [--force] [--yes] (every server that carries all the tags, up to 100; --preview lists them and changes nothing)
apidly servers auto-extend ID on|off (move the server to a new machine shortly before its machine ends; disk contents are not moved)
apidly servers keep-on-error ID on|off (on: a fatal error the app prints while starting never closes the server; it stays running and charged)
apidly servers events ID [--limit N | --all]
apidly servers metrics ID [--range 1h|6h|24h|48h]
apidly servers usage ID [--from DATE] [--to DATE]
apidly servers max-price ID [USD_PER_HOUR] [--yes]
apidly servers export ID [-f FILE.json] (the launch settings as a file for `apidly deploy -f`; secret values are never written)
apidly servers wait ID [--for running|stopped|destroyed] [--timeout SECONDS] (for scripts: exit 0 once the server is there, 1 when it cannot get there)
apidly servers benchmark ID [-i KEYFILE] [--budget SECONDS] [--no-save] [--print] (runs our standard GPU benchmark over your SSH, about 4 minutes, and compares it with our measured median; needs python3 and PyTorch on the server)
apidly servers benchmarks ID (benchmarks recorded for the server, newest first)
apidly servers create|start|stop|restart|reboot|recreate|destroy|logs|exec|ssh|scp|automation ... (same as the top-level commands)Shortcuts: apidly servers create runs apidly deploy; apidly servers deploy runs apidly deploy; apidly servers start runs apidly start; apidly servers stop runs apidly stop; apidly servers restart runs apidly restart; apidly servers reboot runs apidly reboot; apidly servers recreate runs apidly recreate; apidly servers destroy runs apidly destroy; apidly servers rm runs apidly destroy; apidly servers logs runs apidly logs; apidly servers exec runs apidly exec; apidly servers ssh runs apidly ssh; apidly servers scp runs apidly scp; apidly servers automation runs apidly automation.
apidly servers terminal runs apidly terminal.
| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
-f, --file VALUE |
export: write the launch file to FILE (default: print it; - also prints) |
--from VALUE |
usage: first day (YYYY-MM-DD) |
--to VALUE |
usage: last day (YYYY-MM-DD) |
--include-destroyed |
Include destroyed servers |
--status VALUE |
Only these statuses, comma-separated (running, stopped, interrupted, error, ...); destroyed also lists destroyed servers |
--pricing VALUE |
Only on_demand or interruptible servers |
--search VALUE |
Only servers whose ID, label, GPU model, note or a tag contains TEXT |
--range VALUE |
metrics: 1h (default), 6h, 24h or 48h |
--tag VALUE (repeatable) |
Only servers that carry every one of these tags (repeat or comma-separate) |
--add VALUE (repeatable) |
tag: add this tag, repeatable (up to 10 tags per server) |
--remove VALUE (repeatable) |
tag: remove this tag, repeatable |
--clear |
note: remove the note |
--force |
bulk: stop, restart or destroy even while a copy or backup on the server is unfinished |
--watch |
List: redraw the list every 5 seconds until Ctrl-C |
--for VALUE |
wait: the state to wait for, running (default), stopped or destroyed |
--timeout VALUE |
wait: give up after this many seconds (default 600) |
--budget VALUE |
benchmark: seconds the tests may take, 60 to 900 (default 240) |
-i, --identity VALUE |
benchmark: private key file passed to ssh -i |
--no-save |
benchmark: print the result without recording it |
--print |
benchmark: print the ssh command instead of running it |
--preview |
bulk --tag: list the servers the tags select and change nothing |
-y, --yes |
Do not ask |
API: GET /servers, GET /servers/{id}, PATCH /servers/{id}, POST /servers/tags, GET /servers/{id}/events, GET /servers/{id}/metrics, GET /servers/{id}/max-price, POST /servers/{id}/max-price, GET /servers/{id}/usage, GET /servers/{id}/launch-file, GET /servers/{id}/benchmarks, POST /servers/{id}/benchmarks.
API: POST /servers/bulk.
apidly deploy
Request a new server.
apidly deploy -f FILE.json [--label L] [--env K=V ...] [...any option below overrides the file] (a launch file from `apidly servers export ID`)
apidly deploy --plan SLUG --template SLUG [--disk GB] [--ssh-key ID ...] [--label L] [--tag TAG ...] [--env K=V ...] [--env-file FILE] [--var-set NAME ...] [--interruptible] [--web-terminal] [--self-stop] [--fallback-plan SLUG ...] [--volume ID --mount PATH] [--wait] [--idempotency-key KEY] [--yes] [--dry-run]
placement: [--region na|eu|ap|other] [--hosting datacenter|independent] [--reliability LEVEL] [--min-cpu N] [--min-ram GB] [--min-down MBPS] [--min-up MBPS] [--min-cuda MAJOR] [--direct-ports]| Option | What it does |
|---|---|
-f, --file VALUE |
Launch file (a POST /servers body, such as the one apidly servers export ID writes; - for stdin); options given as well win |
--plan VALUE |
Plan slug or id (see apidly plans) |
--template VALUE |
Template slug or id (see apidly templates) |
--disk VALUE |
Disk in GB (default: the larger of plan minimum and template default) |
--ssh-key VALUE (repeatable) |
SSH key id, repeatable (see apidly ssh-keys) |
--label VALUE |
Server label, up to 60 characters |
--tag VALUE (repeatable) |
Tag for the new server, repeatable (up to 10) |
--env VALUE (repeatable) |
Environment variable KEY=VALUE, repeatable |
--env-file VALUE |
Read KEY=VALUE lines from FILE (- for stdin); --env wins |
--var-set VALUE (repeatable) |
Attach a saved variable set (id or name, apidly variable-sets), repeatable up to 5; a later one wins, --env wins over all |
--interruptible |
Cheaper price; the server can be paused when demand rises |
--on-demand |
Fixed price, never paused (the default) |
--web-terminal |
Also run a browser terminal on the server (only where the platform offers it; read it with apidly terminal ID) |
--self-stop |
Give the server a key (GPU_SERVER_KEY) that can only stop or destroy this server, so a script can end it when done |
--dry-run |
Check the request and show its price per hour (and anything that would refuse it, such as a low balance); creates nothing |
--region VALUE |
na, eu, ap or other |
--hosting VALUE |
datacenter or independent |
--reliability VALUE |
Set to high to use only high-reliability machines |
--min-cpu VALUE |
Minimum CPU cores, 1 to 512 |
--min-ram VALUE |
Minimum RAM in GB, 1 to 4096 |
--min-down VALUE |
Minimum download Mbps |
--min-up VALUE |
Minimum upload Mbps |
--min-cuda VALUE |
Minimum CUDA major, 11 to 30 |
--direct-ports |
Only machines with directly reachable ports |
--fallback-plan VALUE (repeatable) |
Plan slug or id to try when the main plan has no machine, repeatable (up to 2) |
--volume VALUE |
Persistent volume id to mount |
--mount VALUE |
Mount path for --volume |
--idempotency-key VALUE |
Reuse to make a retry safe (default: random) |
--wait |
Wait until the server reaches the target state |
--timeout VALUE |
Seconds to wait with --wait (default 600) |
-y, --yes |
Do not ask for confirmation |
API: POST /servers.
apidly start
Start stopped servers.
apidly start ID [ID...] [--wait] [--timeout SECONDS]| Option | What it does |
|---|---|
--wait |
Wait until the server reaches the target state |
--timeout VALUE |
Seconds to wait with --wait (default 600) |
API: POST /servers/{id}/{action}.
apidly stop
Stop running servers (the disk is kept and still billed).
apidly stop ID [ID...] [--wait] [--timeout SECONDS]
apidly stop --all [--older-than 2h] [--yes] [--wait]| Option | What it does |
|---|---|
--wait |
Wait until the server reaches the target state |
--timeout VALUE |
Seconds to wait with --wait (default 600) |
--all |
Every server (stop: the running ones); lists them and asks first |
--older-than VALUE |
With --all: only servers created at least this long ago (30m, 2h, 1d) |
-y, --yes |
With --all: do not ask first |
API: POST /servers/{id}/{action}.
apidly restart
Restart servers.
apidly restart ID [ID...]API: POST /servers/{id}/{action}.
apidly reboot
Reboot servers (same as restart; --hard stops them first and starts them again).
apidly reboot ID [ID...] [--hard]| Option | What it does |
|---|---|
--hard |
Stop the server and start it again (the next minute job starts it), a cleaner restart; files, /workspace included, are kept |
API: POST /servers/{id}/{action}, POST /servers/{id}/hard-reboot.
apidly recreate
Erase every file on servers, /workspace included, and recreate them from a freshly pulled image (asks first).
apidly recreate ID [ID...] [--yes]| Option | What it does |
|---|---|
-y, --yes |
Skip the typed confirmation (needed when not run in a terminal) |
API: POST /servers/{id}/recreate.
apidly recycle
Deprecated name of apidly recreate: erase every file on servers and recreate them (asks first).
apidly recycle ID [ID...] [--yes]| Option | What it does |
|---|---|
-y, --yes |
Skip the typed confirmation (needed when not run in a terminal) |
API: POST /servers/{id}/recycle.
apidly destroy
Delete servers and their disks (cannot be undone).
apidly destroy ID [ID...] [--yes]
apidly destroy --all [--older-than 2h] [--yes]| Option | What it does |
|---|---|
--all |
Every server (stop: the running ones); lists them and asks first |
--older-than VALUE |
With --all: only servers created at least this long ago (30m, 2h, 1d) |
-y, --yes |
Skip the typed confirmation |
API: DELETE /servers/{id}.
apidly logs
Show server logs.
apidly logs ID [--tail N] [--since TIME] [--until TIME] [--follow] [--download [--out FILE]]| Option | What it does |
|---|---|
--download |
Save the last 1000 lines to a text file instead of printing |
--out VALUE |
--download: file name (default ID-logs.txt) |
--tail VALUE |
Number of lines, 1 to 1000 (default 200) |
--since VALUE |
Only lines timed at or after TIME: 2026-11-24T10:00:00Z or 15m, 2h, 1d back (applies to lines that start with a date-time and its zone) |
--until VALUE |
Only lines timed before TIME (same forms as --since) |
-f, --follow |
Keep printing new lines until Ctrl-C (with --since, older lines stay hidden) |
API: GET /servers/{id}/logs, GET /servers/{id}/logs/download.
apidly up
One command from a goal to a running server (chat, images, notebook, train, api).
apidly up chat|images|notebook|train|api|transcribe|server [--budget USD_PER_HOUR] [--hours H] [--yes]
[--no-auto-stop] [--ssh-key ID] [--label L] [--detach] [--timeout SECONDS]| Option | What it does |
|---|---|
--budget VALUE |
Most to pay per running hour, USD, disk included (for example 0.50) |
--hours VALUE |
How long you need it: priced up front and the automatic stop (default 2, 0.25 to 720) |
--no-auto-stop |
Do not set the automatic stop (it runs until you stop it) |
--ssh-key VALUE (repeatable) |
SSH key id for templates used over SSH (default: your only key) |
--label VALUE |
Server label |
--detach |
Do not wait for the server to run |
--timeout VALUE |
Seconds to wait for the server (default 900) |
-y, --yes |
Do not ask for confirmation |
API: GET /quickstart, POST /servers, PUT /servers/{id}/automation, GET /servers/{id}.
apidly avoided-machines
Never place your servers on a machine again: mark one by its server, list, remove.
apidly avoided-machines
apidly avoided-machines add SERVER [--reason TEXT]
apidly avoided-machines rm ENTRY_ID [--yes]| Option | What it does |
|---|---|
--reason VALUE |
Why you avoid it, for your own list (up to 200 characters) |
-y, --yes |
Do not ask |
API: POST /servers/{id}/avoid-machine, GET /avoided-machines, DELETE /avoided-machines/{id}.
apidly deployments
List server requests, show one, cancel one, or launch one again.
apidly deployments [--status STATUS] [--limit N | --all]
apidly deployments show ID
apidly deployments cancel ID
apidly deployments again ID [--label LABEL] [--env K=V ...] [--env-file FILE] (a new request with the same settings, at today's price)| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--label VALUE |
again: a label for the new server (default: the same) |
--env VALUE (repeatable) |
Re-enter the value of a variable whose stored value was cleared (secret_values_cleared), KEY=VALUE, repeatable |
--env-file VALUE |
Read those KEY=VALUE lines from FILE (- for stdin); --env wins |
--idempotency-key VALUE |
again: your own Idempotency-Key (a retry with it never repeats) |
--status VALUE |
pending_approval, approved, provisioning, active, rejected, failed or cancelled |
API: GET /deployments, GET /deployments/{id}, POST /deployments/{id}/cancel, POST /deployments/{id}/launch-again.
apidly exec
Run a command on a server: over your own ssh when it runs, ls/du/rm through the API when it is stopped.
apidly exec ID [-i KEYFILE] [--print] -- COMMAND [ARGS...]
apidly exec ID -- ls|du|rm [ARGS...] (stopped server)| Option | What it does |
|---|---|
-i, --identity VALUE |
Private key file passed to ssh -i (running server) |
--print |
Print the ssh command instead of running it (running server) |
API: POST /servers/{id}/exec.
apidly terminal
Address and password of a running server's browser terminal (deploy with --web-terminal).
apidly terminal ID [--show-password]| Option | What it does |
|---|---|
--show-password |
Print the password in the table output (JSON output always includes it) |
API: POST /servers/{id}/terminal.
apidly automation
Read, set or clear a server's automation rules.
apidly automation get ID
apidly automation set ID [--max-runtime-hours H] [--idle-threshold PCT --idle-minutes M] [--destroy-at TIME] [--stop-at TIME | --stop-after-hours H] [--spend-cap USD] [--schedule-file FILE.json] [--clear RULE ...]
apidly automation clear ID [--yes]
apidly automation calendar ID [--weeks N] [--out FILE.ics] (planned starts and stops for a calendar app)| Option | What it does |
|---|---|
--weeks VALUE |
calendar: how many weeks ahead (1 to 12, default 4) |
--out VALUE |
calendar: write to this file (default: print it) |
--max-runtime-hours VALUE |
Stop after this many hours (0.25 to 2160) |
--idle-threshold VALUE |
GPU use below this percent (1 to 50) counts as idle |
--idle-minutes VALUE |
Minutes idle before stopping (10 to 1440) |
--destroy-at VALUE |
Destroy at this time (ISO timestamp ending in Z) |
--stop-at VALUE |
Stop the server at this time (ISO timestamp ending in Z; it must be at least a minute ahead) |
--stop-after-hours VALUE |
Stop the server this many hours from now (same rule as --stop-at) |
--spend-cap VALUE |
Stop after this much spend in USD (0.10 and up) |
--schedule-file VALUE |
JSON {timezone, windows:[{days,start,stop,count?}]} (- for stdin) |
--clear VALUE (repeatable) |
Remove a rule: max-runtime, idle, destroy-at, stop-at, spend-cap or schedule |
-y, --yes |
Do not ask |
API: GET /servers/{id}/automation, PUT /servers/{id}/automation, DELETE /servers/{id}/automation, GET /servers/{id}/automation/calendar.
apidly clone
Launch a copy of a server: same plan, template, disk, keys, variables and tags.
apidly clone SERVER_ID [--label LABEL] [--env K=V ...] [--env-file FILE] [--idempotency-key KEY]| Option | What it does |
|---|---|
--label VALUE |
Label of the copy (default: " copy") |
--env VALUE (repeatable) |
Re-enter the value of a variable whose stored value was cleared (secret_values_cleared), KEY=VALUE, repeatable |
--env-file VALUE |
Read those KEY=VALUE lines from FILE (- for stdin); --env wins |
--idempotency-key VALUE |
Your own Idempotency-Key (a retry with it never repeats) |
API: POST /servers/{id}/clone.
apidly ports
Check whether each port of a running server answers.
apidly ports SERVER_IDAPI: GET /servers/{id}/portal-health.
apidly plan
Show what apidly apply would create, change or leave for an apidly.yaml file, and the price; changes nothing.
apidly plan [-f apidly.yaml] [--max-hourly-usd USD] [--prune] [--detailed-exitcode]| Option | What it does |
|---|---|
-f, --file VALUE |
The file (default apidly.yaml in this folder; - for stdin) |
--max-hourly-usd VALUE |
Refuse when what would be created costs more than this many US dollars per hour |
--prune |
Show the servers of this stack that are no longer in the file as deleted |
--detailed-exitcode |
Exit with code 3 when apply would change something, 0 when it has nothing to do (1 is a failure, 2 a typing mistake) |
API: GET /servers, GET /deployments, GET /plans, GET /templates, GET /ssh-keys, GET /secrets, GET /volumes, GET /volumes/options, GET /endpoints, GET /servers/{id}/automation.
apidly apply
Create and change what an apidly.yaml file describes, after showing the plan and asking.
apidly apply [-f apidly.yaml] [--max-hourly-usd USD] [--prune] [--yes]| Option | What it does |
|---|---|
-f, --file VALUE |
The file (default apidly.yaml in this folder; - for stdin) |
--max-hourly-usd VALUE |
Refuse when what would be created costs more than this many US dollars per hour |
--prune |
Also destroy the servers that carry this stack's tag but are no longer in the file |
-y, --yes |
Do not ask |
API: GET /servers, GET /deployments, GET /plans, GET /templates, GET /ssh-keys, GET /secrets, GET /volumes, GET /volumes/options, GET /endpoints, GET /servers/{id}/automation, POST /ssh-keys, POST /volumes, POST /servers, PATCH /servers/{id}, PUT /servers/{id}/automation, GET /servers/{id}, DELETE /servers/{id}, POST /endpoints, PATCH /endpoints/{id}.
SSH
apidly ssh-keys
List, add, rename or remove SSH keys.
apidly ssh-keys [--limit N | --all]
apidly ssh-keys show ID
apidly ssh-keys add FILE [--name NAME]
apidly ssh-keys import USER [--site github|gitlab] (the public keys that account publishes)
apidly ssh-keys rename ID NAME
apidly ssh-keys rm ID [--yes]
apidly ssh-keys on SERVER
apidly ssh-keys attach SERVER KEY_ID
apidly ssh-keys detach SERVER KEY_ID [--yes]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--name VALUE |
Name for the new key (default: the key comment or file name) |
--site VALUE |
Where import reads the public keys: github (default) or gitlab |
-y, --yes |
Do not ask |
API: GET /ssh-keys, GET /ssh-keys/{id}, POST /ssh-keys, PATCH /ssh-keys/{id}, DELETE /ssh-keys/{id}, GET /servers/{id}/ssh-keys, POST /servers/{id}/ssh-keys, DELETE /servers/{id}/ssh-keys/{keyId}.
apidly ssh
Open an SSH session to a running server.
apidly ssh ID [-i KEYFILE] [--print] [-- extra ssh args or a remote command]| Option | What it does |
|---|---|
--print |
Print the ssh command instead of running it |
-i, --identity VALUE |
Private key file passed to ssh -i |
API: GET /servers/{id}.
apidly scp
Copy files to or from a running server with scp.
apidly scp ID SRC DST [-i KEYFILE] [-r] [--print]
a path starting with : is on the server, for example:
apidly scp ins_abc ./data.tar :/workspace/
apidly scp ins_abc :/workspace/out ./out -r| Option | What it does |
|---|---|
--print |
Print the scp command instead of running it |
-i, --identity VALUE |
Private key file passed to scp -i |
-r, --recursive |
Copy directories |
API: GET /servers/{id}.
apidly ssh-config
Print SSH config entries for your running servers, or keep them in ~/.ssh/config (then ssh ID just works).
apidly ssh-config [ID...] [-i KEYFILE]
apidly ssh-config --write [--file PATH] [-i KEYFILE]| Option | What it does |
|---|---|
-i, --identity VALUE |
Private key file to add as IdentityFile |
--write |
Keep the entries in a marked block of the SSH config file; a later run replaces only that block |
--file VALUE |
--write: config file to update (default ~/.ssh/config) |
API: GET /servers, GET /servers/{id}.
Plans and templates
apidly plans
List GPU plans with price and availability, or one plan's price history.
apidly plans [--gpu NAME] [--gpus N] [--tier T] [--min-vram GB] [--max-vram GB] [--min-gpus N] [--max-gpus N] [--min-ram GB] [--min-cpu N] [--min-disk GB] [--max-price USD_PER_HOUR] [--region R] [--hosting H] [--min-perf INDEX] [--availability A] [--available] [--sort KEY] [--limit N]
apidly plans history SLUG|ID
apidly plans search 'vram>=24 gpus>=2 price<1.5 region=eu sort=perf_per_dollar' [other flags]| Option | What it does |
|---|---|
-q, --query VALUE |
All filters as one line, for example 'vram>=24 gpus>=2 price<1.5' (keys: gpu, gpus, vram, ram, cpu, disk, price, perf, region, hosting, availability, sort) |
--gpu VALUE |
GPU model contains NAME (case-insensitive) |
--gpus VALUE |
Exactly N GPUs per server |
--tier VALUE |
standard, performance or enterprise |
--min-vram VALUE |
Minimum VRAM of each GPU in GB (filtered by the API) |
--max-vram VALUE |
Maximum VRAM of each GPU in GB (filtered by the API) |
--min-gpus VALUE |
At least N GPUs per server (filtered by the API) |
--max-gpus VALUE |
At most N GPUs per server (filtered by the API) |
--min-ram VALUE |
Minimum system RAM in GB (filtered by the API) |
--min-cpu VALUE |
Minimum vCPUs (filtered by the API) |
--min-disk VALUE |
Minimum disk in GB |
--max-price VALUE |
Maximum price per hour in USD (filtered by the API) |
--region VALUE |
na, eu, ap or other (filtered by the API) |
--hosting VALUE |
datacenter, independent or any (filtered by the API) |
--min-perf VALUE |
Minimum Apidly performance index, reference GPU = 100 (filtered by the API) |
--availability VALUE |
available, limited or unavailable (filtered by the API) |
--available |
Only plans that can be requested now |
--sort VALUE |
recommended (default), price (cheapest first), perf, perf-per-dollar, vram, price-desc, ram, cpu, gpus or name |
--limit VALUE |
Show at most N plans |
API: GET /plans, GET /plans/{id}/history.
apidly templates
List, show, create, update or delete templates.
apidly templates [--search TEXT] [--category C] [--own | --builtin] [--vram GB] [--limit N | --all]
apidly templates show ID
apidly templates create -f FILE.json
apidly templates update ID -f FILE.json
apidly templates rm ID [--yes]
apidly templates share ID [--name TEXT] [--include-start-script] [--expires-days N]
apidly templates unshare ID [--yes]
apidly templates duplicate ID
apidly templates save SERVER_ID [--name TEXT] [--summary TEXT] [--idempotency-key KEY] (secret values are not copied)
apidly templates revisions ID
apidly templates restore ID REVISION
apidly templates export ID [-f FILE.json]
apidly templates import -f FILE.json (an exported file, or a create body)
apidly templates shares ID
apidly templates use SHARE_TOKEN
apidly templates report SHARE_TOKEN --reason malware|illegal|secrets|other [--details "TEXT"]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--reason VALUE |
report: malware, illegal, secrets or other |
--details VALUE |
report: what you saw |
--search VALUE |
List: only templates whose name, slug, summary, image or category contains this text |
--category VALUE |
List: only this category (base, llm, image, notebook, training or custom) |
--own |
List: only your organization's own templates |
--builtin |
List: only the public catalogue |
--vram VALUE |
List: only templates that run on a GPU with this much memory (GB) |
-f, --file VALUE |
JSON body for create/update (- for stdin) |
--name VALUE |
Display name on a share link; save: the new template's name (default: the server's label) |
--summary VALUE |
save: a short summary of the new template |
--idempotency-key VALUE |
save: your own Idempotency-Key (a retry with it never repeats) |
--include-start-script |
Let people who open the share link see the start script |
--expires-days VALUE |
Share link lifetime in days, 1 to 365 (default: no expiry) |
-y, --yes |
Do not ask |
API: GET /templates, POST /templates, GET /templates/{id}, PATCH /templates/{id}, DELETE /templates/{id}, POST /templates/{id}/share, DELETE /templates/{id}/share, POST /templates/{id}/duplicate, POST /servers/{id}/template, GET /templates/{id}/revisions, POST /templates/{id}/revisions/{rev}/restore, GET /templates/{id}/share, GET /templates/{id}/export, POST /templates/import, POST /template-shares/{token}/import, POST /template-shares/{token}/report.
apidly benchmarks
Measured performance per GPU class (our own benchmark runs).
apidly benchmarks [--gpu MODEL] [--limit N | --all]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--gpu VALUE |
Only this GPU model (exact name) |
API: GET /benchmarks.
apidly gpus
List GPU models with the lowest price and availability.
apidly gpus [--limit N | --all]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
API: GET /gpus.
apidly regions
List the regions your servers run in.
apidly regions [--limit N | --all]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
API: GET /regions.
apidly filters
List, save or delete saved plan filters (the deploy wizard's saved searches).
apidly filters
apidly filters save NAME -f FILTERS.json (FILTERS.json: { core: {...}, hw: {...} }, as `filters --json` prints; every field is optional)
apidly filters save 4090-eu -f - <<< '{"core":{"query":"RTX 4090"},"hw":{"region":"eu"}}'
apidly filters rm ID [--yes]| Option | What it does |
|---|---|
-f, --file VALUE |
Filter set as JSON (- for stdin) |
--idempotency-key VALUE |
Your own Idempotency-Key (a retry with it never repeats) |
-y, --yes |
Do not ask |
API: GET /plan-filters, POST /plan-filters, DELETE /plan-filters/{id}.
apidly watch
Get one email when an unavailable plan is back (14-day watch).
apidly watch
apidly watch add PLAN_ID
apidly watch rm PLAN_ID [--yes]| Option | What it does |
|---|---|
-y, --yes |
Do not ask |
API: GET /plan-watches, POST /plan-watches, DELETE /plan-watches/{planId}.
Server groups
apidly groups
Manage server groups (a desired number of identical servers).
apidly groups [list]
apidly groups create -f FILE.json
apidly groups show ID
apidly groups scale ID N
apidly groups update ID -f FILE.json
apidly groups pause ID
apidly groups resume ID
apidly groups rm ID [--yes]| Option | What it does |
|---|---|
-f, --file VALUE |
JSON body for create (- for stdin) |
-y, --yes |
Do not ask |
API: GET /groups, POST /groups, GET /groups/{id}, PATCH /groups/{id}, DELETE /groups/{id}, POST /groups/{id}/{action}.
Serverless endpoints
apidly endpoints
Serverless endpoints: create, scale, pause, read metrics and call them.
apidly endpoints
apidly endpoints show ID
apidly endpoints create [-f FILE.json] --name N --plan SLUG --template SLUG [--disk GB] [scaling flags] [placement flags] [--env K=V ...] [--env-file FILE]
apidly endpoints update ID [-f FILE.json] [scaling flags] [--template SLUG] [--disk GB] [--env K=V ...] [--env-file FILE] [--keep-env NAME ... | --keep-other-env] [constraint flags]
apidly endpoints rollout ID resume|cancel|start|rollback
apidly endpoints groups ID
apidly endpoints set-groups ID (-f FILE.json | --clear)
apidly endpoints rm ID [--yes]
apidly endpoints pause ID
apidly endpoints resume ID
apidly endpoints stop ID (stop every worker but keep its disk, billed; resume comes back faster than from pause)
apidly endpoints metrics ID [--window 1h|24h|7d]
apidly endpoints invoke ID PATH [-X METHOD] [-d DATA | -d @FILE | -d -] [--content-type T] [--openai] [--session ID]
apidly endpoints jobs ID [--limit N]
apidly endpoints submit ID PATH [-X GET|POST|PUT] [-d DATA | -d @FILE | -d -] [--content-type T] [--query QS] [--webhook] [--cost N] [--priority N] [--queue-ttl SECONDS] [--result-ttl SECONDS] [--keep-request]
apidly endpoints job ID JOB_ID [--wait] [--wait-timeout SECONDS]
apidly endpoints cancel-job ID JOB_ID [--yes]
apidly endpoints retry-job ID JOB_ID [--priority N] [--queue-ttl SECONDS] [--result-ttl SECONDS] [--idempotency-key KEY]
apidly endpoints purge ID [--older-than SECONDS] [--yes] (cancel every job still waiting; running jobs are not touched)
apidly endpoints health ID
apidly endpoints requests ID [--status S] [--kind K] [--limit N] [--before CURSOR] [--csv]
apidly endpoints logs ID [--tail N] [--worker SERVER_ID]
apidly endpoints job-logs ID JOB_ID [--tail N] (the log tail of the worker that ran the job)
apidly endpoints presets ID (scale_to_zero, always_warm, burst, with their hourly cost)
apidly endpoints preset ID scale_to_zero|always_warm|burst
apidly endpoints releases ID [--limit N]
apidly endpoints restore ID VERSION [--yes] (put an earlier release back)| Option | What it does |
|---|---|
-f, --file VALUE |
JSON body for create/update; flags override it (- for stdin) |
--name VALUE |
Endpoint name, up to 40 characters |
--plan VALUE |
Plan slug or id (create) |
--template VALUE |
Template slug or id (create; update starts a rolling update) |
--disk VALUE |
Disk in GB (create; default: the larger of plan minimum and template default; update starts a rolling update) |
--clear |
set-groups: remove all groups (one implicit group again) |
--tail VALUE |
Log lines per worker for logs (1-500, default 100) |
--health-path VALUE |
Health check path |
--cold-start-note VALUE |
Note shown while a worker starts |
--max-spend VALUE |
Hourly spend cap in USD, or none |
--rate-limit VALUE |
Proxy requests per minute for the endpoint, all keys together (1 to 1200), or none for the platform limit of 1200 |
--auto-rollback VALUE |
on: roll back by itself when a new worker fails its health check during a rolling update; off (default): the update pauses |
--fallback-plan VALUE (repeatable) |
Alternative plan slug or id, repeatable (up to 2) |
--job-mode VALUE |
sync or kit |
--env VALUE (repeatable) |
Environment variable KEY=VALUE, repeatable (create; on update it replaces all variables and starts a rolling update) |
--env-file VALUE |
Read KEY=VALUE lines from FILE (create, update) |
--keep-env VALUE (repeatable) |
update: keep this stored variable as it is, repeatable (its value is never shown again); variables not kept and not in --env are removed |
--keep-other-env |
update: keep every stored variable not named in --env/--env-file, so you change one value without sending the others |
--region VALUE |
na, eu, ap or other |
--hosting VALUE |
datacenter or independent |
--reliability VALUE |
Set to high to use only high-reliability machines |
--min-cpu VALUE |
Minimum CPU cores, 1 to 512 |
--min-ram VALUE |
Minimum RAM in GB, 1 to 4096 |
--min-down VALUE |
Minimum download Mbps |
--min-up VALUE |
Minimum upload Mbps |
--min-cuda VALUE |
Minimum CUDA major, 11 to 30 |
--direct-ports |
Only machines with directly reachable ports |
--http-port VALUE |
Port the worker listens on (1 to 65535) |
--min-workers VALUE |
Workers kept running (0 to 10) |
--max-workers VALUE |
Most workers at once (1 to 20) |
--idle-seconds VALUE |
Idle seconds before a worker is released (60 to 86400) |
--target-concurrency VALUE |
Requests one worker handles at once (1 to 256) |
--startup-seconds VALUE |
Seconds a worker may take to become ready (120 to 7200) |
--min-warm-workers VALUE |
Workers kept warm (0 to 10) |
--warm-percent VALUE |
Extra warm capacity in percent (0 to 500) |
--max-queue-seconds VALUE |
Longest a request may queue (0 to 120) |
--target-queue-seconds VALUE |
Queue time the scaler aims for (1 to 120) |
--job-timeout-seconds VALUE |
Job timeout (10 to 3600) |
--max-surge VALUE |
New workers started above the wanted count during a rolling update (1 to 5) |
--range VALUE |
Metrics window: 1h, 24h or 7d (default 24h) |
--window VALUE |
metrics: time window, 1h, 24h or 7d (default 24h; same as --range) |
--worker VALUE |
logs: only this worker (its server id) |
--monthly-cap VALUE |
Hard monthly spending cap in USD (the endpoint pauses itself at it), or none |
--resume-at-new-month VALUE |
on: an endpoint paused by its monthly cap resumes by itself when a new month starts below the cap; off (default): it stays paused |
--release-stopped-at-cap VALUE |
on: a stopped endpoint releases its stopped workers at the monthly cap, so their disks stop billing; off (default): they are kept |
-X, --method VALUE |
HTTP method for invoke (GET or POST) |
-d, --data VALUE |
Request body for invoke: text, @FILE or - for stdin |
--content-type VALUE |
Content type of the body (default application/json) |
--openai |
Send through the OpenAI-style base URL: PATH is relative to the worker's /v1 |
--session VALUE |
invoke: sticky session; calls with the same ID reach the same worker (X-Session-Id) |
--query VALUE |
Query string for submit (without ?) |
--webhook |
Send an endpoint.job.completed webhook when the job ends |
--cost VALUE |
Load units of a job, 1 to 100 |
--priority VALUE |
submit: priority -10 to 10 (default 0); waiting jobs with a higher priority go to a worker first. Write a negative value as --priority=-5 |
--queue-ttl VALUE |
submit: seconds the job may wait for a worker before it expires, 60 to 3600 (default 3600) |
--result-ttl VALUE |
submit: seconds the answer is kept, 60 to 86400 (default 86400) |
--keep-request |
submit: keep the request after the job ends, so retry-job can send it again |
--wait |
job: wait until the job has ended (each call waits up to 60 seconds on the server) |
--wait-timeout VALUE |
job --wait: give up after this many seconds, 1 to 86400 (default 600) |
--older-than VALUE |
purge: only jobs that have waited at least this many seconds, 0 to 3600 |
--idempotency-key VALUE |
retry-job: repeat with the same key to get the same new job instead of a second one |
--status VALUE |
Request log filter: all, 2xx, 4xx, 5xx or queued_out |
--kind VALUE |
Request log filter: all, proxy or job |
--limit VALUE |
Rows to return (jobs, requests) |
--before VALUE |
Request log: rows older than this cursor |
--csv |
Request log as CSV text |
-y, --yes |
Do not ask |
API: GET /endpoints, POST /endpoints, GET /endpoints/{id}, PATCH /endpoints/{id}, DELETE /endpoints/{id}, POST /endpoints/{id}/{action}, GET /endpoints/{id}/metrics, GET /endpoints/{id}/proxy/{...path}, POST /endpoints/{id}/proxy/{...path}, GET /endpoints/{id}/openai/v1/{...path}, POST /endpoints/{id}/openai/v1/{...path}, GET /endpoints/{id}/jobs, POST /endpoints/{id}/jobs, GET /endpoints/{id}/jobs/{jobId}, POST /endpoints/{id}/jobs/{jobId}/cancel, POST /endpoints/{id}/jobs/{jobId}/retry, POST /endpoints/{id}/jobs/purge, GET /endpoints/{id}/health, GET /endpoints/{id}/requests, GET /endpoints/{id}/logs, POST /endpoints/{id}/rollout, GET /endpoints/{id}/groups, PUT /endpoints/{id}/groups, GET /endpoints/{id}/jobs/{jobId}/logs, GET /endpoints/{id}/presets, POST /endpoints/{id}/presets, GET /endpoints/{id}/releases, POST /endpoints/{id}/releases/{version}/restore.
Storage
apidly secrets
List, set or delete organization secrets (values are write-only).
apidly secrets ls
printf %s "$VALUE" | apidly secrets set NAME
apidly secrets rm NAME [--yes]| Option | What it does |
|---|---|
-y, --yes |
Do not ask |
API: GET /secrets, PUT /secrets, DELETE /secrets.
apidly volumes
List, show, create, price, rename or delete persistent volumes.
apidly volumes [--limit N | --all]
apidly volumes show ID
apidly volumes options SIZE_GB [--plan PLAN] ("offers" is its deprecated name)
apidly volumes create NAME --size GB --plan PLAN [--yes]
apidly volumes availability ID
apidly volumes fit PLAN_SLUG (free volumes a server of this plan can mount)
apidly volumes rename ID NAME
apidly volumes rm ID [--yes]
apidly volumes upload ID LOCAL_PATH [--dest DIR] [--plan PLAN] [--ssh-key ID] [-i KEYFILE] [-r] [--yes] (a short-lived server you pay for; destroyed after)| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--size VALUE |
Size in GB, 10 to 2000 |
--plan VALUE |
GPU plan (id or slug) the volume is for: it is created on a machine that offers this plan, and servers with it run there |
--region VALUE |
No longer used for create (a volume is placed by --plan) |
--dest VALUE |
upload: folder inside the volume (default its root) |
--template VALUE |
upload: template of the short-lived server (default ubuntu-cuda) |
--ssh-key VALUE (repeatable) |
upload: SSH key id for the short-lived server (default: the organization's default keys, or your only key) |
-i, --identity VALUE |
upload: private key file passed to scp -i |
-r, --recursive |
upload: copy a directory |
--timeout VALUE |
upload: seconds to wait for the short-lived server to start (default 600) |
-y, --yes |
Do not ask |
API: GET /volumes, POST /volumes, GET /volumes/options, GET /volumes/offers, GET /volumes/{id}, GET /volumes/{id}/availability, GET /volumes/fit, DELETE /volumes/{id}, PATCH /volumes/{id}.
apidly transfers
Copy data between servers.
apidly transfers [--limit N | --all]
apidly transfers show ID
apidly transfers cancel ID [--yes]
apidly transfers copy SERVER:PATH SERVER:PATH| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
-y, --yes |
Do not ask |
API: GET /transfers, POST /transfers, GET /transfers/{id}, DELETE /transfers/{id}.
apidly registries
List, add or remove private image registry logins.
apidly registries [--limit N | --all]
printf %s "$TOKEN" | apidly registries add HOST --username USER
apidly registries update ID [--username USER] [--rotate-token] (the new token is read from stdin)
apidly registries rm ID [--yes]
apidly registries check ID (tries the login against the registry; nothing is pulled)| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--username VALUE |
Registry user name |
--rotate-token |
update: read a new token from stdin |
-y, --yes |
Do not ask |
API: GET /registries, POST /registries, PATCH /registries/{id}, DELETE /registries/{id}, POST /registries/{id}/check.
apidly variable-sets
Save named sets of environment variables (secret values included) and attach them to a launch (values are write-only).
Also available as apidly var-sets.
apidly variable-sets [ls]
apidly variable-sets show ID|NAME
apidly variable-sets create NAME --env-file FILE (KEY=VALUE lines; - reads stdin)
apidly variable-sets update ID|NAME [--env-file FILE] [--unset KEY]... [--name NEW_NAME]
apidly variable-sets rm ID|NAME [--yes]
apidly deploy ... --var-set NAME [--var-set NAME2] (attach at launch; a --env of the same name wins)| Option | What it does |
|---|---|
--env-file VALUE |
create, update: file of KEY=VALUE lines (- reads stdin); values are never taken from arguments |
--unset VALUE (repeatable) |
update: remove this variable from the set |
--name VALUE |
update: rename the set |
-y, --yes |
Do not ask |
API: GET /variable-sets, POST /variable-sets, GET /variable-sets/{id}, PATCH /variable-sets/{id}, DELETE /variable-sets/{id}.
Access
apidly team
List the members and roles of your organization.
apidly team [members] [--limit N | --all]
apidly team roles
apidly team invitations [--limit N | --all]
apidly team invite EMAIL [--role admin|member|ROLE_ID] [--idempotency-key KEY]
apidly team revoke INVITATION_ID [--yes]
apidly team resend INVITATION_ID
apidly team role-create NAME --permissions a,b,c [--description TEXT]
apidly team role-update ROLE_ID NAME --permissions a,b,c [--description TEXT]
apidly team role-rm ROLE_ID [--yes]
apidly team role USER_ID ROLE
apidly team remove USER_ID [--yes]
apidly team limit USER_ID USD | --clear (monthly spending limit of the servers the member launches; only where spending limits are available)| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--clear |
limit: remove the member's spending limit |
--permissions VALUE |
role-create, role-update: comma-separated permission names (see team roles) |
--description VALUE |
role-create, role-update: short note, up to 200 characters |
--role VALUE |
invite: admin, member (default) or a custom role id |
--idempotency-key VALUE |
invite: reuse a key to make a retry safe |
-y, --yes |
Do not ask |
API: GET /team/members, GET /team/roles, GET /team/invitations, POST /team/invitations, DELETE /team/invitations/{id}, POST /team/invitations/{id}/resend, POST /team/roles, PATCH /team/roles/{id}, DELETE /team/roles/{id}, PATCH /team/members/{userId}, DELETE /team/members/{userId}.
API: PUT /team/members/{userId}/spending-limit.
apidly webhooks
List, add or remove webhook endpoints and read their deliveries.
apidly webhooks list
apidly webhooks add URL --events a,b [--format json|slack|discord|teams] [--description TEXT]
apidly webhooks update ID [--url URL] [--format json|slack|discord|teams] [--events a,b] [--description TEXT] [--active on|off]
apidly webhooks rotate-secret ID
apidly webhooks test ID
apidly webhooks redeliver DELIVERY_ID
apidly webhooks rm ID [--yes]
apidly webhooks deliveries ID [--limit N]| Option | What it does |
|---|---|
--url VALUE |
update: the new HTTPS address |
--format VALUE |
json (signed envelope, default), slack, discord or teams (a short message posted to that app's incoming-webhook URL, no signature) |
--active VALUE |
update: on or off (off pauses deliveries) |
--events VALUE |
Comma-separated event types (see webhooks list) |
--description VALUE |
Short note, up to 120 characters |
--limit VALUE |
Deliveries to show, 1 to 100 |
-y, --yes |
Do not ask |
API: GET /webhooks, POST /webhooks, PATCH /webhooks/{id}, DELETE /webhooks/{id}, GET /webhooks/{id}/deliveries, POST /webhooks/{id}/rotate-secret, POST /webhooks/{id}/test, POST /webhooks/deliveries/{deliveryId}/redeliver.
apidly support
Open, read, reply to and close support tickets.
apidly support [--status open|pending|closed] [--limit N | --all]
apidly support show ID
apidly support open SUBJECT --message TEXT|- [--category C] [--priority low|normal|high] [--server ID]
apidly support reply ID MESSAGE|-
apidly support close ID [--yes]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--status VALUE |
Only open, pending or closed tickets |
--message VALUE |
open: the text of the ticket (- reads stdin) |
--category VALUE |
open: ticket category |
--priority VALUE |
open: low, normal or high |
--server VALUE |
open: a related server ID |
-y, --yes |
Do not ask |
API: GET /support/tickets, POST /support/tickets, GET /support/tickets/{id}, POST /support/tickets/{id}/messages, POST /support/tickets/{id}/close.
apidly api-keys
List, create, edit, rotate or revoke API keys.
apidly api-keys
apidly api-keys create NAME [--scope read|servers|full] [--expires 30d|DATE] [--allowed-ip CIDR ...] [--permission NAME ...] [--endpoint ID]
apidly api-keys update ID [--name NAME] [--scope read|servers|full] [--expires 30d|DATE] [--allowed-ip CIDR ... | --any-ip] [--permission NAME ...]
apidly api-keys rotate ID [--grace 0|30m|1h|24h] [--yes]
apidly api-keys revoke ID [--yes]
apidly api-keys create NAME --monthly-limit USD (stop new launches with the key at a monthly spend; running servers keep running)
apidly api-keys limit ID --monthly-limit USD|none| Option | What it does |
|---|---|
--scope VALUE |
read, servers or full (default full) |
--expires VALUE |
Expiry: 30d, 12h, a date (2027-01-31) or an ISO timestamp |
--allowed-ip VALUE (repeatable) |
Only accept the key from this IP or CIDR, repeatable (up to 20) |
--permission VALUE (repeatable) |
Limit the key to this permission (for example servers.view), repeatable |
--endpoint VALUE |
Bind the key to one serverless endpoint (ID): it can then only call that endpoint |
--name VALUE |
update: the new name |
--any-ip |
update: remove the IP allowlist |
--grace VALUE |
rotate: how long the old secret keeps working: 0 (default, revoked at once), 30m, 1h ... up to 24h |
--monthly-limit VALUE |
create, limit: monthly spending limit in USD over the servers and endpoints launched with the key (none removes it). At the limit new launches and starts with the key are refused; running servers are not stopped |
-y, --yes |
Do not ask |
API: GET /api-keys, POST /api-keys, DELETE /api-keys/{id}, PATCH /api-keys/{id}, POST /api-keys/{id}/rotate.
API: PUT /api-keys/{id}/spending-limit.
apidly activity
Read the organization's activity trail.
apidly activity [--category C] [--actor TEXT] [--from DATE] [--to DATE] [--limit N | --all]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--category VALUE |
signIn, team, keys, servers, billing or settings |
--actor VALUE |
Only this actor (a member user id or an API key id) |
--from VALUE |
Start (inclusive) |
--to VALUE |
End (exclusive) |
API: GET /activity.
apidly notifications
Show or change notification switches.
apidly notifications [get]
apidly notifications set CATEGORY [--email on|off] [--in-app on|off] [--webhook on|off]
apidly notifications reminder HOURS|off
apidly notifications weekly [on|off] (the weekly spend summary mail; off unless switched on; no argument shows it)
apidly notifications inbox [--limit N]
apidly notifications read| Option | What it does |
|---|---|
--limit VALUE |
inbox: 1 to 100 (default 20) |
--email VALUE |
Email for this category: on or off |
--in-app VALUE |
In-app for this category: on or off |
--webhook VALUE |
Organization webhook for this category: on or off |
API: GET /notification-preferences, PUT /notification-preferences, GET /notifications, POST /notifications/read.
Billing
apidly usage
What you were charged.
apidly usage [--from DATE] [--to DATE] [--by-day] [--limit N]
apidly usage --by template|tag|gpu|member|api-key|day|instance [--from DATE] [--to DATE]
apidly usage --server ID [--by-day] [--from DATE] [--to DATE] (one server's charges, per day with --by-day)| Option | What it does |
|---|---|
--from VALUE |
Start (inclusive), 2026-11-01 or a timestamp |
--to VALUE |
End (exclusive) |
--by-day |
Group by day instead of by server |
--by VALUE |
Group by instance, day, gpu, member, template, tag (a server with several tags counts under each) or api-key (the key each server was launched with) |
--server VALUE |
Only this server's compute and disk charges (with --by instance or day) |
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
API: GET /usage.
apidly balance
Show the prepaid balance, burn rate and runway.
apidly balance [--below USD]
apidly balance --watch [--interval SECONDS] [--below USD]| Option | What it does |
|---|---|
--below VALUE |
Exit with code 3 when the balance is below this many US dollars (scripts, cron); with --watch, stop at the first reading below it |
--watch |
Read the balance again every 60 seconds (or --interval) until Ctrl-C |
--interval VALUE |
--watch: seconds between readings, 10 to 3600 |
API: GET /balance.
apidly ledger
List credits and charges, newest first.
apidly ledger [--type TYPE] [--server ID] [--from DATE] [--to DATE] [--limit N | --all]
apidly ledger receipt ENTRY_ID [--out FILE] [--lang CODE]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--type VALUE |
topup, usage, refund, adjustment, subscription_credit or promo |
--server VALUE |
Only the charges and credits of this server |
--from VALUE |
From this date or date-time (inclusive), e.g. 2026-11-01 |
--to VALUE |
Before this date or date-time (exclusive) |
--out VALUE |
PDF output file (default: apidly-statement-YYYY-MM.pdf or apidly-receipt-ID.pdf) |
--lang VALUE |
PDF label language (a locale code such as de; English when the PDF font cannot draw it) |
API: GET /ledger, GET /ledger/{id}/receipt.
apidly invoices
List invoices, receipts and statements.
apidly invoices [--kind topup|subscription|statement] [--from DATE] [--to DATE] [--limit N | --all]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--kind VALUE |
topup, subscription or statement |
--from VALUE |
From this date or date-time (inclusive), e.g. 2026-11-01 |
--to VALUE |
Before this date or date-time (exclusive) |
API: GET /invoices.
apidly statements
List monthly statements, or show one month (totals, servers, volumes).
apidly statements [--limit N | --all]
apidly statements show YYYY-MM [--csv | --pdf [--out FILE] [--lang CODE]]| Option | What it does |
|---|---|
--limit VALUE |
Return at most N items (default 50) |
--all |
Follow every page |
--cursor VALUE |
Continue from a nextCursor |
--csv |
show: print the CSV download |
--pdf |
show: save the statement as a PDF file |
--out VALUE |
PDF output file (default: apidly-statement-YYYY-MM.pdf or apidly-receipt-ID.pdf) |
--lang VALUE |
PDF label language (a locale code such as de; English when the PDF font cannot draw it) |
API: GET /statements, GET /statements/{month}.
apidly topup
Start a checkout to add credit (prints the payment link).
apidly topup AMOUNT --accept-terms [--idempotency-key KEY]| Option | What it does |
|---|---|
--accept-terms |
Confirm the express request and acknowledgement the console asks for |
--idempotency-key VALUE |
Reuse to make a retry safe (default: random) |
API: POST /topups.
apidly budget
Show or change the monthly budget and alert levels.
apidly budget [get]
apidly budget status (this month's spend against the budget)
apidly budget set [--monthly USD|none] [--alert 50,80,100] [--hard-stop | --no-hard-stop] [--confirm-hard-stop] [--low-balance USD|none]| Option | What it does |
|---|---|
--monthly VALUE |
Monthly budget in USD, or none |
--alert VALUE |
Comma-separated percent levels from 50, 80, 100 |
--hard-stop |
Stop servers when the budget is reached |
--no-hard-stop |
Only alert at the budget |
--confirm-hard-stop |
Acknowledge that a hard stop stops running servers |
--low-balance VALUE |
Warn when the balance falls below this many USD, or none |
API: GET /budget, PUT /budget, GET /budget/status.
apidly billing-details
Show or change the billing name, address and tax ID.
apidly billing details [get]
apidly billing details set [--name N] [--line1 L] [--line2 L] [--city C] [--state S] [--postal-code Z] [--country CC] [--tax-id ID] [-f FILE.json]| Option | What it does |
|---|---|
--name VALUE |
Billing name |
--line1 VALUE |
Address line 1 |
--line2 VALUE |
Address line 2 |
--city VALUE |
City |
--state VALUE |
State or region |
--postal-code VALUE |
Postal code |
--country VALUE |
Country code |
--tax-id VALUE |
Tax or VAT id |
-f, --file VALUE |
JSON with the fields to change (- for stdin) |
API: GET /billing/details, PUT /billing/details.
apidly billing
Balance, ledger, invoices, usage, top-up and billing details.
apidly billing [summary] (balance, auto top-up, default card, subscription and top-up limits; read-only)
apidly billing bonus (top-up bonus tiers: promotional credit a paid top-up earns; read-only)
apidly billing auto-topup off [--yes] (turn auto top-up off; turning it on is done in the console)
apidly billing balance | ledger | invoices | usage | topup AMOUNT | details [get|set] (same as the top-level commands)Shortcuts: apidly billing balance runs apidly balance; apidly billing ledger runs apidly ledger; apidly billing invoices runs apidly invoices; apidly billing statements runs apidly invoices; apidly billing usage runs apidly usage; apidly billing topup runs apidly topup; apidly billing details runs apidly billing-details.
| Option | What it does |
|---|---|
-y, --yes |
Do not ask |
API: GET /billing/summary.
API: GET /billing/topup-bonus.
API: PATCH /billing/auto-topup.
apidly cost
What one server has cost, since creation and this month.
apidly cost SERVER_IDAPI: GET /servers/{id}/billing.
apidly invoice
Save one invoice as its printable HTML page.
apidly invoice INVOICE_ID [--out FILE.html] [--lang CODE]| Option | What it does |
|---|---|
--out VALUE |
Output file (default: apidly-invoice-ID.html; - prints it) |
--lang VALUE |
Label language (a locale code such as de) |
API: GET /invoices/{id}.
apidly export
Write your servers, volumes and SSH keys as an apidly.yaml file, or download usage, ledger or activity as a CSV file.
apidly export [stack] [--stack NAME] [--out FILE]
apidly export usage [--group-by instance|day|gpu|member|template|tag|detail] [--from DATE] [--to DATE] [--out FILE]
apidly export ledger [--type TYPE] [--from DATE] [--to DATE] [--out FILE]
apidly export activity [--category C] [--actor ID] [--from DAY] [--to DAY] [--out FILE]| Option | What it does |
|---|---|
--stack VALUE |
stack: the stack name to write (default main); servers of other stacks are left out |
--group-by VALUE |
usage: how rows are grouped (default instance) |
--type VALUE |
ledger: topup, usage, refund, adjustment, subscription_credit or promo |
--category VALUE |
activity: signIn, team, keys, servers, billing or settings |
--actor VALUE |
activity: a member user id or an API key id |
--from VALUE |
Start (inclusive), e.g. 2026-11-01 |
--to VALUE |
End (usage and ledger: exclusive; activity: last day) |
--out VALUE |
Output file (default: prints the file) |
API: GET /billing/export, GET /activity/export, GET /servers, GET /servers/{id}/automation, GET /plans, GET /templates, GET /ssh-keys, GET /volumes, GET /endpoints.
apidly refund
Ask for a refund (opens a billing ticket; no money moves until a person decides).
apidly refund AMOUNT_USD --reason "TEXT" [--idempotency-key KEY] [--yes]| Option | What it does |
|---|---|
--reason VALUE |
Why, 10 to 2000 characters |
--idempotency-key VALUE |
Your own Idempotency-Key (a retry with it never repeats) |
-y, --yes |
Do not ask |
API: POST /billing/refund-requests.
apidly promo
Redeem a promo code (promotional credit, never refundable).
apidly promo CODEAPI: POST /billing/promo.
Lists, pages and output
Every list command takes --limit N (default 50), --all to follow every page, and --cursor C to continue from a nextCursor. When a list is cut short the command says so on stderr.
--output table is the default. --output json (or --json) prints the API's own JSON, including nextCursor. --output yaml prints the same data as YAML. Errors go to stderr, as JSON when the output is not a table. Exit code 0 is success, 1 a failure, 2 a typing mistake, 3 from apidly plan --detailed-exitcode when applying would change something, and 130 when Ctrl-C interrupted a wait (the server is left as it is).
id=$(apidly deploy --plan rtx-4090-1x --template pytorch --ssh-key ssh_abc --yes --json | jq -r '.server.id')
apidly servers --all --json | jq -r '.servers[].id'Shell completion
Generated from the same command table, so new commands and flags appear without any change to the scripts.
source <(apidly completion bash) # add to ~/.bashrc
source <(apidly completion zsh) # add to ~/.zshrc
apidly completion fish > ~/.config/fish/completions/apidly.fishErrors
Every API error prints the API's own sentence, the error code, a Next: line with the command to run where there is one, a help link when the API sends one, and the request id to quote to support. --debug also prints the raw response (address, status, headers and body). An unknown command suggests the closest one.
- Key missing or rejected: run
apidly init. - Balance too low: the message links to the billing page in the console. See billing and balance.
- Too many requests: the message says how many seconds to wait. Limits are in the API reference.
Deleting a server needs a key created by an owner or admin.
Settings
APIDLY_API_KEY overrides the saved key. --api-url, APIDLY_API_URL or apidly config set api-url URL sets the address of the service, for example when you use your own domain.
For code instead of a shell, see the SDKs.
Ready to try it?
Create a free account and add credit when you want to start a server. The smallest top-up is $10.
Was this helpful?