Try it free

Update a bucket

  • Latest Dynatrace
  • Reference
  • Published Oct 13, 2026

Update a bucket definition in Dynatrace with the Grail Storage Management API using the bucket name, optimistic locking version, and changed fields.

PUTSaaShttps://{your-environment-id}.apps.dynatrace.com/platform/storage/management/v1/bucket-definitions/{bucketName}

Overview

You provide the bucketName path parameter and the optimistic-locking-version query parameter, then send the fields to update in the request body. The operation updates the bucket definition and returns the updated result.

Authentication

To execute this request, you need a platform token or OAuth access token with storage:bucket-definitions:write scope. To learn how to obtain and use it, see Tokens and authentication.

Parameters

ParameterTypeDescriptionInRequired
bucketNamestring

Bucket name to update

pathRequired
optimistic-locking-versioninteger

optimistic-locking-version defines the base version that this update applies to. You can get the current version of a bucket definition by checking the version field in the JSON response of GET bucket definitions or GET bucket definition.

ATTENTION: this optimistic-locking-version and the version value in the JSON body must match.

queryRequired
bodyUpdateBucket

Updated Bucket

bodyRequired

Request body objects

The UpdateBucket object

ElementTypeDescriptionRequired
bucketClassstring

The class of the bucket. Read-only after creation.

The element can hold these values
  • live
  • historic
Optional
bucketNamestring

The unique identifier of the bucket within the tenant.

Required
displayNamestring

Descriptive name of the bucket. No restriction regarding unique naming or valid characters.

Optional
includedQueryLimitDaysinteger

The period in days in which queries from the bucket are included in the pricing model.

Optional
includedQueryLimitDaysOrDefaultinteger-Optional
metricIntervalstring

Metric interval for metric buckets. Will be ignored for other buckets.

The element can hold these values
  • PT1M
  • PT5M
  • PT15M
  • PT1H
Optional
retentionDaysinteger

The retention period in days of the data in the bucket. Important note: the new retention days will also apply to existing records. Shortening the retention period could result in data deletion!

Optional
retentionDaysOrDefaultinteger-Optional
statusstring

The current status of the bucket, depending on bucket lifecycle.

The element can hold these values
  • creating
  • active
  • updating
  • deleting
Required
tablestring

Name of the table the bucket is assigned to.

Required
versioninteger

Optimistic locking version. Update requests define with this on which version the data updated is based on. This must match with the version stored, otherwise the update will fail due to concurrent modification.

Optional
versionOrDefaultinteger-Optional

Request body JSON model

This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.

{
"bucketName": "custom_logs",
"table": "logs",
"displayName": "Custom logs bucket (updated)",
"status": "active",
"retentionDays": 10,
"includedQueryLimitDays": 0,
"version": 1
}

Response

Response codes

CodeTypeDescription
200-

Successfully updated bucket definition

202-

Accepted update bucket definition

400ErrorEnvelope

bad request

401ErrorEnvelope

unauthorized

403ErrorEnvelope

Forbidden

404ErrorEnvelope

Bucket with provided name was not found

409ErrorEnvelope

Attempt to update an old version or an operation is currently in progress that prevents current modifications (creating, deleting, updating)

Response body objects

The ErrorEnvelope object

ElementTypeDescription
errorExceptionalReturn-

The ExceptionalReturn object

ElementTypeDescription
codeinteger-
errorDetails(CustomValidationErrorInfo | InvalidAuditEventsErrorInfo | MediaTypeErrorInfo | ParameterErrorInfo | ProxyErrorInfo | QueryFrontendRawErrorInfo | RequestBodyErrorInfo)[]-
messagestring-

The CustomValidationErrorInfo object

The ErrorInfo object

ElementTypeDescription
messagestring-

The InvalidAuditEventsErrorInfo object

The MediaTypeErrorInfo object

The ParameterErrorInfo object

The ProxyErrorInfo object

The QueryFrontendRawErrorInfo object

The RequestBodyErrorInfo object

Response body JSON models

{
"error": {
"code": 400,
"message": "Missing request header",
"errorDetails": [
{
"type": "parameter",
"parameterDescriptor": "Dt-Tenant",
"message": "is required"
}
]
}
}
Related tags
Platform APIDynatrace Platform