Custom First Party Sensor Endpoint

Deprecated

The default first party endpoint to retrieve the HUMAN sensor is /<app_id_without_PX>/init.js. In certain cases (adblockers, etc.) it may be beneficial to change this endpoint name to a different value. You can do this by configuring a custom endpoint name using this configuration.

"px_custom_first_party_sensor_endpoint": "/botdefense"

The /<app_id_without_PX>/init.js endpoint will continue to work even when a custom endpoint is configured.

You should also modify the snippet on the HTML pages served to refer to this custom endpoint.

// JS snippet code
(function(){
// Custom parameters
// window._pxParam1 = "<param1>";
var p = document.getElementsByTagName('script')[0],
s = document.createElement('script');
s.async = 1;
s.src = '/botdefense'; // custom endpoint
p.parentNode.insertBefore(s,p);
}());