CLI Reference
The ske CLI is a standalone Go binary. It deploys, rolls back, runs commands and reads logs, metrics, secrets and jobs. Cloud providers, projects, environments, networks, databases, caches, domains and settings are managed in the dashboard. ske help <command> shows any command’s full help.
Global flags
Section titled “Global flags”These flags work on all commands:
| Flag | Description | Env override |
|---|---|---|
--json |
Output machine-readable JSON | — |
--api-url |
Override the SKE API base URL | SKE_API_URL |
--org |
Override the current organization slug | SKE_ORG |
--workspace |
Override the current workspace slug | SKE_WORKSPACE |
--project |
Override the linked project | SKE_PROJECT |
--env |
Override the linked environment | SKE_ENV |
--no-color |
Disable colored output | NO_COLOR |
Exit codes
Section titled “Exit codes”| Code | Meaning |
|---|---|
0 |
Success |
1 |
General failure |
2 |
Usage error (bad flags or arguments) |
3 |
Authentication error |
4 |
API error |
5 |
Conflict |
ske run exits with the remote command’s own exit code instead.
Authentication
Section titled “Authentication”ske login
Section titled “ske login”Sign in to SKE using passwordless authentication.
ske login [--email you@example.com]Emails you a link to approve this sign-in and prints a code, then waits. Open the link, check it shows the same code, and press Approve; the command finishes on its own once you do. On success, stores credentials in ~/.ske/credentials.json.
| Flag | Description |
|---|---|
--email |
Email address (prompted if omitted; required with --json) |
ske logout
Section titled “ske logout”Sign out and revoke this machine’s session.
ske logoutRevokes the session server-side, then deletes ~/.ske/credentials.json. Refuses if SKE_API_TOKEN is set (unset it instead).
ske whoami
Section titled “ske whoami”Show the signed-in account and current organization.
ske whoamiyou@example.com — acme-corpOrganizations
Section titled “Organizations”ske orgs
Section titled “ske orgs”List organizations you belong to. Alias: ske organizations.
ske orgsSLUG NAME PERSONAL* acme-corp Acme Corporation nojane-doe Jane Doe yesThe current organization is marked with *.
ske orgs switch
Section titled “ske orgs switch”Set the organization later commands operate on.
ske orgs switch <slug>ske orgs switch acme-corpNow using acme-corpValidates the slug with the server, saves it to ~/.ske/config.json and clears the cached workspace, so the next command finds the new organization’s default workspace.
Workspaces
Section titled “Workspaces”ske workspace list
Section titled “ske workspace list”List workspaces in the current organization.
ske workspace listNAME SLUG DEFAULT CREATEDProduction production yes 2026-08-15T10:02:11.000000ZStaging staging no 2026-08-20T08:41:57.000000Zske workspace switch
Section titled “ske workspace switch”Switch to a different workspace.
ske workspace switch <slug>ske workspace switch stagingSwitched to workspace Staging (staging)Project Setup
Section titled “Project Setup”ske link
Section titled “ske link”Link this directory to a project and a default environment.
ske link [--project <project>] [--env <environment>]Without flags it lists the workspace’s projects and then the project’s environments, and asks for each. The choice is saved in .ske/project.json, and .ske/ is added to .gitignore. Commands run in the directory then use them without --project or --env. Without a terminal (CI, --json), both flags are required; in CI, setting SKE_PROJECT and SKE_ENV instead of linking also works.
ske dockerfile
Section titled “ske dockerfile”Create ske/Dockerfile, a starter for the project’s own build steps (system packages, extensions). ske deploy joins it into the Dockerfile SKE generates. An existing ske/Dockerfile is never overwritten. See Build configuration.
ske dockerfileske version
Section titled “ske version”Print the CLI version and build information.
ske versionske 1.0.0 (linux/amd64)commit abc1234built 2026-09-20T14:30:00Zske completion
Section titled “ske completion”Generate the autocompletion script for your shell (bash, zsh, fish or powershell).
ske completion zshDeployments
Section titled “Deployments”ske deploy
Section titled “ske deploy”Deploy the current directory to the linked environment (or the one --env names).
ske deploy [--env <environment>] [--project <project>]For an application, the CLI builds a Docker image from the runtime’s generated Dockerfile and ske/Dockerfile, pushes it, and uploads its public assets. Docker must be installed and running. For a static site, it runs the environment’s build command with the environment’s variables set, then uploads its output directory; Docker is not needed.
Deployment 7246183051948032011 initialized.Building image (linux/arm64)... ...Image pushed.Uploaded 128 assets.Deployment 7246183051948032011 started.
[stack] Stack ready[function] Functions updated[alias] Traffic switchedDeployment succeeded (sequence #42) in 2m 41s
Application URL: https://abc123.execute-api.us-east-1.amazonaws.comske deploy list
Section titled “ske deploy list”List recent deployments.
ske deploy list [--limit <n>]| Flag | Description | Default |
|---|---|---|
--limit |
Number of deployments to show | 15 |
ID TYPE STATUS INITIATOR CREATED7246183051948032011 deploy succeeded you@example.com 2026-09-20T14:30:12.000000Z7245860719322145803 rollback succeeded you@example.com 2026-09-19T09:15:40.000000Z7245517348101873667 deploy succeeded ci@example.com 2026-09-18T16:00:03.000000Zske deploy show
Section titled “ske deploy show”Show deployment details including the output log.
ske deploy show <deployment-id>ske status
Section titled “ske status”Show the latest deployment status.
ske status [--env <environment>]ske rollback
Section titled “ske rollback”Roll back to a previous deployment.
ske rollback [--to <deployment-id>] [--env <environment>]| Flag | Description |
|---|---|
--to |
Specific deployment ID to roll back to (defaults to the previous successful one) |
Operations
Section titled “Operations”ske run
Section titled “ske run”Run a shell command on the linked environment (or the one --env names), wait for it to end, print its output and exit with its exit code.
ske run [--env <environment>] <command...>ske run list [--limit <n>]ske run show <run-id>Flags of ske go before the command: everything from the command’s first word on is sent as it is. A command can’t be stopped once it has started; Ctrl-C stops waiting for it. See Artisan commands.
ske run php artisan migrate --forceske run --env production bin/rails db:migrateske run -- listske logs
Section titled “ske logs”Show an environment’s logs, newest first.
ske logs [env] [--since 1h] [--level error] [--search <pattern>] [--function http] [--limit 100] [--platform] [-f]See Logs for each flag.
ske metrics
Section titled “ske metrics”Show an environment’s metrics over a period, read live from the cloud provider: API Gateway requests, each function’s invocations, errors, throttles and duration, queue backlogs, and the estimated application-layer cost.
ske metrics [env] [--period 1d]| Flag | Description | Default |
|---|---|---|
--period |
Period to report: 1m, 5m, 30m, 1h, 8h, 1d, 3d, 7d, 1M |
1d |
ske database metrics
Section titled “ske database metrics”Show a database’s CPU, connections, memory, IOPS, latency, storage and ACU, read live from the cloud provider.
ske database metrics <name> [--period 1d]Secrets
Section titled “Secrets”ske secret list
Section titled “ske secret list”List secrets for the current environment.
ske secret list [--env <environment>]KEY LAST MODIFIEDAPP_KEY 2026-09-15 14:30STRIPE_SECRET 2026-09-15 14:32ske secret set
Section titled “ske secret set”Set a secret value.
ske secret set <key> [--value <value>] [--env <environment>]If --value is omitted, prompts for the value with hidden input. Supports piped stdin:
printf '%s' "$SECRET" | ske secret set API_KEYske secret delete
Section titled “ske secret delete”Delete a secret.
ske secret delete <key> [--force] [--env <environment>]| Flag | Description |
|---|---|
--force |
Skip confirmation prompt |
ske secret import
Section titled “ske secret import”Set secrets from a .env file (- reads standard input).
ske secret import <file> [--dry-run] [--prune] [--yes]Prints what changes first: keys to add, change, keep or remove (with --prune), with values never shown. Then asks before applying, unless --yes is passed. A file with lines that can’t be read changes nothing.
| Flag | Description |
|---|---|
--dry-run |
Print the changes without applying them |
--prune |
Remove secrets the file doesn’t set |
--yes |
Apply without asking |
ske job list
Section titled “ske job list”List recent infrastructure jobs.
ske job list [--limit <n>]| Flag | Description | Default |
|---|---|---|
--limit |
Number of jobs to show | 15 |
ID TYPE STATUS CREATED7246181998310522881 database:create succeeded 2026-09-20T14:30:41.000000Z7246181523785342977 network:create succeeded 2026-09-20T14:28:09.000000Zske job show
Section titled “ske job show”Show job details including steps and output.
ske job show <job-id>Configuration
Section titled “Configuration”Resolution precedence
Section titled “Resolution precedence”API URL: --api-url flag → SKE_API_URL env → api_url in config.json → https://api.ske.io
Organization: --org flag → SKE_ORG env → the linked directory’s organization → current_org in config.json
Workspace: --workspace flag → SKE_WORKSPACE env → the linked directory’s workspace → current_workspace in config.json → the organization’s default workspace
Project: --project flag → SKE_PROJECT env → the linked project
Environment: --env flag → SKE_ENV env → the linked default environment
Configuration files
Section titled “Configuration files”| File | Location | Mode | Contents |
|---|---|---|---|
config.json |
~/.ske/config.json |
0644 |
API URL, current org, current workspace |
credentials.json |
~/.ske/credentials.json |
0600 |
Access token, refresh token, email, expiry |
project.json |
.ske/project.json in the linked directory |
0644 |
Organization, workspace, project and default environment |
Token refresh
Section titled “Token refresh”Access tokens are short-lived. The CLI refreshes them with the stored refresh token. File locking prevents concurrent CLI invocations from racing on the same refresh.
Environment variables
Section titled “Environment variables”| Variable | Purpose |
|---|---|
SKE_API_URL |
Override API base URL (default: https://api.ske.io) |
SKE_ORG |
Override current organization slug |
SKE_WORKSPACE |
Override current workspace slug |
SKE_PROJECT |
Override the linked project |
SKE_ENV |
Override the linked environment |
SKE_API_TOKEN |
Static API token for CI (skips credential file) |
SKE_CONFIG_DIR |
Override config directory (default: ~/.ske) |
NO_COLOR |
Disable colored output |