hosting
POST /v1/storage/buckets
Provision Zinn® storage, or attach a bucket of your own.
Tabbatar da Asali
Aika maɓallin API azaman alamar ɗauka (bearer token). Dole ne maɓallin ya kasance yana da izinin storage.manage; idan babu shi, za a ƙi amfani da maɓallin tare da lambar 403, ba 404 ba.
Wannan wurin ƙarewa ba ya buƙatar ID na ƙungiya. Maɓallin ku ya riga ya gano ƙungiyar da yake ciki, kuma an iyakance amsa a kanta.
Gwada
May gurbin komai da ke cikin kusurwa da ƙimar ka, kuma may gurbin maballi da maballi daga allon sarrafa ka.
curl -X POST https://api.zinndigital.com/v1/storage/buckets \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string> }'An shiga? Na'urar sarrafa API da ke cikin sashin kulawarka tana cika ainihin lambar ƙungiyarka da maɓallinka naka, sannan tana gudanar da buƙatar a kan ainihin API don haka zaka iya ganin amsar gaske. Buɗe wannan tashar a cikin na'urar kula da API
Bayani
With `ownership: zinn` this provisions storage on our own backend and needs nothing else. With `ownership: customer` it attaches an existing S3-compatible bucket and requires `bucket_name`, `endpoint`, `access_key_id` and `secret_access_key`. The key pair is written to Vault and never to a column; the bucket is created `pending` and only becomes `active` once the write has returned, so a failure part way leaves a visibly unfinished bucket rather than one that reads as configured and cannot sign. Requires `storage.manage`.
Jikin buƙata
| Suna | Nau'i | Ana buƙata | Abin da yake |
|---|---|---|---|
name | string | Eh | — |
ownership | string<zinn, customer> | A'a | — |
vendor | string<r2, s3, b2, bunny, gcore, minio> | A'a | — |
bucket_name | string | A'a | — |
endpoint | string | A'a | — |
region | string | A'a | — |
public_base_url | string | A'a | — |
access_key_id | string | A'a | Required for `ownership: customer`. Written to Vault, never to a column. |
secret_access_key | string | A'a | Required for `ownership: customer`. Written to Vault, never to a column. |
Martani
| Suna | Nau'i | Ana buƙata | Abin da yake |
|---|---|---|---|
id | string | Eh | — |
name | string | Eh | The customer's own label, not the bucket's name at the vendor. |
ownership | string<zinn, customer> | Eh | `zinn` is storage we operate and bill for; `customer` is the organisation's own bucket, which costs us nothing and is not metered against their allowance. |
vendor | string<r2, s3, b2, bunny, gcore, minio> | Eh | — |
status | string<pending, active, suspended, failed> | Eh | — |
bucket_name | string | Eh | — |
endpoint | string | A'a | — |
region | string | A'a | — |
public_base_url | string | A'a | Where a public object is readable. Empty means the bucket is private and its objects are reachable only through a presigned URL. |
bytes_stored | integer | A'a | — |
objects_stored | integer | A'a | — |
usage_measured_at | string | A'a | When the size above was last measured against the vendor. `null` means it has not been measured yet — which is not the same as empty. |
has_credential | boolean | Eh | Whether a stored key exists. The key and the Vault path it lives at are deliberately absent from this payload. |
metered | boolean | Eh | Whether this bucket's bytes count against `object_storage_gb`. |
created_at | string | A'a | — |
Kuskuren da wannan matsaya za ta iya maido wa
401 · 403 · 422 · 429