Analytics API - Get Broken Down Data - By "Domain" Option


#1

Hi There!

When in the HubSpot App in the Traffic Analytics Reporting area, under the "Sources" tab I can select specific Domains to filter the data.

Is it possible to Get Broken Down Data against each Domain, mirroring the in-app experience?

Thank you in advance!


#2

Hi Brie,

Just to confirm you would like to see all the entrance URLs or "Domains" for the Direct traffic source? If so you can use this endpoint: https://api.hubapi.com/analytics/v2/reports/sources/total?hapikey=demo&start=20180101&end=20180301&d1=direct

This will break down your analytics by Sources and then further drill down (d1=direct) exclusively into the Direct Traffic Source.

Let me know if this is what you're looking for!

Kelsey


#3

Hi Kelsey!

So you're saying that the urls returned by source=direct is the same as if I were to use the "Domains" drop down on the main Analytics tab in your application?

When I use this drop down in HubSpot, I can see the source breakdown after I select a specific Domain in the upper left corner.

I'm wondering if we can get the Source breakdown for a specific Domain like in the application.

Feel free to email me if you want some sample screenshots :slight_smile:

Thanks!


#4

Hi There - wanted to check in on this.

Can anyone provide some guidance?

Thank you!


#5

Hi @brie,

It's not yet documented, but you can actually use the subdomain query parameter to filter by a specific domain. For example:

https://api.hubapi.com/analytics/v2/reports/:breakdown_by/:time_period?subdomain=www.subdomain.com