[skill-drift] update(sentry-browser-sdk): document setAttribute and setAttributes APIs#223
Open
github-actions[bot] wants to merge 1 commit into
Conversation
…etAttributes APIs Automated drift-fix run. Co-Authored-By: Claude (claude-sonnet-4-5) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Warning
Auto-generated from external SDK content. Review all links and code suggestions before acting on them.
Summary
Sentry.setAttribute()andSentry.setAttributes()APIs introduced in SDK v10.61.0setAttributeandsetAttributesContext
PR #21705 added top-level
setAttribute(s)APIs for setting scope attributes, analogous tosetTag(s). These APIs write attributes to the isolation scope and simplify scope enrichment with structured key names (e.g.,user.num_orders,subscription.tier).Changes Made
File:
skills/sentry-browser-sdk/references/error-monitoring.mdAdded new "Attributes — Structured Scope Properties" section with:
Sentry.setAttribute()Sentry.setAttributes()withScope()Updated "Scope Methods" reference to include:
scope.setAttribute("key", value)scope.setAttributes({ key1: v1, key2: v2 })SDK Version
These APIs are available in
@sentry/browser>= 10.61.0 (released 2026-06-25).Co-Authored-By: Claude Sonnet 4.5 noreply@anthropic.com
Source PRs
Sentry.setAttribute(s)APIs