Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/node
SDK Version
8.2.1
Framework Version
No response
Link to Sentry event
No response
SDK Setup
Sentry.init({
dsn: '....',
beforeBreadcrumb: beforeBreadcrumb,
enableTracing: true,
sampleRate: 1,
integrations: [Sentry.httpIntegration(), Sentry.nativeNodeFetchIntegration()],
});
export function beforeBreadcrumb(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): Breadcrumb | null {
if (breadcrumb.type !== 'http' || breadcrumb.category !== 'http' || !hint) { // <---- hint is undefined here
return breadcrumb;
}
// .....
}
Steps to Reproduce
- Make an native node fetch api call
- Throw an error so that beforeBreadcrumb is triggered
Expected Result
The beforeBreadcrumb
handler should receive the original fetch Request object as a hint parameter. This is used to extract the fetch request headers and apply this information to enrich the breadcrumb.
Actual Result
The beforeBreadcrumb
handler does not receive the original fetch Request object anymore since Sentry v8

Metadata
Metadata
Assignees
Type
Projects
Status
No status