REST API Referansı

Skyversal REST API referansı: proje, deploy, ortam değişkeni, alan adı, yedek, cron ve e-posta uçları. Device-code OAuth akışı, rol matrisi ve rate-limit tablosuyla.

Skyversal REST API, panelde yapabildiğiniz her şeyi programatik erişime açar — Skyversal CLI'ın konuştuğu yüzeyin ta kendisidir. Projeler, dağıtımlar, ortam değişkenleri, alan adları, yedekler, zamanlanmış görevler ve e-posta servisi buradan yönetilir.

İnteraktif deneme: uçları tarayıcıdan canlı çağırmak için API Explorer'ı açın. Makine-okunur spec: /api/openapi.yaml (veya .json).

Kimlik doğrulama — cihaz kodu (RFC 8628)

  1. POST /device/code → device_code + user_code döner.
  2. Kullanıcı verification_uri'yi açıp kodu onaylar — şifre terminale hiç girmez.
  3. POST /device/token → Bearer access_token döner.
  4. Tüm kimlikli isteklerde Authorization: Bearer <token> gönderilir.

Yetki matrisi ve hız limitleri

Proje kapsamlı her uç {projectKey}'i sayısal id veya slug olarak çözer, sonra rolünüzü kontrol eder: owner > manager > developer > viewer. Okuma uçları viewer, yazma uçları manager ister. Yetkisiz veya olmayan proje 404 döner — kaynağın varlığı sızdırılmaz.

HavuzLimit
Okuma (kimlikli GET)60 istek/dk
Yazma (POST/PUT/PATCH/DELETE)10 istek/dk
Kaynak yükleme20 istek/dk
Cihaz kodu / token yoklama10 / 30 istek/dk
Herkese açık health & apps60 istek/dk

Uç noktalar

Açıklamalar spesifikasyondaki gibidir (teknik terimler İngilizce kalır). Temel adres: https://skyversal.com/api/cli

Kimlik Doğrulama

POST/device/code

Request a device code

Starts the device authorization flow. Returns the codes the user must approve in the browser.

Body (application/json): client_id — gerekli: client_id

200 · 422 · 429

POST/device/token

Poll for an access token

Poll until the user approves (authorization_pending) or the code expires. On approval returns a Bearer token.

Body (application/json): client_id, grant_type, device_code — gerekli: client_id, grant_type, device_code

200 · 400 · 422 · 429

GET/whoami

Current token owner

200 · 401 · 429

Platform

GET/health

Platform health

200 · 429

GET/apps

Installable app catalog

200 · 429

POST/apps/install

Install an app

Requires manager role.

Body (application/json): app_id — gerekli: app_id

200 · 401 · 422 · 429

GET/doctor

Connectivity self-check

200 · 401 · 429

Projeler

GET/projects

List accessible projects

Owned + shared projects, sorted by name. Viewer role is enough.

200 · 401 · 429

POST/projects

Create a project

Requires manager role. A verified e-mail address is required first (403 otherwise).

Body (application/json): name, framework, port — gerekli: name

201 · 401 · 403 · 422 · 429

GET/projects/{projectKey}

Project detail

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/restart

Restart the process

Requires manager role. Restarts the running container — no rebuild.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

Dağıtımlar

POST/projects/{projectKey}/deploy

Trigger a deploy

Requires manager role. Rebuilds from the linked source (GitHub/template) or the last uploaded artifact.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/deploys

Deployment history

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/deploys/{deploymentId}

Deployment status

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
deploymentId *path(integer)

200 · 401 · 404 · 429

GET/projects/{projectKey}/deploys/{deploymentId}/logs

Deployment build log

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
deploymentId *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/deploys/{deploymentId}/rollback

Roll back to a deployment

Requires manager role. Re-points traffic to a previous image — no rebuild.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
deploymentId *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/deploys/{deploymentId}/cancel

Cancel a deployment

Requires manager role. Queued deploys cancel immediately; running builds stop at the next checkpoint.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
deploymentId *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/upload

Upload source artifact

Requires manager role. Multipart upload of a .tar.gz source
snapshot (max 100 MB). Pass deploy=true to deploy right after.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (multipart/form-data): source, deploy — gerekli: source

200 · 401 · 404 · 422 · 429

Ortam Değişkenleri

GET/projects/{projectKey}/env

List environment variables

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/env

Set environment variables

Requires manager role. Keys must match ^[A-Za-z_][A-Za-z0-9_]*$.
Changes take effect on the next deploy.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): vars — gerekli: vars

200 · 401 · 404 · 422 · 429

DELETE/projects/{projectKey}/env/{envKey}

Delete an environment variable

Requires manager role.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
envKey *path

200 · 401 · 404 · 429

Log ve Metrikler

GET/projects/{projectKey}/logs/runtime

Runtime logs

Live application logs from the running container.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/logs/access

Access log summary

IP / user-agent / path breakdown for the project's own domains.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/metrics

Resource metrics

CPU / RAM / disk usage of the running container.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

Alan Adları

GET/projects/{projectKey}/domains

List domains

Domains attached to the project, with SSL state.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/domains

Attach a domain

Requires manager role. Platform subdomains (*.skyversal.xyz etc.)
cannot be attached — they are auto-assigned. SSL starts as pending;
call verify once DNS has propagated.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): domain — gerekli: domain

200 · 401 · 404 · 409 · 422 · 429

DELETE/projects/{projectKey}/domains/{hostOrId}

Detach a domain

Requires manager role.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
hostOrId *pathDomain host (`www.example.com`) or numeric id.

