Skip to main content

browser_protocol/target/
mod.rs

1//! Supports additional targets discovery and allows to attach to them.
2use serde::{Serialize, Deserialize};
3use serde_json::Value as JsonValue;
4
5
6pub type TargetID = String;
7
8/// Unique identifier of attached debugging session.
9
10pub type SessionID = String;
11
12
13#[derive(Debug, Clone, Serialize, Deserialize, Default)]
14#[serde(rename_all = "camelCase")]
15pub struct TargetInfo {
16
17    pub targetId: TargetID,
18    /// List of types: https://source.chromium.org/chromium/chromium/src/+/main:content/browser/devtools/devtools_agent_host_impl.cc?ss=chromium&q=f:devtools%20-f:out%20%22::kTypeTab%5B%5D%22
19
20    #[serde(rename = "type")]
21    pub type_: String,
22
23    pub title: String,
24
25    pub url: String,
26    /// Whether the target has an attached client.
27
28    pub attached: bool,
29    /// Opener target Id
30
31    #[serde(skip_serializing_if = "Option::is_none")]
32    pub openerId: Option<TargetID>,
33    /// Whether the target has access to the originating window.
34
35    pub canAccessOpener: bool,
36    /// Frame id of originating window (is only set if target has an opener).
37
38    #[serde(skip_serializing_if = "Option::is_none")]
39    pub openerFrameId: Option<crate::page::FrameId>,
40    /// Id of the parent frame, present for "iframe" and "worker" targets. For nested workers,
41    /// this is the "ancestor" frame that created the first worker in the nested chain.
42
43    #[serde(skip_serializing_if = "Option::is_none")]
44    pub parentFrameId: Option<crate::page::FrameId>,
45
46    #[serde(skip_serializing_if = "Option::is_none")]
47    pub browserContextId: Option<crate::browser::BrowserContextID>,
48    /// Provides additional details for specific target types. For example, for
49    /// the type of "page", this may be set to "prerender".
50
51    #[serde(skip_serializing_if = "Option::is_none")]
52    pub subtype: Option<String>,
53}
54
55/// A filter used by target query/discovery/auto-attach operations.
56
57#[derive(Debug, Clone, Serialize, Deserialize, Default)]
58#[serde(rename_all = "camelCase")]
59pub struct FilterEntry {
60    /// If set, causes exclusion of matching targets from the list.
61
62    #[serde(skip_serializing_if = "Option::is_none")]
63    pub exclude: Option<bool>,
64    /// If not present, matches any type.
65
66    #[serde(skip_serializing_if = "Option::is_none")]
67    #[serde(rename = "type")]
68    pub type_: Option<String>,
69}
70
71/// The entries in TargetFilter are matched sequentially against targets and
72/// the first entry that matches determines if the target is included or not,
73/// depending on the value of 'exclude' field in the entry.
74/// If filter is not specified, the one assumed is
75/// [{type: "browser", exclude: true}, {type: "tab", exclude: true}, {}]
76/// (i.e. include everything but 'browser' and 'tab').
77
78pub type TargetFilter = Vec<FilterEntry>;
79
80
81#[derive(Debug, Clone, Serialize, Deserialize, Default)]
82#[serde(rename_all = "camelCase")]
83pub struct RemoteLocation {
84
85    pub host: String,
86
87    pub port: i64,
88}
89
90/// The state of the target window.
91
92#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Default)]
93pub enum WindowState {
94    #[default]
95    Normal,
96    Minimized,
97    Maximized,
98    Fullscreen,
99}
100
101/// Activates (focuses) the target.
102
103#[derive(Debug, Clone, Serialize, Deserialize, Default)]
104#[serde(rename_all = "camelCase")]
105pub struct ActivateTargetParams {
106
107    pub targetId: TargetID,
108}
109
110impl ActivateTargetParams { pub const METHOD: &'static str = "Target.activateTarget"; }
111
112impl crate::CdpCommand for ActivateTargetParams {
113    const METHOD: &'static str = "Target.activateTarget";
114    type Response = crate::EmptyReturns;
115}
116
117/// Attaches to the target with given id.
118
119#[derive(Debug, Clone, Serialize, Deserialize, Default)]
120#[serde(rename_all = "camelCase")]
121pub struct AttachToTargetParams {
122
123    pub targetId: TargetID,
124    /// Enables "flat" access to the session via specifying sessionId attribute in the commands.
125    /// We plan to make this the default, deprecate non-flattened mode,
126    /// and eventually retire it. See crbug.com/991325.
127
128    #[serde(skip_serializing_if = "Option::is_none")]
129    pub flatten: Option<bool>,
130}
131
132/// Attaches to the target with given id.
133
134#[derive(Debug, Clone, Serialize, Deserialize, Default)]
135#[serde(rename_all = "camelCase")]
136pub struct AttachToTargetReturns {
137    /// Id assigned to the session.
138
139    pub sessionId: SessionID,
140}
141
142impl AttachToTargetParams { pub const METHOD: &'static str = "Target.attachToTarget"; }
143
144impl crate::CdpCommand for AttachToTargetParams {
145    const METHOD: &'static str = "Target.attachToTarget";
146    type Response = AttachToTargetReturns;
147}
148
149/// Attaches to the browser target, only uses flat sessionId mode.
150
151#[derive(Debug, Clone, Serialize, Deserialize, Default)]
152#[serde(rename_all = "camelCase")]
153pub struct AttachToBrowserTargetReturns {
154    /// Id assigned to the session.
155
156    pub sessionId: SessionID,
157}
158
159#[derive(Debug, Clone, Serialize, Deserialize, Default)]
160pub struct AttachToBrowserTargetParams {}
161
162impl AttachToBrowserTargetParams { pub const METHOD: &'static str = "Target.attachToBrowserTarget"; }
163
164impl crate::CdpCommand for AttachToBrowserTargetParams {
165    const METHOD: &'static str = "Target.attachToBrowserTarget";
166    type Response = AttachToBrowserTargetReturns;
167}
168
169/// Closes the target. If the target is a page that gets closed too.
170
171#[derive(Debug, Clone, Serialize, Deserialize, Default)]
172#[serde(rename_all = "camelCase")]
173pub struct CloseTargetParams {
174
175    pub targetId: TargetID,
176}
177
178/// Closes the target. If the target is a page that gets closed too.
179
180#[derive(Debug, Clone, Serialize, Deserialize, Default)]
181#[serde(rename_all = "camelCase")]
182pub struct CloseTargetReturns {
183    /// Always set to true. If an error occurs, the response indicates protocol error.
184
185    pub success: bool,
186}
187
188impl CloseTargetParams { pub const METHOD: &'static str = "Target.closeTarget"; }
189
190impl crate::CdpCommand for CloseTargetParams {
191    const METHOD: &'static str = "Target.closeTarget";
192    type Response = CloseTargetReturns;
193}
194
195/// Inject object to the target's main frame that provides a communication
196/// channel with browser target.
197/// 
198/// Injected object will be available as 'window[bindingName]'.
199/// 
200/// The object has the following API:
201/// - 'binding.send(json)' - a method to send messages over the remote debugging protocol
202/// - 'binding.onmessage = json => handleMessage(json)' - a callback that will be called for the protocol notifications and command responses.
203
204#[derive(Debug, Clone, Serialize, Deserialize, Default)]
205#[serde(rename_all = "camelCase")]
206pub struct ExposeDevToolsProtocolParams {
207
208    pub targetId: TargetID,
209    /// Binding name, 'cdp' if not specified.
210
211    #[serde(skip_serializing_if = "Option::is_none")]
212    pub bindingName: Option<String>,
213    /// If true, inherits the current root session's permissions (default: false).
214
215    #[serde(skip_serializing_if = "Option::is_none")]
216    pub inheritPermissions: Option<bool>,
217}
218
219impl ExposeDevToolsProtocolParams { pub const METHOD: &'static str = "Target.exposeDevToolsProtocol"; }
220
221impl crate::CdpCommand for ExposeDevToolsProtocolParams {
222    const METHOD: &'static str = "Target.exposeDevToolsProtocol";
223    type Response = crate::EmptyReturns;
224}
225
226/// Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than
227/// one.
228
229#[derive(Debug, Clone, Serialize, Deserialize, Default)]
230#[serde(rename_all = "camelCase")]
231pub struct CreateBrowserContextParams {
232    /// If specified, disposes this context when debugging session disconnects.
233
234    #[serde(skip_serializing_if = "Option::is_none")]
235    pub disposeOnDetach: Option<bool>,
236    /// Proxy server, similar to the one passed to --proxy-server
237
238    #[serde(skip_serializing_if = "Option::is_none")]
239    pub proxyServer: Option<String>,
240    /// Proxy bypass list, similar to the one passed to --proxy-bypass-list
241
242    #[serde(skip_serializing_if = "Option::is_none")]
243    pub proxyBypassList: Option<String>,
244    /// An optional list of origins to grant unlimited cross-origin access to.
245    /// Parts of the URL other than those constituting origin are ignored.
246
247    #[serde(skip_serializing_if = "Option::is_none")]
248    pub originsWithUniversalNetworkAccess: Option<Vec<String>>,
249}
250
251/// Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than
252/// one.
253
254#[derive(Debug, Clone, Serialize, Deserialize, Default)]
255#[serde(rename_all = "camelCase")]
256pub struct CreateBrowserContextReturns {
257    /// The id of the context created.
258
259    pub browserContextId: crate::browser::BrowserContextID,
260}
261
262impl CreateBrowserContextParams { pub const METHOD: &'static str = "Target.createBrowserContext"; }
263
264impl crate::CdpCommand for CreateBrowserContextParams {
265    const METHOD: &'static str = "Target.createBrowserContext";
266    type Response = CreateBrowserContextReturns;
267}
268
269/// Returns all browser contexts created with 'Target.createBrowserContext' method.
270
271#[derive(Debug, Clone, Serialize, Deserialize, Default)]
272#[serde(rename_all = "camelCase")]
273pub struct GetBrowserContextsReturns {
274    /// An array of browser context ids.
275
276    pub browserContextIds: Vec<crate::browser::BrowserContextID>,
277    /// The id of the default browser context if available.
278
279    #[serde(skip_serializing_if = "Option::is_none")]
280    pub defaultBrowserContextId: Option<crate::browser::BrowserContextID>,
281}
282
283#[derive(Debug, Clone, Serialize, Deserialize, Default)]
284pub struct GetBrowserContextsParams {}
285
286impl GetBrowserContextsParams { pub const METHOD: &'static str = "Target.getBrowserContexts"; }
287
288impl crate::CdpCommand for GetBrowserContextsParams {
289    const METHOD: &'static str = "Target.getBrowserContexts";
290    type Response = GetBrowserContextsReturns;
291}
292
293/// Creates a new page.
294
295#[derive(Debug, Clone, Serialize, Deserialize, Default)]
296#[serde(rename_all = "camelCase")]
297pub struct CreateTargetParams {
298    /// The initial URL the page will be navigated to. An empty string indicates about:blank.
299
300    pub url: String,
301    /// Frame left origin in DIP (requires newWindow to be true or headless shell).
302
303    #[serde(skip_serializing_if = "Option::is_none")]
304    pub left: Option<i64>,
305    /// Frame top origin in DIP (requires newWindow to be true or headless shell).
306
307    #[serde(skip_serializing_if = "Option::is_none")]
308    pub top: Option<i64>,
309    /// Frame width in DIP (requires newWindow to be true or headless shell).
310
311    #[serde(skip_serializing_if = "Option::is_none")]
312    pub width: Option<u64>,
313    /// Frame height in DIP (requires newWindow to be true or headless shell).
314
315    #[serde(skip_serializing_if = "Option::is_none")]
316    pub height: Option<i64>,
317    /// Frame window state (requires newWindow to be true or headless shell).
318    /// Default is normal.
319
320    #[serde(skip_serializing_if = "Option::is_none")]
321    pub windowState: Option<WindowState>,
322    /// The browser context to create the page in.
323
324    #[serde(skip_serializing_if = "Option::is_none")]
325    pub browserContextId: Option<crate::browser::BrowserContextID>,
326    /// Whether BeginFrames for this target will be controlled via DevTools (headless shell only,
327    /// not supported on MacOS yet, false by default).
328
329    #[serde(skip_serializing_if = "Option::is_none")]
330    pub enableBeginFrameControl: Option<bool>,
331    /// Whether to create a new Window or Tab (false by default, not supported by headless shell).
332
333    #[serde(skip_serializing_if = "Option::is_none")]
334    pub newWindow: Option<bool>,
335    /// Whether to create the target in background or foreground (false by default, not supported
336    /// by headless shell).
337
338    #[serde(skip_serializing_if = "Option::is_none")]
339    pub background: Option<bool>,
340    /// Whether to create the target of type "tab".
341
342    #[serde(skip_serializing_if = "Option::is_none")]
343    pub forTab: Option<bool>,
344    /// Whether to create a hidden target. The hidden target is observable via protocol, but not
345    /// present in the tab UI strip. Cannot be created with 'forTab: true', 'newWindow: true' or
346    /// 'background: false'. The life-time of the tab is limited to the life-time of the session.
347
348    #[serde(skip_serializing_if = "Option::is_none")]
349    pub hidden: Option<bool>,
350    /// If specified, the option is used to determine if the new target should
351    /// be focused or not. By default, the focus behavior depends on the
352    /// value of the background field. For example, background=false and focus=false
353    /// will result in the target tab being opened but the browser window remain
354    /// unchanged (if it was in the background, it will remain in the background)
355    /// and background=false with focus=undefined will result in the window being focused.
356    /// Using background: true and focus: true is not supported and will result in an error.
357
358    #[serde(skip_serializing_if = "Option::is_none")]
359    pub focus: Option<bool>,
360}
361
362/// Creates a new page.
363
364#[derive(Debug, Clone, Serialize, Deserialize, Default)]
365#[serde(rename_all = "camelCase")]
366pub struct CreateTargetReturns {
367    /// The id of the page opened.
368
369    pub targetId: TargetID,
370}
371
372impl CreateTargetParams { pub const METHOD: &'static str = "Target.createTarget"; }
373
374impl crate::CdpCommand for CreateTargetParams {
375    const METHOD: &'static str = "Target.createTarget";
376    type Response = CreateTargetReturns;
377}
378
379/// Detaches session with given id.
380
381#[derive(Debug, Clone, Serialize, Deserialize, Default)]
382#[serde(rename_all = "camelCase")]
383pub struct DetachFromTargetParams {
384    /// Session to detach.
385
386    #[serde(skip_serializing_if = "Option::is_none")]
387    pub sessionId: Option<SessionID>,
388    /// Deprecated.
389
390    #[serde(skip_serializing_if = "Option::is_none")]
391    pub targetId: Option<TargetID>,
392}
393
394impl DetachFromTargetParams { pub const METHOD: &'static str = "Target.detachFromTarget"; }
395
396impl crate::CdpCommand for DetachFromTargetParams {
397    const METHOD: &'static str = "Target.detachFromTarget";
398    type Response = crate::EmptyReturns;
399}
400
401/// Deletes a BrowserContext. All the belonging pages will be closed without calling their
402/// beforeunload hooks.
403
404#[derive(Debug, Clone, Serialize, Deserialize, Default)]
405#[serde(rename_all = "camelCase")]
406pub struct DisposeBrowserContextParams {
407
408    pub browserContextId: crate::browser::BrowserContextID,
409}
410
411impl DisposeBrowserContextParams { pub const METHOD: &'static str = "Target.disposeBrowserContext"; }
412
413impl crate::CdpCommand for DisposeBrowserContextParams {
414    const METHOD: &'static str = "Target.disposeBrowserContext";
415    type Response = crate::EmptyReturns;
416}
417
418/// Returns information about a target.
419
420#[derive(Debug, Clone, Serialize, Deserialize, Default)]
421#[serde(rename_all = "camelCase")]
422pub struct GetTargetInfoParams {
423
424    #[serde(skip_serializing_if = "Option::is_none")]
425    pub targetId: Option<TargetID>,
426}
427
428/// Returns information about a target.
429
430#[derive(Debug, Clone, Serialize, Deserialize, Default)]
431#[serde(rename_all = "camelCase")]
432pub struct GetTargetInfoReturns {
433
434    pub targetInfo: TargetInfo,
435}
436
437impl GetTargetInfoParams { pub const METHOD: &'static str = "Target.getTargetInfo"; }
438
439impl crate::CdpCommand for GetTargetInfoParams {
440    const METHOD: &'static str = "Target.getTargetInfo";
441    type Response = GetTargetInfoReturns;
442}
443
444/// Retrieves a list of available targets.
445
446#[derive(Debug, Clone, Serialize, Deserialize, Default)]
447#[serde(rename_all = "camelCase")]
448pub struct GetTargetsParams {
449    /// Only targets matching filter will be reported. If filter is not specified
450    /// and target discovery is currently enabled, a filter used for target discovery
451    /// is used for consistency.
452
453    #[serde(skip_serializing_if = "Option::is_none")]
454    pub filter: Option<TargetFilter>,
455}
456
457/// Retrieves a list of available targets.
458
459#[derive(Debug, Clone, Serialize, Deserialize, Default)]
460#[serde(rename_all = "camelCase")]
461pub struct GetTargetsReturns {
462    /// The list of targets.
463
464    pub targetInfos: Vec<TargetInfo>,
465}
466
467impl GetTargetsParams { pub const METHOD: &'static str = "Target.getTargets"; }
468
469impl crate::CdpCommand for GetTargetsParams {
470    const METHOD: &'static str = "Target.getTargets";
471    type Response = GetTargetsReturns;
472}
473
474/// Sends protocol message over session with given id.
475/// Consider using flat mode instead; see commands attachToTarget, setAutoAttach,
476/// and crbug.com/991325.
477
478#[derive(Debug, Clone, Serialize, Deserialize, Default)]
479#[serde(rename_all = "camelCase")]
480pub struct SendMessageToTargetParams {
481
482    pub message: String,
483    /// Identifier of the session.
484
485    #[serde(skip_serializing_if = "Option::is_none")]
486    pub sessionId: Option<SessionID>,
487    /// Deprecated.
488
489    #[serde(skip_serializing_if = "Option::is_none")]
490    pub targetId: Option<TargetID>,
491}
492
493impl SendMessageToTargetParams { pub const METHOD: &'static str = "Target.sendMessageToTarget"; }
494
495impl crate::CdpCommand for SendMessageToTargetParams {
496    const METHOD: &'static str = "Target.sendMessageToTarget";
497    type Response = crate::EmptyReturns;
498}
499
500/// Controls whether to automatically attach to new targets which are considered
501/// to be directly related to this one (for example, iframes or workers).
502/// When turned on, attaches to all existing related targets as well. When turned off,
503/// automatically detaches from all currently attached targets.
504/// This also clears all targets added by 'autoAttachRelated' from the list of targets to watch
505/// for creation of related targets.
506/// You might want to call this recursively for auto-attached targets to attach
507/// to all available targets.
508
509#[derive(Debug, Clone, Serialize, Deserialize, Default)]
510#[serde(rename_all = "camelCase")]
511pub struct SetAutoAttachParams {
512    /// Whether to auto-attach to related targets.
513
514    pub autoAttach: bool,
515    /// Whether to pause new targets when attaching to them. Use 'Runtime.runIfWaitingForDebugger'
516    /// to run paused targets.
517
518    pub waitForDebuggerOnStart: bool,
519    /// Enables "flat" access to the session via specifying sessionId attribute in the commands.
520    /// We plan to make this the default, deprecate non-flattened mode,
521    /// and eventually retire it. See crbug.com/991325.
522
523    #[serde(skip_serializing_if = "Option::is_none")]
524    pub flatten: Option<bool>,
525    /// Only targets matching filter will be attached.
526
527    #[serde(skip_serializing_if = "Option::is_none")]
528    pub filter: Option<TargetFilter>,
529}
530
531impl SetAutoAttachParams { pub const METHOD: &'static str = "Target.setAutoAttach"; }
532
533impl crate::CdpCommand for SetAutoAttachParams {
534    const METHOD: &'static str = "Target.setAutoAttach";
535    type Response = crate::EmptyReturns;
536}
537
538/// Adds the specified target to the list of targets that will be monitored for any related target
539/// creation (such as child frames, child workers and new versions of service worker) and reported
540/// through 'attachedToTarget'. The specified target is also auto-attached.
541/// This cancels the effect of any previous 'setAutoAttach' and is also cancelled by subsequent
542/// 'setAutoAttach'. Only available at the Browser target.
543
544#[derive(Debug, Clone, Serialize, Deserialize, Default)]
545#[serde(rename_all = "camelCase")]
546pub struct AutoAttachRelatedParams {
547
548    pub targetId: TargetID,
549    /// Whether to pause new targets when attaching to them. Use 'Runtime.runIfWaitingForDebugger'
550    /// to run paused targets.
551
552    pub waitForDebuggerOnStart: bool,
553    /// Only targets matching filter will be attached.
554
555    #[serde(skip_serializing_if = "Option::is_none")]
556    pub filter: Option<TargetFilter>,
557}
558
559impl AutoAttachRelatedParams { pub const METHOD: &'static str = "Target.autoAttachRelated"; }
560
561impl crate::CdpCommand for AutoAttachRelatedParams {
562    const METHOD: &'static str = "Target.autoAttachRelated";
563    type Response = crate::EmptyReturns;
564}
565
566/// Controls whether to discover available targets and notify via
567/// 'targetCreated/targetInfoChanged/targetDestroyed' events.
568
569#[derive(Debug, Clone, Serialize, Deserialize, Default)]
570#[serde(rename_all = "camelCase")]
571pub struct SetDiscoverTargetsParams {
572    /// Whether to discover available targets.
573
574    pub discover: bool,
575    /// Only targets matching filter will be attached. If 'discover' is false,
576    /// 'filter' must be omitted or empty.
577
578    #[serde(skip_serializing_if = "Option::is_none")]
579    pub filter: Option<TargetFilter>,
580}
581
582impl SetDiscoverTargetsParams { pub const METHOD: &'static str = "Target.setDiscoverTargets"; }
583
584impl crate::CdpCommand for SetDiscoverTargetsParams {
585    const METHOD: &'static str = "Target.setDiscoverTargets";
586    type Response = crate::EmptyReturns;
587}
588
589/// Enables target discovery for the specified locations, when 'setDiscoverTargets' was set to
590/// 'true'.
591
592#[derive(Debug, Clone, Serialize, Deserialize, Default)]
593#[serde(rename_all = "camelCase")]
594pub struct SetRemoteLocationsParams {
595    /// List of remote locations.
596
597    pub locations: Vec<RemoteLocation>,
598}
599
600impl SetRemoteLocationsParams { pub const METHOD: &'static str = "Target.setRemoteLocations"; }
601
602impl crate::CdpCommand for SetRemoteLocationsParams {
603    const METHOD: &'static str = "Target.setRemoteLocations";
604    type Response = crate::EmptyReturns;
605}
606
607/// Gets the targetId of the DevTools page target opened for the given target
608/// (if any).
609
610#[derive(Debug, Clone, Serialize, Deserialize, Default)]
611#[serde(rename_all = "camelCase")]
612pub struct GetDevToolsTargetParams {
613    /// Page or tab target ID.
614
615    pub targetId: TargetID,
616}
617
618/// Gets the targetId of the DevTools page target opened for the given target
619/// (if any).
620
621#[derive(Debug, Clone, Serialize, Deserialize, Default)]
622#[serde(rename_all = "camelCase")]
623pub struct GetDevToolsTargetReturns {
624    /// The targetId of DevTools page target if exists.
625
626    #[serde(skip_serializing_if = "Option::is_none")]
627    pub targetId: Option<TargetID>,
628}
629
630impl GetDevToolsTargetParams { pub const METHOD: &'static str = "Target.getDevToolsTarget"; }
631
632impl crate::CdpCommand for GetDevToolsTargetParams {
633    const METHOD: &'static str = "Target.getDevToolsTarget";
634    type Response = GetDevToolsTargetReturns;
635}
636
637/// Opens a DevTools window for the target.
638
639#[derive(Debug, Clone, Serialize, Deserialize, Default)]
640#[serde(rename_all = "camelCase")]
641pub struct OpenDevToolsParams {
642    /// This can be the page or tab target ID.
643
644    pub targetId: TargetID,
645    /// The id of the panel we want DevTools to open initially. Currently
646    /// supported panels are elements, console, network, sources, resources
647    /// and performance.
648
649    #[serde(skip_serializing_if = "Option::is_none")]
650    pub panelId: Option<String>,
651}
652
653/// Opens a DevTools window for the target.
654
655#[derive(Debug, Clone, Serialize, Deserialize, Default)]
656#[serde(rename_all = "camelCase")]
657pub struct OpenDevToolsReturns {
658    /// The targetId of DevTools page target.
659
660    pub targetId: TargetID,
661}
662
663impl OpenDevToolsParams { pub const METHOD: &'static str = "Target.openDevTools"; }
664
665impl crate::CdpCommand for OpenDevToolsParams {
666    const METHOD: &'static str = "Target.openDevTools";
667    type Response = OpenDevToolsReturns;
668}