Discover APIs, integration guides, and other documentation
This API is currently in public beta
The Web Analytics endpoint allows developers to find and filter events associated with a CRM object of any type. These events form a timeline of the interactions the selected object has had within the HubSpot system. Objects and events can be of any type including HubSpot native types, app-specific types, or portal specific types.
Common uses for this API
This API returns events for a single CRM object at a time -- selection of a single object is required. In the future we may relax this restriction, returning events for multiple target objects in a single request.
The desired object can be selected by specifying the objectType
and using either the objectId
or objectProperty
query parameter.
When the exact objectId is known, the object is selected using the objectType
and objectId
query parameters. If multiple objectId
or objectType
parameters are provided, only the first are used. For example:
/events-beta/v1/events?objectType=contact&objectId=224834
In these examples, ?objectType=contact&objectId=2832
will select HubSpot contact 2832 from the currently authorized portal.
When object properties are required to make a selection, the objectType
and objectProperty
prefixed parameters are used to make the selection. The events API allows the use of any properties which can uniquely identify the object. There generally will be very few to none such properties available. A particular property to match on is identified by an objectProperty.{propname}={propvalue}
query parameter. For example, to find contacts by their email property:
/events-beta/v1/events?objectType=contact&objectProperty.email=user12@dev.com
All event types are returned. At present only e_visited_page
and e_submitted_form
types are available.