How to remove URL search params from analytics requests?

Some requests that originate from the Tracking code script include the full URL with search params in it’s URLs or headers. I would really like to have control over this behaviour. For example:

Request URL: https://api-eu1.hubspot.com/livechat-public/v1/message/public?...
...
X-Hubspot-Messages-Uri: https://website-url.com/?with=search-params

or the iframe’s request (#hubspot-conversations-iframe) includes the full URL with search params in it’s “Referer” header:

Referer: https://app-eu1.hubspot.com/conversations-visitor/...&url=https%3A%2F%2Fwebsite-url.com%2F%3Fwith%3Dsearch-params&...

Is there a way to get rid of the search params in any of the Tracking code’s requests?

Hi, @PTsaruk :waving_hand: Thanks for your question. Welcome to our community. I don’t think you are missing an option based on what is listed in the documentation.

There isn’t a straightforward, supported way to exclude URL search parameters from HubSpot tracking code requests. If you have the resources, you might explore indirect methods like server-side processing to strip out data you don’t want passed along to your HubSpot portal.

I hope this helps get you moving forward! — Jaycee