การยืนยันตัวตน

ส่ง API key ในรูปแบบ bearer token คีย์ดังกล่าวต้องมีสิทธิ์ sites.view หากไม่มีสิทธิ์ ระบบจะปฏิเสธด้วยรหัส 403 แทนที่จะเป็น 404

ปลายทางนี้ไม่ต้องใช้รหัสองค์กร คีย์ของคุณระบุองค์กรที่เป็นเจ้าของอยู่แล้ว และการตอบกลับจะถูกจำกัดขอบเขตไว้เฉพาะองค์กรนั้น

ทดลองใช้เลย

แทนที่สิ่งใดๆ ที่อยู่ภายในวงเล็บแหลมด้วยค่าของคุณเอง และตัวยึดตำแหน่งคีย์ด้วยคีย์จากแดชบอร์ดของคุณ

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

เข้าสู่ระบบแล้วใช่ไหม คอนโซล API ในแดชบอร์ดของคุณจะเติมรหัสองค์กรจริงและคีย์ของคุณเองโดยอัตโนมัติ และทำการส่งคำขอไปยัง API จริง เพื่อให้คุณเห็นผลลัพธ์ที่เป็นข้อมูลจริง เปิดจุดสิ้นสุดนี้ในคอนโซล API

รายละเอียด

Whether anything is scheduled for this site, when it fires, and whether it can still be stopped. This is also where the client reads primary_domain — the value the customer must type into deleteSite — so the instruction on screen and the check on the server come from one place and cannot drift apart. ⛔ can_cancel is its own field and must never be recomputed as state == "scheduled". Once the teardown starts, the request row still says scheduled while the site is already being deleted; a client doing its own arithmetic would offer the cancel button at the exact moment it can only fail. Requires sites.view only — a read-only member learning that their site is about to be deleted is the whole point, and hiding the countdown from them would mean the first they hear of it is the site being gone. 404 for a site with no vendor hosting package, or one that is not theirs.

พารามิเตอร์

ชื่อประเภทจำเป็นต้องมีลักษณะของสิ่งนี้
siteId (path)Uuidใช่Site ID (UUIDv7).

การตอบกลับ

ชื่อประเภทจำเป็นต้องมีลักษณะของสิ่งนี้
site_idstringใช่The site this deletion state belongs to.
primary_domainstringใช่⛔ What the customer must type into deleteSite, and what the engine compares against. Read it from here rather than from a Site object already on screen: one value on both…
statestring<none, scheduled, running, stalled, deleted>ใช่Where the site is in its lifecycle. A stable machine value the client turns into a localised sentence — never English composed by the engine (§2.19). ⛔ stalled is running that…
deletablebooleanใช่Whether a deletion could be requested right now. False on a site whose state does not allow it, so the form is explained rather than offered and refused.
scheduled_forstringใช่When the teardown fires, or null when nothing is scheduled.
requested_atstringใช่When the deletion was requested, or null when nothing is scheduled.
grace_daysintegerใช่How many days the countdown runs. Clamped at both ends — a floor of one day is what stops a misconfiguration meaning delete now.
grace_free_reasonstring<, internal, never_provisioned>ใช่Why this site would skip the grace period entirely, or "" when it would not. never_provisioned means the site is failed — provisioning never completed, so nothing was ever…
can_cancelbooleanใช่Its own field, and never recomputed as state == "scheduled". Once the teardown starts, the request row still says scheduled while the site is already being deleted; a…

ข้อผิดพลาดที่เอนด์พอยต์นี้สามารถส่งกลับได้

401 · 403 · 404 · 429 · 503