Privacy
Additional optional settings to restrict the data that is sent to the devunus servers
Redact URLs or ignore requests
optional
urlSanitizer : (url: string) => string
Function to update the URL stored against the request or pass null to ignore the request completely
import { devunusClient } from "@devunus/js-client-sdk";
const context: Options = {
...
urlSanitizer: (url: string) => {
if (url.includes('/cdn-cgi/rum')) {
return null; // do not log any requests to this URL
}
if (url.includes('/users/')) {
return url.replace(/\/users\/\d+/, '/users/:id'); // strip user_ids
}
return url;
},
};
devunusClient.init(env_key, context);
IP Address
IP addresses for your users are not captured by default.
optional (default false)
enable_ip_capture : bool
import { devunusClient } from "@devunus/js-client-sdk";
const context: Options = {
...
enable_ip_capture: true, // IP addresses for your users will be captured
};
devunusClient.init(env_key, context);