hosting
POST /v1/offsite-destinations
Add a place to send backups to, after proving we can write, read and delete there.
Autentifikacija
Pošaljite API ključ kao nosivi token. Ključ mora imati dozvolu hosting.backup.manage; ključ bez nje se odbija s kodom 403, a ne 404.
Gdje dolazi ID vaše organizacije
Ova krajnja točka prihvaća org_id kao polje u JSON tijelu.
ID vaše organizacije nalazi se na zaslonu API ključeva u vašoj nadzornoj ploči, pored samog ključa. To je isti ID u svakom pozivu koji uputite.
Isprobajte
Zamijenite sve unutar šiljastih zagrada svojim vlastitim vrijednostima, a rezervirano mjesto za ključ s ključem iz vaše nadzorne ploče.
curl -X POST https://api.zinndigital.com/v1/offsite-destinations \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string>, "kind": <string<s3, sftp>> }'Prijavljeni ste? API konzola na vašoj nadzornoj ploči automatski unosi stvarni ID vaše organizacije i vaš vlastiti ključ te šalje zahtjev prema aktivnom API-ju kako biste mogli vidjeti stvarni odgovor. Otvori ovu krajnju točku u API konzoli
Pojedinosti
The destination is saved only after a real round trip: a small test file is written, read back byte for byte and deleted. For SFTP the server's host key is read without authenticating and pinned; every later connection must present it. Addresses must be on the public internet and S3 endpoints must be https://. Credentials are write-only and go straight to our secret store with a fresh encryption key; every archive is encrypted (AES-256-CTR with HMAC-SHA256) before it leaves us. Refusals are 422 with a machine code in details[0].code. Requires hosting.backup.manage.
Tijelo zahtjeva
| Naziv | Vrsta | Obavezno | Što je to |
|---|---|---|---|
org_id | string | Ne | — |
name | string | Da | — |
kind | string<s3, sftp> | Da | — |
prefix | string | Ne | — |
endpoint | string | Ne | S3: an https:// endpoint with no path. |
region | string | Ne | S3: the bucket's region, or auto for Cloudflare R2. |
bucket | string | Ne | — |
access_key_id | string | Ne | — |
secret_access_key | string | Ne | — |
host | string | Ne | SFTP: the server's host name. |
port | integer | Ne | — |
username | string | Ne | — |
password | string | Ne | — |
private_key | string | Ne | OpenSSH format. |
Odgovor
| Naziv | Vrsta | Obavezno | Što je to |
|---|---|---|---|
id | string | Da | — |
org_id | string | Da | — |
name | string | Da | — |
kind | string<s3, sftp> | Da | — |
endpoint | string | Ne | — |
region | string | Ne | — |
bucket | string | Ne | — |
host | string | Ne | — |
port | integer | Ne | — |
username | string | Ne | — |
host_key_fingerprint | string | Ne | The pinned SFTP host key as SHA256:…, the form ssh-keygen -lf prints. |
prefix | string | Da | — |
status | string<working, failing> | Da | — |
last_checked_at | string | Ne | — |
last_check_code | string | Ne | — |
sites_using | integer | Da | — |
created_at | string | Da | — |
Pogreške koje ova krajnja točka može vratiti
401 · 403 · 404 · 422