Empty a bucket in Dynatrace with the Grail Storage Management API by removing its content asynchronously while keeping the bucket definition.
| POST | SaaS | https://{your-environment-id}.apps.dynatrace.com/platform/storage/management/v1/bucket-definitions/{bucketName}:truncate |
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.
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.
| Parameter | Type | Description | In | Required |
|---|---|---|---|---|
| bucketName | string | Bucket name to truncate. | path | Required |
| Code | Type | Description |
|---|---|---|
| 202 | - | Accepted truncate bucket |
| 400 | Error | bad request |
| 401 | Error | unauthorized |
| 403 | Error | Forbidden |
| 404 | Error | Bucket not found |
| 503 | Error | Server not ready |
ErrorEnvelope object| Element | Type | Description |
|---|---|---|
| error | Exceptional | - |
ExceptionalReturn object| Element | Type | Description |
|---|---|---|
| code | integer | - |
| errorDetails | (Custom | - |
| message | string | - |
CustomValidationErrorInfo objectErrorInfo object| Element | Type | Description |
|---|---|---|
| message | string | - |
InvalidAuditEventsErrorInfo objectMediaTypeErrorInfo objectParameterErrorInfo objectProxyErrorInfo objectQueryFrontendRawErrorInfo objectRequestBodyErrorInfo object{"error": {"code": 400,"message": "Missing request header","errorDetails": [{"type": "parameter","parameterDescriptor": "Dt-Tenant","message": "is required"}]}}