Skip to main content
Version: v1

Update Bucket

This method allows modifying parameters of a selected bucket

info

Additional headers specified during update will be added to all server responses when accessing the corresponding bucket

Request Parameters

PUT /api/clients/v1/s3Buckets/{id}/

Headers

  • Content-Type: application/json
  • Authorization: Bearer $access_token

Path

ParameterTypeConstraintsDescriptionExample
idinteger> 0, requiredBucket ID46

JSON body

ParameterTypeConstraintsDescriptionExample
headersobject[]List of additional HTTP headers
headers.keystringHeader nameX-MEDIA-TYPE
headers.valuestringHeader value.pptx

Response Parameters

JSON body

ParameterTypeDescription
idintegerBucket ID
namestringBucket name
statusstringCDN status for the bucket
resource_idintegerResource ID
last_cache_cleanupstringLast cache cleanup time for the bucket
headersobject[]List of additional HTTP headers
headers.keystringHeader name
headers.valuestringHeader value
200 OK

Bucket object

{
"id": 46,
"name": "media",
"status": "ok",
"resource_id": 16,
"last_cache_cleanup": null,
"headers": [
{
"key": "X-MEDIA-TYPE",
"value": ".pptx"
}
]
}
400 Bad Request

Invalid path parameters

{
"id": [
"A valid integer is required."
]
}
401 Unauthorized

Authentication credentials missing or invalid

{
"detail": "Given token not valid for any token type",
"code": "token_not_valid",
"messages": [
{
"token_class": "AccessToken",
"token_type": "access",
"message": "Token is invalid or expired"
}
]
}
403 Forbidden

Bucket modification is only allowed for project participants associated with the bucket

{
"detail": "Only project participants can view this project's buckets"
}
404 Not Found

Bucket with specified ID not found

{
"detail": "Bucket not found"
}