Skip to content

Conversation

@abdussamadbello
Copy link
Contributor

This pull request adds support for setting OpenTelemetry resource attributes in the browser SDK, allowing users to specify custom key/value pairs (such as service version or deployment environment) that are attached as global attributes. The changes include updates to the SDK configuration, documentation, and initialization logic.

OpenTelemetry resource attributes support:

  • Added an optional otelResourceAttributes array to the BrowserSDKConfig type in index.ts, allowing users to specify key/value pairs for OpenTelemetry resource attributes.
  • Updated the Browser class constructor to accept and process the otelResourceAttributes option, converting the array to an object and setting them as global attributes during initialization. [1] [2]

Documentation updates:

  • Updated the usage example in README.md to demonstrate how to use the new otelResourceAttributes option in HyperDX.init.
  • Added documentation for the otelResourceAttributes option, including a code example, to the configuration options list in README.md.

@changeset-bot
Copy link

changeset-bot bot commented Oct 9, 2025

🦋 Changeset detected

Latest commit: 393892f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@hyperdx/browser Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Member

@wrn14897 wrn14897 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution!

@wrn14897 wrn14897 merged commit d726266 into hyperdxio:main Oct 19, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants