hyperdxio / hyperdxio/hyperdx-js
Add Request Body and Header Field Masking Support for Browser SDK
Open
@wrn14897 is already working on this.
Since May 5, 2026.
- Dominant language
- TypeScript
- Stars
- 25
- Forks
- 30
- Avg merge
- 4h 26m
- Merged PRs (30d)
- 6
Description
The Browser SDK should support masking of sensitive data in both request bodies and headers before sending telemetry to HyperDX. This feature is important for privacy and compliance, ensuring that sensitive fields such as tokens, credentials, or personal data are not transmitted or stored.
Recommended Acceptance Criteria:
- Allow configuration of field names (e.g., password, authorization, token) to be masked.
- Mask matching fields in request headers.
- Mask matching fields in request bodies (including nested objects).
- Ensure masking happens before data leaves the client.
- Provide default mask pattern (e.g., ***) and allow custom mask value.
- Include documentation and usage examples in the Browser SDK README.
HyperDX.init({
apiKey: "<API_KEY>",
maskFields: {
headers: ["authorization", "x-api-key"],
body: ["password", "creditCard.number"]
},
maskPlaceholder: "***"
});
Goal:
Prevent sensitive or personally identifiable information from being logged or transmitted by the HyperDX Browser SDK.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.