hosting

GET /v1/sites/{siteId}/deploy

Get a site's deploy target and status.

Բոլոր hosting վերջնակետերը

Նույնականացում

Ուղարկեք API բանալին որպես bearer token: Բանալին պետք է ունենա sites.view թույլտվությունը. առանց դրա բանալին մերժվում է 403, և ոչ թե 404 կարգավիճակով:

Այս վերջնակետը կազմակերպության ID չի ընդունում: Ձեր բանալին արդեն իսկ նույնականացնում է այն կազմակերպությունը, որին պատկանում է, և պատասխանը սահմանափակված է դրանով:

Փորձել

Փոխարինեք անկյունային փակագծերում գտնվող ցանկացած բան ձեր սեփական արժեքներով, և բանալու տեղապահը՝ ձեր վահանակի բանալիով:

curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/deploy \
  -H "Authorization: Bearer zdk_live_…"

Մուտք գործե՞լ եք: Ձեր վահանակի API վահանակը լրացնում է ձեր իրական կազմակերպության ID-ն և ձեր սեփական բանալին և գործարկում է հարցումը ուղիղ API-ի դեմ, որպեսզի կարողանաք տեսնել փաստացի պատասխանը: Բացեք այս վերջնակետը API վահանակում

Մանրամասներ

A site that has never been deployed reports status `idle` with null details — null means "nothing to show", never zero or an epoch. This is polled while a deploy is in flight, so it is a cheap database read and never calls a build provider. Requires `sites.view`.

Պարամետրեր

ԱնունՏեսակՊահանջվում էԻնչ է դա
siteId (path)UuidԱյոSite ID (UUIDv7).

Պատասխան

ԱնունՏեսակՊահանջվում էԻնչ է դա
site_idUuidԱյոUUIDv7 identifier — sortable by creation time (docs/02 §8).
targetDeployTarget | nullԱյոNull when no target can be derived yet.
statusDeployStatusԱյո`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_atobjectԱյո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_urlobjectԱյոThe served URL once live, always https, else null. A non-HTTPS value is rejected server-side rather than returned.
repoobjectԱյոSource repository for the Pages targets, else null.
commitobjectԱյոThe deployed commit ref, else null.
messageobjectԱյոWhy the last deploy failed, else null. Rendered to the customer verbatim.
can_deploybooleanԱյոFalse while a deploy is in flight or the site cannot be deployed.

Այս վերջնակետի կողմից վերադարձվող սխալները

401 · 403 · 404 · 429