Skip to main content
POST
/
media-bridge
/
v1
/
events
/
media-played-percent
Create a quartile event
curl --request POST \
  --url https://api.hubapi.com/media-bridge/v1/events/media-played-percent \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "mediaType": "AUDIO",
  "occurredTimestamp": 123,
  "playedPercent": 123,
  "sessionId": "<string>",
  "_hsenc": "<string>",
  "contactId": 123,
  "contactUtk": "<string>",
  "externalId": "<string>",
  "externalPlayContext": "EMAIL",
  "mediaBridgeId": 123,
  "mediaName": "<string>",
  "mediaUrl": "<string>",
  "pageId": 123,
  "pageName": "<string>",
  "pageUrl": "<string>"
}
'
{
  "contactId": 123,
  "mediaBridgeId": 123,
  "mediaBridgeObjectCoordinates": "<string>",
  "mediaBridgeObjectTypeId": "<string>",
  "mediaName": "<string>",
  "mediaType": "AUDIO",
  "occurredTimestamp": 123,
  "playedPercent": 123,
  "portalId": 123,
  "providerId": 123,
  "sessionId": "<string>",
  "externalPlayContext": "EMAIL",
  "mediaUrl": "<string>",
  "pageId": 123,
  "pageName": "<string>",
  "pageObjectCoordinates": "<string>",
  "pageUrl": "<string>"
}

Supported products

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json
mediaType
enum<string>
required
Available options:
AUDIO,
DOCUMENT,
IMAGE,
OTHER,
VIDEO
occurredTimestamp
integer<int64>
required
playedPercent
integer<int32>
required
sessionId
string
required
_hsenc
string
contactId
integer<int64>
contactUtk
string
externalId
string
externalPlayContext
enum<string>
Available options:
EMAIL,
EXTERNAL_PAGE
mediaBridgeId
integer<int64>
mediaName
string
mediaUrl
string
pageId
integer<int64>
pageName
string
pageUrl
string

Response

successful operation

contactId
integer<int64>
required

The ID of the contact in HubSpot’s system that consumed the media. This can be fetched using HubSpot's Get contact by usertoken (utk) API. The API also supports supplying a usertoken, and will handle converting this into a contact ID automatically.

mediaBridgeId
integer<int64>
required
mediaBridgeObjectCoordinates
string
required
mediaBridgeObjectTypeId
string
required
mediaName
string
required
mediaType
enum<string>
required
Available options:
AUDIO,
DOCUMENT,
IMAGE,
OTHER,
VIDEO
occurredTimestamp
integer<int64>
required
playedPercent
integer<int32>
required
portalId
integer<int32>
required

The ID of the HubSpot account.

providerId
integer<int32>
required
sessionId
string
required
externalPlayContext
enum<string>
Available options:
EMAIL,
EXTERNAL_PAGE
mediaUrl
string
pageId
integer<int64>

The content ID of the page that an event happened on, for HubSpot pages. Required if the page is a HubSpot page.

pageName
string

The name or title of the page that an event happened on. Required for non-HubSpot pages.

pageObjectCoordinates
string
pageUrl
string

The URL of the page that an event happened on. Required for non-HubSpot pages.

Last modified on March 30, 2026