# Lifecycle

Lifecycle Configuration of a Bucket

## GetBucketLifecycle

> Returns the lifecycle configuration for the specified bucket.\
> \
> \#### Permissions\
> You must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\
> to perform the \`s3:GetLifecycleConfiguration\` operation using \[Bucket Policy]\(#tag/Policy/operation/PutBucketPolicy).<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS Object Storage API for contract-owned buckets","version":"2.0.3"},"tags":[{"name":"Lifecycle","description":"Lifecycle Configuration of a Bucket"}],"servers":[{"url":"https://s3.eu-central-3.ionoscloud.com","description":"The endpoint for the `eu-central-3` region (Berlin, Germany)"},{"url":"https://s3.us-central-1.ionoscloud.com","description":"The endpoint for the `us-central-1` region (Lenexa, USA)"}],"security":[{"hmac":[]}],"components":{"securitySchemes":{"hmac":{"type":"apiKey","name":"Authorization","in":"header","description":"IONOS Object Storage API requests are authenticated using the AWS signature. \nThe IONOS Object Storage API authenticates users using a customized HTTP scheme based on a [keyed-HMAC](https://en.wikipedia.org/wiki/HMAC) (Hash Message Authentication Code).\nThe process of generating the proper Authorization header is somewhat involved. We recommend that you make use of a tool such as Postman.\n\n<img src=\"/docs/s3/hmac-postman.png\" width=\"800px\" />\n\nIn the **Authorization** tab for a request, select **AWS Signature** from the **Type** dropdown list.\nSpecify where Postman should append your authorization data using the **Add authorization data to** drop-down menu.\n\n* If you select **Request Headers**, Postman populates the **Headers** tab with Authorization and `X-Amz-` prefixed fields.\n\n* If you select **Request URL**, Postman populates the **Params** tab with authentication details prefixed with `X-Amz-`.\n\n\n**Note:** The parameters listed below contain confidential information. We recommend using variables to keep this data secure while working in a collaborative environment.\n\n* For **Access Key**, enter your `access key` directly in the fields or through variables for added security.\n\n* For **Secret Key**, enter your `secret key` directly in the fields or through variables for added security.\n\nAdvanced fields are optional, but Postman will attempt to generate them automatically if necessary.\n* For **AWS Region**, enter one of the [regions](#section/Endpoints) (`eu-central-3`) where your bucket is hosted.\n\n* For **Service Name**, enter `s3`. The name of the service that receives the requests.\n\n* For **Session Token**, **leave the field blank**. This is only required when temporary security credentials are used.\n"}},"schemas":{"GetBucketLifecycleOutput":{"type":"object","properties":{"Rules":{"$ref":"#/components/schemas/Rules"}}},"Rules":{"description":"Container for a lifecycle rules.","type":"array","items":{"$ref":"#/components/schemas/Rule"},"xml":{"wrapped":false}},"Rule":{"description":"Specifies lifecycle rules for an IONOS Object Storage bucket.","type":"object","required":["Prefix","Status"],"properties":{"ID":{"type":"string","minLength":1,"maxLength":255,"description":"Unique identifier for the rule. The value can't be longer than 255 characters."},"Prefix":{"$ref":"#/components/schemas/Prefix"},"Status":{"$ref":"#/components/schemas/ExpirationStatus"},"Expiration":{"$ref":"#/components/schemas/LifecycleExpiration"},"NoncurrentVersionExpiration":{"$ref":"#/components/schemas/NoncurrentVersionExpiration"},"AbortIncompleteMultipartUpload":{"$ref":"#/components/schemas/AbortIncompleteMultipartUpload"}}},"Prefix":{"description":"Object key prefix that identifies one or more objects to which this rule applies. Replacement must be made for object keys containing special characters (such as carriage returns) when using XML requests.","type":"string","minLength":1,"maxLength":1024},"ExpirationStatus":{"description":"If `Enabled`, the rule is currently being applied. If `Disabled`, the rule is not currently being applied.","type":"string","enum":["Enabled","Disabled"]},"LifecycleExpiration":{"description":"Specifies when the object expires based on the values defined in the lifecycle configuration.","type":"object","properties":{"Date":{"description":"Indicates at what date the object is to be moved or deleted. Should be in GMT ISO 8601 Format.","type":"string","format":"date-time"},"Days":{"type":"integer","description":"Indicates the lifetime, in days, of the objects that are subject to the rule. The value must be a non-zero positive integer."},"ExpiredObjectDeleteMarker":{"$ref":"#/components/schemas/ExpiredObjectDeleteMarker"}}},"ExpiredObjectDeleteMarker":{"description":"Indicates whether IONOS Object Storage will remove a delete marker with no noncurrent versions. If set to true, the delete marker will be expired; if set to false the policy takes no operation. This cannot be specified with Days or Date in a Lifecycle Expiration Policy.","type":"boolean"},"NoncurrentVersionExpiration":{"description":"Specifies when noncurrent object versions expire. Upon expiration, IONOS Object Storage permanently deletes the noncurrent object versions. You set this lifecycle configuration operation on a bucket that has versioning enabled (or suspended) to request that IONOS Object Storage delete noncurrent object versions at a specific period in the object's lifetime.","type":"object","properties":{"NoncurrentDays":{"type":"integer","description":"Specifies the number of days an object is noncurrent before IONOS Object Storage can perform the associated operation."}}},"AbortIncompleteMultipartUpload":{"description":"Specifies the days since the initiation of an incomplete multipart upload that IONOS Object Storage will wait before permanently removing all parts of the upload.","type":"object","properties":{"DaysAfterInitiation":{"description":"Specifies the number of days after which IONOS Object Storage aborts an incomplete multipart upload.","type":"integer"}}},"Error":{"type":"object","description":"Container for all error elements.","properties":{"Code":{"type":"string","enum":["AccessDenied","AccountProblem","AmbiguousGrantByEmailAddress","BadDigest","BucketAlreadyExists","BucketAlreadyOwnedByYou","BucketNotEmpty","CrossLocationLoggingProhibited","EntityTooSmall","EntityTooLarge","IllegalVersioningConfigurationException","IncorrectNumberOfFilesInPostRequest","InternalError","InvalidAccessKeyId","InvalidArgument","InvalidBucketName","InvalidBucketState","InvalidDigest","InvalidEncryptionAlgorithmError","InvalidLocationConstraint","InvalidObjectState","InvalidPart","InvalidPartOrder","InvalidPolicyDocument","InvalidRange","InvalidRequest","InvalidSecurity","InvalidTargetBucketForLogging","InvalidURI","KeyTooLong","MalformedACLError","MalformedPOSTRequest","MalformedXML","MaxMessageLengthExceeded","MaxPostPreDataLengthExceededError","MetadataTooLarge","MethodNotAllowed","MissingContentLength","MissingSecurityHeader","NoSuchBucket","NoSuchBucketPolicy","NoSuchKey","NoSuchLifecycleConfiguration","NoSuchReplicationConfiguration","NoSuchUpload","NoSuchVersion","NotImplemented","PermanentRedirect","PreconditionFailed","Redirect","RestoreAlreadyInProgress","RequestIsNotMultiPartContent","RequestTimeout","RequestTimeTooSkewed","SignatureDoesNotMatch","ServiceUnavailable","SlowDown","TemporaryRedirect","TooManyBuckets","UnexpectedContent","UnresolvableGrantByEmailAddress","UserKeyMustBeSpecified"],"description":"The error code is a string that uniquely identifies an error\ncondition. It is meant to be read and understood by programs\nthat detect and handle errors by type.\n\n## IONOS Object Storage error codes\n- AccessDenied\n  - Description: Access Denied\n  - HTTPStatus Code: 403 Forbidden\n- AccountProblem\n  - Description: There is a problem with your IONOS Object Storage account that prevents the operation from completing successfully. Contact IONOS for further assistance.\n  - HTTP Status Code: 403 Forbidden\n- AmbiguousGrantByEmailAddress\n  - Description: The email address you provided is associated with more than one account.\n  - HTTP Status Code: 400 Bad Request\n- BadDigest\n  - Description: The Content-MD5 you specified did not match what we received.\n  - HTTP Status Code: 400 Bad Request\n- BucketAlreadyExists\n  - Description: The requested bucket name is not available. The bucket namespace is shared by all users of the system. Please select a different name and try again.\n  - HTTP Status Code: 409 Conflict\n- BucketAlreadyOwnedByYou\n  - Description: The bucket you tried to create already exists, and you own it.\n  - HTTP Code: 409 Conflict\n- BucketNotEmpty\n  - Description: The bucket you tried to delete is not empty.\n  - HTTP Status Code: 409 Conflict\n- CrossLocationLoggingProhibited\n  - Description: Cross-location logging not allowed. Buckets in one geographic location cannot log information to a bucket in another location.\n  - HTTP Status Code: 403 Forbidden\n- EntityTooSmall\n  - Description: Your proposed upload is smaller than the minimum allowed object size.\n  - HTTP Status Code: 400 Bad Request\n- EntityTooLarge\n  - Description: Your proposed upload exceeds the maximum allowed object size.\n  - HTTP Status Code: 400 Bad Request\n- IllegalVersioningConfigurationException\n  - Description: Indicates that the versioning configuration specified in the request is invalid.\n  - HTTP Status Code: 400 Bad Request\n- IncorrectNumberOfFilesInPostRequest\n  - Description: POST requires exactly one file upload per request.\n  - HTTP Status Code: 400 Bad Request\n- InternalError\n  - Description: We encountered an internal error. Please try again.\n  - HTTP Status Code: 500 Internal Server Error \n- InvalidAccessKeyId\n  - Description: The IONOS Object Storage access key ID you provided does not exist in our records.\n  - HTTP Status Code: 403 Forbidden\n- InvalidArgument\n  - Description: Invalid Argument\n  - HTTP Status Code: 400 Bad Request\n- InvalidBucketName\n  - Description: The specified bucket is not valid.\n  - HTTP Status Code: 400 Bad Request\n- InvalidBucketState\n  - Description: The request is not valid with the current state of the bucket.\n  - HTTP Status Code: 409 Conflict\n- InvalidDigest\n  - Description: The Content-MD5 you specified is not valid.\n  - HTTP Status Code: 400 Bad Request\n- InvalidEncryptionAlgorithmError\n  - Description: The encryption request you specified is not valid. The valid value is AES256.\n  - HTTP Status Code: 400 Bad Request\n- InvalidLocationConstraint\n  - HTTP Status Code: 400 Bad Request\n- InvalidObjectState\n  - Description: The operation is not valid for the current state of the object.\n  - HTTP Status Code: 403 Forbidden\n- InvalidPart\n  - Description: One or more of the specified parts could not be found. The part might not have been uploaded, or the specified entity tag might not have matched the part's entity tag.\n  - HTTP Status Code: 400 Bad Request\n- InvalidPartOrder\n  - Description: The list of parts was not in ascending order. Parts list must be specified in order by part number.\n  - HTTP Status Code: 400 Bad Request\n- InvalidPolicyDocument\n  - Description: The content of the form does not meet the conditions specified in the policy document.\n  - HTTP Status Code: 400 Bad Request\n- InvalidRange\n  - Description: The requested range cannot be satisfied.\n  - HTTP Status Code: 416 Requested Range Not Satisfiable\n- InvalidRequest\n  - Description: Please use `AWS4-HMAC-SHA256`.\n  - HTTP Status Code: 400 Bad Request\n- InvalidSecurity\n  - Description: The provided security credentials are not valid.\n  - HTTP Status Code: 403 Forbidden\n- InvalidTargetBucketForLogging\n  - Description: The target bucket for logging does not exist, is not owned by you, or does not have the appropriate grants for the log-delivery group.\n  - Status Code: 400 Bad Request\n- InvalidURI\n  - Description: Couldn't parse the specified URI.\n  - HTTP Status Code: 400 Bad Request\n- KeyTooLong\n  - Description: Your key is too long.\n  - HTTP Status Code: 400 Bad Request\n- MalformedACLError\n  - Description: The XML you provided was not well-formed or did not validate against our published schema.\n  - HTTP Status Code: 400 Bad Request\n- MalformedPOSTRequest\n  - Description: The body of your POST request is not well-formed multipart/form-data.\n  - HTTP Status Code: 400 Bad Request\n- MalformedXML\n  - Description: This happens when the user sends malformed XML (XML that doesn't conform to the published XSD) for the configuration. The error message is, \"The XML you provided was not well-formed or did not validate against our published schema.\"\n  - HTTP Status Code: 400 Bad Request\n- MaxMessageLengthExceeded\n  - Description: Your request was too big.\n  - HTTP Status Code: 400 Bad Request\n- MaxPostPreDataLengthExceededError\n  - Description: Your POST request fields preceding the upload file were too large.\n  - HTTP Status Code: 400 Bad Request\n- MetadataTooLarge\n  - Description: Your metadata headers exceed the maximum allowed metadata size.\n  - HTTP Status Code: 400 Bad Request\n- MethodNotAllowed\n  - Description: The specified method is not allowed against this resource.\n  - HTTP Status Code: 405 Method Not Allowed\n- MissingContentLength\n  - Description: You must provide the Content-Length HTTP header.\n  - HTTP Status Code: 411 Length Required\n- MissingSecurityHeader\n  - Description: Your request is missing a required header.\n  - HTTP Status Code: 400 Bad Request\n- NoSuchBucket\n  - Description: The specified bucket does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchBucketPolicy\n  - Description: The specified bucket does not have a bucket policy.\n  - HTTP Status Code: 404 Not Found\n- NoSuchKey\n  - Description: The specified key does not exist.\n  - HTTP Status Code:404 Not Found\n- NoSuchLifecycleConfiguration\n  - Description: The lifecycle configuration does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchReplicationConfiguration\n  - Description: The replication configuration does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchUpload\n  - Description: The specified multipart upload does not exist. The upload ID might be invalid, or the multipart upload might have been aborted or completed.\n  - HTTP Status Code: 404 Not Found\n- NoSuchVersion\n  - Description: Indicates that the version ID specified in the request does not match an existing version.\n  - HTTP Status Code: 404 Not Found\n- NotImplemented\n  - Description: A header you provided implies functionality that is not implemented.\n  - HTTP Status Code: 501 Not Implemented\n- PermanentRedirect\n  - Description: The bucket you are attempting to access must be addressed using the specified endpoint. Send all future requests to this endpoint.\n  - HTTP Status Code: 301 Moved Permanently\n- PreconditionFailed\n  - Description: At least one of the preconditions you specified did not hold.\n  - HTTP Status Code: 412 Precondition Failed\n- Redirect\n  - Description: Temporary redirect.\n  - HTTP Status Code: 307 Moved Temporarily\n- RestoreAlreadyInProgress\n  - Description: Object restore is already in progress.\n  - HTTP Status Code: 409 Conflict\n- RequestIsNotMultiPartContent\n  - Description: Bucket POST must be of the enclosure-type multipart/form-data.\n  - HTTP Status Code: 400 Bad Request\n- RequestTimeout\n  - Description: Your socket connection to the server was not read from or written to within the timeout period.\n  - HTTP Status Code: 400 Bad Request\n- RequestTimeTooSkewed\n  - Description: The difference between the request time and the server's time is too large.\n  - HTTP Status Code: 403 Forbidden\n- SignatureDoesNotMatch\n  - HTTP Status Code: 403 Forbidden\n- ServiceUnavailable\n  - Description: Reduce your request rate.\n  - HTTP Status Code: 503 Service Unavailable\n- SlowDown\n  - Description: Reduce your request rate.\n  - HTTP Status Code: 503 Slow Down\n- TemporaryRedirect\n  - Description: You are being redirected to the bucket while DNS updates.\n  - HTTP Status Code: 307 Moved Temporarily\n- TooManyBuckets\n  - Description: You have attempted to create more buckets than allowed.\n  - HTTP Status Code: 400 Bad Request\n- UnexpectedContent\n  - Description: This request does not support content.\n  - HTTP Status Code: 400 Bad Request\n- UnresolvableGrantByEmailAddress\n  - Description: The email address you provided does not match any account on record.\n  - HTTP Status Code: 400 Bad Request\n- UserKeyMustBeSpecified\n  - Description: The bucket POST must contain the specified field name. If it is specified, check the order of the fields.\n  - HTTP Status Code: 400 Bad Request\n"},"Message":{"type":"string","description":"Gives a brief English description of the issue."},"RequestId":{"type":"string"},"HostId":{"type":"string"}},"xml":{"name":"Error"}},"BucketName":{"description":"The bucket name.","type":"string","minLength":3,"maxLength":63,"xml":{"name":"Name"}}}},"paths":{"/{Bucket}?lifecycle":{"get":{"tags":["Lifecycle"],"summary":"GetBucketLifecycle","operationId":"GetBucketLifecycle","description":"Returns the lifecycle configuration for the specified bucket.\n\n#### Permissions\nYou must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\nto perform the `s3:GetLifecycleConfiguration` operation using [Bucket Policy](#tag/Policy/operation/PutBucketPolicy).\n","responses":{"200":{"description":"Successful operation","headers":{},"content":{"application/xml":{"schema":{"$ref":"#/components/schemas/GetBucketLifecycleOutput"}}}},"404":{"description":"NoSuchLifecycleConfiguration","headers":{},"content":{"application/xml":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"parameters":[{"name":"Bucket","in":"path","required":true,"schema":{"$ref":"#/components/schemas/BucketName"}},{"name":"lifecycle","in":"query","required":true,"schema":{"type":"boolean","enum":[true]},"allowEmptyValue":true}]}}}}
```

