25 Jan 2019 04:19 PM
Hello,
I actually work with Dynatrace API and I have a little mistake. For each problem, I find when they start and end, afterward I apply a filter on userSession to find how many people are impact by a specific error.For some error, I don't have any value in API response. However, when I search on Dynatrace website, I can find how many people are impact by this specific error. Therefore, I'm wondering if API and website have same data source, and if it's not, how long API keep information and how to change that.
Thanks.
Regards,
Bastien T.
Solved! Go to Solution.
28 Jan 2019 08:39 AM
Hello,
Why "Not everything available in the webUI is available in the Dynatrace API." ? Where can I find datas available in the webUI and not in Dynatrace API ?
Thanks
Bastien T
29 Jan 2019 10:33 AM
Or where can I find all data and why they are available in the webUI and not in Dynatrace API, they are differents sources of datas? All data from userSession are not in the same database if I want to have them from the webUI and Dynatrace API ?
Thanks.
Regards,
Bastien T.
29 Jan 2019 02:35 PM
Hi Bastien,
See below for all the metrics that can be retrieved via the API
https://www.dynatrace.com/support/help/shortlink/api-metrics#built-in-metrics
All the various funtions the API can perform are listed in the link below
https://www.dynatrace.com/support/help/dynatrace-api/
Thanks
NJ
30 Jan 2019 09:33 AM
Hello @Ugochukwu N.,
I'm sorry, you didn't answer my question. I found how to use the Dynatrace API. My question was mainly about the lifetime of the data. I'm wondering about difference between the lifetime of the data in Dynatrace API and the lifetime of the data in webUI.
Do these data come from the same data source or are they in different databases with different data lifetimes?
Thanks.
Regards,
Bastien T.
31 Jan 2019 09:04 AM
Hi Ugochukwu,
It was exactly what I'm looking for! Thank you!
I had only a little question more:
Did you know why my request didn't return any data after few hours after end of an error?
Here startDate is equal to the Timestamp in the begin of a specific error and endDate is the end of this specific error, applicationID is the ID of application receive with endDate and startDate when we interrogate Problem API . If data have a long duration of the lifetime, why evening I can't get information of impact of a specific error which had takes place the morning of same date?
SELECT count(*) as count, userAction.name as name, userAction.targetUrl as targetURL, applicationType, matchingConversionGoals , bounce, userAction.apdexCategory AS apdex
FROM userSession
WHERE totalErrorCount > 0 and userType = "REAL_USER"
AND userId = null
AND ((startTime <= " + startDate + " AND endTime >= " + endDate + ")
OR (startTime <= " + startDate + " AND endTime <= " + endDate + ")
OR (startTime <= " + endDate + " AND startTime >= " + startDate + " AND endTime >= " + endDate + ")
OR (startTime <= " + endDate + " AND startTime >= " + startDate + " AND endTime >= "+ startDate + " AND endTime <= "+ endDate +"))
AND userAction.internalApplicationId=\" " + applicationID + " \"
GROUP BY userAction.name, userAction.targetUrl, applicationType, matchingConversionGoals, bounce, userAction.apdexCategory
ORDER BY count(*) desc
Thanks.
Regards,
Bastien T.