How do I update maintenance windows via the API v2?

Hi,

For context, I am using the Settings - Objects API

badgerfifteen_0-1729595956300.png

I’m looking to create an application which calls the Dynatrace API to update an existing maintenance window. When I put the object ID, I get the following 404 error:

<span class="">"message"</span><span>: </span><span>"Configuration schema builtin:alerting.maintenance-window does not exist with version 1.0.0."</span>

I can’t see any other API which would allow me to update a maintenance window, other than the deprecated one which I can’t use for obvious reasons.

Any ideas? Would be greatly appreciated :slightly_smiling_face:

Hello @badgerfifteen

As per the latest Dynatrace version, Maintenance window via environment API has been deprecated, so you can use Environment API v2 “Settings - Objects”

Simply you will :

  1. Get the Object ID using token with settings.read scope.
  2. Put The Object ID using settings.write scope, and execute the required actions

As per attached steps (1)

2024-10-22_15h53_31.png

(2)

All the best.

KR,

Peter