## PutBucketLifecycle

> Creates a new lifecycle configuration for a specified bucket, or replaces an existing configuration.\</p>\
> This lifecycle configuration allows automatic management of the objects within the bucket.\
> Typical actions can include the deletion of objects after a certain period or deletion of non-current\
> versions of objects.\
> \
> \#### Permissions\
> You must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\
> to perform the \`s3:PutLifecycleConfiguration\` operation using \[Bucket Policy]\(#tag/Policy/operation/PutBucketPolicy).\
> \
> \#### S3 API Compatibility\
> \- The \`NewerNoncurrentVersions\` setting is not supported for the \`NoncurrentVersionExpiration\` option.\
> \- The \`Transition\` and the \`NoncurrentVersionTransition\` options are omitted as only the \`STANDARD\` storage class is currenly supported.<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS Object Storage API for contract-owned buckets","version":"2.0.3"},"tags":[{"name":"Lifecycle","description":"Lifecycle Configuration of a Bucket"}],"servers":[{"url":"https://s3.eu-central-3.ionoscloud.com","description":"The endpoint for the `eu-central-3` region (Berlin, Germany)"},{"url":"https://s3.us-central-1.ionoscloud.com","description":"The endpoint for the `us-central-1` region (Lenexa, USA)"}],"security":[{"hmac":[]}],"components":{"securitySchemes":{"hmac":{"type":"apiKey","name":"Authorization","in":"header","description":"IONOS Object Storage API requests are authenticated using the AWS signature. \nThe IONOS Object Storage API authenticates users using a customized HTTP scheme based on a [keyed-HMAC](https://en.wikipedia.org/wiki/HMAC) (Hash Message Authentication Code).\nThe process of generating the proper Authorization header is somewhat involved. We recommend that you make use of a tool such as Postman.\n\n<img src=\"/docs/s3/hmac-postman.png\" width=\"800px\" />\n\nIn the **Authorization** tab for a request, select **AWS Signature** from the **Type** dropdown list.\nSpecify where Postman should append your authorization data using the **Add authorization data to** drop-down menu.\n\n* If you select **Request Headers**, Postman populates the **Headers** tab with Authorization and `X-Amz-` prefixed fields.\n\n* If you select **Request URL**, Postman populates the **Params** tab with authentication details prefixed with `X-Amz-`.\n\n\n**Note:** The parameters listed below contain confidential information. We recommend using variables to keep this data secure while working in a collaborative environment.\n\n* For **Access Key**, enter your `access key` directly in the fields or through variables for added security.\n\n* For **Secret Key**, enter your `secret key` directly in the fields or through variables for added security.\n\nAdvanced fields are optional, but Postman will attempt to generate them automatically if necessary.\n* For **AWS Region**, enter one of the [regions](#section/Endpoints) (`eu-central-3`) where your bucket is hosted.\n\n* For **Service Name**, enter `s3`. The name of the service that receives the requests.\n\n* For **Session Token**, **leave the field blank**. This is only required when temporary security credentials are used.\n"}},"schemas":{"Error":{"type":"object","description":"Container for all error elements.","properties":{"Code":{"type":"string","enum":["AccessDenied","AccountProblem","AmbiguousGrantByEmailAddress","BadDigest","BucketAlreadyExists","BucketAlreadyOwnedByYou","BucketNotEmpty","CrossLocationLoggingProhibited","EntityTooSmall","EntityTooLarge","IllegalVersioningConfigurationException","IncorrectNumberOfFilesInPostRequest","InternalError","InvalidAccessKeyId","InvalidArgument","InvalidBucketName","InvalidBucketState","InvalidDigest","InvalidEncryptionAlgorithmError","InvalidLocationConstraint","InvalidObjectState","InvalidPart","InvalidPartOrder","InvalidPolicyDocument","InvalidRange","InvalidRequest","InvalidSecurity","InvalidTargetBucketForLogging","InvalidURI","KeyTooLong","MalformedACLError","MalformedPOSTRequest","MalformedXML","MaxMessageLengthExceeded","MaxPostPreDataLengthExceededError","MetadataTooLarge","MethodNotAllowed","MissingContentLength","MissingSecurityHeader","NoSuchBucket","NoSuchBucketPolicy","NoSuchKey","NoSuchLifecycleConfiguration","NoSuchReplicationConfiguration","NoSuchUpload","NoSuchVersion","NotImplemented","PermanentRedirect","PreconditionFailed","Redirect","RestoreAlreadyInProgress","RequestIsNotMultiPartContent","RequestTimeout","RequestTimeTooSkewed","SignatureDoesNotMatch","ServiceUnavailable","SlowDown","TemporaryRedirect","TooManyBuckets","UnexpectedContent","UnresolvableGrantByEmailAddress","UserKeyMustBeSpecified"],"description":"The error code is a string that uniquely identifies an error\ncondition. It is meant to be read and understood by programs\nthat detect and handle errors by type.\n\n## IONOS Object Storage error codes\n- AccessDenied\n  - Description: Access Denied\n  - HTTPStatus Code: 403 Forbidden\n- AccountProblem\n  - Description: There is a problem with your IONOS Object Storage account that prevents the operation from completing successfully. Contact IONOS for further assistance.\n  - HTTP Status Code: 403 Forbidden\n- AmbiguousGrantByEmailAddress\n  - Description: The email address you provided is associated with more than one account.\n  - HTTP Status Code: 400 Bad Request\n- BadDigest\n  - Description: The Content-MD5 you specified did not match what we received.\n  - HTTP Status Code: 400 Bad Request\n- BucketAlreadyExists\n  - Description: The requested bucket name is not available. The bucket namespace is shared by all users of the system. Please select a different name and try again.\n  - HTTP Status Code: 409 Conflict\n- BucketAlreadyOwnedByYou\n  - Description: The bucket you tried to create already exists, and you own it.\n  - HTTP Code: 409 Conflict\n- BucketNotEmpty\n  - Description: The bucket you tried to delete is not empty.\n  - HTTP Status Code: 409 Conflict\n- CrossLocationLoggingProhibited\n  - Description: Cross-location logging not allowed. Buckets in one geographic location cannot log information to a bucket in another location.\n  - HTTP Status Code: 403 Forbidden\n- EntityTooSmall\n  - Description: Your proposed upload is smaller than the minimum allowed object size.\n  - HTTP Status Code: 400 Bad Request\n- EntityTooLarge\n  - Description: Your proposed upload exceeds the maximum allowed object size.\n  - HTTP Status Code: 400 Bad Request\n- IllegalVersioningConfigurationException\n  - Description: Indicates that the versioning configuration specified in the request is invalid.\n  - HTTP Status Code: 400 Bad Request\n- IncorrectNumberOfFilesInPostRequest\n  - Description: POST requires exactly one file upload per request.\n  - HTTP Status Code: 400 Bad Request\n- InternalError\n  - Description: We encountered an internal error. Please try again.\n  - HTTP Status Code: 500 Internal Server Error \n- InvalidAccessKeyId\n  - Description: The IONOS Object Storage access key ID you provided does not exist in our records.\n  - HTTP Status Code: 403 Forbidden\n- InvalidArgument\n  - Description: Invalid Argument\n  - HTTP Status Code: 400 Bad Request\n- InvalidBucketName\n  - Description: The specified bucket is not valid.\n  - HTTP Status Code: 400 Bad Request\n- InvalidBucketState\n  - Description: The request is not valid with the current state of the bucket.\n  - HTTP Status Code: 409 Conflict\n- InvalidDigest\n  - Description: The Content-MD5 you specified is not valid.\n  - HTTP Status Code: 400 Bad Request\n- InvalidEncryptionAlgorithmError\n  - Description: The encryption request you specified is not valid. The valid value is AES256.\n  - HTTP Status Code: 400 Bad Request\n- InvalidLocationConstraint\n  - HTTP Status Code: 400 Bad Request\n- InvalidObjectState\n  - Description: The operation is not valid for the current state of the object.\n  - HTTP Status Code: 403 Forbidden\n- InvalidPart\n  - Description: One or more of the specified parts could not be found. The part might not have been uploaded, or the specified entity tag might not have matched the part's entity tag.\n  - HTTP Status Code: 400 Bad Request\n- InvalidPartOrder\n  - Description: The list of parts was not in ascending order. Parts list must be specified in order by part number.\n  - HTTP Status Code: 400 Bad Request\n- InvalidPolicyDocument\n  - Description: The content of the form does not meet the conditions specified in the policy document.\n  - HTTP Status Code: 400 Bad Request\n- InvalidRange\n  - Description: The requested range cannot be satisfied.\n  - HTTP Status Code: 416 Requested Range Not Satisfiable\n- InvalidRequest\n  - Description: Please use `AWS4-HMAC-SHA256`.\n  - HTTP Status Code: 400 Bad Request\n- InvalidSecurity\n  - Description: The provided security credentials are not valid.\n  - HTTP Status Code: 403 Forbidden\n- InvalidTargetBucketForLogging\n  - Description: The target bucket for logging does not exist, is not owned by you, or does not have the appropriate grants for the log-delivery group.\n  - Status Code: 400 Bad Request\n- InvalidURI\n  - Description: Couldn't parse the specified URI.\n  - HTTP Status Code: 400 Bad Request\n- KeyTooLong\n  - Description: Your key is too long.\n  - HTTP Status Code: 400 Bad Request\n- MalformedACLError\n  - Description: The XML you provided was not well-formed or did not validate against our published schema.\n  - HTTP Status Code: 400 Bad Request\n- MalformedPOSTRequest\n  - Description: The body of your POST request is not well-formed multipart/form-data.\n  - HTTP Status Code: 400 Bad Request\n- MalformedXML\n  - Description: This happens when the user sends malformed XML (XML that doesn't conform to the published XSD) for the configuration. The error message is, \"The XML you provided was not well-formed or did not validate against our published schema.\"\n  - HTTP Status Code: 400 Bad Request\n- MaxMessageLengthExceeded\n  - Description: Your request was too big.\n  - HTTP Status Code: 400 Bad Request\n- MaxPostPreDataLengthExceededError\n  - Description: Your POST request fields preceding the upload file were too large.\n  - HTTP Status Code: 400 Bad Request\n- MetadataTooLarge\n  - Description: Your metadata headers exceed the maximum allowed metadata size.\n  - HTTP Status Code: 400 Bad Request\n- MethodNotAllowed\n  - Description: The specified method is not allowed against this resource.\n  - HTTP Status Code: 405 Method Not Allowed\n- MissingContentLength\n  - Description: You must provide the Content-Length HTTP header.\n  - HTTP Status Code: 411 Length Required\n- MissingSecurityHeader\n  - Description: Your request is missing a required header.\n  - HTTP Status Code: 400 Bad Request\n- NoSuchBucket\n  - Description: The specified bucket does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchBucketPolicy\n  - Description: The specified bucket does not have a bucket policy.\n  - HTTP Status Code: 404 Not Found\n- NoSuchKey\n  - Description: The specified key does not exist.\n  - HTTP Status Code:404 Not Found\n- NoSuchLifecycleConfiguration\n  - Description: The lifecycle configuration does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchReplicationConfiguration\n  - Description: The replication configuration does not exist.\n  - HTTP Status Code: 404 Not Found\n- NoSuchUpload\n  - Description: The specified multipart upload does not exist. The upload ID might be invalid, or the multipart upload might have been aborted or completed.\n  - HTTP Status Code: 404 Not Found\n- NoSuchVersion\n  - Description: Indicates that the version ID specified in the request does not match an existing version.\n  - HTTP Status Code: 404 Not Found\n- NotImplemented\n  - Description: A header you provided implies functionality that is not implemented.\n  - HTTP Status Code: 501 Not Implemented\n- PermanentRedirect\n  - Description: The bucket you are attempting to access must be addressed using the specified endpoint. Send all future requests to this endpoint.\n  - HTTP Status Code: 301 Moved Permanently\n- PreconditionFailed\n  - Description: At least one of the preconditions you specified did not hold.\n  - HTTP Status Code: 412 Precondition Failed\n- Redirect\n  - Description: Temporary redirect.\n  - HTTP Status Code: 307 Moved Temporarily\n- RestoreAlreadyInProgress\n  - Description: Object restore is already in progress.\n  - HTTP Status Code: 409 Conflict\n- RequestIsNotMultiPartContent\n  - Description: Bucket POST must be of the enclosure-type multipart/form-data.\n  - HTTP Status Code: 400 Bad Request\n- RequestTimeout\n  - Description: Your socket connection to the server was not read from or written to within the timeout period.\n  - HTTP Status Code: 400 Bad Request\n- RequestTimeTooSkewed\n  - Description: The difference between the request time and the server's time is too large.\n  - HTTP Status Code: 403 Forbidden\n- SignatureDoesNotMatch\n  - HTTP Status Code: 403 Forbidden\n- ServiceUnavailable\n  - Description: Reduce your request rate.\n  - HTTP Status Code: 503 Service Unavailable\n- SlowDown\n  - Description: Reduce your request rate.\n  - HTTP Status Code: 503 Slow Down\n- TemporaryRedirect\n  - Description: You are being redirected to the bucket while DNS updates.\n  - HTTP Status Code: 307 Moved Temporarily\n- TooManyBuckets\n  - Description: You have attempted to create more buckets than allowed.\n  - HTTP Status Code: 400 Bad Request\n- UnexpectedContent\n  - Description: This request does not support content.\n  - HTTP Status Code: 400 Bad Request\n- UnresolvableGrantByEmailAddress\n  - Description: The email address you provided does not match any account on record.\n  - HTTP Status Code: 400 Bad Request\n- UserKeyMustBeSpecified\n  - Description: The bucket POST must contain the specified field name. If it is specified, check the order of the fields.\n  - HTTP Status Code: 400 Bad Request\n"},"Message":{"type":"string","description":"Gives a brief English description of the issue."},"RequestId":{"type":"string"},"HostId":{"type":"string"}},"xml":{"name":"Error"}},"BucketName":{"description":"The bucket name.","type":"string","minLength":3,"maxLength":63,"xml":{"name":"Name"}},"Content-MD5":{"type":"string","description":"The base64 encoded MD5 digest of the message (without the headers) according to\n[RFC 1864](http://www.ietf.org/rfc/rfc1864.txt).\n"},"Rules":{"description":"Container for a lifecycle rules.","type":"array","items":{"$ref":"#/components/schemas/Rule"},"xml":{"wrapped":false}},"Rule":{"description":"Specifies lifecycle rules for an IONOS Object Storage bucket.","type":"object","required":["Prefix","Status"],"properties":{"ID":{"type":"string","minLength":1,"maxLength":255,"description":"Unique identifier for the rule. The value can't be longer than 255 characters."},"Prefix":{"$ref":"#/components/schemas/Prefix"},"Status":{"$ref":"#/components/schemas/ExpirationStatus"},"Expiration":{"$ref":"#/components/schemas/LifecycleExpiration"},"NoncurrentVersionExpiration":{"$ref":"#/components/schemas/NoncurrentVersionExpiration"},"AbortIncompleteMultipartUpload":{"$ref":"#/components/schemas/AbortIncompleteMultipartUpload"}}},"Prefix":{"description":"Object key prefix that identifies one or more objects to which this rule applies. Replacement must be made for object keys containing special characters (such as carriage returns) when using XML requests.","type":"string","minLength":1,"maxLength":1024},"ExpirationStatus":{"description":"If `Enabled`, the rule is currently being applied. If `Disabled`, the rule is not currently being applied.","type":"string","enum":["Enabled","Disabled"]},"LifecycleExpiration":{"description":"Specifies when the object expires based on the values defined in the lifecycle configuration.","type":"object","properties":{"Date":{"description":"Indicates at what date the object is to be moved or deleted. Should be in GMT ISO 8601 Format.","type":"string","format":"date-time"},"Days":{"type":"integer","description":"Indicates the lifetime, in days, of the objects that are subject to the rule. The value must be a non-zero positive integer."},"ExpiredObjectDeleteMarker":{"$ref":"#/components/schemas/ExpiredObjectDeleteMarker"}}},"ExpiredObjectDeleteMarker":{"description":"Indicates whether IONOS Object Storage will remove a delete marker with no noncurrent versions. If set to true, the delete marker will be expired; if set to false the policy takes no operation. This cannot be specified with Days or Date in a Lifecycle Expiration Policy.","type":"boolean"},"NoncurrentVersionExpiration":{"description":"Specifies when noncurrent object versions expire. Upon expiration, IONOS Object Storage permanently deletes the noncurrent object versions. You set this lifecycle configuration operation on a bucket that has versioning enabled (or suspended) to request that IONOS Object Storage delete noncurrent object versions at a specific period in the object's lifetime.","type":"object","properties":{"NoncurrentDays":{"type":"integer","description":"Specifies the number of days an object is noncurrent before IONOS Object Storage can perform the associated operation."}}},"AbortIncompleteMultipartUpload":{"description":"Specifies the days since the initiation of an incomplete multipart upload that IONOS Object Storage will wait before permanently removing all parts of the upload.","type":"object","properties":{"DaysAfterInitiation":{"description":"Specifies the number of days after which IONOS Object Storage aborts an incomplete multipart upload.","type":"integer"}}}}},"paths":{"/{Bucket}?lifecycle":{"put":{"tags":["Lifecycle"],"summary":"PutBucketLifecycle","operationId":"PutBucketLifecycle","description":"Creates a new lifecycle configuration for a specified bucket, or replaces an existing configuration.</p>\nThis lifecycle configuration allows automatic management of the objects within the bucket.\nTypical actions can include the deletion of objects after a certain period or deletion of non-current\nversions of objects.\n\n#### Permissions\nYou must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\nto perform the `s3:PutLifecycleConfiguration` operation using [Bucket Policy](#tag/Policy/operation/PutBucketPolicy).\n\n#### S3 API Compatibility\n- The `NewerNoncurrentVersions` setting is not supported for the `NoncurrentVersionExpiration` option.\n- The `Transition` and the `NoncurrentVersionTransition` options are omitted as only the `STANDARD` storage class is currenly supported.\n","responses":{"200":{"description":"Successful operation","headers":{},"content":{"application/xml":{}}},"400":{"description":"MalformedXML","headers":{},"content":{"application/xml":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"parameters":[{"name":"Bucket","in":"path","required":true,"schema":{"$ref":"#/components/schemas/BucketName"}},{"name":"Content-MD5","in":"header","required":true,"schema":{"$ref":"#/components/schemas/Content-MD5"}},{"name":"lifecycle","in":"query","required":true,"schema":{"type":"boolean","enum":[true]},"allowEmptyValue":true}],"requestBody":{"required":true,"content":{"application/xml":{"schema":{"type":"object","properties":{"LifecycleConfiguration":{"description":"Container for lifecycle rules. You can add as many as 1000 rules.","type":"object","properties":{"Rules":{"$ref":"#/components/schemas/Rules"}}}}}}}}}}}}
```

