Server Logs & Hubspot

SOLVE
mrich
Participant

Hey everyone.

 

I am building out our hubspot integration for our website. We'd like to set up visitation tracking. One of our engineers indicated it might be sensible for us to do this tracking on the serverside, rather than installing hubspots tracking code.

 

Is that possible? Are there any examples of how you would do this? I'm currently on marketing / sales professional.

0 Upvotes
1 Accepted solution

Accepted Solutions
IsaacTakushi
Solution
HubSpot Employee

Welcome, @mrich.

 

At this time, it's not possible to implement HubSpot page tracking server-side. All of the Tracking Code API methods leverage the embedded script loader except:

  • The Events HTTP API, which requires an Enterprise HubSpot subscription.
  • The Timeline API, which can be used to log custom timeline events.

Neither of these alternative solutions are as robust and flexible as native HubSpot page tracking, however. For example, their statistics cannot be pulled from the Analytics API.

 

Does your team have specific concerns with the HubSpot tracking code on your site?

 

Please let me know if you have additional questions or if I have misunderstood you.

Isaac Takushi

Alumnus, HubSpot Developer Support

View solution in original post

0 Upvotes
4 Replies 4
IsaacTakushi
Solution
HubSpot Employee

Welcome, @mrich.

 

At this time, it's not possible to implement HubSpot page tracking server-side. All of the Tracking Code API methods leverage the embedded script loader except:

  • The Events HTTP API, which requires an Enterprise HubSpot subscription.
  • The Timeline API, which can be used to log custom timeline events.

Neither of these alternative solutions are as robust and flexible as native HubSpot page tracking, however. For example, their statistics cannot be pulled from the Analytics API.

 

Does your team have specific concerns with the HubSpot tracking code on your site?

 

Please let me know if you have additional questions or if I have misunderstood you.

Isaac Takushi

Alumnus, HubSpot Developer Support

View solution in original post

0 Upvotes
mrich
Participant

> Does your team have specific concerns with the HubSpot tracking code on your site?

 

It seems the hubspot tracking code wouldn't be able to track page visits on our native mobile apps if it's a js clientside library only. Server side logging / tracking would enable us to collect data from all of our platforms. Is that not supported in HubSpot?

 

Also, Segment seems to imply they can send data over to hubspot from server side logging (under the 'server' section). Isn't that implying you can send page visits over from serverside logging or am I misreading that? 

0 Upvotes
IsaacTakushi
HubSpot Employee

Hi, @mrich.

 

Correct, HubSpot does not support server-side page view tracking. The closest two solutions are the ones I outlined above.

 

Segment's documentation could be a bit clearer. The analytics.track method described in the Server section (beginning with the sentence "When calling from any of our server-side sources") uses the Events HTTP API I mentioned earlier. This process is distinct from the page view tracking of the JavaScript snippet.

 

This server-side endpoint leverages custom events and so requires an Enterprise HubSpot subscription. Segment's documentation notes this in the preceding paragraph:

"IMPORTANT: You must have a HubSpot Enterprise account for traits from an identify call to be passed through to your track call and be successfully sent as a custom event to HubSpot."

Isaac Takushi

Alumnus, HubSpot Developer Support
mrich
Participant

Cool, that answers my questions. Thanks @IsaacTakushi