Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(327)

Side by Side Diff: third_party/WebCore/inspector/Inspector.json

Issue 12319151: WebKit IDL roll. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 {
2 "version": { "major": "1", "minor": "0" },
3 "domains": [{
4 "domain": "Inspector",
5 "hidden": true,
6 "types": [],
7 "commands": [
8 {
9 "name": "enable",
10 "description": "Enables inspector domain notifications."
11 },
12 {
13 "name": "disable",
14 "description": "Disables inspector domain notifications."
15 }
16 ],
17 "events": [
18 {
19 "name": "evaluateForTestInFrontend",
20 "parameters": [
21 { "name": "testCallId", "type": "integer" },
22 { "name": "script", "type": "string" }
23 ]
24 },
25 {
26 "name": "inspect",
27 "parameters": [
28 { "name": "object", "$ref": "Runtime.RemoteObject" },
29 { "name": "hints", "type": "object" }
30 ]
31 },
32 {
33 "name": "detached",
34 "description": "Fired when remote debugging connection is about to be terminated. Contains detach reason.",
35 "parameters": [
36 { "name": "reason", "type": "string", "description": "The re ason why connection has been terminated." }
37 ]
38 }
39 ]
40 },
41 {
42 "domain": "Memory",
43 "hidden": true,
44 "types": [
45 {
46 "id": "MemoryBlock",
47 "type": "object",
48 "properties": [
49 { "name": "size", "type": "number", "optional": true, "descr iption": "Size of the block in bytes if available" },
50 { "name": "name", "type": "string", "description": "Unique n ame used to identify the component that allocated this block" },
51 { "name": "children", "type": "array", "optional": true, "it ems": { "$ref": "MemoryBlock" }}
52 ]
53 },
54 {
55 "id": "HeapSnapshotChunk",
56 "type": "object",
57 "properties": [
58 { "name": "strings", "type": "array", "items": { "type": "st ring" }, "description": "An array of strings that were found since last update." },
59 { "name": "nodes", "type": "array", "items": { "type": "inte ger" }, "description": "An array of nodes that were found since last update." },
60 { "name": "edges", "type": "array", "items": { "type": "inte ger" }, "description": "An array of edges that were found since last update." },
61 { "name": "baseToRealNodeId", "type": "array", "items": { "t ype": "integer" }, "description": "An array of integers for nodeId remapping. Ev en nodeId has to be mapped to the following odd nodeId." }
62 ]
63 }
64 ],
65 "commands": [
66 {
67 "name": "getDOMCounters",
68 "returns": [
69 { "name": "documents", "type": "integer" },
70 { "name": "nodes", "type": "integer" },
71 { "name": "jsEventListeners", "type": "integer" }
72 ]
73 },
74 {
75 "name": "getProcessMemoryDistribution",
76 "parameters": [
77 { "name": "reportGraph", "type": "boolean", "optional": true , "description": "Whether native memory graph should be reported in addition to aggregated statistics." }
78 ],
79 "returns": [
80 { "name": "distribution", "$ref": "MemoryBlock", "descriptio n": "An object describing all memory allocated by the process"},
81 { "name": "graphMetaInformation", "type": "object", "optiona l": true, "description": "An object describing structures of nodes and edges in the graph."}
82 ]
83 }
84 ],
85 "events": [
86 {
87 "name": "addNativeSnapshotChunk",
88 "parameters": [
89 { "name": "chunk", "$ref": "HeapSnapshotChunk", "description ": "A chunk of the serialized the snapshot." }
90 ]
91 }
92 ]
93 },
94 {
95 "domain": "Page",
96 "description": "Actions and events related to the inspected page belong to the page domain.",
97 "types": [
98 {
99 "id": "ResourceType",
100 "type": "string",
101 "enum": ["Document", "Stylesheet", "Image", "Font", "Script", "X HR", "WebSocket", "Other"],
102 "description": "Resource type as it was perceived by the renderi ng engine."
103 },
104 {
105 "id": "Frame",
106 "type": "object",
107 "description": "Information about the Frame on the page.",
108 "properties": [
109 { "name": "id", "type": "string", "description": "Frame uniq ue identifier." },
110 { "name": "parentId", "type": "string", "optional": true, "d escription": "Parent frame identifier." },
111 { "name": "loaderId", "$ref": "Network.LoaderId", "descripti on": "Identifier of the loader associated with this frame." },
112 { "name": "name", "type": "string", "optional": true, "descr iption": "Frame's name as specified in the tag." },
113 { "name": "url", "type": "string", "description": "Frame doc ument's URL." },
114 { "name": "securityOrigin", "type": "string", "optional": tr ue, "description": "Frame document's security origin." },
115 { "name": "mimeType", "type": "string", "description": "Fram e document's mimeType as determined by the browser." }
116 ],
117 "hidden": true
118 },
119 {
120 "id": "FrameResourceTree",
121 "type": "object",
122 "description": "Information about the Frame hierarchy along with their cached resources.",
123 "properties": [
124 { "name": "frame", "$ref": "Frame", "description": "Frame in formation for this tree item." },
125 { "name": "childFrames", "type": "array", "optional": true, "items": { "$ref": "FrameResourceTree" }, "description": "Child frames." },
126 { "name": "resources", "type": "array",
127 "items": {
128 "type": "object",
129 "properties": [
130 { "name": "url", "type": "string", "description" : "Resource URL." },
131 { "name": "type", "$ref": "ResourceType", "descr iption": "Type of this resource." },
132 { "name": "mimeType", "type": "string", "descrip tion": "Resource mimeType as determined by the browser." },
133 { "name": "failed", "type": "boolean", "optional ": true, "description": "True if the resource failed to load." },
134 { "name": "canceled", "type": "boolean", "option al": true, "description": "True if the resource was canceled during loading." }
135 ]
136 },
137 "description": "Information about frame resources."
138 }
139 ],
140 "hidden": true
141 },
142 {
143 "id": "SearchMatch",
144 "type": "object",
145 "description": "Search match for resource.",
146 "properties": [
147 { "name": "lineNumber", "type": "number", "description": "Li ne number in resource content." },
148 { "name": "lineContent", "type": "string", "description": "L ine with match content." }
149 ],
150 "hidden": true
151 },
152 {
153 "id": "SearchResult",
154 "type": "object",
155 "description": "Search result for resource.",
156 "properties": [
157 { "name": "url", "type": "string", "description": "Resource URL." },
158 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Resource frame id." },
159 { "name": "matchesCount", "type": "number", "description": " Number of matches in the resource content." }
160 ],
161 "hidden": true
162 },
163 {
164 "id": "Cookie",
165 "type": "object",
166 "description": "Cookie object",
167 "properties": [
168 { "name": "name", "type": "string", "description": "Cookie n ame." },
169 { "name": "value", "type": "string", "description": "Cookie value." },
170 { "name": "domain", "type": "string", "description": "Cookie domain." },
171 { "name": "path", "type": "string", "description": "Cookie p ath." },
172 { "name": "expires", "type": "number", "description": "Cooki e expires." },
173 { "name": "size", "type": "integer", "description": "Cookie size." },
174 { "name": "httpOnly", "type": "boolean", "description": "Tru e if cookie is http-only." },
175 { "name": "secure", "type": "boolean", "description": "True if cookie is secure." },
176 { "name": "session", "type": "boolean", "description": "True in case of session cookie." }
177 ],
178 "hidden": true
179 },
180 {
181 "id": "ScriptIdentifier",
182 "type": "string",
183 "description": "Unique script identifier.",
184 "hidden": true
185 }
186 ],
187 "commands": [
188 {
189 "name": "enable",
190 "description": "Enables page domain notifications."
191 },
192 {
193 "name": "disable",
194 "description": "Disables page domain notifications."
195 },
196 {
197 "name": "addScriptToEvaluateOnLoad",
198 "parameters": [
199 { "name": "scriptSource", "type": "string" }
200 ],
201 "returns": [
202 { "name": "identifier", "$ref": "ScriptIdentifier", "descrip tion": "Identifier of the added script." }
203 ],
204 "hidden": true
205 },
206 {
207 "name": "removeScriptToEvaluateOnLoad",
208 "parameters": [
209 { "name": "identifier", "$ref": "ScriptIdentifier" }
210 ],
211 "hidden": true
212 },
213 {
214 "name": "reload",
215 "parameters": [
216 { "name": "ignoreCache", "type": "boolean", "optional": true , "description": "If true, browser cache is ignored (as if the user pressed Shif t+refresh)." },
217 { "name": "scriptToEvaluateOnLoad", "type": "string", "optio nal": true, "description": "If set, the script will be injected into all frames of the inspected page after reload." },
218 { "name": "scriptPreprocessor", "type": "string", "optional" : true, "description": "Script body that should evaluate to function that will p reprocess all the scripts before their compilation.", "hidden": true }
219 ],
220 "description": "Reloads given page optionally ignoring the cache ."
221 },
222 {
223 "name": "navigate",
224 "parameters": [
225 { "name": "url", "type": "string", "description": "URL to na vigate the page to." }
226 ],
227 "description": "Navigates current page to the given URL."
228 },
229 {
230 "name": "getCookies",
231 "returns": [
232 { "name": "cookies", "type": "array", "items": { "$ref": "Co okie"}, "description": "Array of cookie objects." },
233 { "name": "cookiesString", "type": "string", "description": "document.cookie string representation of the cookies." }
234 ],
235 "description": "Returns all browser cookies. Depending on the ba ckend support, will either return detailed cookie information in the <code>cooki e</code> field or string cookie representation using <code>cookieString</code>." ,
236 "hidden": true
237 },
238 {
239 "name": "deleteCookie",
240 "parameters": [
241 { "name": "cookieName", "type": "string", "description": "Na me of the cookie to remove." },
242 { "name": "url", "type": "string", "description": "URL to ma tch cooke domain and path." }
243 ],
244 "description": "Deletes browser cookie with given name, domain a nd path.",
245 "hidden": true
246 },
247 {
248 "name": "getResourceTree",
249 "description": "Returns present frame / resource tree structure. ",
250 "returns": [
251 { "name": "frameTree", "$ref": "FrameResourceTree", "descrip tion": "Present frame / resource tree structure." }
252 ],
253 "hidden": true
254 },
255 {
256 "name": "getResourceContent",
257 "description": "Returns content of the given resource.",
258 "parameters": [
259 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id to get resource for." },
260 { "name": "url", "type": "string", "description": "URL of th e resource to get content for." }
261 ],
262 "returns": [
263 { "name": "content", "type": "string", "description": "Resou rce content." },
264 { "name": "base64Encoded", "type": "boolean", "description": "True, if content was served as base64." }
265 ],
266 "hidden": true
267 },
268 {
269 "name": "searchInResource",
270 "description": "Searches for given string in resource content.",
271 "parameters": [
272 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id for resource to search in." },
273 { "name": "url", "type": "string", "description": "URL of th e resource to search in." },
274 { "name": "query", "type": "string", "description": "String to search for." },
275 { "name": "caseSensitive", "type": "boolean", "optional": tr ue, "description": "If true, search is case sensitive." },
276 { "name": "isRegex", "type": "boolean", "optional": true, "d escription": "If true, treats string parameter as regex." }
277 ],
278 "returns": [
279 { "name": "result", "type": "array", "items": { "$ref": "Sea rchMatch" }, "description": "List of search matches." }
280 ],
281 "hidden": true
282 },
283 {
284 "name": "searchInResources",
285 "description": "Searches for given string in frame / resource tr ee structure.",
286 "parameters": [
287 { "name": "text", "type": "string", "description": "String t o search for." },
288 { "name": "caseSensitive", "type": "boolean", "optional": tr ue, "description": "If true, search is case sensitive." },
289 { "name": "isRegex", "type": "boolean", "optional": true, "d escription": "If true, treats string parameter as regex." }
290 ],
291 "returns": [
292 { "name": "result", "type": "array", "items": { "$ref": "Sea rchResult" }, "description": "List of search results." }
293 ],
294 "hidden": true
295 },
296 {
297 "name": "setDocumentContent",
298 "description": "Sets given markup as the document's HTML.",
299 "parameters": [
300 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id to set HTML for." },
301 { "name": "html", "type": "string", "description": "HTML con tent to set." }
302 ],
303 "hidden": true
304 },
305 {
306 "name": "canOverrideDeviceMetrics",
307 "description": "Checks whether <code>setDeviceMetricsOverride</c ode> can be invoked.",
308 "returns": [
309 { "name": "result", "type": "boolean", "description": "If tr ue, <code>setDeviceMetricsOverride</code> can safely be invoked on the agent." }
310 ],
311 "hidden": true
312 },
313 {
314 "name": "setDeviceMetricsOverride",
315 "description": "Overrides the values of device screen dimensions (window.screen.width, window.screen.height, window.innerWidth, window.innerHeig ht, and \"device-width\"/\"device-height\"-related CSS media query results) and the font scale factor.",
316 "parameters": [
317 { "name": "width", "type": "integer", "description": "Overri ding width value in pixels (minimum 0, maximum 10000000). 0 disables the overrid e." },
318 { "name": "height", "type": "integer", "description": "Overr iding height value in pixels (minimum 0, maximum 10000000). 0 disables the overr ide." },
319 { "name": "fontScaleFactor", "type": "number", "description" : "Overriding font scale factor value (must be positive). 1 disables the overrid e." },
320 { "name": "fitWindow", "type": "boolean", "description": "Wh ether a view that exceeds the available browser window area should be scaled dow n to fit." }
321 ],
322 "hidden": true
323 },
324 {
325 "name": "setShowPaintRects",
326 "description": "Requests that backend shows paint rectangles",
327 "parameters": [
328 { "name": "result", "type": "boolean", "description": "True for showing paint rectangles" }
329 ],
330 "hidden": true
331 },
332 {
333 "name": "canShowDebugBorders",
334 "description": "Tells if backend supports debug borders on layer s",
335 "returns": [
336 { "name": "show", "type": "boolean", "description": "True if the debug borders can be shown" }
337 ],
338 "hidden": true
339 },
340 {
341 "name": "setShowDebugBorders",
342 "description": "Requests that backend shows debug borders on lay ers",
343 "parameters": [
344 { "name": "show", "type": "boolean", "description": "True fo r showing debug borders" }
345 ],
346 "hidden": true
347 },
348 {
349 "name": "canShowFPSCounter",
350 "description": "Tells if backend supports a FPS counter display" ,
351 "returns": [
352 { "name": "show", "type": "boolean", "description": "True if the FPS count can be shown" }
353 ],
354 "hidden": true
355 },
356 {
357 "name": "setShowFPSCounter",
358 "description": "Requests that backend shows the FPS counter",
359 "parameters": [
360 { "name": "show", "type": "boolean", "description": "True fo r showing the FPS counter" }
361 ],
362 "hidden": true
363 },
364 {
365 "name": "canContinuouslyPaint",
366 "description": "Tells if backend supports continuous painting",
367 "returns": [
368 { "name": "value", "type": "boolean", "description": "True i f continuous painting is available" }
369 ],
370 "hidden": true
371 },
372 {
373 "name": "setContinuousPaintingEnabled",
374 "description": "Requests that backend enables continuous paintin g",
375 "parameters": [
376 { "name": "enabled", "type": "boolean", "description": "True for enabling cointinuous painting" }
377 ],
378 "hidden": true
379 },
380 {
381 "name": "getScriptExecutionStatus",
382 "description": "Determines if scripts can be executed in the pag e.",
383 "returns": [
384 { "name": "result", "type": "string", "enum": ["allowed", "d isabled", "forbidden"], "description": "Script execution status: \"allowed\" if scripts can be executed, \"disabled\" if script execution has been disabled thro ugh page settings, \"forbidden\" if script execution for the given page is not p ossible for other reasons." }
385 ]
386 },
387 {
388 "name": "setScriptExecutionDisabled",
389 "description": "Switches script execution in the page.",
390 "parameters": [
391 { "name": "value", "type": "boolean", "description": "Whethe r script execution should be disabled in the page." }
392 ]
393 },
394 {
395 "name": "setGeolocationOverride",
396 "description": "Overrides the Geolocation Position or Error.",
397 "parameters": [
398 { "name": "latitude", "type": "number", "optional": true, "d escription": "Mock longitude"},
399 { "name": "longitude", "type": "number", "optional": true, " description": "Mock latitude"},
400 { "name": "accuracy", "type": "number", "optional": true, "d escription": "Mock accuracy"}
401 ],
402 "hidden": true
403 },
404 {
405 "name": "clearGeolocationOverride",
406 "description": "Clears the overriden Geolocation Position and Er ror.",
407 "hidden": true
408 },
409 {
410 "name": "canOverrideGeolocation",
411 "description": "Checks if Geolocation can be overridden.",
412 "returns": [
413 { "name": "result", "type": "boolean", "description": "True if browser can ovrride Geolocation." }
414 ],
415 "hidden": true
416 },
417 {
418 "name": "setDeviceOrientationOverride",
419 "description": "Overrides the Device Orientation.",
420 "parameters": [
421 { "name": "alpha", "type": "number", "description": "Mock al pha"},
422 { "name": "beta", "type": "number", "description": "Mock bet a"},
423 { "name": "gamma", "type": "number", "description": "Mock ga mma"}
424 ],
425 "hidden": true
426 },
427 {
428 "name": "clearDeviceOrientationOverride",
429 "description": "Clears the overridden Device Orientation.",
430 "hidden": true
431 },
432 {
433 "name": "canOverrideDeviceOrientation",
434 "description": "Check the backend if Web Inspector can override the device orientation.",
435 "returns": [
436 { "name": "result", "type": "boolean", "description": "If tr ue, <code>setDeviceOrientationOverride</code> can safely be invoked on the agent ." }
437 ],
438 "hidden": true
439 },
440 {
441 "name": "setTouchEmulationEnabled",
442 "parameters": [
443 { "name": "enabled", "type": "boolean", "description": "Whet her the touch event emulation should be enabled." }
444 ],
445 "description": "Toggles mouse event-based touch event emulation. ",
446 "hidden": true
447 },
448 {
449 "name": "setEmulatedMedia",
450 "parameters": [
451 { "name": "media", "type": "string", "description": "Media t ype to emulate. Empty string disables the override." }
452 ],
453 "description": "Emulates the given media for CSS media queries." ,
454 "hidden": true
455 },
456 {
457 "name": "getCompositingBordersVisible",
458 "description": "Indicates the visibility of compositing borders. ",
459 "returns": [
460 { "name": "result", "type": "boolean", "description": "If tr ue, compositing borders are visible." }
461 ],
462 "hidden": true
463 },
464 {
465 "name": "setCompositingBordersVisible",
466 "description": "Controls the visibility of compositing borders." ,
467 "parameters": [
468 { "name": "visible", "type": "boolean", "description": "True for showing compositing borders." }
469 ],
470 "hidden": true
471 },
472 {
473 "name": "captureScreenshot",
474 "description": "Capture page screenshot.",
475 "returns": [
476 { "name": "data", "type": "string", "description": "Base64-e ncoded image data (PNG)." }
477 ],
478 "hidden": true
479 },
480 {
481 "name": "handleJavaScriptDialog",
482 "description": "Accepts or dismisses a JavaScript initiated dial og (alert, confirm, prompt, or onbeforeunload).",
483 "parameters": [
484 { "name": "accept", "type": "boolean", "description": "Wheth er to accept or dismiss the dialog." }
485 ],
486 "hidden": true
487 }
488 ],
489 "events": [
490 {
491 "name": "domContentEventFired",
492 "parameters": [
493 { "name": "timestamp", "type": "number" }
494 ]
495 },
496 {
497 "name": "loadEventFired",
498 "parameters": [
499 { "name": "timestamp", "type": "number" }
500 ]
501 },
502 {
503 "name": "frameNavigated",
504 "description": "Fired once navigation of the frame has completed . Frame is now associated with the new loader.",
505 "parameters": [
506 { "name": "frame", "$ref": "Frame", "description": "Frame ob ject." }
507 ],
508 "hidden": true
509 },
510 {
511 "name": "frameDetached",
512 "description": "Fired when frame has been detached from its pare nt.",
513 "parameters": [
514 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the frame that has been detached." }
515 ],
516 "hidden": true
517 },
518 {
519 "name": "frameStartedLoading",
520 "description": "Fired when frame has started loading.",
521 "parameters": [
522 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the frame that has started loading." }
523 ],
524 "hidden": true
525 },
526 {
527 "name": "frameStoppedLoading",
528 "description": "Fired when frame has stopped loading.",
529 "parameters": [
530 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the frame that has stopped loading." }
531 ],
532 "hidden": true
533 },
534 {
535 "name": "frameScheduledNavigation",
536 "description": "Fired when frame schedules a potential navigatio n.",
537 "parameters": [
538 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the frame that has scheduled a navigation." },
539 { "name": "delay", "type": "number", "description": "Delay ( in seconds) until the navigation is scheduled to begin. The navigation is not gu aranteed to start." }
540 ],
541 "hidden": true
542 },
543 {
544 "name": "frameClearedScheduledNavigation",
545 "description": "Fired when frame no longer has a scheduled navig ation.",
546 "parameters": [
547 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the frame that has cleared its scheduled navigation." }
548 ],
549 "hidden": true
550 },
551 {
552 "name": "javascriptDialogOpening",
553 "description": "Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) is about to open.",
554 "parameters": [
555 { "name": "message", "type": "string", "description": "Messa ge that will be displayed by the dialog." }
556 ],
557 "hidden": true
558 },
559 {
560 "name": "javascriptDialogClosed",
561 "description": "Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) has been closed.",
562 "hidden": true
563 },
564 {
565 "name": "scriptsEnabled",
566 "description": "Fired when the JavaScript is enabled/disabled on the page",
567 "parameters": [
568 { "name": "isEnabled", "type": "boolean", "description": "Wh ether script execution is enabled or disabled on the page." }
569 ],
570 "hidden": true
571 }
572 ]
573 },
574 {
575 "domain": "Runtime",
576 "description": "Runtime domain exposes JavaScript runtime by means of re mote evaluation and mirror objects. Evaluation results are returned as mirror ob ject that expose object type, string representation and unique identifier that c an be used for further object reference. Original objects are maintained in memo ry unless they are either explicitly released or are released along with the oth er objects in their object group.",
577 "types": [
578 {
579 "id": "RemoteObjectId",
580 "type": "string",
581 "description": "Unique object identifier."
582 },
583 {
584 "id": "RemoteObject",
585 "type": "object",
586 "description": "Mirror object referencing original JavaScript ob ject.",
587 "properties": [
588 { "name": "type", "type": "string", "enum": ["object", "func tion", "undefined", "string", "number", "boolean"], "description": "Object type. " },
589 { "name": "subtype", "type": "string", "optional": true, "en um": ["array", "null", "node", "regexp", "date"], "description": "Object subtype hint. Specified for <code>object</code> type values only." },
590 { "name": "className", "type": "string", "optional": true, " description": "Object class (constructor) name. Specified for <code>object</code > type values only." },
591 { "name": "value", "type": "any", "optional": true, "descrip tion": "Remote object value (in case of primitive values or JSON values if it wa s requested)." },
592 { "name": "description", "type": "string", "optional": true, "description": "String representation of the object." },
593 { "name": "objectId", "$ref": "RemoteObjectId", "optional": true, "description": "Unique object identifier (for non-primitive values)." },
594 { "name": "preview", "$ref": "ObjectPreview", "optional": tr ue, "description": "Preview containsing abbreviated property values.", "hidden": true }
595 ]
596 },
597 {
598 "id": "ObjectPreview",
599 "type": "object",
600 "hidden": true,
601 "description": "Object containing abbreviated remote object valu e.",
602 "properties": [
603 { "name": "lossless", "type": "boolean", "description": "Det ermines whether preview is lossless (contains all information of the original ob ject)." },
604 { "name": "overflow", "type": "boolean", "description": "Tru e iff some of the properties of the original did not fit." },
605 { "name": "properties", "type": "array", "items": { "$ref": "PropertyPreview" }, "description": "List of the properties." }
606 ]
607 },
608 {
609 "id": "PropertyPreview",
610 "type": "object",
611 "hidden": true,
612 "properties": [
613 { "name": "name", "type": "string", "description": "Property name." },
614 { "name": "type", "type": "string", "enum": ["object", " function", "undefined", "string", "number", "boolean"], "description": "Object t ype." },
615 { "name": "value", "type": "string", "optional": true, " description": "User-friendly property value string." },
616 { "name": "valuePreview", "$ref": "ObjectPreview", "opti onal": true, "description": "Nested value preview." },
617 { "name": "subtype", "type": "string", "optional": true, "enum": ["array", "null", "node", "regexp", "date"], "description": "Object sub type hint. Specified for <code>object</code> type values only." }
618 ]
619 },
620 {
621 "id": "PropertyDescriptor",
622 "type": "object",
623 "description": "Object property descriptor.",
624 "properties": [
625 { "name": "name", "type": "string", "description": "Property name." },
626 { "name": "value", "$ref": "RemoteObject", "optional": true, "description": "The value associated with the property." },
627 { "name": "writable", "type": "boolean", "optional": true, " description": "True if the value associated with the property may be changed (da ta descriptors only)." },
628 { "name": "get", "$ref": "RemoteObject", "optional": true, " description": "A function which serves as a getter for the property, or <code>un defined</code> if there is no getter (accessor descriptors only)." },
629 { "name": "set", "$ref": "RemoteObject", "optional": true, " description": "A function which serves as a setter for the property, or <code>un defined</code> if there is no setter (accessor descriptors only)." },
630 { "name": "configurable", "type": "boolean", "description": "True if the type of this property descriptor may be changed and if the property may be deleted from the corresponding object." },
631 { "name": "enumerable", "type": "boolean", "description": "T rue if this property shows up during enumeration of the properties on the corres ponding object." },
632 { "name": "wasThrown", "type": "boolean", "optional": true, "description": "True if the result was thrown during the evaluation." },
633 { "name": "isOwn", "optional": true, "type": "boolean", "des cription": "True if the property is owned for the object." }
634
635 ]
636 },
637 {
638 "id": "InternalPropertyDescriptor",
639 "type": "object",
640 "description": "Object internal property descriptor. This proper ty isn't normally visible in JavaScript code.",
641 "properties": [
642 { "name": "name", "type": "string", "description": "Conventi onal property name." },
643 { "name": "value", "$ref": "RemoteObject", "optional": true, "description": "The value associated with the property." }
644 ]
645 },
646 {
647 "id": "CallArgument",
648 "type": "object",
649 "description": "Represents function call argument. Either remote object id <code>objectId</code> or primitive <code>value</code> or neither of ( for undefined) them should be specified.",
650 "properties": [
651 { "name": "value", "type": "any", "optional": true, "descrip tion": "Primitive value." },
652 { "name": "objectId", "$ref": "RemoteObjectId", "optional": true, "description": "Remote object handle." }
653 ]
654 },
655 {
656 "id": "ExecutionContextId",
657 "type": "integer",
658 "description": "Id of an execution context.",
659 "hidden": true
660 },
661 {
662 "id": "ExecutionContextDescription",
663 "type": "object",
664 "description": "Description of an isolated world.",
665 "properties": [
666 { "name": "id", "$ref": "ExecutionContextId", "description": "Unique id of the execution context. It can be used to specify in which executi on context script evaluation should be performed." },
667 { "name": "isPageContext", "type": "boolean", "description": "True if this is a context where inpspected web page scripts run. False if it i s a content script isolated context." },
668 { "name": "name", "type": "string", "description": "Human re adable name describing given context." },
669 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Id of the owning frame." }
670 ],
671 "hidden": true
672 }
673
674 ],
675 "commands": [
676 {
677 "name": "evaluate",
678 "parameters": [
679 { "name": "expression", "type": "string", "description": "Ex pression to evaluate." },
680 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple object s." },
681 { "name": "includeCommandLineAPI", "type": "boolean", "optio nal": true, "description": "Determines whether Command Line API should be availa ble during the evaluation.", "hidden": true },
682 { "name": "doNotPauseOnExceptionsAndMuteConsole", "type": "b oolean", "optional": true, "description": "Specifies whether evaluation should s top on exceptions and mute console. Overrides setPauseOnException state.", "hidd en": true },
683 { "name": "contextId", "$ref": "Runtime.ExecutionContextId", "optional": true, "description": "Specifies in which isolated context to perfor m evaluation. Each content script lives in an isolated context and this paramete r may be used to specify one of those contexts. If the parameter is omitted or 0 the evaluation will be performed in the context of the inspected page.", "hidde n": true },
684 { "name": "returnByValue", "type": "boolean", "optional": tr ue, "description": "Whether the result is expected to be a JSON object that shou ld be sent by value." },
685 { "name": "generatePreview", "type": "boolean", "optional": true, "hidden": true, "description": "Whether preview should be generated for th e result." }
686 ],
687 "returns": [
688 { "name": "result", "$ref": "RemoteObject", "description": " Evaluation result." },
689 { "name": "wasThrown", "type": "boolean", "optional": true, "description": "True if the result was thrown during the evaluation." }
690 ],
691 "description": "Evaluates expression on global object."
692 },
693 {
694 "name": "callFunctionOn",
695 "parameters": [
696 { "name": "objectId", "$ref": "RemoteObjectId", "description ": "Identifier of the object to call function on." },
697 { "name": "functionDeclaration", "type": "string", "descript ion": "Declaration of the function to call." },
698 { "name": "arguments", "type": "array", "items": { "$ref": " CallArgument", "description": "Call argument." }, "optional": true, "description ": "Call arguments. All call arguments must belong to the same JavaScript world as the target object." },
699 { "name": "doNotPauseOnExceptionsAndMuteConsole", "type": "b oolean", "optional": true, "description": "Specifies whether function call shoul d stop on exceptions and mute console. Overrides setPauseOnException state.", "h idden": true },
700 { "name": "returnByValue", "type": "boolean", "optional": tr ue, "description": "Whether the result is expected to be a JSON object which sho uld be sent by value." },
701 { "name": "generatePreview", "type": "boolean", "optional": true, "hidden": true, "description": "Whether preview should be generated for th e result." }
702 ],
703 "returns": [
704 { "name": "result", "$ref": "RemoteObject", "description": " Call result." },
705 { "name": "wasThrown", "type": "boolean", "optional": true, "description": "True if the result was thrown during the evaluation." }
706 ],
707 "description": "Calls function with given declaration on the giv en object. Object group of the result is inherited from the target object."
708 },
709 {
710 "name": "getProperties",
711 "parameters": [
712 { "name": "objectId", "$ref": "RemoteObjectId", "description ": "Identifier of the object to return properties for." },
713 { "name": "ownProperties", "optional": true, "type": "boolea n", "description": "If true, returns properties belonging only to the element it self, not to its prototype chain." }
714 ],
715 "returns": [
716 { "name": "result", "type": "array", "items": { "$ref": "Pro pertyDescriptor"}, "description": "Object properties." },
717 { "name": "internalProperties", "optional": true, "type": "a rray", "items": { "$ref": "InternalPropertyDescriptor"}, "description": "Interna l object properties." }
718 ],
719 "description": "Returns properties of a given object. Object gro up of the result is inherited from the target object."
720 },
721 {
722 "name": "releaseObject",
723 "parameters": [
724 { "name": "objectId", "$ref": "RemoteObjectId", "description ": "Identifier of the object to release." }
725 ],
726 "description": "Releases remote object with given id."
727 },
728 {
729 "name": "releaseObjectGroup",
730 "parameters": [
731 { "name": "objectGroup", "type": "string", "description": "S ymbolic object group name." }
732 ],
733 "description": "Releases all remote objects that belong to a giv en group."
734 },
735 {
736 "name": "run",
737 "hidden": true,
738 "description": "Tells inspected instance(worker or page) that it can run in case it was started paused."
739 },
740 {
741 "name": "enable",
742 "hidden": true,
743 "description": "Enables reporting of execution contexts creation by means of <code>executionContextCreated</code> event. When the reporting gets enabled the event will be sent immediately for each existing execution context. "
744 },
745 {
746 "name": "disable",
747 "hidden": true,
748 "description": "Disables reporting of execution contexts creatio n."
749 }
750 ],
751 "events": [
752 {
753 "name": "executionContextCreated",
754 "parameters": [
755 { "name": "context", "$ref": "ExecutionContextDescription", "description": "A newly created execution contex." }
756 ],
757 "hidden": true,
758 "description": "Issued when new execution context is created."
759 }
760 ]
761 },
762 {
763 "domain": "Console",
764 "description": "Console domain defines methods and events for interactio n with the JavaScript console. Console collects messages created by means of the <a href='http://getfirebug.com/wiki/index.php/Console_API'>JavaScript Console A PI</a>. One needs to enable this domain using <code>enable</code> command in ord er to start receiving the console messages. Browser collects messages issued whi le console domain is not enabled as well and reports them using <code>messageAdd ed</code> notification upon enabling.",
765 "types": [
766 {
767 "id": "ConsoleMessage",
768 "type": "object",
769 "description": "Console message.",
770 "properties": [
771 { "name": "source", "type": "string", "enum": ["html", "wml" , "xml", "javascript", "network", "console-api", "other"], "description": "Messa ge source." },
772 { "name": "level", "type": "string", "enum": ["tip", "log", "warning", "error", "debug"], "description": "Message severity." },
773 { "name": "text", "type": "string", "description": "Message text." },
774 { "name": "type", "type": "string", "optional": true, "enum" : ["log", "dir", "dirxml", "table", "trace", "clear", "startGroup", "startGroupC ollapsed", "endGroup", "assert", "timing", "profile", "profileEnd"], "descriptio n": "Console message type." },
775 { "name": "url", "type": "string", "optional": true, "descri ption": "URL of the message origin." },
776 { "name": "line", "type": "integer", "optional": true, "desc ription": "Line number in the resource that generated this message." },
777 { "name": "repeatCount", "type": "integer", "optional": true , "description": "Repeat count for repeated messages." },
778 { "name": "parameters", "type": "array", "items": { "$ref": "Runtime.RemoteObject" }, "optional": true, "description": "Message parameters i n case of the formatted message." },
779 { "name": "stackTrace", "$ref": "StackTrace", "optional": tr ue, "description": "JavaScript stack trace for assertions and error messages." } ,
780 { "name": "networkRequestId", "$ref": "Network.RequestId", " optional": true, "description": "Identifier of the network request associated wi th this message." }
781 ]
782 },
783 {
784 "id": "CallFrame",
785 "type": "object",
786 "description": "Stack entry for console errors and assertions.",
787 "properties": [
788 { "name": "functionName", "type": "string", "description": " JavaScript function name." },
789 { "name": "url", "type": "string", "description": "JavaScrip t script name or url." },
790 { "name": "lineNumber", "type": "integer", "description": "J avaScript script line number." },
791 { "name": "columnNumber", "type": "integer", "description": "JavaScript script column number." }
792 ]
793 },
794 {
795 "id": "StackTrace",
796 "type": "array",
797 "items": { "$ref": "CallFrame" },
798 "description": "Call frames for assertions or error messages."
799 }
800 ],
801 "commands": [
802 {
803 "name": "enable",
804 "description": "Enables console domain, sends the messages colle cted so far to the client by means of the <code>messageAdded</code> notification ."
805 },
806 {
807 "name": "disable",
808 "description": "Disables console domain, prevents further consol e messages from being reported to the client."
809 },
810 {
811 "name": "clearMessages",
812 "description": "Clears console messages collected in the browser ."
813 },
814 {
815 "name": "setMonitoringXHREnabled",
816 "parameters": [
817 { "name": "enabled", "type": "boolean", "description": "Moni toring enabled state." }
818 ],
819 "description": "Toggles monitoring of XMLHttpRequest. If <code>t rue</code>, console will receive messages upon each XHR issued.",
820 "hidden": true
821 },
822 {
823 "name": "addInspectedNode",
824 "parameters": [
825 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "DO M node id to be accessible by means of $x command line API." }
826 ],
827 "description": "Enables console to refer to the node with given id via $x (see Command Line API for more details $x functions).",
828 "hidden": true
829 },
830 {
831 "name": "addInspectedHeapObject",
832 "parameters": [
833 { "name": "heapObjectId", "type": "integer" }
834 ]
835 }
836 ],
837 "events": [
838 {
839 "name": "messageAdded",
840 "parameters": [
841 { "name": "message", "$ref": "ConsoleMessage", "description" : "Console message that has been added." }
842 ],
843 "description": "Issued when new console message is added."
844 },
845 {
846 "name": "messageRepeatCountUpdated",
847 "parameters": [
848 { "name": "count", "type": "integer", "description": "New re peat count value." }
849 ],
850 "description": "Issued when subsequent message(s) are equal to t he previous one(s)."
851 },
852 {
853 "name": "messagesCleared",
854 "description": "Issued when console is cleared. This happens eit her upon <code>clearMessages</code> command or after page navigation."
855 }
856 ]
857 },
858 {
859 "domain": "Network",
860 "description": "Network domain allows tracking network activities of the page. It exposes information about http, file, data and other requests and resp onses, their headers, bodies, timing, etc.",
861 "types": [
862 {
863 "id": "LoaderId",
864 "type": "string",
865 "description": "Unique loader identifier."
866 },
867 {
868 "id": "FrameId",
869 "type": "string",
870 "description": "Unique frame identifier.",
871 "hidden": true
872 },
873 {
874 "id": "RequestId",
875 "type": "string",
876 "description": "Unique request identifier."
877 },
878 {
879 "id": "Timestamp",
880 "type": "number",
881 "description": "Number of seconds since epoch."
882 },
883 {
884 "id": "Headers",
885 "type": "object",
886 "description": "Request / response headers as keys / values of J SON object."
887 },
888 {
889 "id": "ResourceTiming",
890 "type": "object",
891 "description": "Timing information for the request.",
892 "properties": [
893 { "name": "requestTime", "type": "number", "description": "T iming's requestTime is a baseline in seconds, while the other numbers are ticks in milliseconds relatively to this requestTime." },
894 { "name": "proxyStart", "type": "number", "description": "St arted resolving proxy." },
895 { "name": "proxyEnd", "type": "number", "description": "Fini shed resolving proxy." },
896 { "name": "dnsStart", "type": "number", "description": "Star ted DNS address resolve." },
897 { "name": "dnsEnd", "type": "number", "description": "Finish ed DNS address resolve." },
898 { "name": "connectStart", "type": "number", "description": " Started connecting to the remote host." },
899 { "name": "connectEnd", "type": "number", "description": "Co nnected to the remote host." },
900 { "name": "sslStart", "type": "number", "description": "Star ted SSL handshake." },
901 { "name": "sslEnd", "type": "number", "description": "Finish ed SSL handshake." },
902 { "name": "sendStart", "type": "number", "description": "Sta rted sending request." },
903 { "name": "sendEnd", "type": "number", "description": "Finis hed sending request." },
904 { "name": "receiveHeadersEnd", "type": "number", "descriptio n": "Finished receiving response headers." }
905 ]
906 },
907 {
908 "id": "Request",
909 "type": "object",
910 "description": "HTTP request data.",
911 "properties": [
912 { "name": "url", "type": "string", "description": "Request U RL." },
913 { "name": "method", "type": "string", "description": "HTTP r equest method." },
914 { "name": "headers", "$ref": "Headers", "description": "HTTP request headers." },
915 { "name": "postData", "type": "string", "optional": true, "d escription": "HTTP POST request data." }
916 ]
917 },
918 {
919 "id": "Response",
920 "type": "object",
921 "description": "HTTP response data.",
922 "properties": [
923 { "name": "url", "type": "string", "description": "Response URL. This URL can be different from CachedResource.url in case of redirect." },
924 { "name": "status", "type": "number", "description": "HTTP r esponse status code." },
925 { "name": "statusText", "type": "string", "description": "HT TP response status text." },
926 { "name": "headers", "$ref": "Headers", "description": "HTTP response headers." },
927 { "name": "headersText", "type": "string", "optional": true, "description": "HTTP response headers text." },
928 { "name": "mimeType", "type": "string", "description": "Reso urce mimeType as determined by the browser." },
929 { "name": "requestHeaders", "$ref": "Headers", "optional": t rue, "description": "Refined HTTP request headers that were actually transmitted over the network." },
930 { "name": "requestHeadersText", "type": "string", "optional" : true, "description": "HTTP request headers text." },
931 { "name": "connectionReused", "type": "boolean", "descriptio n": "Specifies whether physical connection was actually reused for this request. " },
932 { "name": "connectionId", "type": "number", "description": " Physical connection id that was actually used for this request." },
933 { "name": "fromDiskCache", "type": "boolean", "optional": tr ue, "description": "Specifies that the request was served from the disk cache." },
934 { "name": "timing", "$ref": "ResourceTiming", "optional": tr ue, "description": "Timing information for the given request." }
935 ]
936 },
937 {
938 "id": "WebSocketRequest",
939 "type": "object",
940 "description": "WebSocket request data.",
941 "hidden": true,
942 "properties": [
943 { "name": "headers", "$ref": "Headers", "description": "HTTP response headers." }
944 ]
945 },
946 {
947 "id": "WebSocketResponse",
948 "type": "object",
949 "description": "WebSocket response data.",
950 "hidden": true,
951 "properties": [
952 { "name": "status", "type": "number", "description": "HTTP r esponse status code." },
953 { "name": "statusText", "type": "string", "description": "HT TP response status text." },
954 { "name": "headers", "$ref": "Headers", "description": "HTTP response headers." }
955 ]
956 },
957 {
958 "id": "WebSocketFrame",
959 "type": "object",
960 "description": "WebSocket frame data.",
961 "hidden": true,
962 "properties": [
963 { "name": "opcode", "type": "number", "description": "WebSoc ket frame opcode." },
964 { "name": "mask", "type": "boolean", "description": "WebSock e frame mask." },
965 { "name": "payloadData", "type": "string", "description": "W ebSocke frame payload data." }
966 ]
967 },
968 {
969 "id": "CachedResource",
970 "type": "object",
971 "description": "Information about the cached resource.",
972 "properties": [
973 { "name": "url", "type": "string", "description": "Resource URL. This is the url of the original network request." },
974 { "name": "type", "$ref": "Page.ResourceType", "description" : "Type of this resource." },
975 { "name": "response", "$ref": "Response", "optional": true, "description": "Cached response data." },
976 { "name": "bodySize", "type": "number", "description": "Cach ed response body size." }
977 ]
978 },
979 {
980 "id": "Initiator",
981 "type": "object",
982 "description": "Information about the request initiator.",
983 "properties": [
984 { "name": "type", "type": "string", "enum": ["parser", "scri pt", "other"], "description": "Type of this initiator." },
985 { "name": "stackTrace", "$ref": "Console.StackTrace", "optio nal": true, "description": "Initiator JavaScript stack trace, set for Script onl y." },
986 { "name": "url", "type": "string", "optional": true, "descri ption": "Initiator URL, set for Parser type only." },
987 { "name": "lineNumber", "type": "number", "optional": true, "description": "Initiator line number, set for Parser type only." }
988 ]
989 }
990 ],
991 "commands": [
992 {
993 "name": "enable",
994 "description": "Enables network tracking, network events will no w be delivered to the client."
995 },
996 {
997 "name": "disable",
998 "description": "Disables network tracking, prevents network even ts from being sent to the client."
999 },
1000 {
1001 "name": "setUserAgentOverride",
1002 "description": "Allows overriding user agent with the given stri ng.",
1003 "parameters": [
1004 { "name": "userAgent", "type": "string", "description": "Use r agent to use." }
1005 ]
1006 },
1007 {
1008 "name": "setExtraHTTPHeaders",
1009 "description": "Specifies whether to always send extra HTTP head ers with the requests from this page.",
1010 "parameters": [
1011 { "name": "headers", "$ref": "Headers", "description": "Map with extra HTTP headers." }
1012 ]
1013 },
1014 {
1015 "name": "getResponseBody",
1016 "description": "Returns content served for the given request.",
1017 "parameters": [
1018 { "name": "requestId", "$ref": "RequestId", "description": " Identifier of the network request to get content for." }
1019 ],
1020 "returns": [
1021 { "name": "body", "type": "string", "description": "Response body." },
1022 { "name": "base64Encoded", "type": "boolean", "description": "True, if content was sent as base64." }
1023 ]
1024 },
1025 {
1026 "name": "replayXHR",
1027 "description": "This method sends a new XMLHttpRequest which is identical to the original one. The following parameters should be identical: met hod, url, async, request body, extra headers, withCredentials attribute, user, p assword.",
1028 "parameters": [
1029 { "name": "requestId", "$ref": "RequestId", "description": " Identifier of XHR to replay." }
1030 ],
1031 "hidden": true
1032 },
1033 {
1034 "name": "canClearBrowserCache",
1035 "description": "Tells whether clearing browser cache is supporte d.",
1036 "returns": [
1037 { "name": "result", "type": "boolean", "description": "True if browser cache can be cleared." }
1038 ]
1039 },
1040 {
1041 "name": "clearBrowserCache",
1042 "description": "Clears browser cache."
1043 },
1044 {
1045 "name": "canClearBrowserCookies",
1046 "description": "Tells whether clearing browser cookies is suppor ted.",
1047 "returns": [
1048 { "name": "result", "type": "boolean", "description": "True if browser cookies can be cleared." }
1049 ]
1050 },
1051 {
1052 "name": "clearBrowserCookies",
1053 "description": "Clears browser cookies."
1054 },
1055 {
1056 "name": "setCacheDisabled",
1057 "parameters": [
1058 { "name": "cacheDisabled", "type": "boolean", "description": "Cache disabled state." }
1059 ],
1060 "description": "Toggles ignoring cache for each request. If <cod e>true</code>, cache will not be used."
1061 }
1062 ],
1063 "events": [
1064 {
1065 "name": "requestWillBeSent",
1066 "description": "Fired when page is about to send HTTP request.",
1067 "parameters": [
1068 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1069 { "name": "frameId", "$ref": "FrameId", "description": "Fram e identifier.", "hidden": true },
1070 { "name": "loaderId", "$ref": "LoaderId", "description": "Lo ader identifier." },
1071 { "name": "documentURL", "type": "string", "description": "U RL of the document this request is loaded for." },
1072 { "name": "request", "$ref": "Request", "description": "Requ est data." },
1073 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1074 { "name": "initiator", "$ref": "Initiator", "description": " Request initiator." },
1075 { "name": "redirectResponse", "optional": true, "$ref": "Res ponse", "description": "Redirect response data." }
1076 ]
1077 },
1078 {
1079 "name": "requestServedFromCache",
1080 "description": "Fired if request ended up loading from cache.",
1081 "parameters": [
1082 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." }
1083 ]
1084 },
1085 {
1086 "name": "responseReceived",
1087 "description": "Fired when HTTP response is available.",
1088 "parameters": [
1089 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1090 { "name": "frameId", "$ref": "FrameId", "description": "Fram e identifier.", "hidden": true },
1091 { "name": "loaderId", "$ref": "LoaderId", "description": "Lo ader identifier." },
1092 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1093 { "name": "type", "$ref": "Page.ResourceType", "description" : "Resource type." },
1094 { "name": "response", "$ref": "Response", "description": "Re sponse data." }
1095 ]
1096 },
1097 {
1098 "name": "dataReceived",
1099 "description": "Fired when data chunk was received over the netw ork.",
1100 "parameters": [
1101 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1102 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1103 { "name": "dataLength", "type": "integer", "description": "D ata chunk length." },
1104 { "name": "encodedDataLength", "type": "integer", "descripti on": "Actual bytes received (might be less than dataLength for compressed encodi ngs)." }
1105 ]
1106 },
1107 {
1108 "name": "loadingFinished",
1109 "description": "Fired when HTTP request has finished loading.",
1110 "parameters": [
1111 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1112 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." }
1113 ]
1114 },
1115 {
1116 "name": "loadingFailed",
1117 "description": "Fired when HTTP request has failed to load.",
1118 "parameters": [
1119 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1120 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1121 { "name": "errorText", "type": "string", "description": "Use r friendly error message." },
1122 { "name": "canceled", "type": "boolean", "optional": true, " description": "True if loading was canceled." }
1123 ]
1124 },
1125 {
1126 "name": "requestServedFromMemoryCache",
1127 "description": "Fired when HTTP request has been served from mem ory cache.",
1128 "parameters": [
1129 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1130 { "name": "frameId", "$ref": "FrameId", "description": "Fram e identifier.", "hidden": true },
1131 { "name": "loaderId", "$ref": "LoaderId", "description": "Lo ader identifier." },
1132 { "name": "documentURL", "type": "string", "description": "U RL of the document this request is loaded for." },
1133 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1134 { "name": "initiator", "$ref": "Initiator", "description": " Request initiator." },
1135 { "name": "resource", "$ref": "CachedResource", "description ": "Cached resource data." }
1136 ]
1137 },
1138 {
1139 "name": "webSocketWillSendHandshakeRequest",
1140 "description": "Fired when WebSocket is about to initiate handsh ake.",
1141 "parameters": [
1142 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1143 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1144 { "name": "request", "$ref": "WebSocketRequest", "descriptio n": "WebSocket request data." }
1145 ],
1146 "hidden": true
1147 },
1148 {
1149 "name": "webSocketHandshakeResponseReceived",
1150 "description": "Fired when WebSocket handshake response becomes available.",
1151 "parameters": [
1152 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1153 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1154 { "name": "response", "$ref": "WebSocketResponse", "descript ion": "WebSocket response data." }
1155 ],
1156 "hidden": true
1157 },
1158 {
1159 "name": "webSocketCreated",
1160 "description": "Fired upon WebSocket creation.",
1161 "parameters": [
1162 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1163 { "name": "url", "type": "string", "description": "WebSocket request URL." }
1164 ],
1165 "hidden": true
1166 },
1167 {
1168 "name": "webSocketClosed",
1169 "description": "Fired when WebSocket is closed.",
1170 "parameters": [
1171 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1172 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." }
1173 ],
1174 "hidden": true
1175 },
1176 {
1177 "name": "webSocketFrameReceived",
1178 "description": "Fired when WebSocket frame is received.",
1179 "parameters": [
1180 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1181 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1182 { "name": "response", "$ref": "WebSocketFrame", "description ": "WebSocket response data." }
1183 ],
1184 "hidden": true
1185 },
1186 {
1187 "name": "webSocketFrameError",
1188 "description": "Fired when WebSocket frame error occurs.",
1189 "parameters": [
1190 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1191 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1192 { "name": "errorMessage", "type": "string", "description": " WebSocket frame error message." }
1193 ],
1194 "hidden": true
1195 },
1196 {
1197 "name": "webSocketFrameSent",
1198 "description": "Fired when WebSocket frame is sent.",
1199 "parameters": [
1200 { "name": "requestId", "$ref": "RequestId", "description": " Request identifier." },
1201 { "name": "timestamp", "$ref": "Timestamp", "description": " Timestamp." },
1202 { "name": "response", "$ref": "WebSocketFrame", "description ": "WebSocket response data." }
1203 ],
1204 "hidden": true
1205 }
1206 ]
1207 },
1208 {
1209 "domain": "Database",
1210 "hidden": true,
1211 "types": [
1212 {
1213 "id": "DatabaseId",
1214 "type": "string",
1215 "description": "Unique identifier of Database object.",
1216 "hidden": true
1217 },
1218 {
1219 "id": "Database",
1220 "type": "object",
1221 "description": "Database object.",
1222 "hidden": true,
1223 "properties": [
1224 { "name": "id", "$ref": "DatabaseId", "description": "Databa se ID." },
1225 { "name": "domain", "type": "string", "description": "Databa se domain." },
1226 { "name": "name", "type": "string", "description": "Database name." },
1227 { "name": "version", "type": "string", "description": "Datab ase version." }
1228 ]
1229 },
1230 {
1231 "id": "Error",
1232 "type": "object",
1233 "description": "Database error.",
1234 "properties": [
1235 { "name": "message", "type": "string", "description": "Error message." },
1236 { "name": "code", "type": "integer", "description": "Error c ode." }
1237 ]
1238 }
1239 ],
1240 "commands": [
1241 {
1242 "name": "enable",
1243 "description": "Enables database tracking, database events will now be delivered to the client."
1244 },
1245 {
1246 "name": "disable",
1247 "description": "Disables database tracking, prevents database ev ents from being sent to the client."
1248 },
1249 {
1250 "name": "getDatabaseTableNames",
1251 "parameters": [
1252 { "name": "databaseId", "$ref": "DatabaseId" }
1253 ],
1254 "returns": [
1255 { "name": "tableNames", "type": "array", "items": { "type": "string" } }
1256 ]
1257 },
1258 {
1259 "name": "executeSQL",
1260 "async": true,
1261 "parameters": [
1262 { "name": "databaseId", "$ref": "DatabaseId" },
1263 { "name": "query", "type": "string" }
1264 ],
1265 "returns": [
1266 { "name": "columnNames", "type": "array", "optional": true, "items": { "type": "string" } },
1267 { "name": "values", "type": "array", "optional": true, "item s": { "type": "any" }},
1268 { "name": "sqlError", "$ref": "Error", "optional": true }
1269 ]
1270 }
1271 ],
1272 "events": [
1273 {
1274 "name": "addDatabase",
1275 "parameters": [
1276 { "name": "database", "$ref": "Database" }
1277 ]
1278 }
1279 ]
1280 },
1281 {
1282 "domain": "IndexedDB",
1283 "hidden": true,
1284 "types": [
1285 {
1286 "id": "SecurityOriginWithDatabaseNames",
1287 "type": "object",
1288 "description": "Security origin with database names.",
1289 "properties": [
1290 { "name": "securityOrigin", "type": "string", "description": "Security origin." },
1291 { "name": "databaseNames", "type": "array", "items": { "type ": "string" }, "description": "Database names for this origin." }
1292 ]
1293 },
1294 {
1295 "id": "DatabaseWithObjectStores",
1296 "type": "object",
1297 "description": "Database with an array of object stores.",
1298 "properties": [
1299 { "name": "name", "type": "string", "description": "Database name." },
1300 { "name": "version", "type": "string", "description": "Depre cated string database version." },
1301 { "name": "intVersion", "type": "integer", "description": "I nteger database version." },
1302 { "name": "objectStores", "type": "array", "items": { "$ref" : "ObjectStore" }, "description": "Object stores in this database." }
1303 ]
1304 },
1305 {
1306 "id": "ObjectStore",
1307 "type": "object",
1308 "description": "Object store.",
1309 "properties": [
1310 { "name": "name", "type": "string", "description": "Object s tore name." },
1311 { "name": "keyPath", "$ref": "KeyPath", "description": "Obje ct store key path." },
1312 { "name": "autoIncrement", "type": "boolean", "description": "If true, object store has auto increment flag set." },
1313 { "name": "indexes", "type": "array", "items": { "$ref": "Ob jectStoreIndex" }, "description": "Indexes in this object store." }
1314 ]
1315 },
1316 {
1317 "id": "ObjectStoreIndex",
1318 "type": "object",
1319 "description": "Object store index.",
1320 "properties": [
1321 { "name": "name", "type": "string", "description": "Index na me." },
1322 { "name": "keyPath", "$ref": "KeyPath", "description": "Inde x key path." },
1323 { "name": "unique", "type": "boolean", "description": "If tr ue, index is unique." },
1324 { "name": "multiEntry", "type": "boolean", "description": "I f true, index allows multiple entries for a key." }
1325 ]
1326 },
1327 {
1328 "id": "Key",
1329 "type": "object",
1330 "description": "Key.",
1331 "properties": [
1332 { "name": "type", "type": "string", "enum": ["number", "stri ng", "date", "array"], "description": "Key type." },
1333 { "name": "number", "type": "number", "optional": true, "des cription": "Number value." },
1334 { "name": "string", "type": "string", "optional": true, "des cription": "String value." },
1335 { "name": "date", "type": "number", "optional": true, "descr iption": "Date value." },
1336 { "name": "array", "type": "array", "optional": true, "items ": { "$ref": "Key" }, "description": "Array value." }
1337 ]
1338 },
1339 {
1340 "id": "KeyRange",
1341 "type": "object",
1342 "description": "Key range.",
1343 "properties": [
1344 { "name": "lower", "$ref": "Key", "optional": true, "descrip tion": "Lower bound." },
1345 { "name": "upper", "$ref": "Key", "optional": true, "descrip tion": "Upper bound." },
1346 { "name": "lowerOpen", "type": "boolean", "description": "If true lower bound is open." },
1347 { "name": "upperOpen", "type": "boolean", "description": "If true upper bound is open." }
1348 ]
1349 },
1350 {
1351 "id": "DataEntry",
1352 "type": "object",
1353 "description": "Data entry.",
1354 "properties": [
1355 { "name": "key", "$ref": "Runtime.RemoteObject", "descriptio n": "Key." },
1356 { "name": "primaryKey", "$ref": "Runtime.RemoteObject", "des cription": "Primary key." },
1357 { "name": "value", "$ref": "Runtime.RemoteObject", "descript ion": "Value." }
1358 ]
1359 },
1360 {
1361 "id": "KeyPath",
1362 "type": "object",
1363 "description": "Key path.",
1364 "properties": [
1365 { "name": "type", "type": "string", "enum": ["null", "string ", "array"], "description": "Key path type." },
1366 { "name": "string", "type": "string", "optional": true, "des cription": "String value." },
1367 { "name": "array", "type": "array", "optional": true, "items ": { "type": "string" }, "description": "Array value." }
1368 ]
1369 }
1370 ],
1371 "commands": [
1372 {
1373 "name": "enable",
1374 "description": "Enables events from backend."
1375 },
1376 {
1377 "name": "disable",
1378 "description": "Disables events from backend."
1379 },
1380 {
1381 "name": "requestDatabaseNamesForFrame",
1382 "async": true,
1383 "parameters": [
1384 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id." }
1385 ],
1386 "returns": [
1387 { "name": "securityOriginWithDatabaseNames", "$ref": "Securi tyOriginWithDatabaseNames", "description": "Frame with database names." }
1388 ],
1389 "description": "Requests database names for given frame's securi ty origin."
1390 },
1391 {
1392 "name": "requestDatabase",
1393 "async": true,
1394 "parameters": [
1395 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id." },
1396 { "name": "databaseName", "type": "string", "description": " Database name." }
1397 ],
1398 "returns": [
1399 { "name": "databaseWithObjectStores", "$ref": "DatabaseWithO bjectStores", "description": "Database with an array of object stores." }
1400 ],
1401 "description": "Requests database with given name in given frame ."
1402 },
1403 {
1404 "name": "requestData",
1405 "async": true,
1406 "parameters": [
1407 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame id." },
1408 { "name": "databaseName", "type": "string", "description": " Database name." },
1409 { "name": "objectStoreName", "type": "string", "description" : "Object store name." },
1410 { "name": "indexName", "type": "string", "description": "Ind ex name, empty string for object store data requests." },
1411 { "name": "skipCount", "type": "integer", "description": "Nu mber of records to skip." },
1412 { "name": "pageSize", "type": "integer", "description": "Num ber of records to fetch." },
1413 { "name": "keyRange", "$ref": "KeyRange", "optional": true, "description": "Key range." }
1414 ],
1415 "returns": [
1416 { "name": "objectStoreDataEntries", "type": "array", "items" : { "$ref": "DataEntry" }, "description": "Array of object store data entries." },
1417 { "name": "hasMore", "type": "boolean", "description": "If t rue, there are more entries to fetch in the given range." }
1418 ],
1419 "description": "Requests data from object store or index."
1420 }
1421 ]
1422 },
1423 {
1424 "domain": "DOMStorage",
1425 "hidden": true,
1426 "description": "Query and modify DOM storage.",
1427 "types": [
1428 {
1429 "id": "StorageId",
1430 "type": "object",
1431 "description": "DOM Storage identifier.",
1432 "hidden": true,
1433 "properties": [
1434 { "name": "securityOrigin", "type": "string", "description": "Security origin for the storage." },
1435 { "name": "isLocalStorage", "type": "boolean", "description" : "Whether the storage is local storage (not session storage)." }
1436 ]
1437 },
1438 {
1439 "id": "Item",
1440 "type": "array",
1441 "description": "DOM Storage item.",
1442 "hidden": true,
1443 "items": { "type": "string" }
1444 }
1445 ],
1446 "commands": [
1447 {
1448 "name": "enable",
1449 "description": "Enables storage tracking, storage events will no w be delivered to the client."
1450 },
1451 {
1452 "name": "disable",
1453 "description": "Disables storage tracking, prevents storage even ts from being sent to the client."
1454 },
1455 {
1456 "name": "getDOMStorageItems",
1457 "parameters": [
1458 { "name": "storageId", "$ref": "StorageId" }
1459 ],
1460 "returns": [
1461 { "name": "entries", "type": "array", "items": { "$ref": "It em" } }
1462 ]
1463 },
1464 {
1465 "name": "setDOMStorageItem",
1466 "parameters": [
1467 { "name": "storageId", "$ref": "StorageId" },
1468 { "name": "key", "type": "string" },
1469 { "name": "value", "type": "string" }
1470 ]
1471 },
1472 {
1473 "name": "removeDOMStorageItem",
1474 "parameters": [
1475 { "name": "storageId", "$ref": "StorageId" },
1476 { "name": "key", "type": "string" }
1477 ]
1478 }
1479 ],
1480 "events": [
1481 {
1482 "name": "domStorageItemsCleared",
1483 "parameters": [
1484 { "name": "storageId", "$ref": "StorageId" }
1485 ]
1486 },
1487 {
1488 "name": "domStorageItemRemoved",
1489 "parameters": [
1490 { "name": "storageId", "$ref": "StorageId" },
1491 { "name": "key", "type": "string" }
1492 ]
1493 },
1494 {
1495 "name": "domStorageItemAdded",
1496 "parameters": [
1497 { "name": "storageId", "$ref": "StorageId" },
1498 { "name": "key", "type": "string" },
1499 { "name": "newValue", "type": "string" }
1500 ]
1501 },
1502 {
1503 "name": "domStorageItemUpdated",
1504 "parameters": [
1505 { "name": "storageId", "$ref": "StorageId" },
1506 { "name": "key", "type": "string" },
1507 { "name": "oldValue", "type": "string" },
1508 { "name": "newValue", "type": "string" }
1509 ]
1510 }
1511 ]
1512 },
1513 {
1514 "domain": "ApplicationCache",
1515 "hidden": true,
1516 "types": [
1517 {
1518 "id": "ApplicationCacheResource",
1519 "type": "object",
1520 "description": "Detailed application cache resource information. ",
1521 "properties": [
1522 { "name": "url", "type": "string", "description": "Resource url." },
1523 { "name": "size", "type": "integer", "description": "Resourc e size." },
1524 { "name": "type", "type": "string", "description": "Resource type." }
1525 ]
1526 },
1527 {
1528 "id": "ApplicationCache",
1529 "type": "object",
1530 "description": "Detailed application cache information.",
1531 "properties": [
1532 { "name": "manifestURL", "type": "string", "description": "M anifest URL." },
1533 { "name": "size", "type": "number", "description": "Applicat ion cache size." },
1534 { "name": "creationTime", "type": "number", "description": " Application cache creation time." },
1535 { "name": "updateTime", "type": "number", "description": "Ap plication cache update time." },
1536 { "name": "resources", "type": "array", "items": { "$ref": " ApplicationCacheResource" }, "description": "Application cache resources." }
1537 ]
1538 },
1539 {
1540 "id": "FrameWithManifest",
1541 "type": "object",
1542 "description": "Frame identifier - manifest URL pair.",
1543 "properties": [
1544 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Frame identifier." },
1545 { "name": "manifestURL", "type": "string", "description": "M anifest URL." },
1546 { "name": "status", "type": "integer", "description": "Appli cation cache status." }
1547 ]
1548 }
1549 ],
1550 "commands": [
1551 {
1552 "name": "getFramesWithManifests",
1553 "returns": [
1554 { "name": "frameIds", "type": "array", "items": { "$ref": "F rameWithManifest" }, "description": "Array of frame identifiers with manifest ur ls for each frame containing a document associated with some application cache." }
1555 ],
1556 "description": "Returns array of frame identifiers with manifest urls for each frame containing a document associated with some application cach e."
1557 },
1558 {
1559 "name": "enable",
1560 "description": "Enables application cache domain notifications."
1561 },
1562 {
1563 "name": "getManifestForFrame",
1564 "parameters": [
1565 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Identifier of the frame containing document whose manifest is retrieved." }
1566 ],
1567 "returns": [
1568 { "name": "manifestURL", "type": "string", "description": "M anifest URL for document in the given frame." }
1569 ],
1570 "description": "Returns manifest URL for document in the given f rame."
1571 },
1572 {
1573 "name": "getApplicationCacheForFrame",
1574 "parameters": [
1575 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Identifier of the frame containing document whose application cache is retri eved." }
1576 ],
1577 "returns": [
1578 { "name": "applicationCache", "$ref": "ApplicationCache", "d escription": "Relevant application cache data for the document in given frame." }
1579 ],
1580 "description": "Returns relevant application cache data for the document in given frame."
1581 }
1582 ],
1583 "events": [
1584 {
1585 "name": "applicationCacheStatusUpdated",
1586 "parameters": [
1587 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Identifier of the frame containing document whose application cache updated status." },
1588 { "name": "manifestURL", "type": "string", "description": "M anifest URL." },
1589 { "name": "status", "type": "integer", "description": "Updat ed application cache status." }
1590 ]
1591 },
1592 {
1593 "name": "networkStateUpdated",
1594 "parameters": [
1595 { "name": "isNowOnline", "type": "boolean" }
1596 ]
1597 }
1598 ]
1599 },
1600 {
1601 "domain": "FileSystem",
1602 "hidden": true,
1603 "types": [
1604 {
1605 "id": "Entry",
1606 "type": "object",
1607 "properties": [
1608 { "name": "url", "type": "string", "description": "filesyste m: URL for the entry." },
1609 { "name": "name", "type": "string", "description": "The name of the file or directory." },
1610 { "name": "isDirectory", "type": "boolean", "description": " True if the entry is a directory." },
1611 { "name": "mimeType", "type": "string", "optional": true, "d escription": "MIME type of the entry, available for a file only." },
1612 { "name": "resourceType", "$ref": "Page.ResourceType", "opti onal": true, "description": "ResourceType of the entry, available for a file onl y." },
1613 { "name": "isTextFile", "type": "boolean", "optional": true, "description": "True if the entry is a text file." }
1614 ],
1615 "description": "Represents a browser side file or directory."
1616 },
1617 {
1618 "id": "Metadata",
1619 "type": "object",
1620 "properties": [
1621 { "name": "modificationTime", "type": "number", "description ": "Modification time." },
1622 { "name": "size", "type": "number", "description": "File siz e. This field is always zero for directories." }
1623 ],
1624 "description": "Represents metadata of a file or entry."
1625 }
1626 ],
1627 "commands": [
1628 {
1629 "name": "enable",
1630 "description": "Enables events from backend."
1631 },
1632 {
1633 "name": "disable",
1634 "description": "Disables events from backend."
1635 },
1636 {
1637 "name": "requestFileSystemRoot",
1638 "async": true,
1639 "parameters": [
1640 { "name": "origin", "type": "string", "description": "Securi ty origin of requesting FileSystem. One of frames in current page needs to have this security origin." },
1641 { "name": "type", "type": "string", "enum": ["temporary", "p ersistent"], "description": "FileSystem type of requesting FileSystem." }
1642 ],
1643 "returns": [
1644 { "name": "errorCode", "type": "integer", "description": "0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value." },
1645 { "name": "root", "$ref": "Entry", "optional": true, "descri ption": "Contains root of the requested FileSystem if the command completed succ essfully." }
1646 ],
1647 "description": "Returns root directory of the FileSystem, if exi sts."
1648 },
1649 {
1650 "name": "requestDirectoryContent",
1651 "async": true,
1652 "parameters": [
1653 { "name": "url", "type": "string", "description": "URL of th e directory that the frontend is requesting to read from." }
1654 ],
1655 "returns": [
1656 { "name": "errorCode", "type": "integer", "description": "0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value." },
1657 { "name": "entries", "type": "array", "items": { "$ref": "En try" }, "optional": true, "description": "Contains all entries on directory if t he command completed successfully." }
1658 ],
1659 "description": "Returns content of the directory."
1660 },
1661 {
1662 "name": "requestMetadata",
1663 "async": true,
1664 "parameters": [
1665 { "name": "url", "type": "string", "description": "URL of th e entry that the frontend is requesting to get metadata from." }
1666 ],
1667 "returns": [
1668 { "name": "errorCode", "type": "integer", "description": "0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value." },
1669 { "name": "metadata", "$ref": "Metadata", "optional": true, "description": "Contains metadata of the entry if the command completed successf ully." }
1670 ],
1671 "description": "Returns metadata of the entry."
1672 },
1673 {
1674 "name": "requestFileContent",
1675 "async": true,
1676 "parameters": [
1677 { "name": "url", "type": "string", "description": "URL of th e file that the frontend is requesting to read from." },
1678 { "name": "readAsText", "type": "boolean", "description": "T rue if the content should be read as text, otherwise the result will be returned as base64 encoded text." },
1679 { "name": "start", "type": "integer", "optional": true, "des cription": "Specifies the start of range to read." },
1680 { "name": "end", "type": "integer", "optional": true, "descr iption": "Specifies the end of range to read exclusively." },
1681 { "name": "charset", "type": "string", "optional": true, "de scription": "Overrides charset of the content when content is served as text." }
1682 ],
1683 "returns": [
1684 { "name": "errorCode", "type": "integer", "description": "0, if no error. Otherwise, errorCode is set to FileError::ErrorCode value." },
1685 { "name": "content", "type": "string", "optional": true, "de scription": "Content of the file." },
1686 { "name": "charset", "type": "string", "optional": true, "de scription": "Charset of the content if it is served as text." }
1687 ],
1688 "description": "Returns content of the file. Result should be sl iced into [start, end)."
1689 },
1690 {
1691 "name": "deleteEntry",
1692 "async": true,
1693 "parameters": [
1694 { "name": "url", "type": "string", "description": "URL of th e entry to delete." }
1695 ],
1696 "returns": [
1697 { "name": "errorCode", "type": "integer", "description": "0, if no error. Otherwise errorCode is set to FileError::ErrorCode value." }
1698 ],
1699 "description": "Deletes specified entry. If the entry is a direc tory, the agent deletes children recursively."
1700 }
1701 ]
1702 },
1703 {
1704 "domain": "DOM",
1705 "description": "This domain exposes DOM read/write operations. Each DOM Node is represented with its mirror object that has an <code>id</code>. This <co de>id</code> can be used to get additional information on the Node, resolve it i nto the JavaScript object wrapper, etc. It is important that client receives DOM events only for the nodes that are known to the client. Backend keeps track of the nodes that were sent to the client and never sends the same node twice. It i s client's responsibility to collect information about the nodes that were sent to the client.<p>Note that <code>iframe</code> owner elements will return corres ponding document elements as their child nodes.</p>",
1706 "types": [
1707 {
1708 "id": "NodeId",
1709 "type": "integer",
1710 "description": "Unique DOM node identifier."
1711 },
1712 {
1713 "id": "Node",
1714 "type": "object",
1715 "properties": [
1716 { "name": "nodeId", "$ref": "NodeId", "description": "Node i dentifier that is passed into the rest of the DOM messages as the <code>nodeId</ code>. Backend will only push node with given <code>id</code> once. It is aware of all requested nodes and will only fire DOM events for nodes known to the clie nt." },
1717 { "name": "nodeType", "type": "integer", "description": "<co de>Node</code>'s nodeType." },
1718 { "name": "nodeName", "type": "string", "description": "<cod e>Node</code>'s nodeName." },
1719 { "name": "localName", "type": "string", "description": "<co de>Node</code>'s localName." },
1720 { "name": "nodeValue", "type": "string", "description": "<co de>Node</code>'s nodeValue." },
1721 { "name": "childNodeCount", "type": "integer", "optional": t rue, "description": "Child count for <code>Container</code> nodes." },
1722 { "name": "children", "type": "array", "optional": true, "it ems": { "$ref": "Node" }, "description": "Child nodes of this node when requeste d with children." },
1723 { "name": "attributes", "type": "array", "optional": true, " items": { "type": "string" }, "description": "Attributes of the <code>Element</c ode> node in the form of flat array <code>[name1, value1, name2, value2]</code>. " },
1724 { "name": "documentURL", "type": "string", "optional": true, "description": "Document URL that <code>Document</code> or <code>FrameOwner</co de> node points to." },
1725 { "name": "baseURL", "type": "string", "optional": true, "de scription": "Base URL that <code>Document</code> or <code>FrameOwner</code> node uses for URL completion." },
1726 { "name": "publicId", "type": "string", "optional": true, "d escription": "<code>DocumentType</code>'s publicId." },
1727 { "name": "systemId", "type": "string", "optional": true, "d escription": "<code>DocumentType</code>'s systemId." },
1728 { "name": "internalSubset", "type": "string", "optional": tr ue, "description": "<code>DocumentType</code>'s internalSubset." },
1729 { "name": "xmlVersion", "type": "string", "optional": true, "description": "<code>Document</code>'s XML version in case of XML documents." } ,
1730 { "name": "name", "type": "string", "optional": true, "descr iption": "<code>Attr</code>'s name." },
1731 { "name": "value", "type": "string", "optional": true, "desc ription": "<code>Attr</code>'s value." },
1732 { "name": "frameId", "$ref": "Network.FrameId", "optional": true, "description": "Frame ID for frame owner elements." },
1733 { "name": "contentDocument", "$ref": "Node", "optional": tru e, "description": "Content document for frame owner elements." },
1734 { "name": "shadowRoots", "type": "array", "optional": true, "items": { "$ref": "Node" }, "description": "Shadow root list for given element host." },
1735 { "name": "templateContent", "$ref": "Node", "optional": tru e, "description": "Content document fragment for template elements" }
1736 ],
1737 "description": "DOM interaction is implemented in terms of mirro r objects that represent the actual DOM nodes. DOMNode is a base node mirror typ e."
1738 },
1739 {
1740 "id": "EventListener",
1741 "type": "object",
1742 "hidden": true,
1743 "properties": [
1744 { "name": "type", "type": "string", "description": "<code>Ev entListener</code>'s type." },
1745 { "name": "useCapture", "type": "boolean", "description": "< code>EventListener</code>'s useCapture." },
1746 { "name": "isAttribute", "type": "boolean", "description": " <code>EventListener</code>'s isAttribute." },
1747 { "name": "nodeId", "$ref": "NodeId", "description": "Target <code>DOMNode</code> id." },
1748 { "name": "handlerBody", "type": "string", "description": "E vent handler function body." },
1749 { "name": "location", "$ref": "Debugger.Location", "optional ": true, "description": "Handler code location." },
1750 { "name": "sourceName", "type": "string", "optional": true, "description": "Source script URL." },
1751 { "name": "handler", "$ref": "Runtime.RemoteObject", "option al": true, "description": "Event handler function value." }
1752 ],
1753 "description": "DOM interaction is implemented in terms of mirro r objects that represent the actual DOM nodes. DOMNode is a base node mirror typ e."
1754 },
1755 {
1756 "id": "RGBA",
1757 "type": "object",
1758 "properties": [
1759 { "name": "r", "type": "integer", "description": "The red co mponent, in the [0-255] range." },
1760 { "name": "g", "type": "integer", "description": "The green component, in the [0-255] range." },
1761 { "name": "b", "type": "integer", "description": "The blue c omponent, in the [0-255] range." },
1762 { "name": "a", "type": "number", "optional": true, "descript ion": "The alpha component, in the [0-1] range (default: 1)." }
1763 ],
1764 "description": "A structure holding an RGBA color."
1765 },
1766 {
1767 "id": "HighlightConfig",
1768 "type": "object",
1769 "properties": [
1770 { "name": "showInfo", "type": "boolean", "optional": true, " description": "Whether the node info tooltip should be shown (default: false)." },
1771 { "name": "contentColor", "$ref": "RGBA", "optional": true, "description": "The content box highlight fill color (default: transparent)." },
1772 { "name": "paddingColor", "$ref": "RGBA", "optional": true, "description": "The padding highlight fill color (default: transparent)." },
1773 { "name": "borderColor", "$ref": "RGBA", "optional": true, " description": "The border highlight fill color (default: transparent)." },
1774 { "name": "marginColor", "$ref": "RGBA", "optional": true, " description": "The margin highlight fill color (default: transparent)." }
1775 ],
1776 "description": "Configuration data for the highlighting of page elements."
1777 }
1778 ],
1779 "commands": [
1780 {
1781 "name": "getDocument",
1782 "returns": [
1783 { "name": "root", "$ref": "Node", "description": "Resulting node." }
1784 ],
1785 "description": "Returns the root DOM node to the caller."
1786 },
1787 {
1788 "name": "requestChildNodes",
1789 "parameters": [
1790 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to get children for." },
1791 { "name": "depth", "type": "integer", "optional": true, "des cription": "The maximum depth at which children should be retrieved, defaults to 1. Use -1 for the entire subtree or provide an integer larger than 0." }
1792 ],
1793 "description": "Requests that children of the node with given id are returned to the caller in form of <code>setChildNodes</code> events where n ot only immediate children are retrieved, but all children down to the specified depth."
1794 },
1795 {
1796 "name": "querySelector",
1797 "parameters": [
1798 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to query upon." },
1799 { "name": "selector", "type": "string", "description": "Sele ctor string." }
1800 ],
1801 "returns": [
1802 { "name": "nodeId", "$ref": "NodeId", "description": "Query selector result." }
1803 ],
1804 "description": "Executes <code>querySelector</code> on a given n ode."
1805 },
1806 {
1807 "name": "querySelectorAll",
1808 "parameters": [
1809 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to query upon." },
1810 { "name": "selector", "type": "string", "description": "Sele ctor string." }
1811 ],
1812 "returns": [
1813 { "name": "nodeIds", "type": "array", "items": { "$ref": "No deId" }, "description": "Query selector result." }
1814 ],
1815 "description": "Executes <code>querySelectorAll</code> on a give n node."
1816 },
1817 {
1818 "name": "setNodeName",
1819 "parameters": [
1820 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to set name for." },
1821 { "name": "name", "type": "string", "description": "New node 's name." }
1822 ],
1823 "returns": [
1824 { "name": "nodeId", "$ref": "NodeId", "description": "New no de's id." }
1825 ],
1826 "description": "Sets node name for a node with given id."
1827 },
1828 {
1829 "name": "setNodeValue",
1830 "parameters": [
1831 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to set value for." },
1832 { "name": "value", "type": "string", "description": "New nod e's value." }
1833 ],
1834 "description": "Sets node value for a node with given id."
1835 },
1836 {
1837 "name": "removeNode",
1838 "parameters": [
1839 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to remove." }
1840 ],
1841 "description": "Removes node with given id."
1842 },
1843 {
1844 "name": "setAttributeValue",
1845 "parameters": [
1846 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the element to set attribute for." },
1847 { "name": "name", "type": "string", "description": "Attribut e name." },
1848 { "name": "value", "type": "string", "description": "Attribu te value." }
1849 ],
1850 "description": "Sets attribute for an element with given id."
1851 },
1852 {
1853 "name": "setAttributesAsText",
1854 "parameters": [
1855 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the element to set attributes for." },
1856 { "name": "text", "type": "string", "description": "Text wit h a number of attributes. Will parse this text using HTML parser." },
1857 { "name": "name", "type": "string", "optional": true, "descr iption": "Attribute name to replace with new attributes derived from text in cas e text parsed successfully." }
1858 ],
1859 "description": "Sets attributes on element with given id. This m ethod is useful when user edits some existing attribute value and types in sever al attribute name/value pairs."
1860 },
1861 {
1862 "name": "removeAttribute",
1863 "parameters": [
1864 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the element to remove attribute from." },
1865 { "name": "name", "type": "string", "description": "Name of the attribute to remove." }
1866 ],
1867 "description": "Removes attribute with given name from an elemen t with given id."
1868 },
1869 {
1870 "name": "getEventListenersForNode",
1871 "parameters": [
1872 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to get listeners for." },
1873 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name for handler value. Handler value is not ret urned without this parameter specified." }
1874 ],
1875 "returns": [
1876 { "name": "listeners", "type": "array", "items": { "$ref": " EventListener"}, "description": "Array of relevant listeners." }
1877 ],
1878 "description": "Returns event listeners relevant to the node.",
1879 "hidden": true
1880 },
1881 {
1882 "name": "getOuterHTML",
1883 "parameters": [
1884 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to get markup for." }
1885 ],
1886 "returns": [
1887 { "name": "outerHTML", "type": "string", "description": "Out er HTML markup." }
1888 ],
1889 "description": "Returns node's HTML markup."
1890 },
1891 {
1892 "name": "setOuterHTML",
1893 "parameters": [
1894 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to set markup for." },
1895 { "name": "outerHTML", "type": "string", "description": "Out er HTML markup to set." }
1896 ],
1897 "description": "Sets node HTML markup, returns new node id."
1898 },
1899 {
1900 "name": "performSearch",
1901 "parameters": [
1902 { "name": "query", "type": "string", "description": "Plain t ext or query selector or XPath search query." }
1903 ],
1904 "returns": [
1905 { "name": "searchId", "type": "string", "description": "Uniq ue search session identifier." },
1906 { "name": "resultCount", "type": "integer", "description": " Number of search results." }
1907 ],
1908 "description": "Searches for a given string in the DOM tree. Use <code>getSearchResults</code> to access search results or <code>cancelSearch</c ode> to end this search session.",
1909 "hidden": true
1910 },
1911 {
1912 "name": "getSearchResults",
1913 "parameters": [
1914 { "name": "searchId", "type": "string", "description": "Uniq ue search session identifier." },
1915 { "name": "fromIndex", "type": "integer", "description": "St art index of the search result to be returned." },
1916 { "name": "toIndex", "type": "integer", "description": "End index of the search result to be returned." }
1917 ],
1918 "returns": [
1919 { "name": "nodeIds", "type": "array", "items": { "$ref": "No deId" }, "description": "Ids of the search result nodes." }
1920 ],
1921 "description": "Returns search results from given <code>fromInde x</code> to given <code>toIndex</code> from the sarch with the given identifier. ",
1922 "hidden": true
1923 },
1924 {
1925 "name": "discardSearchResults",
1926 "parameters": [
1927 { "name": "searchId", "type": "string", "description": "Uniq ue search session identifier." }
1928 ],
1929 "description": "Discards search results from the session with th e given id. <code>getSearchResults</code> should no longer be called for that se arch.",
1930 "hidden": true
1931 },
1932 {
1933 "name": "requestNode",
1934 "parameters": [
1935 { "name": "objectId", "$ref": "Runtime.RemoteObjectId", "des cription": "JavaScript object id to convert into node." }
1936 ],
1937 "returns": [
1938 { "name": "nodeId", "$ref": "NodeId", "description": "Node i d for given object." }
1939 ],
1940 "description": "Requests that the node is sent to the caller giv en the JavaScript node object reference. All nodes that form the path from the n ode to the root are also sent to the client as a series of <code>setChildNodes</ code> notifications."
1941 },
1942 {
1943 "name": "setInspectModeEnabled",
1944 "hidden": true,
1945 "parameters": [
1946 { "name": "enabled", "type": "boolean", "description": "True to enable inspection mode, false to disable it." },
1947 { "name": "highlightConfig", "$ref": "HighlightConfig", "opt ional": true, "description": "A descriptor for the highlight appearance of hover ed-over nodes. May be omitted if <code>enabled == false</code>." }
1948 ],
1949 "description": "Enters the 'inspect' mode. In this mode, element s that user is hovering over are highlighted. Backend then generates 'inspect' c ommand upon element selection."
1950 },
1951 {
1952 "name": "highlightRect",
1953 "parameters": [
1954 { "name": "x", "type": "integer", "description": "X coordina te" },
1955 { "name": "y", "type": "integer", "description": "Y coordina te" },
1956 { "name": "width", "type": "integer", "description": "Rectan gle width" },
1957 { "name": "height", "type": "integer", "description": "Recta ngle height" },
1958 { "name": "color", "$ref": "RGBA", "optional": true, "descri ption": "The highlight fill color (default: transparent)." },
1959 { "name": "outlineColor", "$ref": "RGBA", "optional": true, "description": "The highlight outline color (default: transparent)." }
1960 ],
1961 "description": "Highlights given rectangle. Coordinates are abso lute with respect to the main frame viewport."
1962 },
1963 {
1964 "name": "highlightNode",
1965 "parameters": [
1966 { "name": "highlightConfig", "$ref": "HighlightConfig", "de scription": "A descriptor for the highlight appearance." },
1967 { "name": "nodeId", "$ref": "NodeId", "optional": true, "des cription": "Identifier of the node to highlight." },
1968 { "name": "objectId", "$ref": "Runtime.RemoteObjectId", "opt ional": true, "description": "JavaScript object id of the node to be highlighted ." }
1969 ],
1970 "description": "Highlights DOM node with given id or with the gi ven JavaScript object wrapper. Either nodeId or objectId must be specified."
1971 },
1972 {
1973 "name": "hideHighlight",
1974 "description": "Hides DOM node highlight."
1975 },
1976 {
1977 "name": "highlightFrame",
1978 "parameters": [
1979 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Identifier of the frame to highlight." },
1980 { "name": "contentColor", "$ref": "RGBA", "optional": true, "description": "The content box highlight fill color (default: transparent)." },
1981 { "name": "contentOutlineColor", "$ref": "RGBA", "optional": true, "description": "The content box highlight outline color (default: transpa rent)." }
1982 ],
1983 "description": "Highlights owner element of the frame with given id.",
1984 "hidden": true
1985 },
1986 {
1987 "name": "pushNodeByPathToFrontend",
1988 "parameters": [
1989 { "name": "path", "type": "string", "description": "Path to node in the proprietary format." }
1990 ],
1991 "returns": [
1992 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node for given path." }
1993 ],
1994 "description": "Requests that the node is sent to the caller giv en its path. // FIXME, use XPath",
1995 "hidden": true
1996 },
1997 {
1998 "name": "resolveNode",
1999 "parameters": [
2000 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to resolve." },
2001 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple object s." }
2002 ],
2003 "returns": [
2004 { "name": "object", "$ref": "Runtime.RemoteObject", "descrip tion": "JavaScript object wrapper for given node." }
2005 ],
2006 "description": "Resolves JavaScript node object for given node i d."
2007 },
2008 {
2009 "name": "getAttributes",
2010 "parameters": [
2011 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to retrieve attibutes for." }
2012 ],
2013 "returns": [
2014 { "name": "attributes", "type": "array", "items": { "type": "string" }, "description": "An interleaved array of node attribute names and val ues." }
2015 ],
2016 "description": "Returns attributes for the specified node."
2017 },
2018 {
2019 "name": "moveTo",
2020 "parameters": [
2021 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to drop." },
2022 { "name": "targetNodeId", "$ref": "NodeId", "description": " Id of the element to drop into." },
2023 { "name": "insertBeforeNodeId", "$ref": "NodeId", "optional" : true, "description": "Drop node before given one." }
2024 ],
2025 "returns": [
2026 { "name": "nodeId", "$ref": "NodeId", "description": "New id of the moved node." }
2027 ],
2028 "description": "Moves node into the new container, places it bef ore the given anchor."
2029 },
2030 {
2031 "name": "undo",
2032 "description": "Undoes the last performed action.",
2033 "hidden": true
2034 },
2035 {
2036 "name": "redo",
2037 "description": "Re-does the last undone action.",
2038 "hidden": true
2039 },
2040 {
2041 "name": "markUndoableState",
2042 "description": "Marks last undoable state.",
2043 "hidden": true
2044 },
2045 {
2046 "name": "focus",
2047 "parameters": [
2048 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node to focus." }
2049 ],
2050 "description": "Focuses the given element.",
2051 "hidden": true
2052 },
2053 {
2054 "name": "setFileInputFiles",
2055 "parameters": [
2056 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the file input node to set files for." },
2057 { "name": "files", "type": "array", "items": { "type": "stri ng" }, "description": "Array of file paths to set." }
2058 ],
2059 "description": "Sets files for the given file input element.",
2060 "hidden": true
2061 }
2062 ],
2063 "events": [
2064 {
2065 "name": "documentUpdated",
2066 "description": "Fired when <code>Document</code> has been totall y updated. Node ids are no longer valid."
2067 },
2068 {
2069 "name": "setChildNodes",
2070 "parameters": [
2071 { "name": "parentId", "$ref": "NodeId", "description": "Pare nt node id to populate with children." },
2072 { "name": "nodes", "type": "array", "items": { "$ref": "Node "}, "description": "Child nodes array." }
2073 ],
2074 "description": "Fired when backend wants to provide client with the missing DOM structure. This happens upon most of the calls requesting node i ds."
2075 },
2076 {
2077 "name": "attributeModified",
2078 "parameters": [
2079 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
2080 { "name": "name", "type": "string", "description": "Attribut e name." },
2081 { "name": "value", "type": "string", "description": "Attribu te value." }
2082 ],
2083 "description": "Fired when <code>Element</code>'s attribute is m odified."
2084 },
2085 {
2086 "name": "attributeRemoved",
2087 "parameters": [
2088 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
2089 { "name": "name", "type": "string", "description": "A ttribu te name." }
2090 ],
2091 "description": "Fired when <code>Element</code>'s attribute is r emoved."
2092 },
2093 {
2094 "name": "inlineStyleInvalidated",
2095 "parameters": [
2096 { "name": "nodeIds", "type": "array", "items": { "$ref": "No deId" }, "description": "Ids of the nodes for which the inline styles have been invalidated." }
2097 ],
2098 "description": "Fired when <code>Element</code>'s inline style i s modified via a CSS property modification.",
2099 "hidden": true
2100 },
2101 {
2102 "name": "characterDataModified",
2103 "parameters": [
2104 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
2105 { "name": "characterData", "type": "string", "description": "New text value." }
2106 ],
2107 "description": "Mirrors <code>DOMCharacterDataModified</code> ev ent."
2108 },
2109 {
2110 "name": "childNodeCountUpdated",
2111 "parameters": [
2112 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has changed." },
2113 { "name": "childNodeCount", "type": "integer", "description" : "New node count." }
2114 ],
2115 "description": "Fired when <code>Container</code>'s child node c ount has changed."
2116 },
2117 {
2118 "name": "childNodeInserted",
2119 "parameters": [
2120 { "name": "parentNodeId", "$ref": "NodeId", "description": " Id of the node that has changed." },
2121 { "name": "previousNodeId", "$ref": "NodeId", "description": "If of the previous siblint." },
2122 { "name": "node", "$ref": "Node", "description": "Inserted n ode data." }
2123 ],
2124 "description": "Mirrors <code>DOMNodeInserted</code> event."
2125 },
2126 {
2127 "name": "childNodeRemoved",
2128 "parameters": [
2129 { "name": "parentNodeId", "$ref": "NodeId", "description": " Parent id." },
2130 { "name": "nodeId", "$ref": "NodeId", "description": "Id of the node that has been removed." }
2131 ],
2132 "description": "Mirrors <code>DOMNodeRemoved</code> event."
2133 },
2134 {
2135 "name": "shadowRootPushed",
2136 "parameters": [
2137 { "name": "hostId", "$ref": "NodeId", "description": "Host e lement id." },
2138 { "name": "root", "$ref": "Node", "description": "Shadow roo t." }
2139 ],
2140 "description": "Called when shadow root is pushed into the eleme nt.",
2141 "hidden": true
2142 },
2143 {
2144 "name": "shadowRootPopped",
2145 "parameters": [
2146 { "name": "hostId", "$ref": "NodeId", "description": "Host e lement id." },
2147 { "name": "rootId", "$ref": "NodeId", "description": "Shadow root id." }
2148 ],
2149 "description": "Called when shadow root is popped from the eleme nt.",
2150 "hidden": true
2151 }
2152 ]
2153 },
2154 {
2155 "domain": "CSS",
2156 "hidden": true,
2157 "description": "This domain exposes CSS read/write operations. All CSS o bjects, like stylesheets, rules, and styles, have an associated <code>id</code> used in subsequent operations on the related object. Each object type has a spec ific <code>id</code> structure, and those are not interchangeable between object s of different kinds. CSS objects can be loaded using the <code>get*ForNode()</c ode> calls (which accept a DOM node id). Alternatively, a client can discover al l the existing stylesheets with the <code>getAllStyleSheets()</code> method and subsequently load the required stylesheet contents using the <code>getStyleSheet [Text]()</code> methods.",
2158 "types": [
2159 {
2160 "id": "StyleSheetId",
2161 "type": "string"
2162 },
2163 {
2164 "id": "CSSStyleId",
2165 "type": "object",
2166 "properties": [
2167 { "name": "styleSheetId", "$ref": "StyleSheetId", "descripti on": "Enclosing stylesheet identifier." },
2168 { "name": "ordinal", "type": "integer", "description": "The style ordinal within the stylesheet." }
2169 ],
2170 "description": "This object identifies a CSS style in a unique w ay."
2171 },
2172 {
2173 "id": "StyleSheetOrigin",
2174 "type": "string",
2175 "enum": ["user", "user-agent", "inspector", "regular"],
2176 "description": "Stylesheet type: \"user\" for user stylesheets, \"user-agent\" for user-agent stylesheets, \"inspector\" for stylesheets created by the inspector (i.e. those holding the \"via inspector\" rules), \"regular\" for regular stylesheets."
2177 },
2178 {
2179 "id": "CSSRuleId",
2180 "type": "object",
2181 "properties": [
2182 { "name": "styleSheetId", "$ref": "StyleSheetId", "descripti on": "Enclosing stylesheet identifier." },
2183 { "name": "ordinal", "type": "integer", "description": "The rule ordinal within the stylesheet." }
2184 ],
2185 "description": "This object identifies a CSS rule in a unique wa y."
2186 },
2187 {
2188 "id": "PseudoIdMatches",
2189 "type": "object",
2190 "properties": [
2191 { "name": "pseudoId", "type": "integer", "description": "Pse udo style identifier (see <code>enum PseudoId</code> in <code>RenderStyleConstan ts.h</code>)."},
2192 { "name": "matches", "type": "array", "items": { "$ref": "Ru leMatch" }, "description": "Matches of CSS rules applicable to the pseudo style. "}
2193 ],
2194 "description": "CSS rule collection for a single pseudo style."
2195 },
2196 {
2197 "id": "InheritedStyleEntry",
2198 "type": "object",
2199 "properties": [
2200 { "name": "inlineStyle", "$ref": "CSSStyle", "optional": tru e, "description": "The ancestor node's inline style, if any, in the style inheri tance chain." },
2201 { "name": "matchedCSSRules", "type": "array", "items": { "$r ef": "RuleMatch" }, "description": "Matches of CSS rules matching the ancestor n ode in the style inheritance chain." }
2202 ],
2203 "description": "CSS rule collection for a single pseudo style."
2204 },
2205 {
2206 "id": "RuleMatch",
2207 "type": "object",
2208 "properties": [
2209 { "name": "rule", "$ref": "CSSRule", "description": "CSS rul e in the match." },
2210 { "name": "matchingSelectors", "type": "array", "items": { " type": "integer" }, "description": "Matching selector indices in the rule's sele ctorList selectors (0-based)." }
2211 ],
2212 "description": "Match data for a CSS rule."
2213 },
2214 {
2215 "id": "SelectorList",
2216 "type": "object",
2217 "properties": [
2218 { "name": "selectors", "type": "array", "items": { "type": " string" }, "description": "Selectors in the list." },
2219 { "name": "text", "type": "string", "description": "Rule sel ector text." },
2220 { "name": "range", "$ref": "SourceRange", "optional": true, "description": "Rule selector range in the underlying resource (if available)." }
2221 ],
2222 "description": "Selector list data."
2223 },
2224 {
2225 "id": "CSSStyleAttribute",
2226 "type": "object",
2227 "properties": [
2228 { "name": "name", "type": "string", "description": "DOM attr ibute name (e.g. \"width\")."},
2229 { "name": "style", "$ref": "CSSStyle", "description": "CSS s tyle generated by the respective DOM attribute."}
2230 ],
2231 "description": "CSS style information for a DOM style attribute. "
2232 },
2233 {
2234 "id": "CSSStyleSheetHeader",
2235 "type": "object",
2236 "properties": [
2237 { "name": "styleSheetId", "$ref": "StyleSheetId", "descripti on": "The stylesheet identifier."},
2238 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Owner frame identifier."},
2239 { "name": "sourceURL", "type": "string", "description": "Sty lesheet resource URL."},
2240 { "name": "origin", "$ref": "StyleSheetOrigin", "description ": "Stylesheet origin."},
2241 { "name": "title", "type": "string", "description": "Stylesh eet title."},
2242 { "name": "disabled", "type": "boolean", "description": "Den otes whether the stylesheet is disabled."}
2243 ],
2244 "description": "CSS stylesheet metainformation."
2245 },
2246 {
2247 "id": "CSSStyleSheetBody",
2248 "type": "object",
2249 "properties": [
2250 { "name": "styleSheetId", "$ref": "StyleSheetId", "descripti on": "The stylesheet identifier."},
2251 { "name": "rules", "type": "array", "items": { "$ref": "CSSR ule" }, "description": "Stylesheet resource URL."},
2252 { "name": "text", "type": "string", "optional": true, "descr iption": "Stylesheet resource contents (if available)."}
2253 ],
2254 "description": "CSS stylesheet contents."
2255 },
2256 {
2257 "id": "CSSRule",
2258 "type": "object",
2259 "properties": [
2260 { "name": "ruleId", "$ref": "CSSRuleId", "optional": true, " description": "The CSS rule identifier (absent for user agent stylesheet and use r-specified stylesheet rules)."},
2261 { "name": "selectorList", "$ref": "SelectorList", "descripti on": "Rule selector data." },
2262 { "name": "sourceURL", "type": "string", "optional": true, " description": "Parent stylesheet resource URL (for regular rules)."},
2263 { "name": "sourceLine", "type": "integer", "description": "L ine ordinal of the rule selector start character in the resource."},
2264 { "name": "origin", "$ref": "StyleSheetOrigin", "description ": "Parent stylesheet's origin."},
2265 { "name": "style", "$ref": "CSSStyle", "description": "Assoc iated style declaration." },
2266 { "name": "media", "type": "array", "items": { "$ref": "CSSM edia" }, "optional": true, "description": "Media list array (for rules involving media queries). The array enumerates media queries starting with the innermost one, going outwards." }
2267 ],
2268 "description": "CSS rule representation."
2269 },
2270 {
2271 "id": "SourceRange",
2272 "type": "object",
2273 "properties": [
2274 { "name": "start", "type": "integer", "description": "Start of range (inclusive)."},
2275 { "name": "end", "type": "integer", "description": "End of r ange (exclusive)."}
2276 ],
2277 "description": "Text range within a resource."
2278 },
2279 {
2280 "id": "ShorthandEntry",
2281 "type": "object",
2282 "properties": [
2283 { "name": "name", "type": "string", "description": "Shorthan d name." },
2284 { "name": "value", "type": "string", "description": "Shortha nd value." }
2285 ]
2286 },
2287 {
2288 "id": "CSSPropertyInfo",
2289 "type": "object",
2290 "properties": [
2291 { "name": "name", "type": "string", "description": "Property name." },
2292 { "name": "longhands", "type": "array", "optional": true, "i tems": { "type": "string" }, "description": "Longhand property names." }
2293 ]
2294 },
2295 {
2296 "id": "CSSComputedStyleProperty",
2297 "type": "object",
2298 "properties": [
2299 { "name": "name", "type": "string", "description": "Computed style property name." },
2300 { "name": "value", "type": "string", "description": "Compute d style property value." }
2301 ]
2302 },
2303 {
2304 "id": "CSSStyle",
2305 "type": "object",
2306 "properties": [
2307 { "name": "styleId", "$ref": "CSSStyleId", "optional": true, "description": "The CSS style identifier (absent for attribute styles)." },
2308 { "name": "cssProperties", "type": "array", "items": { "$ref ": "CSSProperty" }, "description": "CSS properties in the style." },
2309 { "name": "shorthandEntries", "type": "array", "items": { "$ ref": "ShorthandEntry" }, "description": "Computed values for all shorthands fou nd in the style." },
2310 { "name": "cssText", "type": "string", "optional": true, "de scription": "Style declaration text (if available)." },
2311 { "name": "range", "$ref": "SourceRange", "optional": true, "description": "Style declaration range in the enclosing stylesheet (if availabl e)." },
2312 { "name": "width", "type": "string", "optional": true, "desc ription": "The effective \"width\" property value from this style." },
2313 { "name": "height", "type": "string", "optional": true, "des cription": "The effective \"height\" property value from this style." }
2314 ],
2315 "description": "CSS style representation."
2316 },
2317 {
2318 "id": "CSSProperty",
2319 "type": "object",
2320 "properties": [
2321 { "name": "name", "type": "string", "description": "The prop erty name." },
2322 { "name": "value", "type": "string", "description": "The pro perty value." },
2323 { "name": "priority", "type": "string", "optional": true, "d escription": "The property priority (implies \"\" if absent)." },
2324 { "name": "implicit", "type": "boolean", "optional": true, " description": "Whether the property is implicit (implies <code>false</code> if a bsent)." },
2325 { "name": "text", "type": "string", "optional": true, "descr iption": "The full property text as specified in the style." },
2326 { "name": "parsedOk", "type": "boolean", "optional": true, " description": "Whether the property is understood by the browser (implies <code> true</code> if absent)." },
2327 { "name": "status", "type": "string", "enum": ["active", "in active", "disabled", "style"], "optional": true, "description": "The property st atus: \"active\" if the property is effective in the style, \"inactive\" if the property is overridden by a same-named property in this style later on, \"disabl ed\" if the property is disabled by the user, \"style\" (implied if absent) if t he property is reported by the browser rather than by the CSS source parser." },
2328 { "name": "range", "$ref": "SourceRange", "optional": true, "description": "The entire property range in the enclosing style declaration (if available)." }
2329 ],
2330 "description": "CSS style effective visual dimensions and source offsets."
2331 },
2332 {
2333 "id": "CSSMedia",
2334 "type": "object",
2335 "properties": [
2336 { "name": "text", "type": "string", "description": "Media qu ery text." },
2337 { "name": "source", "type": "string", "enum": ["mediaRule", "importRule", "linkedSheet", "inlineSheet"], "description": "Source of the media query: \"mediaRule\" if specified by a @media rule, \"importRule\" if specified by an @import rule, \"linkedSheet\" if specified by a \"media\" attribute in a linked stylesheet's LINK tag, \"inlineSheet\" if specified by a \"media\" attrib ute in an inline stylesheet's STYLE tag." },
2338 { "name": "sourceURL", "type": "string", "optional": true, " description": "URL of the document containing the media query description." },
2339 { "name": "sourceLine", "type": "integer", "optional": true, "description": "Line in the document containing the media query (not defined fo r the \"stylesheet\" source)." }
2340 ],
2341 "description": "CSS media query descriptor."
2342 },
2343 {
2344 "id": "SelectorProfileEntry",
2345 "type": "object",
2346 "properties": [
2347 { "name": "selector", "type": "string", "description": "CSS selector of the corresponding rule." },
2348 { "name": "url", "type": "string", "description": "URL of th e resource containing the corresponding rule." },
2349 { "name": "lineNumber", "type": "integer", "description": "S elector line number in the resource for the corresponding rule." },
2350 { "name": "time", "type": "number", "description": "Total ti me this rule handling contributed to the browser running time during profiling ( in milliseconds.)" },
2351 { "name": "hitCount", "type": "integer", "description": "Num ber of times this rule was considered a candidate for matching against DOM eleme nts." },
2352 { "name": "matchCount", "type": "integer", "description": "N umber of times this rule actually matched a DOM element." }
2353 ],
2354 "description": "CSS selector profile entry."
2355 },
2356 {
2357 "id": "SelectorProfile",
2358 "type": "object",
2359 "properties": [
2360 { "name": "totalTime", "type": "number", "description": "Tot al processing time for all selectors in the profile (in milliseconds.)" },
2361 { "name": "data", "type": "array", "items": { "$ref": "Selec torProfileEntry" }, "description": "CSS selector profile entries." }
2362 ]
2363 },
2364 {
2365 "id": "Region",
2366 "type": "object",
2367 "properties": [
2368 { "name": "regionOverset", "type": "string", "enum": ["overs et", "fit", "empty"], "description": "The \"overset\" attribute of a Named Flow. " },
2369 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "Th e corresponding DOM node id." }
2370 ],
2371 "description": "This object represents a region that flows from a Named Flow.",
2372 "hidden": true
2373 },
2374 {
2375 "id": "NamedFlow",
2376 "type": "object",
2377 "properties": [
2378 { "name": "documentNodeId", "$ref": "DOM.NodeId", "descripti on": "The document node id." },
2379 { "name": "name", "type": "string", "description": "Named Fl ow identifier." },
2380 { "name": "overset", "type": "boolean", "description": "The \"overset\" attribute of a Named Flow." },
2381 { "name": "content", "type": "array", "items": { "$ref": "DO M.NodeId" }, "description": "An array of nodes that flow into the Named Flow." } ,
2382 { "name": "regions", "type": "array", "items": { "$ref": "Re gion" }, "description": "An array of regions associated with the Named Flow." }
2383 ],
2384 "description": "This object represents a Named Flow.",
2385 "hidden": true
2386 }
2387 ],
2388 "commands": [
2389 {
2390 "name": "enable",
2391 "description": "Enables the CSS agent for the given page. Client s should not assume that the CSS agent has been enabled until the result of this command is received."
2392 },
2393 {
2394 "name": "disable",
2395 "description": "Disables the CSS agent for the given page."
2396 },
2397 {
2398 "name": "getMatchedStylesForNode",
2399 "parameters": [
2400 { "name": "nodeId", "$ref": "DOM.NodeId" },
2401 { "name": "includePseudo", "type": "boolean", "optional": tr ue, "description": "Whether to include pseudo styles (default: true)." },
2402 { "name": "includeInherited", "type": "boolean", "optional": true, "description": "Whether to include inherited styles (default: true)." }
2403 ],
2404 "returns": [
2405 { "name": "matchedCSSRules", "type": "array", "items": { "$r ef": "RuleMatch" }, "optional": true, "description": "CSS rules matching this no de, from all applicable stylesheets." },
2406 { "name": "pseudoElements", "type": "array", "items": { "$re f": "PseudoIdMatches" }, "optional": true, "description": "Pseudo style matches for this node." },
2407 { "name": "inherited", "type": "array", "items": { "$ref": " InheritedStyleEntry" }, "optional": true, "description": "A chain of inherited s tyles (from the immediate node parent up to the DOM tree root)." }
2408 ],
2409 "description": "Returns requested styles for a DOM node identifi ed by <code>nodeId</code>."
2410 },
2411 {
2412 "name": "getInlineStylesForNode",
2413 "parameters": [
2414 { "name": "nodeId", "$ref": "DOM.NodeId" }
2415 ],
2416 "returns": [
2417 { "name": "inlineStyle", "$ref": "CSSStyle", "optional": tru e, "description": "Inline style for the specified DOM node." },
2418 { "name": "attributesStyle", "$ref": "CSSStyle", "optional": true, "description": "Attribute-defined element style (e.g. resulting from \"wi dth=20 height=100%\")."}
2419 ],
2420 "description": "Returns the styles defined inline (explicitly in the \"style\" attribute and implicitly, using DOM attributes) for a DOM node id entified by <code>nodeId</code>."
2421 },
2422 {
2423 "name": "getComputedStyleForNode",
2424 "parameters": [
2425 { "name": "nodeId", "$ref": "DOM.NodeId" }
2426 ],
2427 "returns": [
2428 { "name": "computedStyle", "type": "array", "items": { "$ref ": "CSSComputedStyleProperty" }, "description": "Computed style for the specifie d DOM node." }
2429 ],
2430 "description": "Returns the computed style for a DOM node identi fied by <code>nodeId</code>."
2431 },
2432 {
2433 "name": "getAllStyleSheets",
2434 "returns": [
2435 { "name": "headers", "type": "array", "items": { "$ref": "CS SStyleSheetHeader" }, "description": "Descriptor entries for all available style sheets." }
2436 ],
2437 "description": "Returns metainfo entries for all known styleshee ts."
2438 },
2439 {
2440 "name": "getStyleSheet",
2441 "parameters": [
2442 { "name": "styleSheetId", "$ref": "StyleSheetId" }
2443 ],
2444 "returns": [
2445 { "name": "styleSheet", "$ref": "CSSStyleSheetBody", "descri ption": "Stylesheet contents for the specified <code>styleSheetId</code>." }
2446 ],
2447 "description": "Returns stylesheet data for the specified <code> styleSheetId</code>."
2448 },
2449 {
2450 "name": "getStyleSheetText",
2451 "parameters": [
2452 { "name": "styleSheetId", "$ref": "StyleSheetId" }
2453 ],
2454 "returns": [
2455 { "name": "text", "type": "string", "description": "The styl esheet text." }
2456 ],
2457 "description": "Returns the current textual content and the URL for a stylesheet."
2458 },
2459 {
2460 "name": "setStyleSheetText",
2461 "parameters": [
2462 { "name": "styleSheetId", "$ref": "StyleSheetId" },
2463 { "name": "text", "type": "string" }
2464 ],
2465 "description": "Sets the new stylesheet text, thereby invalidati ng all existing <code>CSSStyleId</code>'s and <code>CSSRuleId</code>'s contained by this stylesheet."
2466 },
2467 {
2468 "name": "setPropertyText",
2469 "parameters": [
2470 { "name": "styleId", "$ref": "CSSStyleId" },
2471 { "name": "propertyIndex", "type": "integer" },
2472 { "name": "text", "type": "string" },
2473 { "name": "overwrite", "type": "boolean" }
2474 ],
2475 "returns": [
2476 { "name": "style", "$ref": "CSSStyle", "description": "The r esulting style after the property text modification." }
2477 ],
2478 "description": "Sets the new <code>text</code> for a property in the respective style, at offset <code>propertyIndex</code>. If <code>overwrite< /code> is <code>true</code>, a property at the given offset is overwritten, othe rwise inserted. <code>text</code> entirely replaces the property <code>name: val ue</code>."
2479 },
2480 {
2481 "name": "toggleProperty",
2482 "parameters": [
2483 { "name": "styleId", "$ref": "CSSStyleId" },
2484 { "name": "propertyIndex", "type": "integer" },
2485 { "name": "disable", "type": "boolean" }
2486 ],
2487 "returns": [
2488 { "name": "style", "$ref": "CSSStyle", "description": "The r esulting style after the property toggling." }
2489 ],
2490 "description": "Toggles the property in the respective style, at offset <code>propertyIndex</code>. The <code>disable</code> parameter denotes w hether the property should be disabled (i.e. removed from the style declaration) . If <code>disable == false</code>, the property gets put back into its original place in the style declaration."
2491 },
2492 {
2493 "name": "setRuleSelector",
2494 "parameters": [
2495 { "name": "ruleId", "$ref": "CSSRuleId" },
2496 { "name": "selector", "type": "string" }
2497 ],
2498 "returns": [
2499 { "name": "rule", "$ref": "CSSRule", "description": "The res ulting rule after the selector modification." }
2500 ],
2501 "description": "Modifies the rule selector."
2502 },
2503 {
2504 "name": "addRule",
2505 "parameters": [
2506 { "name": "contextNodeId", "$ref": "DOM.NodeId" },
2507 { "name": "selector", "type": "string" }
2508 ],
2509 "returns": [
2510 { "name": "rule", "$ref": "CSSRule", "description": "The new ly created rule." }
2511 ],
2512 "description": "Creates a new empty rule with the given <code>se lector</code> in a special \"inspector\" stylesheet in the owner document of the context node."
2513 },
2514 {
2515 "name": "getSupportedCSSProperties",
2516 "returns": [
2517 { "name": "cssProperties", "type": "array", "items": { "$ref ": "CSSPropertyInfo" }, "description": "Supported property metainfo." }
2518 ],
2519 "description": "Returns all supported CSS property names."
2520 },
2521 {
2522 "name": "forcePseudoState",
2523 "parameters": [
2524 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "Th e element id for which to force the pseudo state." },
2525 { "name": "forcedPseudoClasses", "type": "array", "items": { "type": "string", "enum": ["active", "focus", "hover", "visited"] }, "descripti on": "Element pseudo classes to force when computing the element's style." }
2526 ],
2527 "description": "Ensures that the given node will have specified pseudo-classes whenever its style is computed by the browser."
2528 },
2529 {
2530 "name": "startSelectorProfiler"
2531 },
2532 {
2533 "name": "stopSelectorProfiler",
2534 "returns": [
2535 { "name": "profile", "$ref": "SelectorProfile" }
2536 ]
2537 },
2538 {
2539 "name": "getNamedFlowCollection",
2540 "parameters": [
2541 { "name": "documentNodeId", "$ref": "DOM.NodeId", "descripti on": "The document node id for which to get the Named Flow Collection." }
2542 ],
2543 "returns": [
2544 { "name": "namedFlows", "type": "array", "items": { "$ref": "NamedFlow" }, "description": "An array containing the Named Flows in the docume nt." }
2545 ],
2546 "description": "Returns the Named Flows from the document.",
2547 "hidden": true
2548 }
2549 ],
2550 "events": [
2551 {
2552 "name": "mediaQueryResultChanged",
2553 "description": "Fires whenever a MediaQuery result changes (for example, after a browser window has been resized.) The current implementation co nsiders only viewport-dependent media features."
2554 },
2555 {
2556 "name": "styleSheetChanged",
2557 "parameters": [
2558 { "name": "styleSheetId", "$ref": "StyleSheetId" }
2559 ],
2560 "description": "Fired whenever a stylesheet is changed as a resu lt of the client operation."
2561 },
2562 {
2563 "name": "namedFlowCreated",
2564 "parameters": [
2565 { "name": "namedFlow", "$ref": "NamedFlow", "description": " The new Named Flow." }
2566 ],
2567 "description": "Fires when a Named Flow is created.",
2568 "hidden": true
2569 },
2570 {
2571 "name": "namedFlowRemoved",
2572 "parameters": [
2573 { "name": "documentNodeId", "$ref": "DOM.NodeId", "descripti on": "The document node id." },
2574 { "name": "flowName", "type": "string", "description": "Iden tifier of the removed Named Flow." }
2575 ],
2576 "description": "Fires when a Named Flow is removed: has no assoc iated content nodes and regions.",
2577 "hidden": true
2578 },
2579 {
2580 "name": "regionLayoutUpdated",
2581 "parameters": [
2582 { "name": "namedFlow", "$ref": "NamedFlow", "description": " The Named Flow whose layout may have changed." }
2583 ],
2584 "description": "Fires when a Named Flow's layout may have change d.",
2585 "hidden": true
2586 }
2587 ]
2588 },
2589 {
2590 "domain": "Timeline",
2591 "description": "Timeline provides its clients with instrumentation recor ds that are generated during the page runtime. Timeline instrumentation can be s tarted and stopped using corresponding commands. While timeline is started, it i s generating timeline event records.",
2592 "types": [
2593 {
2594 "id": "TimelineEvent",
2595 "type": "object",
2596 "properties": [
2597 { "name": "type", "type": "string", "description": "Event ty pe." },
2598 { "name": "data", "type": "object", "description": "Event da ta." },
2599 { "name": "children", "type": "array", "optional": true, "it ems": { "$ref": "TimelineEvent" }, "description": "Nested records." }
2600 ],
2601 "description": "Timeline record contains information about the r ecorded activity."
2602 }
2603 ],
2604 "commands": [
2605 {
2606 "name": "start",
2607 "parameters": [
2608 { "name": "maxCallStackDepth", "optional": true, "type": "in teger", "description": "Samples JavaScript stack traces up to <code>maxCallStack Depth</code>, defaults to 5." }
2609 ],
2610 "description": "Starts capturing instrumentation events."
2611 },
2612 {
2613 "name": "stop",
2614 "description": "Stops capturing instrumentation events."
2615 },
2616 {
2617 "name": "setIncludeDomCounters",
2618 "parameters": [
2619 { "name": "enabled", "type": "boolean", "description": "Whet her DOM counters data should be included into timeline events." }
2620 ],
2621 "hidden": true,
2622 "description": "Controls if DOM counters should be send as part of timeline events."
2623 },
2624 {
2625 "name": "setIncludeNativeMemoryStatistics",
2626 "parameters": [
2627 { "name": "enabled", "type": "boolean", "description": "Whet her native memory usage statistics should be reported as part of timeline events ." }
2628 ],
2629 "hidden": true,
2630 "description": "Controls whether statistics on native memory usa ge is sent with timeline events."
2631 },
2632 {
2633 "name": "supportsFrameInstrumentation",
2634 "returns": [
2635 { "name": "result", "type": "boolean", "description": "True if timeline supports frame instrumentation." }
2636 ],
2637 "hidden": true,
2638 "description": "Tells whether timeline agent supports frame inst rumentation."
2639 },
2640 {
2641 "name": "canMonitorMainThread",
2642 "returns": [
2643 { "name": "result", "type": "boolean", "description": "True if timeline supports main thread CPU utilization instrumentation." }
2644 ],
2645 "hidden": true,
2646 "description": "Tells whether timeline agent supports main threa d CPU utilization instrumentation."
2647 }
2648 ],
2649 "events": [
2650 {
2651 "name": "eventRecorded",
2652 "parameters": [
2653 { "name": "record", "$ref": "TimelineEvent", "description": "Timeline event record data." }
2654 ],
2655 "description": "Fired for every instrumentation event while time line is started."
2656 }
2657 ]
2658 },
2659 {
2660 "domain": "Debugger",
2661 "description": "Debugger domain exposes JavaScript debugging capabilitie s. It allows setting and removing breakpoints, stepping through execution, explo ring stack traces, etc.",
2662 "types": [
2663 {
2664 "id": "BreakpointId",
2665 "type": "string",
2666 "description": "Breakpoint identifier."
2667 },
2668 {
2669 "id": "ScriptId",
2670 "type": "string",
2671 "description": "Unique script identifier."
2672 },
2673 {
2674 "id": "CallFrameId",
2675 "type": "string",
2676 "description": "Call frame identifier."
2677 },
2678 {
2679 "id": "Location",
2680 "type": "object",
2681 "properties": [
2682 { "name": "scriptId", "$ref": "ScriptId", "description": "Sc ript identifier as reported in the <code>Debugger.scriptParsed</code>." },
2683 { "name": "lineNumber", "type": "integer", "description": "L ine number in the script." },
2684 { "name": "columnNumber", "type": "integer", "optional": tru e, "description": "Column number in the script." }
2685 ],
2686 "description": "Location in the source code."
2687 },
2688 {
2689 "id": "FunctionDetails",
2690 "hidden": true,
2691 "type": "object",
2692 "properties": [
2693 { "name": "location", "$ref": "Location", "description": "Lo cation of the function." },
2694 { "name": "name", "type": "string", "optional": true, "descr iption": "Name of the function. Not present for anonymous functions." },
2695 { "name": "displayName", "type": "string", "optional": true, "description": "Display name of the function(specified in 'displayName' propert y on the function object)." },
2696 { "name": "inferredName", "type": "string", "optional": true , "description": "Name of the function inferred from its initial assignment." },
2697 { "name": "scopeChain", "type": "array", "optional": true, " items": { "$ref": "Scope" }, "description": "Scope chain for this closure." }
2698 ],
2699 "description": "Information about the function."
2700 },
2701 {
2702 "id": "CallFrame",
2703 "type": "object",
2704 "properties": [
2705 { "name": "callFrameId", "$ref": "CallFrameId", "description ": "Call frame identifier. This identifier is only valid while the virtual machi ne is paused." },
2706 { "name": "functionName", "type": "string", "description": " Name of the JavaScript function called on this call frame." },
2707 { "name": "location", "$ref": "Location", "description": "Lo cation in the source code." },
2708 { "name": "scopeChain", "type": "array", "items": { "$ref": "Scope" }, "description": "Scope chain for this call frame." },
2709 { "name": "this", "$ref": "Runtime.RemoteObject", "descripti on": "<code>this</code> object for this call frame." }
2710 ],
2711 "description": "JavaScript call frame. Array of call frames form the call stack."
2712 },
2713 {
2714 "id": "Scope",
2715 "type": "object",
2716 "properties": [
2717 { "name": "type", "type": "string", "enum": ["global", "loca l", "with", "closure", "catch"], "description": "Scope type." },
2718 { "name": "object", "$ref": "Runtime.RemoteObject", "descrip tion": "Object representing the scope. For <code>global</code> and <code>with</c ode> scopes it represents the actual object; for the rest of the scopes, it is a rtificial transient object enumerating scope variables as its properties." }
2719 ],
2720 "description": "Scope description."
2721 }
2722 ],
2723 "commands": [
2724 {
2725 "name": "causesRecompilation",
2726 "returns": [
2727 { "name": "result", "type": "boolean", "description": "True if enabling debugger causes scripts recompilation." }
2728 ],
2729 "hidden": true,
2730 "description": "Tells whether enabling debugger causes scripts r ecompilation."
2731 },
2732 {
2733 "name": "supportsSeparateScriptCompilationAndExecution",
2734 "returns": [
2735 { "name": "result", "type": "boolean", "description": "True if debugger supports separate script compilation and execution." }
2736 ],
2737 "hidden": true,
2738 "description": "Tells whether debugger supports separate script compilation and execution."
2739 },
2740 {
2741 "name": "enable",
2742 "description": "Enables debugger for the given page. Clients sho uld not assume that the debugging has been enabled until the result for this com mand is received."
2743 },
2744 {
2745 "name": "disable",
2746 "description": "Disables debugger for given page."
2747 },
2748 {
2749 "name": "setBreakpointsActive",
2750 "parameters": [
2751 { "name": "active", "type": "boolean", "description": "New v alue for breakpoints active state." }
2752 ],
2753 "description": "Activates / deactivates all breakpoints on the p age."
2754 },
2755 {
2756 "name": "setBreakpointByUrl",
2757 "parameters": [
2758 { "name": "lineNumber", "type": "integer", "description": "L ine number to set breakpoint at." },
2759 { "name": "url", "type": "string", "optional": true, "descri ption": "URL of the resources to set breakpoint on." },
2760 { "name": "urlRegex", "type": "string", "optional": true, "d escription": "Regex pattern for the URLs of the resources to set breakpoints on. Either <code>url</code> or <code>urlRegex</code> must be specified." },
2761 { "name": "columnNumber", "type": "integer", "optional": tru e, "description": "Offset in the line to set breakpoint at." },
2762 { "name": "condition", "type": "string", "optional": true, " description": "Expression to use as a breakpoint condition. When specified, debu gger will only stop on the breakpoint if this expression evaluates to true." }
2763 ],
2764 "returns": [
2765 { "name": "breakpointId", "$ref": "BreakpointId", "descripti on": "Id of the created breakpoint for further reference." },
2766 { "name": "locations", "type": "array", "items": { "$ref": " Location"}, "description": "List of the locations this breakpoint resolved into upon addition." }
2767 ],
2768 "description": "Sets JavaScript breakpoint at given location spe cified either by URL or URL regex. Once this command is issued, all existing par sed scripts will have breakpoints resolved and returned in <code>locations</code > property. Further matching script parsing will result in subsequent <code>brea kpointResolved</code> events issued. This logical breakpoint will survive page r eloads."
2769 },
2770 {
2771 "name": "setBreakpoint",
2772 "parameters": [
2773 { "name": "location", "$ref": "Location", "description": "Lo cation to set breakpoint in." },
2774 { "name": "condition", "type": "string", "optional": true, " description": "Expression to use as a breakpoint condition. When specified, debu gger will only stop on the breakpoint if this expression evaluates to true." }
2775 ],
2776 "returns": [
2777 { "name": "breakpointId", "$ref": "BreakpointId", "descripti on": "Id of the created breakpoint for further reference." },
2778 { "name": "actualLocation", "$ref": "Location", "description ": "Location this breakpoint resolved into." }
2779 ],
2780 "description": "Sets JavaScript breakpoint at a given location."
2781 },
2782 {
2783 "name": "removeBreakpoint",
2784 "parameters": [
2785 { "name": "breakpointId", "$ref": "BreakpointId" }
2786 ],
2787 "description": "Removes JavaScript breakpoint."
2788 },
2789 {
2790 "name": "continueToLocation",
2791 "parameters": [
2792 { "name": "location", "$ref": "Location", "description": "Lo cation to continue to." }
2793 ],
2794 "description": "Continues execution until specific location is r eached."
2795 },
2796 {
2797 "name": "stepOver",
2798 "description": "Steps over the statement."
2799 },
2800 {
2801 "name": "stepInto",
2802 "description": "Steps into the function call."
2803 },
2804 {
2805 "name": "stepOut",
2806 "description": "Steps out of the function call."
2807 },
2808 {
2809 "name": "pause",
2810 "description": "Stops on the next JavaScript statement."
2811 },
2812 {
2813 "name": "resume",
2814 "description": "Resumes JavaScript execution."
2815 },
2816 {
2817 "name": "searchInContent",
2818 "parameters": [
2819 { "name": "scriptId", "$ref": "ScriptId", "description": "Id of the script to search in." },
2820 { "name": "query", "type": "string", "description": "String to search for." },
2821 { "name": "caseSensitive", "type": "boolean", "optional": tr ue, "description": "If true, search is case sensitive." },
2822 { "name": "isRegex", "type": "boolean", "optional": true, "d escription": "If true, treats string parameter as regex." }
2823 ],
2824 "returns": [
2825 { "name": "result", "type": "array", "items": { "$ref": "Pag e.SearchMatch" }, "description": "List of search matches." }
2826 ],
2827 "description": "Searches for given string in script content."
2828 },
2829 {
2830 "name": "canSetScriptSource",
2831 "returns": [
2832 { "name": "result", "type": "boolean", "description": "True if <code>setScriptSource</code> is supported." }
2833 ],
2834 "description": "Tells whether <code>setScriptSource</code> is su pported."
2835 },
2836 {
2837 "name": "setScriptSource",
2838 "parameters": [
2839 { "name": "scriptId", "$ref": "ScriptId", "description": "Id of the script to edit." },
2840 { "name": "scriptSource", "type": "string", "description": " New content of the script." },
2841 { "name": "preview", "type": "boolean", "optional": true, "d escription": " If true the change will not actually be applied. Preview mode may be used to get result description without actually modifying the code.", "hidde n": true }
2842 ],
2843 "returns": [
2844 { "name": "callFrames", "type": "array", "optional": true, " items": { "$ref": "CallFrame"}, "description": "New stack trace in case editing has happened while VM was stopped." },
2845 { "name": "result", "type": "object", "optional": true, "des cription": "VM-specific description of the changes applied.", "hidden": true }
2846 ],
2847 "description": "Edits JavaScript source live."
2848 },
2849 {
2850 "name": "restartFrame",
2851 "parameters": [
2852 { "name": "callFrameId", "$ref": "CallFrameId", "description ": "Call frame identifier to evaluate on." }
2853 ],
2854 "returns": [
2855 { "name": "callFrames", "type": "array", "items": { "$ref": "CallFrame"}, "description": "New stack trace." },
2856 { "name": "result", "type": "object", "description": "VM-spe cific description.", "hidden": true }
2857 ],
2858 "hidden": true,
2859 "description": "Restarts particular call frame from the beginnin g."
2860 },
2861 {
2862 "name": "getScriptSource",
2863 "parameters": [
2864 { "name": "scriptId", "$ref": "ScriptId", "description": "Id of the script to get source for." }
2865 ],
2866 "returns": [
2867 { "name": "scriptSource", "type": "string", "description": " Script source." }
2868 ],
2869 "description": "Returns source for the script with given id."
2870 },
2871 {
2872 "name": "getFunctionDetails",
2873 "hidden": true,
2874 "parameters": [
2875 { "name": "functionId", "$ref": "Runtime.RemoteObjectId", "d escription": "Id of the function to get location for." }
2876 ],
2877 "returns": [
2878 { "name": "details", "$ref": "FunctionDetails", "description ": "Information about the function." }
2879 ],
2880 "description": "Returns detailed informtation on given function. "
2881 },
2882 {
2883 "name": "setPauseOnExceptions",
2884 "parameters": [
2885 { "name": "state", "type": "string", "enum": ["none", "uncau ght", "all"], "description": "Pause on exceptions mode." }
2886 ],
2887 "description": "Defines pause on exceptions state. Can be set to stop on all exceptions, uncaught exceptions or no exceptions. Initial pause on exceptions state is <code>none</code>."
2888 },
2889 {
2890 "name": "evaluateOnCallFrame",
2891 "parameters": [
2892 { "name": "callFrameId", "$ref": "CallFrameId", "description ": "Call frame identifier to evaluate on." },
2893 { "name": "expression", "type": "string", "description": "Ex pression to evaluate." },
2894 { "name": "objectGroup", "type": "string", "optional": true, "description": "String object group name to put result into (allows rapid relea sing resulting object handles using <code>releaseObjectGroup</code>)." },
2895 { "name": "includeCommandLineAPI", "type": "boolean", "optio nal": true, "description": "Specifies whether command line API should be availab le to the evaluated expression, defaults to false.", "hidden": true },
2896 { "name": "doNotPauseOnExceptionsAndMuteConsole", "type": "b oolean", "optional": true, "description": "Specifies whether evaluation should s top on exceptions and mute console. Overrides setPauseOnException state.", "hidd en": true },
2897 { "name": "returnByValue", "type": "boolean", "optional": tr ue, "description": "Whether the result is expected to be a JSON object that shou ld be sent by value." },
2898 { "name": "generatePreview", "type": "boolean", "optional": true, "hidden": true, "description": "Whether preview should be generated for th e result." }
2899 ],
2900 "returns": [
2901 { "name": "result", "$ref": "Runtime.RemoteObject", "descrip tion": "Object wrapper for the evaluation result." },
2902 { "name": "wasThrown", "type": "boolean", "optional": true, "description": "True if the result was thrown during the evaluation." }
2903 ],
2904 "description": "Evaluates expression on a given call frame."
2905 },
2906 {
2907 "name": "compileScript",
2908 "hidden": true,
2909 "parameters": [
2910 { "name": "expression", "type": "string", "description": "Ex pression to compile." },
2911 { "name": "sourceURL", "type": "string", "description": "Sou rce url to be set for the script." }
2912 ],
2913 "returns": [
2914 { "name": "scriptId", "$ref": "ScriptId", "optional": true, "description": "Id of the script." },
2915 { "name": "syntaxErrorMessage", "type": "string", "optional" : true, "description": "Syntax error message if compilation failed." }
2916 ],
2917 "description": "Compiles expression."
2918 },
2919 {
2920 "name": "runScript",
2921 "hidden": true,
2922 "parameters": [
2923 { "name": "scriptId", "$ref": "ScriptId", "description": "Id of the script to run." },
2924 { "name": "contextId", "$ref": "Runtime.ExecutionContextId", "optional": true, "description": "Specifies in which isolated context to perfor m script run. Each content script lives in an isolated context and this paramete r may be used to specify one of those contexts. If the parameter is omitted or 0 the evaluation will be performed in the context of the inspected page." },
2925 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple object s." },
2926 { "name": "doNotPauseOnExceptionsAndMuteConsole", "type": "b oolean", "optional": true, "description": "Specifies whether script run should s top on exceptions and mute console. Overrides setPauseOnException state." }
2927 ],
2928 "returns": [
2929 { "name": "result", "$ref": "Runtime.RemoteObject", "descrip tion": "Run result." },
2930 { "name": "wasThrown", "type": "boolean", "optional": true, "description": "True if the result was thrown during the script run." }
2931 ],
2932 "description": "Runs script with given id in a given context."
2933 },
2934 {
2935 "name": "setOverlayMessage",
2936 "parameters": [
2937 { "name": "message", "type": "string", "optional": true, "de scription": "Overlay message to display when paused in debugger." }
2938 ],
2939 "hidden": true,
2940 "description": "Sets overlay message."
2941 },
2942 {
2943 "name": "setVariableValue",
2944 "parameters": [
2945 { "name": "scopeNumber", "type": "integer", "description": " 0-based number of scope as was listed in scope chain. Only 'local', 'closure' an d 'catch' scope types are allowed. Other scopes could be manipulated manually." },
2946 { "name": "variableName", "type": "string", "description": " Variable name." },
2947 { "name": "newValue", "$ref": "Runtime.CallArgument", "descr iption": "New variable value." },
2948 { "name": "callFrameId", "$ref": "CallFrameId", "optional": true, "description": "Id of callframe that holds variable." },
2949 { "name": "functionObjectId", "$ref": "Runtime.RemoteObjectI d", "optional": true, "description": "Object id of closure (function) that holds variable." }
2950 ],
2951 "hidden": true,
2952 "description": "Changes value of variable in a callframe or a cl osure. Either callframe or function must be specified. Object-based scopes are n ot supported and must be mutated manually."
2953 }
2954 ],
2955 "events": [
2956 {
2957 "name": "globalObjectCleared",
2958 "description": "Called when global has been cleared and debugger client should reset its state. Happens upon navigation or reload."
2959 },
2960 {
2961 "name": "scriptParsed",
2962 "parameters": [
2963 { "name": "scriptId", "$ref": "ScriptId", "description": "Id entifier of the script parsed." },
2964 { "name": "url", "type": "string", "description": "URL or na me of the script parsed (if any)." },
2965 { "name": "startLine", "type": "integer", "description": "Li ne offset of the script within the resource with given URL (for script tags)." } ,
2966 { "name": "startColumn", "type": "integer", "description": " Column offset of the script within the resource with given URL." },
2967 { "name": "endLine", "type": "integer", "description": "Last line of the script." },
2968 { "name": "endColumn", "type": "integer", "description": "Le ngth of the last line of the script." },
2969 { "name": "isContentScript", "type": "boolean", "optional": true, "description": "Determines whether this script is a user extension script. " },
2970 { "name": "sourceMapURL", "type": "string", "optional": true , "description": "URL of source map associated with script (if any)." },
2971 { "name": "hasSourceURL", "type": "boolean", "optional": tru e, "description": "True, if this script has sourceURL." }
2972 ],
2973 "description": "Fired when virtual machine parses script. This e vent is also fired for all known and uncollected scripts upon enabling debugger. "
2974 },
2975 {
2976 "name": "scriptFailedToParse",
2977 "parameters": [
2978 { "name": "url", "type": "string", "description": "URL of th e script that failed to parse." },
2979 { "name": "scriptSource", "type": "string", "description": " Source text of the script that failed to parse." },
2980 { "name": "startLine", "type": "integer", "description": "Li ne offset of the script within the resource." },
2981 { "name": "errorLine", "type": "integer", "description": "Li ne with error." },
2982 { "name": "errorMessage", "type": "string", "description": " Parse error message." }
2983 ],
2984 "description": "Fired when virtual machine fails to parse the sc ript."
2985 },
2986 {
2987 "name": "breakpointResolved",
2988 "parameters": [
2989 { "name": "breakpointId", "$ref": "BreakpointId", "descripti on": "Breakpoint unique identifier." },
2990 { "name": "location", "$ref": "Location", "description": "Ac tual breakpoint location." }
2991 ],
2992 "description": "Fired when breakpoint is resolved to an actual s cript and location."
2993 },
2994 {
2995 "name": "paused",
2996 "parameters": [
2997 { "name": "callFrames", "type": "array", "items": { "$ref": "CallFrame" }, "description": "Call stack the virtual machine stopped on." },
2998 { "name": "reason", "type": "string", "enum": [ "XHR", "DOM" , "EventListener", "exception", "assert", "CSPViolation", "other" ], "descriptio n": "Pause reason." },
2999 { "name": "data", "type": "object", "optional": true, "descr iption": "Object containing break-specific auxiliary properties." }
3000 ],
3001 "description": "Fired when the virtual machine stopped on breakp oint or exception or any other stop criteria."
3002 },
3003 {
3004 "name": "resumed",
3005 "description": "Fired when the virtual machine resumed execution ."
3006 }
3007 ]
3008 },
3009 {
3010 "domain": "DOMDebugger",
3011 "description": "DOM debugging allows setting breakpoints on particular D OM operations and events. JavaScript execution will stop on these operations as if there was a regular breakpoint set.",
3012 "types": [
3013 {
3014 "id": "DOMBreakpointType",
3015 "type": "string",
3016 "enum": ["subtree-modified", "attribute-modified", "node-removed "],
3017 "description": "DOM breakpoint type."
3018 }
3019 ],
3020 "commands": [
3021 {
3022 "name": "setDOMBreakpoint",
3023 "parameters": [
3024 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "Id entifier of the node to set breakpoint on." },
3025 { "name": "type", "$ref": "DOMBreakpointType", "description" : "Type of the operation to stop upon." }
3026 ],
3027 "description": "Sets breakpoint on particular operation with DOM ."
3028 },
3029 {
3030 "name": "removeDOMBreakpoint",
3031 "parameters": [
3032 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "Id entifier of the node to remove breakpoint from." },
3033 { "name": "type", "$ref": "DOMBreakpointType", "description" : "Type of the breakpoint to remove." }
3034 ],
3035 "description": "Removes DOM breakpoint that was set using <code> setDOMBreakpoint</code>."
3036 },
3037 {
3038 "name": "setEventListenerBreakpoint",
3039 "parameters": [
3040 { "name": "eventName", "type": "string", "description": "DOM Event name to stop on (any DOM event will do)." }
3041 ],
3042 "description": "Sets breakpoint on particular DOM event."
3043 },
3044 {
3045 "name": "removeEventListenerBreakpoint",
3046 "parameters": [
3047 { "name": "eventName", "type": "string", "description": "Eve nt name." }
3048 ],
3049 "description": "Removes breakpoint on particular DOM event."
3050 },
3051 {
3052 "name": "setInstrumentationBreakpoint",
3053 "parameters": [
3054 { "name": "eventName", "type": "string", "description": "Ins trumentation name to stop on." }
3055 ],
3056 "description": "Sets breakpoint on particular native event.",
3057 "hidden": true
3058 },
3059 {
3060 "name": "removeInstrumentationBreakpoint",
3061 "parameters": [
3062 { "name": "eventName", "type": "string", "description": "Ins trumentation name to stop on." }
3063 ],
3064 "description": "Sets breakpoint on particular native event.",
3065 "hidden": true
3066 },
3067 {
3068 "name": "setXHRBreakpoint",
3069 "parameters": [
3070 { "name": "url", "type": "string", "description": "Resource URL substring. All XHRs having this substring in the URL will get stopped upon." }
3071 ],
3072 "description": "Sets breakpoint on XMLHttpRequest."
3073 },
3074 {
3075 "name": "removeXHRBreakpoint",
3076 "parameters": [
3077 { "name": "url", "type": "string", "description": "Resource URL substring." }
3078 ],
3079 "description": "Removes breakpoint from XMLHttpRequest."
3080 }
3081 ]
3082 },
3083 {
3084 "domain": "Profiler",
3085 "hidden": true,
3086 "types": [
3087 {
3088 "id": "ProfileHeader",
3089 "type": "object",
3090 "description": "Profile header.",
3091 "properties": [
3092 { "name": "typeId", "type": "string", "enum": ["CPU", "CSS", "HEAP"], "description": "Profile type name." },
3093 { "name": "title", "type": "string", "description": "Profile title." },
3094 { "name": "uid", "type": "integer", "description": "Unique i dentifier of the profile." },
3095 { "name": "maxJSObjectId", "type": "integer", "optional": tr ue, "description": "Last seen JS object Id." }
3096 ]
3097 },
3098 {
3099 "id": "CPUProfileNode",
3100 "type": "object",
3101 "description": "CPU Profile node. Holds callsite information, ex ecution statistics and child nodes.",
3102 "properties": [
3103 { "name": "functionName", "type": "string", "description": " Function name." },
3104 { "name": "url", "type": "string", "description": "URL." },
3105 { "name": "lineNumber", "type": "integer", "description": "L ine number." },
3106 { "name": "totalTime", "type": "number", "description": "Tot al execution time." },
3107 { "name": "selfTime", "type": "number", "description": "Self time." },
3108 { "name": "numberOfCalls", "type": "integer", "description": "Number of calls." },
3109 { "name": "visible", "type": "boolean", "description": "Visi bility." },
3110 { "name": "callUID", "type": "number", "description": "Call UID." },
3111 { "name": "children", "type": "array", "items": { "$ref": "C PUProfileNode" }, "description": "Child nodes." }
3112 ]
3113 },
3114 {
3115 "id": "CPUProfile",
3116 "type": "object",
3117 "description": "Profile.",
3118 "properties": [
3119 { "name": "head", "$ref": "CPUProfileNode", "optional": true },
3120 { "name": "bottomUpHead", "$ref": "CPUProfileNode", "optiona l": true },
3121 { "name": "idleTime", "type": "number", "optional": true }
3122 ]
3123 },
3124 {
3125 "id": "HeapSnapshotObjectId",
3126 "type": "string",
3127 "description": "Heap snashot object id."
3128 }
3129 ],
3130 "commands": [
3131 {
3132 "name": "causesRecompilation",
3133 "returns": [
3134 { "name": "result", "type": "boolean" }
3135 ]
3136 },
3137 {
3138 "name": "isSampling",
3139 "returns": [
3140 { "name": "result", "type": "boolean" }
3141 ]
3142 },
3143 {
3144 "name": "hasHeapProfiler",
3145 "returns": [
3146 { "name": "result", "type": "boolean" }
3147 ]
3148 },
3149 {
3150 "name": "enable"
3151 },
3152 {
3153 "name": "disable"
3154 },
3155 {
3156 "name": "start"
3157 },
3158 {
3159 "name": "stop"
3160 },
3161 {
3162 "name": "getProfileHeaders",
3163 "returns": [
3164 { "name": "headers", "type": "array", "items": { "$ref": "Pr ofileHeader"} }
3165 ]
3166 },
3167 {
3168 "name": "getCPUProfile",
3169 "parameters": [
3170 { "name": "uid", "type": "integer" }
3171 ],
3172 "returns": [
3173 { "name": "profile", "$ref": "CPUProfile" }
3174 ]
3175 },
3176 {
3177 "name": "getHeapSnapshot",
3178 "parameters": [
3179 { "name": "uid", "type": "integer" }
3180 ]
3181 },
3182 {
3183 "name": "removeProfile",
3184 "parameters": [
3185 { "name": "type", "type": "string" },
3186 { "name": "uid", "type": "integer" }
3187 ]
3188 },
3189 {
3190 "name": "clearProfiles"
3191 },
3192 {
3193 "name": "takeHeapSnapshot",
3194 "parameters": [
3195 { "name": "reportProgress", "type": "boolean", "optional": t rue, "description": "If true 'reportHeapSnapshotProgress' events will be generat ed while snapshot is being taken." }
3196 ]
3197 },
3198 {
3199 "name": "collectGarbage"
3200 },
3201 {
3202 "name": "getObjectByHeapObjectId",
3203 "parameters": [
3204 { "name": "objectId", "$ref": "HeapSnapshotObjectId" },
3205 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple object s." }
3206 ],
3207 "returns": [
3208 { "name": "result", "$ref": "Runtime.RemoteObject", "descrip tion": "Evaluation result." }
3209 ]
3210 },
3211 {
3212 "name": "getHeapObjectId",
3213 "parameters": [
3214 { "name": "objectId", "$ref": "Runtime.RemoteObjectId", "des cription": "Identifier of the object to get heap object id for." }
3215 ],
3216 "returns": [
3217 { "name": "heapSnapshotObjectId", "$ref": "HeapSnapshotObjec tId", "description": "Id of the heap snapshot object corresponding to the passed remote object id." }
3218 ]
3219 }
3220 ],
3221 "events": [
3222 {
3223 "name": "addProfileHeader",
3224 "parameters": [
3225 { "name": "header", "$ref": "ProfileHeader" }
3226 ]
3227 },
3228 {
3229 "name": "addHeapSnapshotChunk",
3230 "parameters": [
3231 { "name": "uid", "type": "integer" },
3232 { "name": "chunk", "type": "string" }
3233 ]
3234 },
3235 {
3236 "name": "finishHeapSnapshot",
3237 "parameters": [
3238 { "name": "uid", "type": "integer" }
3239 ]
3240 },
3241 {
3242 "name": "setRecordingProfile",
3243 "parameters": [
3244 { "name": "isProfiling", "type": "boolean" }
3245 ]
3246 },
3247 {
3248 "name": "resetProfiles"
3249 },
3250 {
3251 "name": "reportHeapSnapshotProgress",
3252 "parameters": [
3253 { "name": "done", "type": "integer" },
3254 { "name": "total", "type": "integer" }
3255 ]
3256 }
3257 ]
3258 },
3259 {
3260 "domain": "HeapProfiler",
3261 "hidden": true,
3262 "types": [
3263 {
3264 "id": "ProfileHeader",
3265 "type": "object",
3266 "description": "Profile header.",
3267 "properties": [
3268 { "name": "title", "type": "string", "description": "Profile title." },
3269 { "name": "uid", "type": "integer", "description": "Unique i dentifier of the profile." },
3270 { "name": "maxJSObjectId", "type": "integer", "optional": tr ue, "description": "Last seen JS object Id." }
3271 ]
3272 },
3273 {
3274 "id": "HeapSnapshotObjectId",
3275 "type": "string",
3276 "description": "Heap snashot object id."
3277 }
3278 ],
3279 "commands": [
3280 {
3281 "name": "hasHeapProfiler",
3282 "returns": [
3283 { "name": "result", "type": "boolean" }
3284 ]
3285 },
3286 {
3287 "name": "getProfileHeaders",
3288 "returns": [
3289 { "name": "headers", "type": "array", "items": { "$ref": "Pr ofileHeader"} }
3290 ]
3291 },
3292 {
3293 "name": "getHeapSnapshot",
3294 "parameters": [
3295 { "name": "uid", "type": "integer" }
3296 ]
3297 },
3298 {
3299 "name": "removeProfile",
3300 "parameters": [
3301 { "name": "uid", "type": "integer" }
3302 ]
3303 },
3304 {
3305 "name": "clearProfiles"
3306 },
3307 {
3308 "name": "takeHeapSnapshot",
3309 "parameters": [
3310 { "name": "reportProgress", "type": "boolean", "optional": t rue, "description": "If true 'reportHeapSnapshotProgress' events will be generat ed while snapshot is being taken." }
3311 ]
3312 },
3313 {
3314 "name": "collectGarbage"
3315 },
3316 {
3317 "name": "getObjectByHeapObjectId",
3318 "parameters": [
3319 { "name": "objectId", "$ref": "HeapSnapshotObjectId" },
3320 { "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple object s." }
3321 ],
3322 "returns": [
3323 { "name": "result", "$ref": "Runtime.RemoteObject", "descrip tion": "Evaluation result." }
3324 ]
3325 },
3326 {
3327 "name": "getHeapObjectId",
3328 "parameters": [
3329 { "name": "objectId", "$ref": "Runtime.RemoteObjectId", "des cription": "Identifier of the object to get heap object id for." }
3330 ],
3331 "returns": [
3332 { "name": "heapSnapshotObjectId", "$ref": "HeapSnapshotObjec tId", "description": "Id of the heap snapshot object corresponding to the passed remote object id." }
3333 ]
3334 }
3335 ],
3336 "events": [
3337 {
3338 "name": "addProfileHeader",
3339 "parameters": [
3340 { "name": "header", "$ref": "ProfileHeader" }
3341 ]
3342 },
3343 {
3344 "name": "addHeapSnapshotChunk",
3345 "parameters": [
3346 { "name": "uid", "type": "integer" },
3347 { "name": "chunk", "type": "string" }
3348 ]
3349 },
3350 {
3351 "name": "finishHeapSnapshot",
3352 "parameters": [
3353 { "name": "uid", "type": "integer" }
3354 ]
3355 },
3356 {
3357 "name": "resetProfiles"
3358 },
3359 {
3360 "name": "reportHeapSnapshotProgress",
3361 "parameters": [
3362 { "name": "done", "type": "integer" },
3363 { "name": "total", "type": "integer" }
3364 ]
3365 }
3366 ]
3367 },
3368 {
3369 "domain": "Worker",
3370 "hidden": true,
3371 "types": [],
3372 "commands": [
3373 {
3374 "name": "enable"
3375 },
3376 {
3377 "name": "disable"
3378 },
3379 {
3380 "name": "sendMessageToWorker",
3381 "parameters": [
3382 { "name": "workerId", "type": "integer" },
3383 { "name": "message", "type": "object" }
3384 ]
3385 },
3386 {
3387 "name": "connectToWorker",
3388 "parameters": [
3389 { "name": "workerId", "type": "integer" }
3390 ]
3391 },
3392 {
3393 "name": "disconnectFromWorker",
3394 "parameters": [
3395 { "name": "workerId", "type": "integer" }
3396 ]
3397 },
3398 {
3399 "name": "setAutoconnectToWorkers",
3400 "parameters": [
3401 { "name": "value", "type": "boolean" }
3402 ]
3403 }
3404 ],
3405 "events": [
3406 {
3407 "name": "workerCreated",
3408 "parameters": [
3409 { "name": "workerId", "type": "integer" },
3410 { "name": "url", "type": "string" },
3411 { "name": "inspectorConnected", "type": "boolean" }
3412 ]
3413 },
3414 {
3415 "name": "workerTerminated",
3416 "parameters": [
3417 { "name": "workerId", "type": "integer" }
3418 ]
3419 },
3420 {
3421 "name": "dispatchMessageFromWorker",
3422 "parameters": [
3423 { "name": "workerId", "type": "integer" },
3424 { "name": "message", "type": "object" }
3425 ]
3426 },
3427 {
3428 "name": "disconnectedFromWorker"
3429 }
3430 ]
3431 },
3432 {
3433 "domain": "Canvas",
3434 "hidden": true,
3435 "types": [
3436 {
3437 "id": "ResourceId",
3438 "type": "string",
3439 "description": "Unique resource identifier."
3440 },
3441 {
3442 "id": "ResourceInfo",
3443 "type": "object",
3444 "properties": [
3445 { "name": "id", "$ref": "ResourceId" },
3446 { "name": "description", "type": "string" }
3447 ]
3448 },
3449 {
3450 "id": "ResourceState",
3451 "type": "object",
3452 "properties": [
3453 { "name": "id", "$ref": "ResourceId" },
3454 { "name": "traceLogId", "$ref": "TraceLogId" },
3455 { "name": "imageURL", "type": "string", "optional": true, "d escription": "Screenshot image data URL." }
3456 ]
3457 },
3458 {
3459 "id": "CallArgument",
3460 "type": "object",
3461 "properties": [
3462 { "name": "description", "type": "string" }
3463 ]
3464 },
3465 {
3466 "id": "Call",
3467 "type": "object",
3468 "properties": [
3469 { "name": "contextId", "$ref": "ResourceId" },
3470 { "name": "functionName", "type": "string", "optional": true },
3471 { "name": "arguments", "type": "array", "items": { "$ref": " CallArgument" }, "optional": true },
3472 { "name": "result", "$ref": "CallArgument", "optional": true },
3473 { "name": "isDrawingCall", "type": "boolean", "optional": tr ue },
3474 { "name": "isFrameEndCall", "type": "boolean", "optional": t rue },
3475 { "name": "property", "type": "string", "optional": true },
3476 { "name": "value", "$ref": "CallArgument", "optional": true },
3477 { "name": "sourceURL", "type": "string", "optional": true },
3478 { "name": "lineNumber", "type": "integer", "optional": true },
3479 { "name": "columnNumber", "type": "integer", "optional": tru e }
3480 ]
3481 },
3482 {
3483 "id": "TraceLogId",
3484 "type": "string",
3485 "description": "Unique trace log identifier."
3486 },
3487 {
3488 "id": "TraceLog",
3489 "type": "object",
3490 "properties": [
3491 { "name": "id", "$ref": "TraceLogId" },
3492 { "name": "calls", "type": "array", "items": { "$ref": "Call " } },
3493 { "name": "startOffset", "type": "integer" },
3494 { "name": "alive", "type": "boolean" },
3495 { "name": "totalAvailableCalls", "type": "number" }
3496 ]
3497 }
3498 ],
3499 "commands": [
3500 {
3501 "name": "enable",
3502 "description": "Enables Canvas inspection."
3503 },
3504 {
3505 "name": "disable",
3506 "description": "Disables Canvas inspection."
3507 },
3508 {
3509 "name": "dropTraceLog",
3510 "parameters": [
3511 { "name": "traceLogId", "$ref": "TraceLogId" }
3512 ]
3513 },
3514 {
3515 "name": "hasUninstrumentedCanvases",
3516 "returns": [
3517 { "name": "result", "type": "boolean" }
3518 ],
3519 "description": "Checks if there is any uninstrumented canvas in the inspected page."
3520 },
3521 {
3522 "name": "captureFrame",
3523 "parameters": [
3524 { "name": "frameId", "$ref": "Network.FrameId", "optional": true, "description": "Identifier of the frame containing document whose canvases are to be captured. If omitted, main frame is assumed." }
3525 ],
3526 "returns": [
3527 { "name": "traceLogId", "$ref": "TraceLogId", "description": "Identifier of the trace log containing captured canvas calls." }
3528 ],
3529 "description": "Starts (or continues) a canvas frame capturing w hich will be stopped automatically after the next frame is prepared."
3530 },
3531 {
3532 "name": "startCapturing",
3533 "parameters": [
3534 { "name": "frameId", "$ref": "Network.FrameId", "optional": true, "description": "Identifier of the frame containing document whose canvases are to be captured. If omitted, main frame is assumed." }
3535 ],
3536 "returns": [
3537 { "name": "traceLogId", "$ref": "TraceLogId", "description": "Identifier of the trace log containing captured canvas calls." }
3538 ],
3539 "description": "Starts (or continues) consecutive canvas frames capturing. The capturing is stopped by the corresponding stopCapturing command."
3540 },
3541 {
3542 "name": "stopCapturing",
3543 "parameters": [
3544 { "name": "traceLogId", "$ref": "TraceLogId" }
3545 ]
3546 },
3547 {
3548 "name": "getTraceLog",
3549 "parameters": [
3550 { "name": "traceLogId", "$ref": "TraceLogId" },
3551 { "name": "startOffset", "type": "integer", "optional": true },
3552 { "name": "maxLength", "type": "integer", "optional": true }
3553 ],
3554 "returns": [
3555 { "name": "traceLog", "$ref": "TraceLog" }
3556 ]
3557 },
3558 {
3559 "name": "replayTraceLog",
3560 "parameters": [
3561 { "name": "traceLogId", "$ref": "TraceLogId" },
3562 { "name": "stepNo", "type": "integer" }
3563 ],
3564 "returns": [
3565 { "name": "resourceState", "$ref": "ResourceState" }
3566 ]
3567 },
3568 {
3569 "name": "getResourceInfo",
3570 "parameters": [
3571 { "name": "resourceId", "$ref": "ResourceId" }
3572 ],
3573 "returns": [
3574 { "name": "resourceInfo", "$ref": "ResourceInfo" }
3575 ]
3576 },
3577 {
3578 "name": "getResourceState",
3579 "parameters": [
3580 { "name": "traceLogId", "$ref": "TraceLogId" },
3581 { "name": "resourceId", "$ref": "ResourceId" }
3582 ],
3583 "returns": [
3584 { "name": "resourceState", "$ref": "ResourceState" }
3585 ]
3586 }
3587 ],
3588 "events": [
3589 {
3590 "name": "contextCreated",
3591 "parameters": [
3592 { "name": "frameId", "$ref": "Network.FrameId", "description ": "Identifier of the frame containing a canvas with a context." }
3593 ],
3594 "description": "Fired when a canvas context has been created in the given frame. The context may not be instrumented (see hasUninstrumentedCanva ses command)."
3595 },
3596 {
3597 "name": "traceLogsRemoved",
3598 "parameters": [
3599 { "name": "frameId", "$ref": "Network.FrameId", "optional": true, "description": "If given, trace logs from the given frame were removed." } ,
3600 { "name": "traceLogId", "$ref": "TraceLogId", "optional": tr ue, "description": "If given, trace log with the given ID was removed." }
3601 ],
3602 "description": "Fired when a set of trace logs were removed from the backend. If no parameters are given, all trace logs were removed."
3603 }
3604 ]
3605 },
3606 {
3607 "domain": "Input",
3608 "hidden": true,
3609 "types": [],
3610 "commands": [
3611 {
3612 "name": "dispatchKeyEvent",
3613 "parameters": [
3614 { "name": "type", "type": "string", "enum": ["keyDown", "key Up", "rawKeyDown", "char"], "description": "Type of the key event." },
3615 { "name": "modifiers", "type": "integer", "optional": true, "description": "Bit field representing pressed modifier keys. Alt=1, Ctrl=2, Met a/Command=4, Shift=8 (default: 0)." },
3616 { "name": "timestamp", "type": "number", "optional": true, " description": "Time at which the event occurred. Measured in UTC time in seconds since January 1, 1970 (default: current time)." },
3617 { "name": "text", "type": "string", "optional": true, "descr iption": "Text as generated by processing a virtual key code with a keyboard lay out. Not needed for for <code>keyUp</code> and <code>rawKeyDown</code> events (d efault: \"\")" },
3618 { "name": "unmodifiedText", "type": "string", "optional": tr ue, "description": "Text that would have been generated by the keyboard if no mo difiers were pressed (except for shift). Useful for shortcut (accelerator) key h andling (default: \"\")." },
3619 { "name": "keyIdentifier", "type": "string", "optional": tru e, "description": "Unique key identifier (e.g., 'U+0041') (default: \"\")." },
3620 { "name": "windowsVirtualKeyCode", "type": "integer", "optio nal": true, "description": "Windows virtual key code (default: 0)." },
3621 { "name": "nativeVirtualKeyCode", "type": "integer", "option al": true, "description": "Native virtual key code (default: 0)." },
3622 { "name": "macCharCode", "type": "integer", "optional": true , "description": "Mac character code (default: 0)." },
3623 { "name": "autoRepeat", "type": "boolean", "optional": true, "description": "Whether the event was generated from auto repeat (default: fals e)." },
3624 { "name": "isKeypad", "type": "boolean", "optional": true, " description": "Whether the event was generated from the keypad (default: false). " },
3625 { "name": "isSystemKey", "type": "boolean", "optional": true , "description": "Whether the event was a system key event (default: false)." }
3626 ],
3627 "description": "Dispatches a key event to the page."
3628 },
3629 {
3630 "name": "dispatchMouseEvent",
3631 "parameters": [
3632 { "name": "type", "type": "string", "enum": ["mousePressed", "mouseReleased", "mouseMoved"], "description": "Type of the mouse event." },
3633 { "name": "x", "type": "integer", "description": "X coordina te of the event relative to the main frame's viewport."},
3634 { "name": "y", "type": "integer", "description": "Y coordina te of the event relative to the main frame's viewport. 0 refers to the top of th e viewport and Y increases as it proceeds towards the bottom of the viewport."},
3635 { "name": "modifiers", "type": "integer", "optional": true, "description": "Bit field representing pressed modifier keys. Alt=1, Ctrl=2, Met a/Command=4, Shift=8 (default: 0)." },
3636 { "name": "timestamp", "type": "number", "optional": true, " description": "Time at which the event occurred. Measured in UTC time in seconds since January 1, 1970 (default: current time)." },
3637 { "name": "button", "type": "string", "enum": ["none", "left ", "middle", "right"], "optional": true, "description": "Mouse button (default: \"none\")." },
3638 { "name": "clickCount", "type": "integer", "optional": true, "description": "Number of times the mouse button was clicked (default: 0)." }
3639 ],
3640 "description": "Dispatches a mouse event to the page."
3641 }
3642 ],
3643 "events": []
3644 },
3645 {
3646 "domain": "LayerTree",
3647 "hidden": true,
3648 "types": [
3649 {
3650 "id": "LayerId",
3651 "type": "string",
3652 "description": "Unique RenderLayer identifier."
3653 },
3654 {
3655 "id": "IntRect",
3656 "type": "object",
3657 "description": "A rectangle.",
3658 "properties": [
3659 { "name": "x", "type": "integer", "description": "The x posi tion." },
3660 { "name": "y", "type": "integer", "description": "The y posi tion." },
3661 { "name": "width", "type": "integer", "description": "The wi dth metric." },
3662 { "name": "height", "type": "integer", "description": "The h eight metric." }
3663 ]
3664 },
3665 {
3666 "id": "Layer",
3667 "type": "object",
3668 "description": "Information about a compositing layer.",
3669 "properties": [
3670 { "name": "layerId", "$ref": "LayerId", "description": "The unique id for this layer." },
3671 { "name": "bounds", "$ref": "IntRect", "description": "Bound s of the layer." },
3672 { "name": "isComposited", "type": "boolean", "description": "Indicates whether this layer is composited." },
3673 { "name": "paintCount", "type": "integer", "optional": true, "description": "Indicates how many time this layer has painted." },
3674 { "name": "memory", "type": "integer", "optional": true, "de scription": "Estimated memory used by this layer." },
3675 { "name": "compositedBounds", "$ref": "IntRect", "optional": true, "description": "The bounds of the composited layer." },
3676 { "name": "childLayers", "type": "array", "optional": true, "items": { "$ref": "Layer" }, "description": "Child layers." }
3677 ]
3678 }
3679 ],
3680 "commands": [
3681 {
3682 "name": "enable",
3683 "description": "Enables compositing tree inspection."
3684 },
3685 {
3686 "name": "disable",
3687 "description": "Disables compositing tree inspection."
3688 },
3689 {
3690 "name": "getLayerTree",
3691 "description": "Returns the layer tree structure of the current page.",
3692 "returns": [
3693 { "name": "layerTree", "$ref": "Layer", "description": "Laye r tree structure of the current page." }
3694 ]
3695 },
3696 {
3697 "name": "nodeIdForLayerId",
3698 "description": "Returns the node id for a given layer id.",
3699 "parameters": [
3700 { "name": "layerId", "$ref": "LayerId" }
3701 ],
3702 "returns": [
3703 { "name": "nodeId", "$ref": "DOM.NodeId", "description": "Th e node id for the given layer id." }
3704 ]
3705 }
3706 ],
3707 "events": [
3708 {
3709 "name": "layerTreeDidChange"
3710 }
3711 ]
3712 }]
3713 }
OLDNEW
« no previous file with comments | « third_party/WebCore/inspector/InjectedScriptHost.idl ('k') | third_party/WebCore/inspector/Inspector-0.1.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698