## DeleteBucketLifecycle

> Deletes the lifecycle configuration from the specified bucket.\
> As a result, objects within the bucket will neither expire nor be automatically deleted based\
> on any rules from the deleted configuration.\
> \
> \#### Permissions\
> You must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\
> to perform the \`s3:PutLifecycleConfiguration\` operation using \[Bucket Policy]\(#tag/Policy/operation/PutBucketPolicy).\
> \
> \*\*Note:\*\* A brief delay may occur before the lifecycle configuration deletion is fully\
> propagated across all IONOS Object Storage systems. During this time, lifecycle rules may remain temporarily active.<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS Object Storage API for contract-owned buckets","version":"2.0.3"},"tags":[{"name":"Lifecycle","description":"Lifecycle Configuration of a Bucket"}],"servers":[{"url":"https://s3.eu-central-3.ionoscloud.com","description":"The endpoint for the `eu-central-3` region (Berlin, Germany)"},{"url":"https://s3.us-central-1.ionoscloud.com","description":"The endpoint for the `us-central-1` region (Lenexa, USA)"}],"security":[{"hmac":[]}],"components":{"securitySchemes":{"hmac":{"type":"apiKey","name":"Authorization","in":"header","description":"IONOS Object Storage API requests are authenticated using the AWS signature. \nThe IONOS Object Storage API authenticates users using a customized HTTP scheme based on a [keyed-HMAC](https://en.wikipedia.org/wiki/HMAC) (Hash Message Authentication Code).\nThe process of generating the proper Authorization header is somewhat involved. We recommend that you make use of a tool such as Postman.\n\n<img src=\"/docs/s3/hmac-postman.png\" width=\"800px\" />\n\nIn the **Authorization** tab for a request, select **AWS Signature** from the **Type** dropdown list.\nSpecify where Postman should append your authorization data using the **Add authorization data to** drop-down menu.\n\n* If you select **Request Headers**, Postman populates the **Headers** tab with Authorization and `X-Amz-` prefixed fields.\n\n* If you select **Request URL**, Postman populates the **Params** tab with authentication details prefixed with `X-Amz-`.\n\n\n**Note:** The parameters listed below contain confidential information. We recommend using variables to keep this data secure while working in a collaborative environment.\n\n* For **Access Key**, enter your `access key` directly in the fields or through variables for added security.\n\n* For **Secret Key**, enter your `secret key` directly in the fields or through variables for added security.\n\nAdvanced fields are optional, but Postman will attempt to generate them automatically if necessary.\n* For **AWS Region**, enter one of the [regions](#section/Endpoints) (`eu-central-3`) where your bucket is hosted.\n\n* For **Service Name**, enter `s3`. The name of the service that receives the requests.\n\n* For **Session Token**, **leave the field blank**. This is only required when temporary security credentials are used.\n"}},"schemas":{"BucketName":{"description":"The bucket name.","type":"string","minLength":3,"maxLength":63,"xml":{"name":"Name"}}}},"paths":{"/{Bucket}?lifecycle":{"delete":{"tags":["Lifecycle"],"summary":"DeleteBucketLifecycle","operationId":"DeleteBucketLifecycle","description":"Deletes the lifecycle configuration from the specified bucket.\nAs a result, objects within the bucket will neither expire nor be automatically deleted based\non any rules from the deleted configuration.\n\n#### Permissions\nYou must be the contract owner or an administrator to perform this operation. If not, they can grant you permission\nto perform the `s3:PutLifecycleConfiguration` operation using [Bucket Policy](#tag/Policy/operation/PutBucketPolicy).\n\n**Note:** A brief delay may occur before the lifecycle configuration deletion is fully\npropagated across all IONOS Object Storage systems. During this time, lifecycle rules may remain temporarily active.\n","responses":{"204":{"description":"Successful operation","headers":{},"content":{"application/xml":{}}}},"parameters":[{"name":"Bucket","in":"path","required":true,"schema":{"$ref":"#/components/schemas/BucketName"}},{"name":"lifecycle","in":"query","required":true,"schema":{"type":"boolean","enum":[true]},"allowEmptyValue":true}]}}}}
```
