Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Is it possible to access page view data via the C# API? I wish to access the top 10 viewed pages.
There is no C# API (yet) to retrieve the top X most visited pages.
You can query the tables directly though. Something like this should work:
SELECT TOP 10 p.protocol, p.domain, p.path, COUNT(p.id) pageviews
FROM [uMarketingSuiteAnalyticsPageview] pv
JOIN uMarketingSuiteAnalyticsPage p
ON pv.pageId = p.id
GROUP BY p.id, p.protocol, p.domain, p.path
ORDER BY COUNT(p.id) DESC
If you also want Umbraco node ids you can get those by joining the uMarketingSuiteAnalyticsUmbracoPageVariant table (on pageview.umbracoPageVariantId).
If this does not work for you, let me know!
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted