Settings API - DELETE an object

  • Reference
  • Published Feb 24, 2021

Updates the specified settings object. Deletion cannot be undone!

DELETEManagedDynatrace for Governmenthttps://{your-domain}/e/{your-environment-id}/api/v2/settings/objects/{objectId}
Environment and Cluster ActiveGate (default port 9999)https://{your-activegate-domain}:9999/e/{your-environment-id}/api/v2/settings/objects/{objectId}

Authentication

To execute this request, you need an access token with settings.write scope.

To learn how to obtain and use it, see Tokens and authentication.

Parameters

ParameterTypeDescriptionInRequired
objectIdstring

The ID of the required settings object.

pathRequired
updateTokenstring

The update token of the object. You can use it to detect simultaneous modifications by different users.

It is generated upon retrieval (GET requests). If set on update (PUT request) or deletion, the update/deletion will be allowed only if there wasn't any change between the retrieval and the update.

If omitted on update/deletion, the operation overrides the current value or deletes it without any checks.

queryOptional
adminAccessboolean

If set to true and user has settings:objects:admin permission, the endpoint will act as if the user is the owner of all objects

queryOptional

Response

Response codes

CodeTypeDescription
204-

Success. Response doesn't have a body.

400SettingsObjectResponse

Failed. Schema validation failed.

403ErrorEnvelope

Failed. Forbidden.

404SettingsObjectResponse

Failed. The requested resource doesn't exist.

409SettingsObjectResponse

Failed. Conflicting resource.

4XXErrorEnvelope

Client side error.

5XXErrorEnvelope

Server side error.

Response body objects

The SettingsObjectResponse object

The response to a creation- or update-request.

ElementTypeDescription
codeinteger

The HTTP status code for the object.

errorError-
invalidValuestring

The value of the setting.

It defines the actual values of settings' parameters.

The actual content depends on the object's schema.

objectIdstring

For a successful request, the ID of the created or modified settings object.

The Error object

ElementTypeDescription
codeinteger

The HTTP status code

constraintViolationsConstraintViolation[]

A list of constraint violations

messagestring

The error message

The ConstraintViolation object

A list of constraint violations

ElementTypeDescription
locationstring-
messagestring-
parameterLocationstring-
The element can hold these values
  • HEADER
  • PATH
  • PAYLOAD_BODY
  • QUERY
pathstring-

The AnyValue object

A schema representing an arbitrary value type.

Response body JSON models

{
"code": 1,
"error": {
"code": 1,
"constraintViolations": [
{
"location": "string",
"message": "string",
"parameterLocation": "HEADER",
"path": "string"
}
],
"message": "string"
},
"invalidValue": "string",
"objectId": "Y2ktaGdyb3VwLTEyMythZjhjOThlOS0wN2I0LTMyMGEtOTQzNi02NTEyMmVlNWY4NGQ="
}