Expand my Community achievements bar.

SOLVED

Query metrics every 5 minues

Avatar

Level 1

We use Adobe Experience to store website analytics. We need to query the metrics using Adobe Analytics API (rest interface). Can I query the analytics at every 5 minutes interval? For example, I want to get the metrics for every 5 minutes from 0th hour of today until five minutes ago. If yes, can you please provide a sample request in Json format?

 

Thanks!

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

So what you can do is first:

  • Create an Adobe I/O integration as it will be needed to use Adobe Analytics API
  • Check Adobe Analytics API 2.0, don't use 1.4. Also if you want to reproduce same data as from the Analysis Workspace report, in Analysis Workspace go to Help > Enable Debugger and you will see a little bug next to the table you built. Click on it and it will provide you the API structure call. So create a table with hours or minute granularity and check the API call
  • Now that you have everything ready you just need to make the API call

Now what I guess you want is real-time data and Adobe has a functionality but it is way too limited. There is also the livestream API that is only in 1.4 as far as I can see. For your use I won't bother with it.

 

Also please bear in mind that Adobe Analytics has a processing time of in average from 30 minutes to 90 minutes. This means that some metrics will not be updated straight away like visits for example.

 

So I would maybe not query every 5 minutes depending on your metrics and dimensions.

View solution in original post

5 Replies

Avatar

Level 2

@rohithaksha I will suggest to check the below link once :-

https://github.com/AdobeDocs/analytics-1.4-apis/blob/master/docs/live-stream-api/getting_started.md#

If this fullfills your requirement than you need to check if the above is in the contract or not.

Avatar

Level 3

@rohithaksha You can refer the below Github for the Query the Metrics and it have the sample JSON also for your refrence.

URL:- https://github.com/AdobeDocs/analytics-2.0-apis/blob/master/calculatedmetrics.md#:~:text=The%20Analy...

 

Thank You

Avatar

Correct answer by
Community Advisor

So what you can do is first:

  • Create an Adobe I/O integration as it will be needed to use Adobe Analytics API
  • Check Adobe Analytics API 2.0, don't use 1.4. Also if you want to reproduce same data as from the Analysis Workspace report, in Analysis Workspace go to Help > Enable Debugger and you will see a little bug next to the table you built. Click on it and it will provide you the API structure call. So create a table with hours or minute granularity and check the API call
  • Now that you have everything ready you just need to make the API call

Now what I guess you want is real-time data and Adobe has a functionality but it is way too limited. There is also the livestream API that is only in 1.4 as far as I can see. For your use I won't bother with it.

 

Also please bear in mind that Adobe Analytics has a processing time of in average from 30 minutes to 90 minutes. This means that some metrics will not be updated straight away like visits for example.

 

So I would maybe not query every 5 minutes depending on your metrics and dimensions.

Avatar

Level 1

Thank you all for the replies.

 

Regarding choosing API2.0, can I select the API version while creating the project in Adobe Developer Console (where we upload certificates and get the API key/secret etc.)? If not, where do I set the API version?

Avatar

Community Advisor

IN Adobe I/O you do not really choose the version of the API. You simply configure an integration with the Adobe API which will allow you to generate an access token. You should then use the correct API version endpoint with the credentials provided in your integration and the access token you generated.

 

Check out the github page https://github.com/AdobeDocs/analytics-2.0-apis/tree/master