hosting

GET /v1/sites/{siteId}/deploy

Get a site's deploy target and status.

همه نقاط پایانی hosting

احراز هویت

یک کلید API را به عنوان یک توکن حامل ارسال کنید. این کلید باید دارای مجوز sites.view باشد؛ کلیدی که فاقد آن باشد با خطای 403 رد می‌شود، نه 404.

این نقطه پایانی هیچ شناسه سازمانی را دریافت نمی‌کند. کلید شما در حال حاضر سازمان مربوطه را مشخص می‌کند و پاسخ در همان محدوده ارائه می‌شود.

امتحان کنید

هر چیزی را که داخل براکت‌های زاویه‌دار قرار دارد با مقادیر خودتان جایگزین کنید، و نگهدارنده کلید را با کلیدی از داشبورد خود جایگزین نمایید.

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

وارد شده‌اید؟ کنسول API در داشبورد شما شناسه سازمان واقعی و کلید خودتان را پر می‌کند و درخواست را روی 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