200 · 401 · 404 · 429

POST/projects/{projectKey}/domains/{hostOrId}/verify

Verify domain (DNS + TLS)

Requires manager role. Runs a real TLS handshake; writes active only when the certificate is live — never fabricated.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
hostOrId *pathDomain host (`www.example.com`) or numeric id.

200 · 401 · 404 · 429

Yedekler

GET/projects/{projectKey}/backups

List backups

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/backups

Take a backup now

Requires manager role. Runs asynchronously.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

DELETE/projects/{projectKey}/backups/{id}

Delete a backup

Requires manager role.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

200 · 401 · 404 · 429

GET/projects/{projectKey}/backups/{id}/download

Download a backup

Returns the backup file for download. Viewer role is enough.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/backups/{id}/restore

Restore a backup

Requires manager role. Destructive — overwrites the live
database. Body confirm must exactly equal the backup's filename.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

Body (application/json): confirm — gerekli: confirm

200 · 401 · 404 · 422 · 429

GET/projects/{projectKey}/backup-schedule

Read backup schedule

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

PUT/projects/{projectKey}/backup-schedule

Set backup schedule

Requires manager role. Retention derives from interval (hourly → 3d, 3-hourly → 7d, daily → 30d). The newest successful backup is never pruned.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): every_hours

200 · 401 · 404 · 422 · 429

PATCH/projects/{projectKey}/backup-schedule

Set backup schedule (PATCH)

Same as PUT — both verbs accepted.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): every_hours

200 · 401 · 404 · 422 · 429

Kaynak Sınırları

GET/projects/{projectKey}/scale

Current resource limits

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

PATCH/projects/{projectKey}/scale

Set resource limits

Requires manager role. Values must stay under the plan +
add-on ceiling — raising the ceiling is billing's job; the API
returns 422 instead of silently clipping.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): ram_mb, cpu_mcpu, disk_mb

200 · 401 · 404 · 422 · 429

Zamanlanmış Görevler

GET/projects/{projectKey}/cron

List scheduled jobs

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/cron

Create a scheduled job

Requires manager role. cron_expression is validated up front — an invalid expression is rejected instead of silently never running.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): name, command, cron_expression, timezone, timeout_seconds — gerekli: name, command, cron_expression

200 · 401 · 404 · 422 · 429

DELETE/projects/{projectKey}/cron/{id}

Delete a job

Requires manager role.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/cron/{id}/toggle

Enable / disable a job

Requires manager role.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

200 · 401 · 404 · 429

POST/projects/{projectKey}/cron/{id}/run

Run a job now

Requires manager role. Fires the command immediately, outside the schedule.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.
id *path(integer)

200 · 401 · 404 · 429

E-posta Servisi

GET/projects/{projectKey}/mail

Mail service status

Enabled state, sender domain, quota usage, DNS health.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

PUT/projects/{projectKey}/mail

Configure mail service

Requires manager role. Set sender domain or toggle the service. Your MX records are never touched — inbound mail keeps working.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): domain, enabled

200 · 401 · 404 · 422 · 429

PATCH/projects/{projectKey}/mail

Configure mail service (PATCH)

Same as PUT — both verbs accepted.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): domain, enabled

200 · 401 · 404 · 422 · 429

DELETE/projects/{projectKey}/mail

Disable mail service

Requires manager role. DNS records are kept — re-enable any time.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/mail/relay

Relay (SMTP) credentials info

Shared-relay SASL endpoint + username for direct SMTP use.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/mail/dns

DNS records to publish

SPF + DKIM records needed for the sender domain.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/mail/verify

Verify mail DNS

Live check whether published DNS matches expected records.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/mail/usage

Quota usage + trend

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

GET/projects/{projectKey}/mail/log

Send history

Message-ID based send log for the project.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

POST/projects/{projectKey}/mail/test

Send a test e-mail

Requires manager role. Fails cleanly when the service is off — enable first.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

Body (application/json): to — gerekli: to

200 · 401 · 404 · 422 · 429

POST/projects/{projectKey}/mail/provision

Provision / repair mail service

Requires manager role. (Re)creates SASL + DKIM for the project — idempotent repair path.

ParamInAçıklama / Type
projectKey *pathProject numeric **id** or **slug**.

200 · 401 · 404 · 429

Veritabanları

GET/databases

List databases

Account-scoped databases owned by the token user.

200 · 401 · 429

POST/databases

Create a database

Requires manager-equivalent account scope.

Body (application/json): engine, name — gerekli: engine

200 · 401 · 422 · 429

DELETE/databases/{id}

Delete a database

ParamInAçıklama / Type
id *path`project_303`, `standalone_8` or bare numeric id.

200 · 401 · 404 · 429

GET/databases/{id}/credential

Database credentials

Connection credentials. Accepts project_303, standalone_8 or a bare 8 as id.

ParamInAçıklama / Type
id *path`project_303`, `standalone_8` or bare numeric id.

200 · 401 · 404 · 429

Redis

GET/redis

List Redis instances

Account-scoped Redis instances owned by the token user.

200 · 401 · 429

POST/redis

Create a Redis instance

200 · 401 · 422 · 429

DELETE/redis/{id}

Delete a Redis instance

ParamInAçıklama / Type
id *path`project_303`, `standalone_8` or bare numeric id.

200 · 401 · 404 · 429

Bu referans openapi.yaml dosyasından otomatik üretilir — spec güncellendikçe sayfa da güncellenir.

Son güncelleme: 4 Kasım 2026
Bu sayfayı GitHub'da düzenle