Object Storage

Set lifecycle rules

put/object-storage/buckets/{bucket_uuid}/lifecycle

Replace every lifecycle rule of the bucket: delete objects some days after they are written or on a date, delete old versions, clean up delete markers and abort incomplete multipart uploads. Expired objects are deleted permanently in the background, usually within 48 hours of the due date.

Autorización

Authorization
Authorization*string

Bearer YOUR_API_TOKEN con un token de API. También vale la cabecera X-API-Key: YOUR_API_TOKEN.

Parámetros de ruta

bucket_uuid*string

Cuerpo de la petición

Replace every lifecycle rule of the bucket (DELETE removes them all).

application/jsonObligatorio
rules*array<ObjectStorageLifecycleRule>
Rangoitems ≤ 1000
Propiedades (8)
id*string
Rangolength ≤ 255
enabled?boolean
Por defectotrue
filter?ObjectStorageLifecycleFilter | null
Propiedades (4)
prefix?string | null
Rangolength ≤ 4096
tags?array<ObjectStorageLifecycleTag> | null
Rangoitems ≤ 50
Propiedades (2)
key*string
Rangolength ≤ 512
value*string
Rangolength ≤ 512
object_size_greater_than?integer | null
object_size_less_than?integer | null
expiration?ObjectStorageLifecycleExpiration | null
Propiedades (3)
days?integer | null

Days after the object was written

date?string | null

YYYY-MM-DD (midnight UTC), after today

expired_object_delete_marker?boolean | null

Remove delete markers left without any version (versioned buckets)

noncurrent_version_expiration?ObjectStorageLifecycleNoncurrent | null
Propiedades (2)
noncurrent_days*integer

Days after a version stopped being the current one

newer_noncurrent_versions?integer | null

Keep this many newer versions

abort_incomplete_multipart_upload?ObjectStorageLifecycleAbort | null
Propiedades (1)
days_after_initiation*integer
transitions?any

Not supported

noncurrent_version_transitions?any

Not supported

Respuestas

Successful Response

application/json

detail*string
generation?integer | null
notes?array<string>