Uwierzytelnianie
Wyślij klucz API jako token bearer. Klucz musi posiadać uprawnienie hosting.deploy.manage; klucz bez niego jest odrzucany z kodem 403, a nie 404.
Ten punkt końcowy nie wymaga identyfikatora organizacji. Twój klucz już identyfikuje organizację, do której należy, a odpowiedź jest do niej ograniczona.
Wypróbuj
Zastąp wszystko w nawiasach ostrych własnymi wartościami, a zastępczy znacznik klucza kluczem ze swojego pulpitu nawigacyjnego.
curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/deploy \
-H "Authorization: Bearer zdk_live_…"Zalogowany? Konsola API w Twoim panelu uzupełnia rzeczywiste identyfikator organizacji oraz Twój własny klucz i wykonuje żądanie względem aktywnego API, dzięki czemu możesz zobaczyć rzeczywistą odpowiedź. Otwórz ten punkt końcowy w konsoli API
Szczegóły
Starts a durable deploy workflow and returns immediately with the new in-flight state. The target is derived from the site's stack and its connected accounts; there is no target to choose. A site with a deploy already running returns `DEPLOY_IN_PROGRESS`, and one with no usable target returns `DEPLOY_TARGET_UNAVAILABLE`. Requires `hosting.deploy.manage`.
Parametry
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
siteId (path) | Uuid | Tak | Site ID (UUIDv7). |
Idempotency-Key (header) | string | Nie | Client-generated key that makes an unsafe request replay-safe: the server stores the first response and returns it verbatim for repeats. |
Odpowiedź
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
site_id | Uuid | Tak | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
target | DeployTarget | null | Tak | Null when no target can be derived yet. |
status | DeployStatus | Tak | `idle` means the site has never been deployed. It is reported, never stored — a stored idle would be a second way to say "no deployments" that could contradict the first. |
last_deployed_at | object | Tak | When the site last went live, or null if it never has. Null means nothing to show — never zero and never an epoch date. |
live_url | object | Tak | The served URL once live, always https, else null. A non-HTTPS value is rejected server-side rather than returned. |
repo | object | Tak | Source repository for the Pages targets, else null. |
commit | object | Tak | The deployed commit ref, else null. |
message | object | Tak | Why the last deploy failed, else null. Rendered to the customer verbatim. |
can_deploy | boolean | Tak | False while a deploy is in flight or the site cannot be deployed. |
Błędy, które ten punkt końcowy może zwrócić
401 · 403 · 404 · 409 · 422 · 429 · 503