1use serde::{Deserialize, Serialize};
2#[doc = "Fired when data chunk was received over the network.\n[dataReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-dataReceived)"]
3#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
4pub struct DataReceivedParams {
5 #[doc = "Request identifier."]
6 #[serde(rename = "requestId")]
7 pub request_id: super::types::RequestId,
8 #[doc = "Timestamp."]
9 #[serde(rename = "timestamp")]
10 pub timestamp: super::types::MonotonicTime,
11 #[doc = "Data chunk length."]
12 #[serde(rename = "dataLength")]
13 pub data_length: i64,
14 #[doc = "Actual bytes received (might be less than dataLength for compressed encodings)."]
15 #[serde(rename = "encodedDataLength")]
16 pub encoded_data_length: i64,
17 #[doc = "Data that was received."]
18 #[serde(rename = "data")]
19 #[serde(skip_serializing_if = "Option::is_none")]
20 #[serde(default)]
21 pub data: Option<crate::Binary>,
22}
23#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
24pub enum DataReceivedMethod {
25 #[serde(rename = "Network.dataReceived")]
26 DataReceived,
27}
28#[doc = "Fired when data chunk was received over the network.\n[dataReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-dataReceived)"]
29#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
30pub struct DataReceived {
31 pub method: DataReceivedMethod,
32 pub params: DataReceivedParams,
33}
34impl DataReceived {
35 pub const IDENTIFIER: &'static str = "Network.dataReceived";
36 pub fn identifier(&self) -> &'static str {
37 Self::IDENTIFIER
38 }
39}
40#[doc = "Fired when EventSource message is received.\n[eventSourceMessageReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-eventSourceMessageReceived)"]
41#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
42pub struct EventSourceMessageReceivedParams {
43 #[doc = "Request identifier."]
44 #[serde(rename = "requestId")]
45 pub request_id: super::types::RequestId,
46 #[doc = "Timestamp."]
47 #[serde(rename = "timestamp")]
48 pub timestamp: super::types::MonotonicTime,
49 #[doc = "Message type."]
50 #[serde(rename = "eventName")]
51 pub event_name: String,
52 #[doc = "Message identifier."]
53 #[serde(rename = "eventId")]
54 pub event_id: String,
55 #[doc = "Message content."]
56 #[serde(rename = "data")]
57 pub data: String,
58}
59#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
60pub enum EventSourceMessageReceivedMethod {
61 #[serde(rename = "Network.eventSourceMessageReceived")]
62 EventSourceMessageReceived,
63}
64#[doc = "Fired when EventSource message is received.\n[eventSourceMessageReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-eventSourceMessageReceived)"]
65#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
66pub struct EventSourceMessageReceived {
67 pub method: EventSourceMessageReceivedMethod,
68 pub params: EventSourceMessageReceivedParams,
69}
70impl EventSourceMessageReceived {
71 pub const IDENTIFIER: &'static str = "Network.eventSourceMessageReceived";
72 pub fn identifier(&self) -> &'static str {
73 Self::IDENTIFIER
74 }
75}
76#[doc = "Fired when HTTP request has failed to load.\n[loadingFailed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-loadingFailed)"]
77#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
78pub struct LoadingFailedParams {
79 #[doc = "Request identifier."]
80 #[serde(rename = "requestId")]
81 pub request_id: super::types::RequestId,
82 #[doc = "Timestamp."]
83 #[serde(rename = "timestamp")]
84 pub timestamp: super::types::MonotonicTime,
85 #[doc = "Resource type."]
86 #[serde(rename = "type")]
87 pub r#type: super::types::ResourceType,
88 #[doc = "Error message. List of network errors: https://cs.chromium.org/chromium/src/net/base/net_error_list.h"]
89 #[serde(rename = "errorText")]
90 pub error_text: String,
91 #[doc = "True if loading was canceled."]
92 #[serde(rename = "canceled")]
93 #[serde(skip_serializing_if = "Option::is_none")]
94 #[serde(default)]
95 pub canceled: Option<bool>,
96 #[doc = "The reason why loading was blocked, if any."]
97 #[serde(rename = "blockedReason")]
98 #[serde(skip_serializing_if = "Option::is_none")]
99 #[serde(default)]
100 pub blocked_reason: Option<super::types::BlockedReason>,
101 #[doc = "The reason why loading was blocked by CORS, if any."]
102 #[serde(rename = "corsErrorStatus")]
103 #[serde(skip_serializing_if = "Option::is_none")]
104 #[serde(default)]
105 pub cors_error_status: Option<super::types::CorsErrorStatus>,
106}
107#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
108pub enum LoadingFailedMethod {
109 #[serde(rename = "Network.loadingFailed")]
110 LoadingFailed,
111}
112#[doc = "Fired when HTTP request has failed to load.\n[loadingFailed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-loadingFailed)"]
113#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
114pub struct LoadingFailed {
115 pub method: LoadingFailedMethod,
116 pub params: LoadingFailedParams,
117}
118impl LoadingFailed {
119 pub const IDENTIFIER: &'static str = "Network.loadingFailed";
120 pub fn identifier(&self) -> &'static str {
121 Self::IDENTIFIER
122 }
123}
124#[doc = "Fired when HTTP request has finished loading.\n[loadingFinished](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-loadingFinished)"]
125#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
126pub struct LoadingFinishedParams {
127 #[doc = "Request identifier."]
128 #[serde(rename = "requestId")]
129 pub request_id: super::types::RequestId,
130 #[doc = "Timestamp."]
131 #[serde(rename = "timestamp")]
132 pub timestamp: super::types::MonotonicTime,
133 #[doc = "Total number of bytes received for this request."]
134 #[serde(rename = "encodedDataLength")]
135 pub encoded_data_length: f64,
136}
137#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
138pub enum LoadingFinishedMethod {
139 #[serde(rename = "Network.loadingFinished")]
140 LoadingFinished,
141}
142#[doc = "Fired when HTTP request has finished loading.\n[loadingFinished](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-loadingFinished)"]
143#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
144pub struct LoadingFinished {
145 pub method: LoadingFinishedMethod,
146 pub params: LoadingFinishedParams,
147}
148impl LoadingFinished {
149 pub const IDENTIFIER: &'static str = "Network.loadingFinished";
150 pub fn identifier(&self) -> &'static str {
151 Self::IDENTIFIER
152 }
153}
154#[doc = "Fired if request ended up loading from cache.\n[requestServedFromCache](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestServedFromCache)"]
155#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
156pub struct RequestServedFromCacheParams {
157 #[doc = "Request identifier."]
158 #[serde(rename = "requestId")]
159 pub request_id: super::types::RequestId,
160}
161#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
162pub enum RequestServedFromCacheMethod {
163 #[serde(rename = "Network.requestServedFromCache")]
164 RequestServedFromCache,
165}
166#[doc = "Fired if request ended up loading from cache.\n[requestServedFromCache](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestServedFromCache)"]
167#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
168pub struct RequestServedFromCache {
169 pub method: RequestServedFromCacheMethod,
170 pub params: RequestServedFromCacheParams,
171}
172impl RequestServedFromCache {
173 pub const IDENTIFIER: &'static str = "Network.requestServedFromCache";
174 pub fn identifier(&self) -> &'static str {
175 Self::IDENTIFIER
176 }
177}
178#[doc = "Fired when page is about to send HTTP request.\n[requestWillBeSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestWillBeSent)"]
179#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
180pub struct RequestWillBeSentParams {
181 #[doc = "Request identifier."]
182 #[serde(rename = "requestId")]
183 pub request_id: super::types::RequestId,
184 #[doc = "Loader identifier. Empty string if the request is fetched from worker."]
185 #[serde(rename = "loaderId")]
186 pub loader_id: Box<super::types::LoaderId>,
187 #[doc = "URL of the document this request is loaded for."]
188 #[serde(rename = "documentURL")]
189 pub document_url: String,
190 #[doc = "Request data."]
191 #[serde(rename = "request")]
192 pub request: super::types::Request,
193 #[doc = "Timestamp."]
194 #[serde(rename = "timestamp")]
195 pub timestamp: super::types::MonotonicTime,
196 #[doc = "Timestamp."]
197 #[serde(rename = "wallTime")]
198 pub wall_time: super::types::TimeSinceEpoch,
199 #[doc = "Request initiator."]
200 #[serde(rename = "initiator")]
201 pub initiator: super::types::Initiator,
202 #[doc = "In the case that redirectResponse is populated, this flag indicates whether\nrequestWillBeSentExtraInfo and responseReceivedExtraInfo events will be or were emitted\nfor the request which was just redirected."]
203 #[serde(rename = "redirectHasExtraInfo")]
204 pub redirect_has_extra_info: bool,
205 #[doc = "Redirect response data."]
206 #[serde(rename = "redirectResponse")]
207 #[serde(skip_serializing_if = "Option::is_none")]
208 #[serde(default)]
209 pub redirect_response: Option<super::types::Response>,
210 #[doc = "Type of this resource."]
211 #[serde(rename = "type")]
212 #[serde(skip_serializing_if = "Option::is_none")]
213 #[serde(default)]
214 pub r#type: Option<super::types::ResourceType>,
215 #[doc = "Frame identifier."]
216 #[serde(rename = "frameId")]
217 #[serde(skip_serializing_if = "Option::is_none")]
218 #[serde(default)]
219 pub frame_id: Option<crate::browser_protocol::page::types::FrameId>,
220 #[doc = "Whether the request is initiated by a user gesture. Defaults to false."]
221 #[serde(rename = "hasUserGesture")]
222 #[serde(skip_serializing_if = "Option::is_none")]
223 #[serde(default)]
224 pub has_user_gesture: Option<bool>,
225 #[doc = "The render blocking behavior of the request."]
226 #[serde(rename = "renderBlockingBehavior")]
227 #[serde(skip_serializing_if = "Option::is_none")]
228 #[serde(default)]
229 pub render_blocking_behavior: Option<super::types::RenderBlockingBehavior>,
230}
231#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
232pub enum RequestWillBeSentMethod {
233 #[serde(rename = "Network.requestWillBeSent")]
234 RequestWillBeSent,
235}
236#[doc = "Fired when page is about to send HTTP request.\n[requestWillBeSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestWillBeSent)"]
237#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
238pub struct RequestWillBeSent {
239 pub method: RequestWillBeSentMethod,
240 pub params: RequestWillBeSentParams,
241}
242impl RequestWillBeSent {
243 pub const IDENTIFIER: &'static str = "Network.requestWillBeSent";
244 pub fn identifier(&self) -> &'static str {
245 Self::IDENTIFIER
246 }
247}
248#[doc = "Fired when resource loading priority is changed\n[resourceChangedPriority](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-resourceChangedPriority)"]
249#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
250pub struct ResourceChangedPriorityParams {
251 #[doc = "Request identifier."]
252 #[serde(rename = "requestId")]
253 pub request_id: super::types::RequestId,
254 #[doc = "New priority"]
255 #[serde(rename = "newPriority")]
256 pub new_priority: super::types::ResourcePriority,
257 #[doc = "Timestamp."]
258 #[serde(rename = "timestamp")]
259 pub timestamp: super::types::MonotonicTime,
260}
261#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
262pub enum ResourceChangedPriorityMethod {
263 #[serde(rename = "Network.resourceChangedPriority")]
264 ResourceChangedPriority,
265}
266#[doc = "Fired when resource loading priority is changed\n[resourceChangedPriority](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-resourceChangedPriority)"]
267#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
268pub struct ResourceChangedPriority {
269 pub method: ResourceChangedPriorityMethod,
270 pub params: ResourceChangedPriorityParams,
271}
272impl ResourceChangedPriority {
273 pub const IDENTIFIER: &'static str = "Network.resourceChangedPriority";
274 pub fn identifier(&self) -> &'static str {
275 Self::IDENTIFIER
276 }
277}
278#[doc = "Fired when a signed exchange was received over the network\n[signedExchangeReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-signedExchangeReceived)"]
279#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
280pub struct SignedExchangeReceivedParams {
281 #[doc = "Request identifier."]
282 #[serde(rename = "requestId")]
283 pub request_id: super::types::RequestId,
284 #[doc = "Information about the signed exchange response."]
285 #[serde(rename = "info")]
286 pub info: super::types::SignedExchangeInfo,
287}
288#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
289pub enum SignedExchangeReceivedMethod {
290 #[serde(rename = "Network.signedExchangeReceived")]
291 SignedExchangeReceived,
292}
293#[doc = "Fired when a signed exchange was received over the network\n[signedExchangeReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-signedExchangeReceived)"]
294#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
295pub struct SignedExchangeReceived {
296 pub method: SignedExchangeReceivedMethod,
297 pub params: SignedExchangeReceivedParams,
298}
299impl SignedExchangeReceived {
300 pub const IDENTIFIER: &'static str = "Network.signedExchangeReceived";
301 pub fn identifier(&self) -> &'static str {
302 Self::IDENTIFIER
303 }
304}
305#[doc = "Fired when HTTP response is available.\n[responseReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceived)"]
306#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
307pub struct ResponseReceivedParams {
308 #[doc = "Request identifier."]
309 #[serde(rename = "requestId")]
310 pub request_id: super::types::RequestId,
311 #[doc = "Loader identifier. Empty string if the request is fetched from worker."]
312 #[serde(rename = "loaderId")]
313 pub loader_id: Box<super::types::LoaderId>,
314 #[doc = "Timestamp."]
315 #[serde(rename = "timestamp")]
316 pub timestamp: super::types::MonotonicTime,
317 #[doc = "Resource type."]
318 #[serde(rename = "type")]
319 pub r#type: super::types::ResourceType,
320 #[doc = "Response data."]
321 #[serde(rename = "response")]
322 pub response: super::types::Response,
323 #[doc = "Indicates whether requestWillBeSentExtraInfo and responseReceivedExtraInfo events will be\nor were emitted for this request."]
324 #[serde(rename = "hasExtraInfo")]
325 pub has_extra_info: bool,
326 #[doc = "Frame identifier."]
327 #[serde(rename = "frameId")]
328 #[serde(skip_serializing_if = "Option::is_none")]
329 #[serde(default)]
330 pub frame_id: Option<crate::browser_protocol::page::types::FrameId>,
331}
332#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
333pub enum ResponseReceivedMethod {
334 #[serde(rename = "Network.responseReceived")]
335 ResponseReceived,
336}
337#[doc = "Fired when HTTP response is available.\n[responseReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceived)"]
338#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
339pub struct ResponseReceived {
340 pub method: ResponseReceivedMethod,
341 pub params: ResponseReceivedParams,
342}
343impl ResponseReceived {
344 pub const IDENTIFIER: &'static str = "Network.responseReceived";
345 pub fn identifier(&self) -> &'static str {
346 Self::IDENTIFIER
347 }
348}
349#[doc = "Fired when WebSocket is closed.\n[webSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketClosed)"]
350#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
351pub struct WebSocketClosedParams {
352 #[doc = "Request identifier."]
353 #[serde(rename = "requestId")]
354 pub request_id: super::types::RequestId,
355 #[doc = "Timestamp."]
356 #[serde(rename = "timestamp")]
357 pub timestamp: super::types::MonotonicTime,
358}
359#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
360pub enum WebSocketClosedMethod {
361 #[serde(rename = "Network.webSocketClosed")]
362 WebSocketClosed,
363}
364#[doc = "Fired when WebSocket is closed.\n[webSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketClosed)"]
365#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
366pub struct WebSocketClosed {
367 pub method: WebSocketClosedMethod,
368 pub params: WebSocketClosedParams,
369}
370impl WebSocketClosed {
371 pub const IDENTIFIER: &'static str = "Network.webSocketClosed";
372 pub fn identifier(&self) -> &'static str {
373 Self::IDENTIFIER
374 }
375}
376#[doc = "Fired upon WebSocket creation.\n[webSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketCreated)"]
377#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
378pub struct WebSocketCreatedParams {
379 #[doc = "Request identifier."]
380 #[serde(rename = "requestId")]
381 pub request_id: super::types::RequestId,
382 #[doc = "WebSocket request URL."]
383 #[serde(rename = "url")]
384 pub url: String,
385 #[doc = "Request initiator."]
386 #[serde(rename = "initiator")]
387 #[serde(skip_serializing_if = "Option::is_none")]
388 #[serde(default)]
389 pub initiator: Option<super::types::Initiator>,
390}
391#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
392pub enum WebSocketCreatedMethod {
393 #[serde(rename = "Network.webSocketCreated")]
394 WebSocketCreated,
395}
396#[doc = "Fired upon WebSocket creation.\n[webSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketCreated)"]
397#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
398pub struct WebSocketCreated {
399 pub method: WebSocketCreatedMethod,
400 pub params: WebSocketCreatedParams,
401}
402impl WebSocketCreated {
403 pub const IDENTIFIER: &'static str = "Network.webSocketCreated";
404 pub fn identifier(&self) -> &'static str {
405 Self::IDENTIFIER
406 }
407}
408#[doc = "Fired when WebSocket message error occurs.\n[webSocketFrameError](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameError)"]
409#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
410pub struct WebSocketFrameErrorParams {
411 #[doc = "Request identifier."]
412 #[serde(rename = "requestId")]
413 pub request_id: super::types::RequestId,
414 #[doc = "Timestamp."]
415 #[serde(rename = "timestamp")]
416 pub timestamp: super::types::MonotonicTime,
417 #[doc = "WebSocket error message."]
418 #[serde(rename = "errorMessage")]
419 pub error_message: String,
420}
421#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
422pub enum WebSocketFrameErrorMethod {
423 #[serde(rename = "Network.webSocketFrameError")]
424 WebSocketFrameError,
425}
426#[doc = "Fired when WebSocket message error occurs.\n[webSocketFrameError](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameError)"]
427#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
428pub struct WebSocketFrameError {
429 pub method: WebSocketFrameErrorMethod,
430 pub params: WebSocketFrameErrorParams,
431}
432impl WebSocketFrameError {
433 pub const IDENTIFIER: &'static str = "Network.webSocketFrameError";
434 pub fn identifier(&self) -> &'static str {
435 Self::IDENTIFIER
436 }
437}
438#[doc = "Fired when WebSocket message is received.\n[webSocketFrameReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameReceived)"]
439#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
440pub struct WebSocketFrameReceivedParams {
441 #[doc = "Request identifier."]
442 #[serde(rename = "requestId")]
443 pub request_id: super::types::RequestId,
444 #[doc = "Timestamp."]
445 #[serde(rename = "timestamp")]
446 pub timestamp: super::types::MonotonicTime,
447 #[doc = "WebSocket response data."]
448 #[serde(rename = "response")]
449 pub response: super::types::WebSocketFrame,
450}
451#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
452pub enum WebSocketFrameReceivedMethod {
453 #[serde(rename = "Network.webSocketFrameReceived")]
454 WebSocketFrameReceived,
455}
456#[doc = "Fired when WebSocket message is received.\n[webSocketFrameReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameReceived)"]
457#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
458pub struct WebSocketFrameReceived {
459 pub method: WebSocketFrameReceivedMethod,
460 pub params: WebSocketFrameReceivedParams,
461}
462impl WebSocketFrameReceived {
463 pub const IDENTIFIER: &'static str = "Network.webSocketFrameReceived";
464 pub fn identifier(&self) -> &'static str {
465 Self::IDENTIFIER
466 }
467}
468#[doc = "Fired when WebSocket message is sent.\n[webSocketFrameSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameSent)"]
469#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
470pub struct WebSocketFrameSentParams {
471 #[doc = "Request identifier."]
472 #[serde(rename = "requestId")]
473 pub request_id: super::types::RequestId,
474 #[doc = "Timestamp."]
475 #[serde(rename = "timestamp")]
476 pub timestamp: super::types::MonotonicTime,
477 #[doc = "WebSocket response data."]
478 #[serde(rename = "response")]
479 pub response: super::types::WebSocketFrame,
480}
481#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
482pub enum WebSocketFrameSentMethod {
483 #[serde(rename = "Network.webSocketFrameSent")]
484 WebSocketFrameSent,
485}
486#[doc = "Fired when WebSocket message is sent.\n[webSocketFrameSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketFrameSent)"]
487#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
488pub struct WebSocketFrameSent {
489 pub method: WebSocketFrameSentMethod,
490 pub params: WebSocketFrameSentParams,
491}
492impl WebSocketFrameSent {
493 pub const IDENTIFIER: &'static str = "Network.webSocketFrameSent";
494 pub fn identifier(&self) -> &'static str {
495 Self::IDENTIFIER
496 }
497}
498#[doc = "Fired when WebSocket handshake response becomes available.\n[webSocketHandshakeResponseReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketHandshakeResponseReceived)"]
499#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
500pub struct WebSocketHandshakeResponseReceivedParams {
501 #[doc = "Request identifier."]
502 #[serde(rename = "requestId")]
503 pub request_id: super::types::RequestId,
504 #[doc = "Timestamp."]
505 #[serde(rename = "timestamp")]
506 pub timestamp: super::types::MonotonicTime,
507 #[doc = "WebSocket response data."]
508 #[serde(rename = "response")]
509 pub response: super::types::WebSocketResponse,
510}
511#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
512pub enum WebSocketHandshakeResponseReceivedMethod {
513 #[serde(rename = "Network.webSocketHandshakeResponseReceived")]
514 WebSocketHandshakeResponseReceived,
515}
516#[doc = "Fired when WebSocket handshake response becomes available.\n[webSocketHandshakeResponseReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketHandshakeResponseReceived)"]
517#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
518pub struct WebSocketHandshakeResponseReceived {
519 pub method: WebSocketHandshakeResponseReceivedMethod,
520 pub params: WebSocketHandshakeResponseReceivedParams,
521}
522impl WebSocketHandshakeResponseReceived {
523 pub const IDENTIFIER: &'static str = "Network.webSocketHandshakeResponseReceived";
524 pub fn identifier(&self) -> &'static str {
525 Self::IDENTIFIER
526 }
527}
528#[doc = "Fired when WebSocket is about to initiate handshake.\n[webSocketWillSendHandshakeRequest](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketWillSendHandshakeRequest)"]
529#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
530pub struct WebSocketWillSendHandshakeRequestParams {
531 #[doc = "Request identifier."]
532 #[serde(rename = "requestId")]
533 pub request_id: super::types::RequestId,
534 #[doc = "Timestamp."]
535 #[serde(rename = "timestamp")]
536 pub timestamp: super::types::MonotonicTime,
537 #[doc = "UTC Timestamp."]
538 #[serde(rename = "wallTime")]
539 pub wall_time: super::types::TimeSinceEpoch,
540 #[doc = "WebSocket request data."]
541 #[serde(rename = "request")]
542 pub request: super::types::WebSocketRequest,
543}
544#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
545pub enum WebSocketWillSendHandshakeRequestMethod {
546 #[serde(rename = "Network.webSocketWillSendHandshakeRequest")]
547 WebSocketWillSendHandshakeRequest,
548}
549#[doc = "Fired when WebSocket is about to initiate handshake.\n[webSocketWillSendHandshakeRequest](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webSocketWillSendHandshakeRequest)"]
550#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
551pub struct WebSocketWillSendHandshakeRequest {
552 pub method: WebSocketWillSendHandshakeRequestMethod,
553 pub params: WebSocketWillSendHandshakeRequestParams,
554}
555impl WebSocketWillSendHandshakeRequest {
556 pub const IDENTIFIER: &'static str = "Network.webSocketWillSendHandshakeRequest";
557 pub fn identifier(&self) -> &'static str {
558 Self::IDENTIFIER
559 }
560}
561#[doc = "Fired upon WebTransport creation.\n[webTransportCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportCreated)"]
562#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
563pub struct WebTransportCreatedParams {
564 #[doc = "WebTransport identifier."]
565 #[serde(rename = "transportId")]
566 pub transport_id: super::types::RequestId,
567 #[doc = "WebTransport request URL."]
568 #[serde(rename = "url")]
569 pub url: String,
570 #[doc = "Timestamp."]
571 #[serde(rename = "timestamp")]
572 pub timestamp: super::types::MonotonicTime,
573 #[doc = "Request initiator."]
574 #[serde(rename = "initiator")]
575 #[serde(skip_serializing_if = "Option::is_none")]
576 #[serde(default)]
577 pub initiator: Option<super::types::Initiator>,
578}
579#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
580pub enum WebTransportCreatedMethod {
581 #[serde(rename = "Network.webTransportCreated")]
582 WebTransportCreated,
583}
584#[doc = "Fired upon WebTransport creation.\n[webTransportCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportCreated)"]
585#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
586pub struct WebTransportCreated {
587 pub method: WebTransportCreatedMethod,
588 pub params: WebTransportCreatedParams,
589}
590impl WebTransportCreated {
591 pub const IDENTIFIER: &'static str = "Network.webTransportCreated";
592 pub fn identifier(&self) -> &'static str {
593 Self::IDENTIFIER
594 }
595}
596#[doc = "Fired when WebTransport handshake is finished.\n[webTransportConnectionEstablished](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportConnectionEstablished)"]
597#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
598pub struct WebTransportConnectionEstablishedParams {
599 #[doc = "WebTransport identifier."]
600 #[serde(rename = "transportId")]
601 pub transport_id: super::types::RequestId,
602 #[doc = "Timestamp."]
603 #[serde(rename = "timestamp")]
604 pub timestamp: super::types::MonotonicTime,
605}
606#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
607pub enum WebTransportConnectionEstablishedMethod {
608 #[serde(rename = "Network.webTransportConnectionEstablished")]
609 WebTransportConnectionEstablished,
610}
611#[doc = "Fired when WebTransport handshake is finished.\n[webTransportConnectionEstablished](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportConnectionEstablished)"]
612#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
613pub struct WebTransportConnectionEstablished {
614 pub method: WebTransportConnectionEstablishedMethod,
615 pub params: WebTransportConnectionEstablishedParams,
616}
617impl WebTransportConnectionEstablished {
618 pub const IDENTIFIER: &'static str = "Network.webTransportConnectionEstablished";
619 pub fn identifier(&self) -> &'static str {
620 Self::IDENTIFIER
621 }
622}
623#[doc = "Fired when WebTransport is disposed.\n[webTransportClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportClosed)"]
624#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
625pub struct WebTransportClosedParams {
626 #[doc = "WebTransport identifier."]
627 #[serde(rename = "transportId")]
628 pub transport_id: super::types::RequestId,
629 #[doc = "Timestamp."]
630 #[serde(rename = "timestamp")]
631 pub timestamp: super::types::MonotonicTime,
632}
633#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
634pub enum WebTransportClosedMethod {
635 #[serde(rename = "Network.webTransportClosed")]
636 WebTransportClosed,
637}
638#[doc = "Fired when WebTransport is disposed.\n[webTransportClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-webTransportClosed)"]
639#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
640pub struct WebTransportClosed {
641 pub method: WebTransportClosedMethod,
642 pub params: WebTransportClosedParams,
643}
644impl WebTransportClosed {
645 pub const IDENTIFIER: &'static str = "Network.webTransportClosed";
646 pub fn identifier(&self) -> &'static str {
647 Self::IDENTIFIER
648 }
649}
650#[doc = "Fired upon direct_socket.TCPSocket creation.\n[directTCPSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketCreated)"]
651#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
652pub struct DirectTcpSocketCreatedParams {
653 #[serde(rename = "identifier")]
654 pub identifier: super::types::RequestId,
655 #[serde(rename = "remoteAddr")]
656 pub remote_addr: String,
657 #[doc = "Unsigned int 16."]
658 #[serde(rename = "remotePort")]
659 pub remote_port: i64,
660 #[serde(rename = "options")]
661 pub options: super::types::DirectTcpSocketOptions,
662 #[serde(rename = "timestamp")]
663 pub timestamp: super::types::MonotonicTime,
664 #[serde(rename = "initiator")]
665 #[serde(skip_serializing_if = "Option::is_none")]
666 #[serde(default)]
667 pub initiator: Option<super::types::Initiator>,
668}
669#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
670pub enum DirectTcpSocketCreatedMethod {
671 #[serde(rename = "Network.directTCPSocketCreated")]
672 DirectTcpSocketCreated,
673}
674#[doc = "Fired upon direct_socket.TCPSocket creation.\n[directTCPSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketCreated)"]
675#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
676pub struct DirectTcpSocketCreated {
677 pub method: DirectTcpSocketCreatedMethod,
678 pub params: DirectTcpSocketCreatedParams,
679}
680impl DirectTcpSocketCreated {
681 pub const IDENTIFIER: &'static str = "Network.directTCPSocketCreated";
682 pub fn identifier(&self) -> &'static str {
683 Self::IDENTIFIER
684 }
685}
686#[doc = "Fired when direct_socket.TCPSocket connection is opened.\n[directTCPSocketOpened](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketOpened)"]
687#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
688pub struct DirectTcpSocketOpenedParams {
689 #[serde(rename = "identifier")]
690 pub identifier: super::types::RequestId,
691 #[serde(rename = "remoteAddr")]
692 pub remote_addr: String,
693 #[doc = "Expected to be unsigned integer."]
694 #[serde(rename = "remotePort")]
695 pub remote_port: i64,
696 #[serde(rename = "timestamp")]
697 pub timestamp: super::types::MonotonicTime,
698 #[serde(rename = "localAddr")]
699 #[serde(skip_serializing_if = "Option::is_none")]
700 #[serde(default)]
701 pub local_addr: Option<String>,
702 #[doc = "Expected to be unsigned integer."]
703 #[serde(rename = "localPort")]
704 #[serde(skip_serializing_if = "Option::is_none")]
705 #[serde(default)]
706 pub local_port: Option<i64>,
707}
708#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
709pub enum DirectTcpSocketOpenedMethod {
710 #[serde(rename = "Network.directTCPSocketOpened")]
711 DirectTcpSocketOpened,
712}
713#[doc = "Fired when direct_socket.TCPSocket connection is opened.\n[directTCPSocketOpened](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketOpened)"]
714#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
715pub struct DirectTcpSocketOpened {
716 pub method: DirectTcpSocketOpenedMethod,
717 pub params: DirectTcpSocketOpenedParams,
718}
719impl DirectTcpSocketOpened {
720 pub const IDENTIFIER: &'static str = "Network.directTCPSocketOpened";
721 pub fn identifier(&self) -> &'static str {
722 Self::IDENTIFIER
723 }
724}
725#[doc = "Fired when direct_socket.TCPSocket is aborted.\n[directTCPSocketAborted](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketAborted)"]
726#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
727pub struct DirectTcpSocketAbortedParams {
728 #[serde(rename = "identifier")]
729 pub identifier: super::types::RequestId,
730 #[serde(rename = "errorMessage")]
731 pub error_message: String,
732 #[serde(rename = "timestamp")]
733 pub timestamp: super::types::MonotonicTime,
734}
735#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
736pub enum DirectTcpSocketAbortedMethod {
737 #[serde(rename = "Network.directTCPSocketAborted")]
738 DirectTcpSocketAborted,
739}
740#[doc = "Fired when direct_socket.TCPSocket is aborted.\n[directTCPSocketAborted](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketAborted)"]
741#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
742pub struct DirectTcpSocketAborted {
743 pub method: DirectTcpSocketAbortedMethod,
744 pub params: DirectTcpSocketAbortedParams,
745}
746impl DirectTcpSocketAborted {
747 pub const IDENTIFIER: &'static str = "Network.directTCPSocketAborted";
748 pub fn identifier(&self) -> &'static str {
749 Self::IDENTIFIER
750 }
751}
752#[doc = "Fired when direct_socket.TCPSocket is closed.\n[directTCPSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketClosed)"]
753#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
754pub struct DirectTcpSocketClosedParams {
755 #[serde(rename = "identifier")]
756 pub identifier: super::types::RequestId,
757 #[serde(rename = "timestamp")]
758 pub timestamp: super::types::MonotonicTime,
759}
760#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
761pub enum DirectTcpSocketClosedMethod {
762 #[serde(rename = "Network.directTCPSocketClosed")]
763 DirectTcpSocketClosed,
764}
765#[doc = "Fired when direct_socket.TCPSocket is closed.\n[directTCPSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketClosed)"]
766#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
767pub struct DirectTcpSocketClosed {
768 pub method: DirectTcpSocketClosedMethod,
769 pub params: DirectTcpSocketClosedParams,
770}
771impl DirectTcpSocketClosed {
772 pub const IDENTIFIER: &'static str = "Network.directTCPSocketClosed";
773 pub fn identifier(&self) -> &'static str {
774 Self::IDENTIFIER
775 }
776}
777#[doc = "Fired when data is sent to tcp direct socket stream.\n[directTCPSocketChunkSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketChunkSent)"]
778#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
779pub struct DirectTcpSocketChunkSentParams {
780 #[serde(rename = "identifier")]
781 pub identifier: super::types::RequestId,
782 #[serde(rename = "data")]
783 pub data: crate::Binary,
784 #[serde(rename = "timestamp")]
785 pub timestamp: super::types::MonotonicTime,
786}
787#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
788pub enum DirectTcpSocketChunkSentMethod {
789 #[serde(rename = "Network.directTCPSocketChunkSent")]
790 DirectTcpSocketChunkSent,
791}
792#[doc = "Fired when data is sent to tcp direct socket stream.\n[directTCPSocketChunkSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketChunkSent)"]
793#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
794pub struct DirectTcpSocketChunkSent {
795 pub method: DirectTcpSocketChunkSentMethod,
796 pub params: DirectTcpSocketChunkSentParams,
797}
798impl DirectTcpSocketChunkSent {
799 pub const IDENTIFIER: &'static str = "Network.directTCPSocketChunkSent";
800 pub fn identifier(&self) -> &'static str {
801 Self::IDENTIFIER
802 }
803}
804#[doc = "Fired when data is received from tcp direct socket stream.\n[directTCPSocketChunkReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketChunkReceived)"]
805#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
806pub struct DirectTcpSocketChunkReceivedParams {
807 #[serde(rename = "identifier")]
808 pub identifier: super::types::RequestId,
809 #[serde(rename = "data")]
810 pub data: crate::Binary,
811 #[serde(rename = "timestamp")]
812 pub timestamp: super::types::MonotonicTime,
813}
814#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
815pub enum DirectTcpSocketChunkReceivedMethod {
816 #[serde(rename = "Network.directTCPSocketChunkReceived")]
817 DirectTcpSocketChunkReceived,
818}
819#[doc = "Fired when data is received from tcp direct socket stream.\n[directTCPSocketChunkReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directTCPSocketChunkReceived)"]
820#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
821pub struct DirectTcpSocketChunkReceived {
822 pub method: DirectTcpSocketChunkReceivedMethod,
823 pub params: DirectTcpSocketChunkReceivedParams,
824}
825impl DirectTcpSocketChunkReceived {
826 pub const IDENTIFIER: &'static str = "Network.directTCPSocketChunkReceived";
827 pub fn identifier(&self) -> &'static str {
828 Self::IDENTIFIER
829 }
830}
831#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
832pub struct DirectUdpSocketJoinedMulticastGroupParams {
833 #[serde(rename = "identifier")]
834 pub identifier: super::types::RequestId,
835 #[serde(rename = "IPAddress")]
836 pub ip_address: String,
837}
838#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
839pub enum DirectUdpSocketJoinedMulticastGroupMethod {
840 #[serde(rename = "Network.directUDPSocketJoinedMulticastGroup")]
841 DirectUdpSocketJoinedMulticastGroup,
842}
843#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
844pub struct DirectUdpSocketJoinedMulticastGroup {
845 pub method: DirectUdpSocketJoinedMulticastGroupMethod,
846 pub params: DirectUdpSocketJoinedMulticastGroupParams,
847}
848impl DirectUdpSocketJoinedMulticastGroup {
849 pub const IDENTIFIER: &'static str = "Network.directUDPSocketJoinedMulticastGroup";
850 pub fn identifier(&self) -> &'static str {
851 Self::IDENTIFIER
852 }
853}
854#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
855pub struct DirectUdpSocketLeftMulticastGroupParams {
856 #[serde(rename = "identifier")]
857 pub identifier: super::types::RequestId,
858 #[serde(rename = "IPAddress")]
859 pub ip_address: String,
860}
861#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
862pub enum DirectUdpSocketLeftMulticastGroupMethod {
863 #[serde(rename = "Network.directUDPSocketLeftMulticastGroup")]
864 DirectUdpSocketLeftMulticastGroup,
865}
866#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
867pub struct DirectUdpSocketLeftMulticastGroup {
868 pub method: DirectUdpSocketLeftMulticastGroupMethod,
869 pub params: DirectUdpSocketLeftMulticastGroupParams,
870}
871impl DirectUdpSocketLeftMulticastGroup {
872 pub const IDENTIFIER: &'static str = "Network.directUDPSocketLeftMulticastGroup";
873 pub fn identifier(&self) -> &'static str {
874 Self::IDENTIFIER
875 }
876}
877#[doc = "Fired upon direct_socket.UDPSocket creation.\n[directUDPSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketCreated)"]
878#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
879pub struct DirectUdpSocketCreatedParams {
880 #[serde(rename = "identifier")]
881 pub identifier: super::types::RequestId,
882 #[serde(rename = "options")]
883 pub options: super::types::DirectUdpSocketOptions,
884 #[serde(rename = "timestamp")]
885 pub timestamp: super::types::MonotonicTime,
886 #[serde(rename = "initiator")]
887 #[serde(skip_serializing_if = "Option::is_none")]
888 #[serde(default)]
889 pub initiator: Option<super::types::Initiator>,
890}
891#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
892pub enum DirectUdpSocketCreatedMethod {
893 #[serde(rename = "Network.directUDPSocketCreated")]
894 DirectUdpSocketCreated,
895}
896#[doc = "Fired upon direct_socket.UDPSocket creation.\n[directUDPSocketCreated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketCreated)"]
897#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
898pub struct DirectUdpSocketCreated {
899 pub method: DirectUdpSocketCreatedMethod,
900 pub params: DirectUdpSocketCreatedParams,
901}
902impl DirectUdpSocketCreated {
903 pub const IDENTIFIER: &'static str = "Network.directUDPSocketCreated";
904 pub fn identifier(&self) -> &'static str {
905 Self::IDENTIFIER
906 }
907}
908#[doc = "Fired when direct_socket.UDPSocket connection is opened.\n[directUDPSocketOpened](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketOpened)"]
909#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
910pub struct DirectUdpSocketOpenedParams {
911 #[serde(rename = "identifier")]
912 pub identifier: super::types::RequestId,
913 #[serde(rename = "localAddr")]
914 pub local_addr: String,
915 #[doc = "Expected to be unsigned integer."]
916 #[serde(rename = "localPort")]
917 pub local_port: i64,
918 #[serde(rename = "timestamp")]
919 pub timestamp: super::types::MonotonicTime,
920 #[serde(rename = "remoteAddr")]
921 #[serde(skip_serializing_if = "Option::is_none")]
922 #[serde(default)]
923 pub remote_addr: Option<String>,
924 #[doc = "Expected to be unsigned integer."]
925 #[serde(rename = "remotePort")]
926 #[serde(skip_serializing_if = "Option::is_none")]
927 #[serde(default)]
928 pub remote_port: Option<i64>,
929}
930#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
931pub enum DirectUdpSocketOpenedMethod {
932 #[serde(rename = "Network.directUDPSocketOpened")]
933 DirectUdpSocketOpened,
934}
935#[doc = "Fired when direct_socket.UDPSocket connection is opened.\n[directUDPSocketOpened](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketOpened)"]
936#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
937pub struct DirectUdpSocketOpened {
938 pub method: DirectUdpSocketOpenedMethod,
939 pub params: DirectUdpSocketOpenedParams,
940}
941impl DirectUdpSocketOpened {
942 pub const IDENTIFIER: &'static str = "Network.directUDPSocketOpened";
943 pub fn identifier(&self) -> &'static str {
944 Self::IDENTIFIER
945 }
946}
947#[doc = "Fired when direct_socket.UDPSocket is aborted.\n[directUDPSocketAborted](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketAborted)"]
948#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
949pub struct DirectUdpSocketAbortedParams {
950 #[serde(rename = "identifier")]
951 pub identifier: super::types::RequestId,
952 #[serde(rename = "errorMessage")]
953 pub error_message: String,
954 #[serde(rename = "timestamp")]
955 pub timestamp: super::types::MonotonicTime,
956}
957#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
958pub enum DirectUdpSocketAbortedMethod {
959 #[serde(rename = "Network.directUDPSocketAborted")]
960 DirectUdpSocketAborted,
961}
962#[doc = "Fired when direct_socket.UDPSocket is aborted.\n[directUDPSocketAborted](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketAborted)"]
963#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
964pub struct DirectUdpSocketAborted {
965 pub method: DirectUdpSocketAbortedMethod,
966 pub params: DirectUdpSocketAbortedParams,
967}
968impl DirectUdpSocketAborted {
969 pub const IDENTIFIER: &'static str = "Network.directUDPSocketAborted";
970 pub fn identifier(&self) -> &'static str {
971 Self::IDENTIFIER
972 }
973}
974#[doc = "Fired when direct_socket.UDPSocket is closed.\n[directUDPSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketClosed)"]
975#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
976pub struct DirectUdpSocketClosedParams {
977 #[serde(rename = "identifier")]
978 pub identifier: super::types::RequestId,
979 #[serde(rename = "timestamp")]
980 pub timestamp: super::types::MonotonicTime,
981}
982#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
983pub enum DirectUdpSocketClosedMethod {
984 #[serde(rename = "Network.directUDPSocketClosed")]
985 DirectUdpSocketClosed,
986}
987#[doc = "Fired when direct_socket.UDPSocket is closed.\n[directUDPSocketClosed](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketClosed)"]
988#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
989pub struct DirectUdpSocketClosed {
990 pub method: DirectUdpSocketClosedMethod,
991 pub params: DirectUdpSocketClosedParams,
992}
993impl DirectUdpSocketClosed {
994 pub const IDENTIFIER: &'static str = "Network.directUDPSocketClosed";
995 pub fn identifier(&self) -> &'static str {
996 Self::IDENTIFIER
997 }
998}
999#[doc = "Fired when message is sent to udp direct socket stream.\n[directUDPSocketChunkSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketChunkSent)"]
1000#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1001pub struct DirectUdpSocketChunkSentParams {
1002 #[serde(rename = "identifier")]
1003 pub identifier: super::types::RequestId,
1004 #[serde(rename = "message")]
1005 pub message: super::types::DirectUdpMessage,
1006 #[serde(rename = "timestamp")]
1007 pub timestamp: super::types::MonotonicTime,
1008}
1009#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1010pub enum DirectUdpSocketChunkSentMethod {
1011 #[serde(rename = "Network.directUDPSocketChunkSent")]
1012 DirectUdpSocketChunkSent,
1013}
1014#[doc = "Fired when message is sent to udp direct socket stream.\n[directUDPSocketChunkSent](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketChunkSent)"]
1015#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1016pub struct DirectUdpSocketChunkSent {
1017 pub method: DirectUdpSocketChunkSentMethod,
1018 pub params: DirectUdpSocketChunkSentParams,
1019}
1020impl DirectUdpSocketChunkSent {
1021 pub const IDENTIFIER: &'static str = "Network.directUDPSocketChunkSent";
1022 pub fn identifier(&self) -> &'static str {
1023 Self::IDENTIFIER
1024 }
1025}
1026#[doc = "Fired when message is received from udp direct socket stream.\n[directUDPSocketChunkReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketChunkReceived)"]
1027#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1028pub struct DirectUdpSocketChunkReceivedParams {
1029 #[serde(rename = "identifier")]
1030 pub identifier: super::types::RequestId,
1031 #[serde(rename = "message")]
1032 pub message: super::types::DirectUdpMessage,
1033 #[serde(rename = "timestamp")]
1034 pub timestamp: super::types::MonotonicTime,
1035}
1036#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1037pub enum DirectUdpSocketChunkReceivedMethod {
1038 #[serde(rename = "Network.directUDPSocketChunkReceived")]
1039 DirectUdpSocketChunkReceived,
1040}
1041#[doc = "Fired when message is received from udp direct socket stream.\n[directUDPSocketChunkReceived](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-directUDPSocketChunkReceived)"]
1042#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1043pub struct DirectUdpSocketChunkReceived {
1044 pub method: DirectUdpSocketChunkReceivedMethod,
1045 pub params: DirectUdpSocketChunkReceivedParams,
1046}
1047impl DirectUdpSocketChunkReceived {
1048 pub const IDENTIFIER: &'static str = "Network.directUDPSocketChunkReceived";
1049 pub fn identifier(&self) -> &'static str {
1050 Self::IDENTIFIER
1051 }
1052}
1053#[doc = "Fired when additional information about a requestWillBeSent event is available from the\nnetwork stack. Not every requestWillBeSent event will have an additional\nrequestWillBeSentExtraInfo fired for it, and there is no guarantee whether requestWillBeSent\nor requestWillBeSentExtraInfo will be fired first for the same request.\n[requestWillBeSentExtraInfo](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestWillBeSentExtraInfo)"]
1054#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1055pub struct RequestWillBeSentExtraInfoParams {
1056 #[doc = "Request identifier. Used to match this information to an existing requestWillBeSent event."]
1057 #[serde(rename = "requestId")]
1058 pub request_id: super::types::RequestId,
1059 #[doc = "A list of cookies potentially associated to the requested URL. This includes both cookies sent with\nthe request and the ones not sent; the latter are distinguished by having blockedReasons field set."]
1060 #[serde(rename = "associatedCookies")]
1061 #[serde(skip_serializing_if = "Vec::is_empty")]
1062 pub associated_cookies: Vec<super::types::AssociatedCookie>,
1063 #[doc = "Raw request headers as they will be sent over the wire."]
1064 #[serde(rename = "headers")]
1065 pub headers: super::types::Headers,
1066 #[doc = "Connection timing information for the request."]
1067 #[serde(rename = "connectTiming")]
1068 pub connect_timing: super::types::ConnectTiming,
1069 #[doc = "How the request site's device bound sessions were used during this request."]
1070 #[serde(rename = "deviceBoundSessionUsages")]
1071 #[serde(skip_serializing_if = "Option::is_none")]
1072 #[serde(default)]
1073 pub device_bound_session_usages: Option<Vec<super::types::DeviceBoundSessionWithUsage>>,
1074 #[doc = "The client security state set for the request."]
1075 #[serde(rename = "clientSecurityState")]
1076 #[serde(skip_serializing_if = "Option::is_none")]
1077 #[serde(default)]
1078 pub client_security_state: Option<super::types::ClientSecurityState>,
1079 #[doc = "Whether the site has partitioned cookies stored in a partition different than the current one."]
1080 #[serde(rename = "siteHasCookieInOtherPartition")]
1081 #[serde(skip_serializing_if = "Option::is_none")]
1082 #[serde(default)]
1083 pub site_has_cookie_in_other_partition: Option<bool>,
1084 #[doc = "The network conditions id if this request was affected by network conditions configured via\nemulateNetworkConditionsByRule."]
1085 #[serde(rename = "appliedNetworkConditionsId")]
1086 #[serde(skip_serializing_if = "Option::is_none")]
1087 #[serde(default)]
1088 pub applied_network_conditions_id: Option<String>,
1089}
1090#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1091pub enum RequestWillBeSentExtraInfoMethod {
1092 #[serde(rename = "Network.requestWillBeSentExtraInfo")]
1093 RequestWillBeSentExtraInfo,
1094}
1095#[doc = "Fired when additional information about a requestWillBeSent event is available from the\nnetwork stack. Not every requestWillBeSent event will have an additional\nrequestWillBeSentExtraInfo fired for it, and there is no guarantee whether requestWillBeSent\nor requestWillBeSentExtraInfo will be fired first for the same request.\n[requestWillBeSentExtraInfo](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-requestWillBeSentExtraInfo)"]
1096#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1097pub struct RequestWillBeSentExtraInfo {
1098 pub method: RequestWillBeSentExtraInfoMethod,
1099 pub params: RequestWillBeSentExtraInfoParams,
1100}
1101impl RequestWillBeSentExtraInfo {
1102 pub const IDENTIFIER: &'static str = "Network.requestWillBeSentExtraInfo";
1103 pub fn identifier(&self) -> &'static str {
1104 Self::IDENTIFIER
1105 }
1106}
1107#[doc = "Fired when additional information about a responseReceived event is available from the network\nstack. Not every responseReceived event will have an additional responseReceivedExtraInfo for\nit, and responseReceivedExtraInfo may be fired before or after responseReceived.\n[responseReceivedExtraInfo](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceivedExtraInfo)"]
1108#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1109pub struct ResponseReceivedExtraInfoParams {
1110 #[doc = "Request identifier. Used to match this information to another responseReceived event."]
1111 #[serde(rename = "requestId")]
1112 pub request_id: super::types::RequestId,
1113 #[doc = "A list of cookies which were not stored from the response along with the corresponding\nreasons for blocking. The cookies here may not be valid due to syntax errors, which\nare represented by the invalid cookie line string instead of a proper cookie."]
1114 #[serde(rename = "blockedCookies")]
1115 #[serde(skip_serializing_if = "Vec::is_empty")]
1116 pub blocked_cookies: Vec<super::types::BlockedSetCookieWithReason>,
1117 #[doc = "Raw response headers as they were received over the wire.\nDuplicate headers in the response are represented as a single key with their values\nconcatentated using `\\n` as the separator.\nSee also `headersText` that contains verbatim text for HTTP/1.*."]
1118 #[serde(rename = "headers")]
1119 pub headers: super::types::Headers,
1120 #[doc = "The IP address space of the resource. The address space can only be determined once the transport\nestablished the connection, so we can't send it in `requestWillBeSentExtraInfo`."]
1121 #[serde(rename = "resourceIPAddressSpace")]
1122 pub resource_ip_address_space: super::types::IpAddressSpace,
1123 #[doc = "The status code of the response. This is useful in cases the request failed and no responseReceived\nevent is triggered, which is the case for, e.g., CORS errors. This is also the correct status code\nfor cached requests, where the status in responseReceived is a 200 and this will be 304."]
1124 #[serde(rename = "statusCode")]
1125 pub status_code: i64,
1126 #[doc = "Raw response header text as it was received over the wire. The raw text may not always be\navailable, such as in the case of HTTP/2 or QUIC."]
1127 #[serde(rename = "headersText")]
1128 #[serde(skip_serializing_if = "Option::is_none")]
1129 #[serde(default)]
1130 pub headers_text: Option<String>,
1131 #[doc = "The cookie partition key that will be used to store partitioned cookies set in this response.\nOnly sent when partitioned cookies are enabled."]
1132 #[serde(rename = "cookiePartitionKey")]
1133 #[serde(skip_serializing_if = "Option::is_none")]
1134 #[serde(default)]
1135 pub cookie_partition_key: Option<super::types::CookiePartitionKey>,
1136 #[doc = "True if partitioned cookies are enabled, but the partition key is not serializable to string."]
1137 #[serde(rename = "cookiePartitionKeyOpaque")]
1138 #[serde(skip_serializing_if = "Option::is_none")]
1139 #[serde(default)]
1140 pub cookie_partition_key_opaque: Option<bool>,
1141 #[doc = "A list of cookies which should have been blocked by 3PCD but are exempted and stored from\nthe response with the corresponding reason."]
1142 #[serde(rename = "exemptedCookies")]
1143 #[serde(skip_serializing_if = "Option::is_none")]
1144 #[serde(default)]
1145 pub exempted_cookies: Option<Vec<super::types::ExemptedSetCookieWithReason>>,
1146}
1147#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1148pub enum ResponseReceivedExtraInfoMethod {
1149 #[serde(rename = "Network.responseReceivedExtraInfo")]
1150 ResponseReceivedExtraInfo,
1151}
1152#[doc = "Fired when additional information about a responseReceived event is available from the network\nstack. Not every responseReceived event will have an additional responseReceivedExtraInfo for\nit, and responseReceivedExtraInfo may be fired before or after responseReceived.\n[responseReceivedExtraInfo](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceivedExtraInfo)"]
1153#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1154pub struct ResponseReceivedExtraInfo {
1155 pub method: ResponseReceivedExtraInfoMethod,
1156 pub params: ResponseReceivedExtraInfoParams,
1157}
1158impl ResponseReceivedExtraInfo {
1159 pub const IDENTIFIER: &'static str = "Network.responseReceivedExtraInfo";
1160 pub fn identifier(&self) -> &'static str {
1161 Self::IDENTIFIER
1162 }
1163}
1164#[doc = "Fired when 103 Early Hints headers is received in addition to the common response.\nNot every responseReceived event will have an responseReceivedEarlyHints fired.\nOnly one responseReceivedEarlyHints may be fired for eached responseReceived event.\n[responseReceivedEarlyHints](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceivedEarlyHints)"]
1165#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1166pub struct ResponseReceivedEarlyHintsParams {
1167 #[doc = "Request identifier. Used to match this information to another responseReceived event."]
1168 #[serde(rename = "requestId")]
1169 pub request_id: super::types::RequestId,
1170 #[doc = "Raw response headers as they were received over the wire.\nDuplicate headers in the response are represented as a single key with their values\nconcatentated using `\\n` as the separator.\nSee also `headersText` that contains verbatim text for HTTP/1.*."]
1171 #[serde(rename = "headers")]
1172 pub headers: super::types::Headers,
1173}
1174#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1175pub enum ResponseReceivedEarlyHintsMethod {
1176 #[serde(rename = "Network.responseReceivedEarlyHints")]
1177 ResponseReceivedEarlyHints,
1178}
1179#[doc = "Fired when 103 Early Hints headers is received in addition to the common response.\nNot every responseReceived event will have an responseReceivedEarlyHints fired.\nOnly one responseReceivedEarlyHints may be fired for eached responseReceived event.\n[responseReceivedEarlyHints](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-responseReceivedEarlyHints)"]
1180#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1181pub struct ResponseReceivedEarlyHints {
1182 pub method: ResponseReceivedEarlyHintsMethod,
1183 pub params: ResponseReceivedEarlyHintsParams,
1184}
1185impl ResponseReceivedEarlyHints {
1186 pub const IDENTIFIER: &'static str = "Network.responseReceivedEarlyHints";
1187 pub fn identifier(&self) -> &'static str {
1188 Self::IDENTIFIER
1189 }
1190}
1191#[doc = "Fired exactly once for each Trust Token operation. Depending on\nthe type of the operation and whether the operation succeeded or\nfailed, the event is fired before the corresponding request was sent\nor after the response was received.\n[trustTokenOperationDone](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-trustTokenOperationDone)"]
1192#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1193pub struct TrustTokenOperationDoneParams {
1194 #[doc = "Detailed success or error status of the operation.\n'AlreadyExists' also signifies a successful operation, as the result\nof the operation already exists und thus, the operation was abort\npreemptively (e.g. a cache hit)."]
1195 #[serde(rename = "status")]
1196 pub status: TrustTokenOperationDoneStatus,
1197 #[serde(rename = "type")]
1198 pub r#type: super::types::TrustTokenOperationType,
1199 #[serde(rename = "requestId")]
1200 pub request_id: super::types::RequestId,
1201 #[doc = "Top level origin. The context in which the operation was attempted."]
1202 #[serde(rename = "topLevelOrigin")]
1203 #[serde(skip_serializing_if = "Option::is_none")]
1204 #[serde(default)]
1205 pub top_level_origin: Option<String>,
1206 #[doc = "Origin of the issuer in case of a \"Issuance\" or \"Redemption\" operation."]
1207 #[serde(rename = "issuerOrigin")]
1208 #[serde(skip_serializing_if = "Option::is_none")]
1209 #[serde(default)]
1210 pub issuer_origin: Option<String>,
1211 #[doc = "The number of obtained Trust Tokens on a successful \"Issuance\" operation."]
1212 #[serde(rename = "issuedTokenCount")]
1213 #[serde(skip_serializing_if = "Option::is_none")]
1214 #[serde(default)]
1215 pub issued_token_count: Option<i64>,
1216}
1217#[doc = "Detailed success or error status of the operation.\n'AlreadyExists' also signifies a successful operation, as the result\nof the operation already exists und thus, the operation was abort\npreemptively (e.g. a cache hit)."]
1218#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize)]
1219pub enum TrustTokenOperationDoneStatus {
1220 #[serde(rename = "Ok")]
1221 Ok,
1222 #[serde(rename = "InvalidArgument")]
1223 InvalidArgument,
1224 #[serde(rename = "MissingIssuerKeys")]
1225 MissingIssuerKeys,
1226 #[serde(rename = "FailedPrecondition")]
1227 FailedPrecondition,
1228 #[serde(rename = "ResourceExhausted")]
1229 ResourceExhausted,
1230 #[serde(rename = "AlreadyExists")]
1231 AlreadyExists,
1232 #[serde(rename = "ResourceLimited")]
1233 ResourceLimited,
1234 #[serde(rename = "Unauthorized")]
1235 Unauthorized,
1236 #[serde(rename = "BadResponse")]
1237 BadResponse,
1238 #[serde(rename = "InternalError")]
1239 InternalError,
1240 #[serde(rename = "UnknownError")]
1241 UnknownError,
1242 #[serde(rename = "FulfilledLocally")]
1243 FulfilledLocally,
1244 #[serde(rename = "SiteIssuerLimit")]
1245 SiteIssuerLimit,
1246}
1247#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1248pub enum TrustTokenOperationDoneMethod {
1249 #[serde(rename = "Network.trustTokenOperationDone")]
1250 TrustTokenOperationDone,
1251}
1252#[doc = "Fired exactly once for each Trust Token operation. Depending on\nthe type of the operation and whether the operation succeeded or\nfailed, the event is fired before the corresponding request was sent\nor after the response was received.\n[trustTokenOperationDone](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-trustTokenOperationDone)"]
1253#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1254pub struct TrustTokenOperationDone {
1255 pub method: TrustTokenOperationDoneMethod,
1256 pub params: TrustTokenOperationDoneParams,
1257}
1258impl TrustTokenOperationDone {
1259 pub const IDENTIFIER: &'static str = "Network.trustTokenOperationDone";
1260 pub fn identifier(&self) -> &'static str {
1261 Self::IDENTIFIER
1262 }
1263}
1264#[doc = "Fired once security policy has been updated.\n[policyUpdated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-policyUpdated)"]
1265#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1266pub struct PolicyUpdatedParams {}
1267#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1268pub enum PolicyUpdatedMethod {
1269 #[serde(rename = "Network.policyUpdated")]
1270 PolicyUpdated,
1271}
1272#[doc = "Fired once security policy has been updated.\n[policyUpdated](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-policyUpdated)"]
1273#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1274pub struct PolicyUpdated {
1275 pub method: PolicyUpdatedMethod,
1276 pub params: PolicyUpdatedParams,
1277}
1278impl PolicyUpdated {
1279 pub const IDENTIFIER: &'static str = "Network.policyUpdated";
1280 pub fn identifier(&self) -> &'static str {
1281 Self::IDENTIFIER
1282 }
1283}
1284#[doc = "Is sent whenever a new report is added.\nAnd after 'enableReportingApi' for all existing reports.\n[reportingApiReportAdded](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-reportingApiReportAdded)"]
1285#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1286pub struct ReportingApiReportAddedParams {
1287 #[serde(rename = "report")]
1288 pub report: super::types::ReportingApiReport,
1289}
1290#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1291pub enum ReportingApiReportAddedMethod {
1292 #[serde(rename = "Network.reportingApiReportAdded")]
1293 ReportingApiReportAdded,
1294}
1295#[doc = "Is sent whenever a new report is added.\nAnd after 'enableReportingApi' for all existing reports.\n[reportingApiReportAdded](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-reportingApiReportAdded)"]
1296#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1297pub struct ReportingApiReportAdded {
1298 pub method: ReportingApiReportAddedMethod,
1299 pub params: ReportingApiReportAddedParams,
1300}
1301impl ReportingApiReportAdded {
1302 pub const IDENTIFIER: &'static str = "Network.reportingApiReportAdded";
1303 pub fn identifier(&self) -> &'static str {
1304 Self::IDENTIFIER
1305 }
1306}
1307#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1308pub struct ReportingApiReportUpdatedParams {
1309 #[serde(rename = "report")]
1310 pub report: super::types::ReportingApiReport,
1311}
1312#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1313pub enum ReportingApiReportUpdatedMethod {
1314 #[serde(rename = "Network.reportingApiReportUpdated")]
1315 ReportingApiReportUpdated,
1316}
1317#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1318pub struct ReportingApiReportUpdated {
1319 pub method: ReportingApiReportUpdatedMethod,
1320 pub params: ReportingApiReportUpdatedParams,
1321}
1322impl ReportingApiReportUpdated {
1323 pub const IDENTIFIER: &'static str = "Network.reportingApiReportUpdated";
1324 pub fn identifier(&self) -> &'static str {
1325 Self::IDENTIFIER
1326 }
1327}
1328#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1329pub struct ReportingApiEndpointsChangedForOriginParams {
1330 #[doc = "Origin of the document(s) which configured the endpoints."]
1331 #[serde(rename = "origin")]
1332 pub origin: String,
1333 #[serde(rename = "endpoints")]
1334 #[serde(skip_serializing_if = "Vec::is_empty")]
1335 pub endpoints: Vec<super::types::ReportingApiEndpoint>,
1336}
1337#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1338pub enum ReportingApiEndpointsChangedForOriginMethod {
1339 #[serde(rename = "Network.reportingApiEndpointsChangedForOrigin")]
1340 ReportingApiEndpointsChangedForOrigin,
1341}
1342#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1343pub struct ReportingApiEndpointsChangedForOrigin {
1344 pub method: ReportingApiEndpointsChangedForOriginMethod,
1345 pub params: ReportingApiEndpointsChangedForOriginParams,
1346}
1347impl ReportingApiEndpointsChangedForOrigin {
1348 pub const IDENTIFIER: &'static str = "Network.reportingApiEndpointsChangedForOrigin";
1349 pub fn identifier(&self) -> &'static str {
1350 Self::IDENTIFIER
1351 }
1352}
1353#[doc = "Triggered when the initial set of device bound sessions is added.\n[deviceBoundSessionsAdded](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-deviceBoundSessionsAdded)"]
1354#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1355pub struct DeviceBoundSessionsAddedParams {
1356 #[doc = "The device bound sessions."]
1357 #[serde(rename = "sessions")]
1358 #[serde(skip_serializing_if = "Vec::is_empty")]
1359 pub sessions: Vec<super::types::DeviceBoundSession>,
1360}
1361#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1362pub enum DeviceBoundSessionsAddedMethod {
1363 #[serde(rename = "Network.deviceBoundSessionsAdded")]
1364 DeviceBoundSessionsAdded,
1365}
1366#[doc = "Triggered when the initial set of device bound sessions is added.\n[deviceBoundSessionsAdded](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-deviceBoundSessionsAdded)"]
1367#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1368pub struct DeviceBoundSessionsAdded {
1369 pub method: DeviceBoundSessionsAddedMethod,
1370 pub params: DeviceBoundSessionsAddedParams,
1371}
1372impl DeviceBoundSessionsAdded {
1373 pub const IDENTIFIER: &'static str = "Network.deviceBoundSessionsAdded";
1374 pub fn identifier(&self) -> &'static str {
1375 Self::IDENTIFIER
1376 }
1377}
1378#[doc = "Triggered when a device bound session event occurs.\n[deviceBoundSessionEventOccurred](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-deviceBoundSessionEventOccurred)"]
1379#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1380pub struct DeviceBoundSessionEventOccurredParams {
1381 #[doc = "A unique identifier for this session event."]
1382 #[serde(rename = "eventId")]
1383 pub event_id: super::types::DeviceBoundSessionEventId,
1384 #[doc = "The site this session event is associated with."]
1385 #[serde(rename = "site")]
1386 pub site: String,
1387 #[doc = "Whether this event was considered successful."]
1388 #[serde(rename = "succeeded")]
1389 pub succeeded: bool,
1390 #[doc = "The session ID this event is associated with. May not be populated for\nfailed events."]
1391 #[serde(rename = "sessionId")]
1392 #[serde(skip_serializing_if = "Option::is_none")]
1393 #[serde(default)]
1394 pub session_id: Option<String>,
1395 #[doc = "The below are the different session event type details. Exactly one is populated."]
1396 #[serde(rename = "creationEventDetails")]
1397 #[serde(skip_serializing_if = "Option::is_none")]
1398 #[serde(default)]
1399 pub creation_event_details: Option<super::types::CreationEventDetails>,
1400 #[serde(rename = "refreshEventDetails")]
1401 #[serde(skip_serializing_if = "Option::is_none")]
1402 #[serde(default)]
1403 pub refresh_event_details: Option<super::types::RefreshEventDetails>,
1404 #[serde(rename = "terminationEventDetails")]
1405 #[serde(skip_serializing_if = "Option::is_none")]
1406 #[serde(default)]
1407 pub termination_event_details: Option<super::types::TerminationEventDetails>,
1408 #[serde(rename = "challengeEventDetails")]
1409 #[serde(skip_serializing_if = "Option::is_none")]
1410 #[serde(default)]
1411 pub challenge_event_details: Option<super::types::ChallengeEventDetails>,
1412}
1413#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1414pub enum DeviceBoundSessionEventOccurredMethod {
1415 #[serde(rename = "Network.deviceBoundSessionEventOccurred")]
1416 DeviceBoundSessionEventOccurred,
1417}
1418#[doc = "Triggered when a device bound session event occurs.\n[deviceBoundSessionEventOccurred](https://chromedevtools.github.io/devtools-protocol/tot/Network/#event-deviceBoundSessionEventOccurred)"]
1419#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
1420pub struct DeviceBoundSessionEventOccurred {
1421 pub method: DeviceBoundSessionEventOccurredMethod,
1422 pub params: DeviceBoundSessionEventOccurredParams,
1423}
1424impl DeviceBoundSessionEventOccurred {
1425 pub const IDENTIFIER: &'static str = "Network.deviceBoundSessionEventOccurred";
1426 pub fn identifier(&self) -> &'static str {
1427 Self::IDENTIFIER
1428 }
1429}
1430group_enum ! (NetworkEvents { DataReceived (DataReceived) , EventSourceMessageReceived (EventSourceMessageReceived) , LoadingFailed (LoadingFailed) , LoadingFinished (LoadingFinished) , RequestServedFromCache (RequestServedFromCache) , RequestWillBeSent (RequestWillBeSent) , ResourceChangedPriority (ResourceChangedPriority) , SignedExchangeReceived (SignedExchangeReceived) , ResponseReceived (ResponseReceived) , WebSocketClosed (WebSocketClosed) , WebSocketCreated (WebSocketCreated) , WebSocketFrameError (WebSocketFrameError) , WebSocketFrameReceived (WebSocketFrameReceived) , WebSocketFrameSent (WebSocketFrameSent) , WebSocketHandshakeResponseReceived (WebSocketHandshakeResponseReceived) , WebSocketWillSendHandshakeRequest (WebSocketWillSendHandshakeRequest) , WebTransportCreated (WebTransportCreated) , WebTransportConnectionEstablished (WebTransportConnectionEstablished) , WebTransportClosed (WebTransportClosed) , DirectTcpSocketCreated (DirectTcpSocketCreated) , DirectTcpSocketOpened (DirectTcpSocketOpened) , DirectTcpSocketAborted (DirectTcpSocketAborted) , DirectTcpSocketClosed (DirectTcpSocketClosed) , DirectTcpSocketChunkSent (DirectTcpSocketChunkSent) , DirectTcpSocketChunkReceived (DirectTcpSocketChunkReceived) , DirectUdpSocketJoinedMulticastGroup (DirectUdpSocketJoinedMulticastGroup) , DirectUdpSocketLeftMulticastGroup (DirectUdpSocketLeftMulticastGroup) , DirectUdpSocketCreated (DirectUdpSocketCreated) , DirectUdpSocketOpened (DirectUdpSocketOpened) , DirectUdpSocketAborted (DirectUdpSocketAborted) , DirectUdpSocketClosed (DirectUdpSocketClosed) , DirectUdpSocketChunkSent (DirectUdpSocketChunkSent) , DirectUdpSocketChunkReceived (DirectUdpSocketChunkReceived) , RequestWillBeSentExtraInfo (RequestWillBeSentExtraInfo) , ResponseReceivedExtraInfo (ResponseReceivedExtraInfo) , ResponseReceivedEarlyHints (ResponseReceivedEarlyHints) , TrustTokenOperationDone (TrustTokenOperationDone) , PolicyUpdated (PolicyUpdated) , ReportingApiReportAdded (ReportingApiReportAdded) , ReportingApiReportUpdated (ReportingApiReportUpdated) , ReportingApiEndpointsChangedForOrigin (ReportingApiEndpointsChangedForOrigin) , DeviceBoundSessionsAdded (DeviceBoundSessionsAdded) , DeviceBoundSessionEventOccurred (DeviceBoundSessionEventOccurred) } + identifiable);