22 Nov 2024 04:44 PM - last edited on 25 Nov 2024 08:26 AM by MaciejNeumann
Hi Team,
We are trying to automate metrics for our workloads and see below exception with 400 code
Exception in thread "main" java.io.IOException:
Error Code: 400
Response Text: {"error":{"code":400,"message":"Constraints violated.","constraintViolations":[{"path":"nextPageKey","message":"expected one of nextPageKey or metricSelector to be specified","parameterLocation":"QUERY","location":null}]}}
<> is host, ** is our workload, masking it for data privacy.
metricSelector is mentioned in URL yet seeing same errorcode, adding pageKey as suggested shows combination is not supported. Stuck here please help
Please note that the same call works using postman
27 Nov 2024 09:33 AM
Hello @ajithsaranya
Kindly ensure the specified parameters in the Api call meets the defined parameters in Dynatrace doc to avoid exposure to the highlighted error:
Hoping it adds value
Regards,
Peter