hosting
POST /v1/sites/{siteId}/edge-domains/{hostname}/dns
Publish this domain's DNS records for the customer.
Pengesahan
Hantar kunci API sebagai token pembawa. Kunci tersebut mesti membawa kebenaran hosting.deploy.manage; kunci yang tidak mempunyainya akan ditolak dengan 403, bukan 404.
Titik akhir ini tidak memerlukan id organisasi. Kunci anda telah mengenal pasti organisasi kepunyaannya, dan respons dis skopkan kepadanya.
Cuba
Gantikan apa sahaja di dalam kurungan sudut dengan nilai anda sendiri, dan pemegang tempat kunci dengan kunci dari papan pemuka anda.
curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/edge-domains/{hostname}/dns \
-H "Authorization: Bearer zdk_live_…"Sudah log masuk? Konsol API dalam papan pemuka anda mengisi id organisasi sebenar dan kunci anda sendiri, serta menjalankan permintaan terhadap API langsung supaya anda boleh melihat respons sebenar. Buka penamat ini dalam konsol API
Butiran
Writes the records and then resolves them, so the answer is what the internet says rather than what we did. Three tiers in order — the customer's own connected DNS provider, then our nameservers with the zone pre-built, then the records to publish by hand — and the tier that was actually used comes back as `mode`. In `nameservers` mode the `nameservers` array is the one thing left for the customer to do. Requires `hosting.deploy.manage`.
Parameter
| Nama | Jenis | Diperlukan | Apakah ia |
|---|---|---|---|
siteId (path) | Uuid | Ya | Site ID (UUIDv7). |
hostname (path) | string | Ya | The bound hostname, lower-cased and without a trailing dot. |
Respons
| Nama | Jenis | Diperlukan | Apakah ia |
|---|---|---|---|
hostname | string | Ya | — |
mode | string<unknown, our_zone, byo_dns, nameservers, manual> | Ya | — |
zone | string | Ya | — |
vendor | string | Ya | — |
detail | string | Ya | — |
nameservers | string[] | Ya | Populated only in `nameservers` mode — the zone is built and the records are in it, and setting these at the registrar is the one thing left to do. |
records | DnsRecordPlan[] | Ya | — |
checks | DnsRecordCheck[] | Ya | — |
resolves | boolean | Ya | — |
Ralat yang boleh dikembalikan oleh titik akhir ini
401 · 403 · 404 · 422 · 429