API: Get a page URL from the itemId | Community
Skip to main content
Level 2
June 28, 2021
Solved

API: Get a page URL from the itemId

  • June 28, 2021
  • 1 reply
  • 1951 views

Hi, I'm looking to do exactly what is described here: https://experienceleaguecommunities.adobe.com/t5/adobe-analytics-questions/adobe-analytics-2-0-api/qaq-p/326794: Fetch metrics by page URL.


I've found out that the dimension to use is 'variables/page', but as the pages are named in my demo data, I get the name in the objects of the response: (I can't paste any JSON object to illustrate that, it makes my posts disappearing, but it contains a itemId, a value which is the name, and the data)

 

Now, how can we associate the itemId with an actual URL? The linked post mention to make a separate breakdown call, but I can't find the concrete endpoint to do that in the API.

Thanks!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Hemangini

Hi @sbellone ,
If you are capturing page URL in any variable (eVar/prop) then the easiest way would be to create a similar report in Workspace by breaking down Page with Page URL (your custom variable) and then use the Workspace debugger to copy that JSON request and try that out in Swagger under /reports endpoint.

Approach best described in this video: https://experienceleague.adobe.com/docs/analytics-learn/tutorials/apis/using-analysis-workspace-to-build-api-2-requests.html?lang=en

1 reply

HemanginiAdobe EmployeeAccepted solution
Adobe Employee
June 29, 2021

Hi @sbellone ,
If you are capturing page URL in any variable (eVar/prop) then the easiest way would be to create a similar report in Workspace by breaking down Page with Page URL (your custom variable) and then use the Workspace debugger to copy that JSON request and try that out in Swagger under /reports endpoint.

Approach best described in this video: https://experienceleague.adobe.com/docs/analytics-learn/tutorials/apis/using-analysis-workspace-to-build-api-2-requests.html?lang=en

sbelloneAuthor
Level 2
June 29, 2021
Thank you for confirming, @hemangini!