Skip to content

Commit facdb7e

Browse files
committed
ref(types): Add known attribute keys to SpanAttributes
1 parent 6868256 commit facdb7e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

packages/types/src/span.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,13 @@ export type SpanAttributeValue =
2323
| Array<null | undefined | number>
2424
| Array<null | undefined | boolean>;
2525

26-
export type SpanAttributes = Record<string, SpanAttributeValue | undefined>;
26+
export type SpanAttributes = Partial<{
27+
'sentry.origin': string;
28+
'sentry.op': string;
29+
'sentry.source': string;
30+
'sentry.sample_rate': number;
31+
}> &
32+
Record<string, SpanAttributeValue | undefined>;
2733

2834
/** This type is aligned with the OpenTelemetry TimeInput type. */
2935
export type SpanTimeInput = HrTime | number | Date;

0 commit comments

Comments
 (0)