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

This product reached the end of support date on March 31, 2021.

Help using REST Interface

Radu
Dynatrace Pro
Dynatrace Pro

Hi,

I've just started learning about and using the DC RUM REST services and I find myself stuck trying to do some simple things. Currently I am trying to do the following tasks:

  1. Retrieve all application names (as defined in business units)
  2. Retrieve value of Application Health Index for 1 application (e.g. "EasyTravel") for past 24 hours (i.e. as we see it in the Application Health Status report)

What should the body and request params look like for these calls?

Regards,

Radu

7 REPLIES 7

brett_b2
Inactive


Hey Radu,


I built a DC RUM RESTful Helper for this situation. Check it out on GitHub. Essentially, you'll just create a DMI using the dropdown menus and then it will provide you what that rest call is. Let me know if it works for you and if you have any questions on how to use it.


Regards

cosmin_gherghel
Dynatrace Pro
Dynatrace Pro

Hey Radu,

I created this rest call a while back that returns all the client sites that have application performance less than 80%. You can reuse this just change the dimensions and filters.

#Create POST request
url = "https://CAS_server:443/rest/dmiquery/getDMIData3/"
headers = {"Content-Type" : "application/json"}
payload = { "appId": "CVENT",
"viewId": "ClientView",
"dataSourceId": "ALL_AGGR",
"dimensionIds": [ "begT", "cLoc"], # add dimension
"metricIds": [ "appPerf"], # add metric
"dimFilters": [ ["cLoc", "Back Office - Strongsville - Main Lab Rack 1", 1], ["businessHour", "business", 0] ], # set dimension filters
"metricFilters": [ ["appPerf", "<", "80", 1] ], #set metric filters
"sort": [],
"top": 0, #return all results
"resolution": "r", #period
"timePeriod": "1D", #last day
"numberOfPeriods": 240, #1 full day
"timeBegin": r'null',
"timeEnd": r'null'
}
#Send POST
r = requests.post(url, headers=headers, verify=False, data=json.dumps(payload), auth=('username', 'password'))

Hi Cosmin,

I am interested - what does this request return?

Will it return 240 values of the appPerf metric for the past day?

I am currently trying to find a way to collect the metrics values for each period in DC RUM. Something like a dump - I expect something like time: 10:00:00, appPerf = 90%, time: 10:05:00, appPerft = 80% - is there something like this I can achive with the API?

OK... I just found the solution:
In order to get the granularity or the dump of metric values we need to include the ''begT'' dimension

erenedo
Organizer

Hello everyone,


Is it possible to use DCRUM RESTful Helper to check AMD?

Thanks in advance.

Elena.

Hi Elena,
What metrics are you looking to pull from your AMD. The REST helper will grab most things a DMI can generate so if you can make a DMI report chances are high you can grab it through the REST helper.

erenedo
Organizer

Hi Kyle,

We want to check AMD status. It would be insteresting checking status dashboard using REST.

Would it possible?

Thanks a lot.