Skip to content

PSA Hubspot trashes event properties #494

Description

@nigelsim

As much of a public service announcement as anything. If HubSpot is one of the analytics providers, it mutates the properties object it gets from the subscription to add its own additional properties. We need to clone the events before passing to _hsq.push

We send it this

{
  "event": "show",
  "properties": {
    "category": "screen",
    "label": "activity-stream",
    "screen": "activity-stream",
  }
}

And the object is this when its done

{
  "event": "show",
  "properties": {
    "a": 3997179,
    "b": "203733263.8.1742973083895",
    "bfp": 2185067903,
    "category": "screen",
    "cc": 15,
    "cd": "24-bit",
    "cs": "UTF-8",
    "cts": 1742973719320,
    "i": "email=nigel.sim%2Btestnigel%blah.com&firstname=Nigel&lastname=Simms&dimension2=USER",
    "k": 3,
    "label": "activity-stream",
    "ln": "en-gb",
    "m": "",
    "n": "",
    "nc": false,
    "po": "/home",
    "pu": "https://blah/home?organisationId=253",
    "rpo": "/",
    "screen": "activity-stream",
    "sd": "2560x1080",
    "t": "3. Blah",
    "u": "203733263.342574745c9349180c61038d5fbf7889.1624960793985.1742963233752.1742973083895.2724",
    "v": 1.1,
    "vi": "342574745c9349180c61038d5fbf7889"
  }
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions