@@ -5,6 +5,7 @@ import type { LegacyCSPReport } from './csp';
5
5
import type { DsnComponents } from './dsn' ;
6
6
import type { Event } from './event' ;
7
7
import type { FeedbackEvent , UserFeedback } from './feedback' ;
8
+ import type { Log } from './log' ;
8
9
import type { Profile , ProfileChunk } from './profiling' ;
9
10
import type { ReplayEvent , ReplayRecordingData } from './replay' ;
10
11
import type { SdkInfo } from './sdkinfo' ;
@@ -43,6 +44,7 @@ export type EnvelopeItemType =
43
44
| 'replay_recording'
44
45
| 'check_in'
45
46
| 'span'
47
+ | 'otel_log'
46
48
| 'raw_security' ;
47
49
48
50
export type BaseEnvelopeHeaders = {
@@ -85,6 +87,7 @@ type CheckInItemHeaders = { type: 'check_in' };
85
87
type ProfileItemHeaders = { type : 'profile' } ;
86
88
type ProfileChunkItemHeaders = { type : 'profile_chunk' } ;
87
89
type SpanItemHeaders = { type : 'span' } ;
90
+ type LogItemHeaders = { type : 'otel_log' } ;
88
91
type RawSecurityHeaders = { type : 'raw_security' ; sentry_release ?: string ; sentry_environment ?: string } ;
89
92
90
93
export type EventItem = BaseEnvelopeItem < EventItemHeaders , Event > ;
@@ -101,6 +104,7 @@ export type FeedbackItem = BaseEnvelopeItem<FeedbackItemHeaders, FeedbackEvent>;
101
104
export type ProfileItem = BaseEnvelopeItem < ProfileItemHeaders , Profile > ;
102
105
export type ProfileChunkItem = BaseEnvelopeItem < ProfileChunkItemHeaders , ProfileChunk > ;
103
106
export type SpanItem = BaseEnvelopeItem < SpanItemHeaders , Partial < SpanJSON > > ;
107
+ export type LogItem = BaseEnvelopeItem < LogItemHeaders , Log > ;
104
108
export type RawSecurityItem = BaseEnvelopeItem < RawSecurityHeaders , LegacyCSPReport > ;
105
109
106
110
export type EventEnvelopeHeaders = { event_id : string ; sent_at : string ; trace ?: Partial < DynamicSamplingContext > } ;
@@ -109,6 +113,7 @@ type CheckInEnvelopeHeaders = { trace?: DynamicSamplingContext };
109
113
type ClientReportEnvelopeHeaders = BaseEnvelopeHeaders ;
110
114
type ReplayEnvelopeHeaders = BaseEnvelopeHeaders ;
111
115
type SpanEnvelopeHeaders = BaseEnvelopeHeaders & { trace ?: DynamicSamplingContext } ;
116
+ type LogEnvelopeHeaders = BaseEnvelopeHeaders & { trace ?: DynamicSamplingContext } ;
112
117
113
118
export type EventEnvelope = BaseEnvelope <
114
119
EventEnvelopeHeaders ,
@@ -121,6 +126,7 @@ export type CheckInEnvelope = BaseEnvelope<CheckInEnvelopeHeaders, CheckInItem>;
121
126
export type SpanEnvelope = BaseEnvelope < SpanEnvelopeHeaders , SpanItem > ;
122
127
export type ProfileChunkEnvelope = BaseEnvelope < BaseEnvelopeHeaders , ProfileChunkItem > ;
123
128
export type RawSecurityEnvelope = BaseEnvelope < BaseEnvelopeHeaders , RawSecurityItem > ;
129
+ export type LogEnvelope = BaseEnvelope < LogEnvelopeHeaders , LogItem > ;
124
130
125
131
export type Envelope =
126
132
| EventEnvelope
@@ -130,6 +136,7 @@ export type Envelope =
130
136
| ReplayEnvelope
131
137
| CheckInEnvelope
132
138
| SpanEnvelope
133
- | RawSecurityEnvelope ;
139
+ | RawSecurityEnvelope
140
+ | LogEnvelope ;
134
141
135
142
export type EnvelopeItem = Envelope [ 1 ] [ number ] ;
0 commit comments