The SDK collects what performance and error monitoring need, and nothing that identifies a person unless you add it. Every field is listed in the data reference.
What’s collected
| Category | What |
|---|---|
| Performance | Page-load phases, route changes, interactions, request timings, Web Vitals and long-task counts |
| URLs | The path and the query string, with sensitive parameters redacted. Fragments (#…) and user info are dropped |
| Browser | The browser, its version, the operating system, the device type (desktop, mobile or tablet) and the User-Agent string |
| Location | The approximate location: country, region and city |
| Session | A random session ID |
| Errors | The error’s type, message and stack trace |
| Breadcrumbs | The last 50 events before an error: views, action names, requests (method, redacted URL, status, duration), and console errors and warnings truncated to 256 characters |
| User | A user ID, only if you call setUser({ id }) |
What isn’t
- IP addresses. EZGH looks up the location when data arrives, then discards the address. It’s never stored.
- Cookies. The SDK sets none. The session lives in
localStorage, under the keyezgh_rum_s. - Form values and page text. Action names come only from a
data-ezgh-actionattribute oraria-label, else the element’s tag and ID: never its text. - Email addresses or names. There’s no field for them.
setUsertakes only an ID; use an opaque one.
URLs
The values of these query parameters are replaced with REDACTED in the browser, before
anything is sent: token, access_token, id_token, code, state, password, passwd,
secret, key, api_key, apikey, session, sessionid, auth, signature and sig.
redactQueryParams adds names to the list:
init({ token: "ezgh_ct_…", release, redactQueryParams: ["invite", "reset_token"] });To remove path segments, such as an account number in /accounts/123456, use
beforeSend.
Consent
To wait for your users’ consent:
import { init, consent } from "@ezghcloud/rum";
init({ token: "ezgh_ct_…", release, trackingConsent: "pending" });
// later, when the user accepts:
consent.grant();
// and if they withdraw it:
consent.revoke(); // stops sending and clears the sessionWith "pending", nothing is collected, stored or sent until consent.grant(). Call init with
trackingConsent: "granted" (the default) on later visits when you already have consent.
Redact more at ingest
Transform rules apply to browser data as to any other, before it’s
stored. For example, to drop user.id from an environment’s browser logs and spans:
delete_key(log.attributes, "user.id")delete_key(span.attributes, "user.id")Sampling
sessionSampleRate records a percentage of sessions, decided once per session: with 25, a
quarter of your users’ sessions are recorded, completely, and the rest send nothing.