# Dynatrace API to fetch monitoring details

**URL:** <https://community.dynatrace.com/t/dynatrace-api-to-fetch-monitoring-details/42708>\
**Category:** Dynatrace API\
**Tags:** databases, dynatrace-api\
**Created:** [November 20, 2023, 9:57am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-monitoring-details/42708 "2023-11-20T09:57:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shruts](https://avatars.discourse-cdn.com/v4/letter/s/839c29/32.png) [@Shruts](https://community.dynatrace.com/u/Shruts)\
**Post date:** [November 20, 2023, 9:57am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-monitoring-details/42708/1 "2023-11-20T09:57:46Z")

</div>

Hi,

I’m looking for an API who can give database queries which is taking more than 30 second to load.

I’m looking this integration with Jenkins pipeline.

Kindly suggest me which API can give the data.

---

<div class="post-metadata">

**Author:** ![RazTN7](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/raztn7/32/10208_2.png) [@RazTN7](https://community.dynatrace.com/u/RazTN7)\
**Post date:** [November 20, 2023, 10:34am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-monitoring-details/42708/2 "2023-11-20T10:34:50Z")

</div>

Hello&nbsp;[@Shruts](https://community.dynatrace.com/user/68893)

2 main steps to follow

1. Create Calculate metrics (see if below screen print works or try to create one with logic)

 ![RazTN7X_0-1700476257504.png](https://global.discourse-cdn.com/dynatrace/original/3X/a/e/aec0f88376058f51caad582a95347b2fc8c3f736.png)

2. Get the metric details via Metrics APIv2

 ![RazTN7X_1-1700476414035.png](https://global.discourse-cdn.com/dynatrace/original/3X/d/a/da421836475e262f9b2c0ff00556e122fc7d5ace.png)

Cheers!

RN

---

<div class="post-metadata">

**Author:** ![Shruts](https://avatars.discourse-cdn.com/v4/letter/s/839c29/32.png) [@Shruts](https://community.dynatrace.com/u/Shruts)\
**Post date:** [November 23, 2023, 10:40am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-monitoring-details/42708/3 "2023-11-23T10:40:15Z")

</div>

Hi,

Can we have any other way without creating the new metrics? Can we get the all queries which are failing and also which are taking more than 30s
