cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

modify parameters when retrieving metric value and usage of DT API

MariettaAlmeida
Organizer

hi all, we are using DT API and we have some questions about its usage:

1) can we edit the info that we retrieve from the API? Example: we are getting the total amount of problems of the environment through API and we would like to bring the problems just from 2 hours ago. how can we do this ?

2) when using api do we need internet connection ? the servers itself doesnt have internet connection and we use them with a proxy

 

7 REPLIES 7

Peter_Youssef
Leader

Hi @MariettaAlmeida 

Regarding the raised concerns:

  • Having admin permissions or at least permission to change monitoring settings.
  • Using the problems Api v2 under environment API V2.
  • Create authentication token with "problems.read && optionally you can add problems.write".
  • Use the generated token to unlock the Api and fetch the related problems details.

Connectivity between Dynatrace and API endpoint or Postman should be conducted properly even through proxy , it won't be an issue as long as the communication is stable.

The attached URL will guide you to accomplish the objective: 

As simple as that specify the below attached parameters.

2024-12-07_18h30_21.png

2024-12-07_18h32_22.png

2024-12-07_18h33_53.png

2024-12-07_18h35_38.png

2024-12-07_18h36_55.png

For Sorting:

2024-12-07_18h38_17.png

Tip:

  • Form : will be 2H and to will be now "Not vice versa" 😉 😊

Hoping it helps.

KR,

Peter.

Peter_Youssef
Leader

Hello @MariettaAlmeida 

For detailed info about the Dynatrace problems API, fell free to review:

Regards,

Peter

Peter_Youssef
Leader

Hi @MariettaAlmeida 

For detailed information about Davis AI and problem generation feel free to review:

Kindly note:

  • Problems API v1 is decommissioned, API v2 is the available option.

BR, 

Peter 

Peter_Youssef
Leader

Hi @MariettaAlmeida 

Regarding the metrics point, it can be exposed under Observe and explore:

  • Data Explorer
  • Metrics 

2024-12-07_18h48_53.png

You can customize the preferred visualizations through dashboard or creating a metric events for alerting as per monitoring requirements.

Hoping it adds value.

BR,

Peter

MariettaAlmeida
Organizer

thank you all, we are using Postman and when using the table visualization it shows just 10 problems from a total of 15 problems, how can we see the total amount of problems ? is like the table trim the data.

here is the total count 

MariettaAlmeida_0-1733760360593.png

 

and the total of problems on postman page 

MariettaAlmeida_1-1733760398455.png

 

Hi.

So, in general, if pagination occurs, you'd do further calls as needed, using only the querying parameter nextPageKey with the value shown in the last call

paulo_calaxa_0-1734013961158.png

 

About giving you only the first 10: as it is shown in the screenshot, either it is what was asked for in pageSize, or it is a default.

 

Kind regards,
Paulo.

GosiaMurawska
Community Team
Community Team

Hi, @MariettaAlmeida! Have you managed to find the answer to your question? It would be great if you share it with the Community 🙂

Featured Posts