hosting

POST /v1/sites/deleted/{deletedSiteId}/restore

Restore a deleted site.

تمام hosting اینڈ پوائنٹس

توثيقِ شناخت

ایک بیرر ٹوکن کے طور پر ایک API کی بھیجیں۔ کی کے پاس sites.create اجازت ہونی چاہیے؛ اس کے بغیر کی کو 404 کے بجائے 403 کے ساتھ مسترد کر دیا جاتا ہے۔

یہ اینڈ پوائنٹ کوئی آرگنائزیشن آئی ڈی نہیں لیتا۔ آپ کی کلید پہلے ہی اس آرگنائزیشن کی شناخت کرتی ہے جس سے یہ تعلق رکھتی ہے، اور اس کا جواب اسی کے مطابق محدود ہوتا ہے۔

آزمائیں

کوئی بھی چیز جو زاویہ دار قوسین میں ہو اسے اپنی اقدار سے بدلیں، اور کلیدی پلیس ہولڈر کو اپنے ڈیش بورڈ کی کسی کلید سے بدلیں۔

curl -X POST https://api.zinndigital.com/v1/sites/deleted/{deletedSiteId}/restore \
  -H "Authorization: Bearer zdk_live_…"

لاگ ان ہیں؟ آپ کے ڈیش بورڈ میں موجود API کنسول آپ کی حقیقی تنظیم کی آئی ڈی اور آپ کی اپنی کلید خود بخود پُر کر دیتا ہے، اور لائیو API پر درخواست چلاتا ہے تاکہ آپ اصل ردعمل دیکھ سکیں۔ اس اینڈ پوائنٹ کو API کنسول میں کھولیں

تفصیلات

Brings a deleted site back. Answers `202` — the site is rebuilt by a workflow, and returns to `suspended` rather than `active` until it is actually serving again. ⛔ **The guard is re-evaluated on this request, never trusted from the button.** Between the list rendering and the click the customer may have recreated a site on the same domain, the retention window may have closed, or the purge may have run. A `422` carries the machine-readable reason (`no_backup`, `purged`, `domain_in_use`, `already_restored`, `abuse_hold`) so the client can say which it was. Requires `sites.create` as well as `sites.view`: a restore *creates* a live site.

پیرامیٹرز

نامقسملازمییہ کیا ہے
deletedSiteId (path)UuidہاںThe `DeletedSite` record id (not the site id).

جواب

نامقسملازمییہ کیا ہے
idUuidہاںUUIDv7 identifier — sortable by creation time (docs/02 §8).
site_idUuidہاںThe site this was. May no longer exist as a row.
org_idUuidہاںUUIDv7 identifier — sortable by creation time (docs/02 §8).
primary_domainstringہاں
reasonstring<dunning, customer, staff, abuse>ہاںWhy it was deleted. `abuse` is restorable by staff only — a one-click customer restore of a site removed for terms enforcement would undo the enforcement.
deleted_atstringہاںSoft delete — removed from serving. The data is still here.
deleted_bystringنہیں
purge_due_atstringنہیں**When the backup is purged and the site becomes permanently unrecoverable.** ⛔ Computed by the engine from the live retention policy, by the same function the purge sweep selec…
purged_atstringنہیںHard delete. Non-null means the data is gone and no restore is possible.
restored_atstringنہیں
restorablebooleanہاںWhether a restore would succeed **right now**. Reflects a real check that the backup object exists in storage — not a status column.
reason_codestring<, no_backup, purged, domain_in_use, already_restored, abuse_hold>ہاںEmpty when restorable. Otherwise one of `no_backup`, `purged`, `domain_in_use`, `already_restored`, `abuse_hold`. ⛔ A **code**, rendered by the client through its own catalogue…

وہ خرابیان جو یہ اینڈ پوائنٹ واپس کر سکتا ہے

401 · 403 · 404 · 422 · 429 · 503