Try it free

Empty a bucket

  • Latest Dynatrace
  • Reference
  • Published Oct 13, 2026

Empty a bucket in Dynatrace with the Grail Storage Management API by removing its content asynchronously while keeping the bucket definition.

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

Overview

ATTENTION - This operation is irreversibly

Truncate can be used to empty a bucket. This operation will remove the content of a given bucket.

Truncate is an asyncronous task. Runtime will depend on the amount of data that has to be removed.

Operation can be executed on all types of buckets.

Authentication

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

Parameters

ParameterTypeDescriptionInRequired
bucketNamestring

Bucket name to truncate.

pathRequired

Response

Response codes

CodeTypeDescription
202-

Accepted truncate bucket

400ErrorEnvelope

bad request

401ErrorEnvelope

unauthorized

403ErrorEnvelope

Forbidden

404ErrorEnvelope

Bucket not found

503ErrorEnvelope

Server not ready

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