summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/inspector/Inspector.json
blob: ed5929ea00d64bc39004529d96493107f06a6533 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
[
    {
        "domain": "Inspector",
        "types": [],
        "commands": [
            {
                "name": "didEvaluateForTestInFrontend",
                "parameters": [
                    { "name": "testCallId", "type": "integer" },
                    { "name": "jsonResult", "type": "string" }
                ]
            }
        ],
        "events": [
            {
                "name": "frontendReused"
            },
            {
                "name": "bringToFront"
            },
            {
                "name": "disconnectFromBackend"
            },
            {
                "name": "reset"
            },
            {
                "name": "showPanel",
                "parameters": [
                    { "name": "panel", "type": "string" }
                ]
            },
            {
                "name": "startUserInitiatedDebugging"
            },
            {
                "name": "evaluateForTestInFrontend",
                "parameters": [
                    { "name": "testCallId", "type": "integer" },
                    { "name": "script", "type": "string" }
                ]
            },
            {
                "name": "inspect",
                "parameters": [
                    { "name": "object", "$ref": "RemoteObject" },
                    { "name": "hints", "type": "object" }
                ]
            },
            {
                "name": "didCreateWorker",
                "parameters": [
                    { "name": "id", "type": "integer" },
                    { "name": "url", "type": "string" },
                    { "name": "isShared", "type": "boolean" }
                ]
            },
            {
                "name": "didDestroyWorker",
                "parameters": [
                    { "name": "id", "type": "integer" }
                ]
            }
        ]
    },
    {
        "domain": "Page",
        "types": [],
        "commands": [
            {
                "name": "addScriptToEvaluateOnLoad",
                "parameters": [
                    { "name": "scriptSource", "type": "string" }
                ]
            },
            {
                "name": "removeAllScriptsToEvaluateOnLoad"
            },
            {
                "name": "reloadPage",
                "parameters": [
                    { "name": "ignoreCache", "type": "boolean" }
                ]
            },
            {
                "name": "openInInspectedWindow",
                "parameters": [
                    { "name": "url", "type": "string" }
                ]
            },
            {
                "name": "setUserAgentOverride",
                "parameters": [
                    { "name": "userAgent", "type": "string" }
                ]
            },
            {
                "name": "getCookies",
                "returns": [
                    { "name": "cookies", "type": "array", "items": { "$ref" : "Cookie"} },
                    { "name": "cookiesString", "type": "string" }
                ]
            },
            {
                "name": "deleteCookie",
                "parameters": [
                    { "name": "cookieName", "type": "string" },
                    { "name": "domain", "type": "string" }
                ]
            }
        ],
        "events": [
            {
                "name": "inspectedURLChanged",
                "parameters": [
                    { "name": "url", "type": "string" }
                ]
            },
            {
                "name": "domContentEventFired",
                "parameters": [
                    { "name": "time", "type": "number" }
                ]
            },
            {
                "name": "loadEventFired",
                "parameters": [
                    { "name": "time", "type": "number" }
                ]
            }
        ]
    },
    {
        "domain": "Runtime",
        "types": [],
        "commands": [
            {
                "name": "evaluate",
                "parameters": [
                    { "name": "expression", "type": "string" },
                    { "name": "objectGroup", "type": "string" },
                    { "name": "includeCommandLineAPI", "type": "boolean" }
                ],
                "returns": [
                    { "name": "result", "$ref": "RuntimeObject" }
                ]
            },
            {
                "name": "evaluateOn",
                "parameters": [
                    { "name": "objectId", "type": "string" },
                    { "name": "expression", "type": "string" }
                ],
                "returns": [
                    { "name": "result", "$ref": "RuntimeObject" }
                ]
            },
            {
                "name": "getProperties",
                "parameters": [
                    { "name": "objectId", "type": "string" },
                    { "name": "ignoreHasOwnProperty", "type": "boolean" },
                    { "name": "abbreviate", "type": "boolean" }
                ],
                "returns": [
                    { "name": "result", "type": "array", "items": { "$ref" : "RuntimeProperty"} }
                ]
            },
            {
                "name": "setPropertyValue",
                "parameters": [
                    { "name": "objectId", "type": "string" },
                    { "name": "propertyName", "type": "string" },
                    { "name": "expression", "type": "string" }
                ]
            },
            {
                "name": "releaseObject",
                "parameters": [
                    { "name": "objectId", "type": "string" }
                ]
            },
            {
                "name": "releaseObjectGroup",
                "parameters": [
                    { "name": "objectGroup", "type": "string" }
                ]
            }
        ]
    },
    {
        "domain": "Console",
        "types": [],
        "commands": [
            {
                "name": "enable",
                "returns": [
                   { "name": "expiredMessagesCount", "type": "integer" }
                ]
            },
            {
                "name": "disable"
           },
            {
                "name": "clearConsoleMessages"
            },
            {
                "name": "setMonitoringXHREnabled",
                "parameters": [
                    { "name": "enabled", "type": "boolean" }
                ]
            },
            {
                "name": "addInspectedNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer" }
                ]
            }
        ],
        "events": [
            {
                "name": "consoleMessage",
                "parameters": [
                    { "name": "messageObj", "$ref": "ConsoleMessage" }
                ]
            },
           {
                "name": "consoleMessageRepeatCountUpdated",
                "parameters": [
                    { "name": "count", "type": "integer" }
                ]
            },
            {
                "name": "consoleMessagesCleared"
            }
        ]
    },
    {
        "domain": "Network",
        "description": "Network domain allows tracking network activities of the page. It exposes information about HTTP and WebSocket requests and responses, their headers, bodies, timing, etc. It also allows getting the tree of the Frames on the page along with information about their resources.",
        "types": [
            {
                "id": "ResourceTiming",
                "type": "object",
                "description": "Timing information for the request.",
                "properties": {
                    "requestTime": { "type": "number", "description": "Timing's requestTime is a baseline in seconds, while the other numbers are ticks in milliseconds relatively to this requestTime." },
                    "proxyStart": { "type": "number", "description": "Started resolving proxy." },
                    "proxyEnd": { "type": "number", "description": "Finished resolving proxy." },
                    "dnsStart": { "type": "number", "description": "Started DNS address resolve." },
                    "dnsEnd": { "type": "number", "description": "Finished DNS address resolve." },
                    "connectStart": { "type": "number", "description": "Started connecting to the remote host." },
                    "connectEnd": { "type": "number", "description": "Connected to the remote host." },
                    "sslStart": { "type": "number", "description": "Started SSL handshake." },
                    "sslEnd": { "type": "number", "description": "Finished SSL handshake." },
                    "sendStart": { "type": "number", "description": "Started sending request." },
                    "sendEnd": { "type": "number", "description": "Finished sending request." },
                    "receiveHeadersEnd": { "type": "number", "description": "Finished receiving response headers." }
                }
            },
            {
                "id": "ResourceRequest",
                "type": "object",
                "description": "HTTP request data.",
                "properties": {
                    "url": { "type": "string", "description": "Request URL." },
                    "method": { "type": "string", "description": "HTTP request method." },
                    "headers": { "type": "object", "description": "HTTP request headers." },
                    "postData": { "type": "string", "optional": true, "description": "HTTP POST request data." }
                }
            },
            {
                "id": "ResourceResponse",
                "type": "object",
                "description": "HTTP response data.",
                "properties": {
                    "status": { "type": "number", "description": "HTTP response status code." },
                    "statusText": { "type": "string", "description": "HTTP response status text." },
                    "headers": { "type": "object", "description": "HTTP response headers." },
                    "mimeType": { "type": "string", "description": "Resource mimeType as determined by the browser." },
                    "requestHeaders": { "type": "object", "optional": true, "description": "Refined HTTP request headers that were actually transmitted over the network." },
                    "connectionReused": { "type": "boolean", "description": "Specifies whether physical connection was actually reused for this request." },
                    "connectionID": { "type": "number", "description": "Physical connection id that was actually used for this request." },
                    "fromDiskCache": { "type": "boolean", "optional": true, "description": "Specifies that the resource was loaded from the disk cache." },
                    "timing": { "$ref": "ResourceTiming", "optional": true, "description": "Timing information for the given request." }
                }
            },
            {
                "id": "CachedResource",
                "type": "object",
                "description": "Information about the cached resource.",
                "properties": {
                    "url": { "type": "string", "description": "Resource URL." },
                    "type": { "type": "string", "description": "Type of this resource. // FIXME" },
                    "response": { "$ref": "ResourceResponse", "description": "Cached response data." },
                    "bodySize": { "type": "number", "description": "Cached response body size." }
                }
            },
            {
                "id": "Frame",
                "type": "object",
                "description": "Information about the Frame on the page.",
                "properties": {
                    "id": { "type": "string", "description": "Frame unique identifier." },
                    "parentId": { "type": "string", "description": "Parent frame identifier." },
                    "loaderId": { "type": "string", "description": "Identifier of the loader associated with this frame." },
                    "name": { "type": "string", "optional": true, "description": "Frame's name as specified in the tag." },
                    "url": { "type": "string", "description": "Frame document's URL." }
                }
            },
            {
                "id": "FrameResourceTree",
                "type": "object",
                "description": "Information about the Frame hierarchy along with their cached resources.",
                "properties": {
                    "frame": { "$ref": "Frame", "description": "Frame information for this tree item." },
                    "childFrames": { "type": "array", "optional": true, "items": { "$ref": "FrameResourceTree" }, "description": "Child frames." },
                    "resources": { "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "url": { "type": "string", "description": "Resource URL." },
                                "type": { "type": "string", "description": "Type of this resource. // FIXME" }
                            }
                        },
                        "description": "Information about frame resources."
                    }
                }
            }
        ],
        "commands": [
            {
                "name": "enable",
                "description": "Enables network tracking, network events will now be delivered to the client."
            },
            {
                "name": "disable",
                "description": "Disables network tracking, prevents network events from being sent to the client."
            },
            {
                "name": "getCachedResources",
                "description": "Returns present frame / resource tree structure.",
                "returns": [
                    { "name": "frameTree", "$ref": "FrameResourceTree", "description": "Present frame / resource tree structure." }
                ]
            },
            {
                "name": "getResourceContent",
                "description": "Returns content of the given resource.",
                "parameters": [
                    { "name": "frameId", "type": "string", "description": "Frame id to get resource for."  },
                    { "name": "url", "type": "string", "description": "URL of the resource to get content for."  },
                    { "name": "base64Encode", "type": "boolean", "optional": true, "description": "Requests that resource content is served as base64."  }
                ],
                "returns": [
                    { "name": "content", "type": "string", "description": "Resource content." }
                ]
            },
            {
                "name": "setExtraHeaders",
                "description": "Allows sending extra HTTP headers with the requests from this page.",
                "parameters": [
                    { "name": "headers", "type": "object", "description": "Map with extra HTTP headers." }
                ]
            }
        ],
        "events": [
            {
                "name": "frameDetached",
                "description": "Fired when frame has been detached from its parent.",
                "parameters": [
                    { "name": "frameId", "type": "string", "description": "If of the frame that has been detached." }
                ]
            },
            {
                "name": "requestWillBeSent",
                "description": "Fired when page is about to send HTTP request.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "frameId", "type": "string", "description": "Frame identifier." },
                    { "name": "loaderId", "type": "string", "description": "Loader identifier." },
                    { "name": "documentURL", "type": "string", "description": "URL of the document this resource is loaded for." },
                    { "name": "request", "$ref": "ResourceRequest", "description": "Request data." },
                    { "name": "redirectResponse", "$ref": "ResourceResponse", "description": "Redirect response data." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "callStack", "type": "array", "items": { "$ref" : "DebuggerStackFrame"}, "description": "JavaScript stack trace upon issuing this request." }
                ]
            },
            {
                "name": "resourceMarkedAsCached",
                "description": "Fired when request is known to be served from memory cache.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." }
                ]
            },
            {
                "name": "responseReceived",
                "description": "Fired when HTTP response is available.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "resourceType", "type": "string", "description": "Resource type. // FIXME" },
                    { "name": "response", "$ref": "ResourceResponse", "description": "Response data." }
                ]
            },
            {
                "name": "dataReceived",
                "description": "Fired when data chunk was received over the network.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "dataLength", "type": "integer", "description": "Data chunk length." },
                    { "name": "lengthReceived", "type": "integer", "description": "Actual bytes received (might be less than dataLength for compressed encodings)." }
                ]
            },
            {
                "name": "loadingFinished",
                "description": "Fired when HTTP request has finished loading.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "finishTime", "type": "number", "description": "Timestamp." }
                ]
            },
            {
                "name": "loadingFailed",
                "description": "Fired when HTTP request has failed to load.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "errorText", "type": "string", "description": "User friendly error message." }
                ]
            },
            {
                "name": "resourceLoadedFromMemoryCache",
                "description": "Fired when HTTP request has been served from memory cache.",
                "parameters": [
                    { "name": "frameId", "type": "string", "description": "Frame identifier." },
                    { "name": "loaderId", "type": "string", "description": "Loader identifier." },
                    { "name": "documentURL", "type": "string", "description": "URL of the document this resource is loaded for." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "resource", "$ref": "CachedResource", "description": "Cached resource data." }
                ]
            },
            {
                "name": "initialContentSet",
                "description": "Fired for XMLHttpRequests when their content becomes available.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "content", "type": "string", "description": "Resource content." },
                    { "name": "type", "type": "string", "description": "Resource type. // FIXME" }
                ]
            },
            {
                "name": "frameNavigated",
                "description": "Fired once navigation of the frame has completed. Frame is now associated with the new loader.",
                "parameters": [
                    { "name": "frame", "$ref": "Frame", "description": "Frame identifier." },
                    { "name": "loaderId", "type": "string", "description": "Loader identifier." }
                ]
            },
            {
                "name": "webSocketWillSendHandshakeRequest",
                "description": "Fired when WebSocket is about to initiate handshake.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "request", "type": "object", "description": "WebSocket request data." }
                ]
            },
            {
                "name": "webSocketHandshakeResponseReceived",
                "description": "Fired when WebSocket handshake response becomes available.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." },
                    { "name": "response", "type": "object", "description": "WebSocket response data." }
                ]
            },
            {
                "name": "webSocketCreated",
                "description": "Fired upon WebSocket creation.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "url", "type": "string", "description": "WebSocket request URL." }
                ]
            },
            {
                "name": "webSocketClosed",
                "description": "Fired when WebSocket is closed.",
                "parameters": [
                    { "name": "identifier", "type": "integer", "description": "Request identifier." },
                    { "name": "time", "type": "number", "description": "Timestamp." }
                ]
            }
        ]
    },
    {
        "domain": "Database",
        "types": [],
        "commands": [
            {
                "name": "getDatabaseTableNames",
                "parameters": [
                    { "name": "databaseId", "type": "integer" }
                ],
                "returns": [
                    { "name": "tableNames", "type": "array", "items": { "type": "string" } }
                ]
            },
            {
                "name": "executeSQL",
                "parameters": [
                    { "name": "databaseId", "type": "integer" },
                    { "name": "query", "type": "string" }
                ],
                "returns": [
                    { "name": "success", "type": "boolean" },
                    { "name": "transactionId", "type": "integer" }
                ]
            }
        ],
        "events": [
            {
                "name": "addDatabase",
                "parameters": [
                    { "name": "database", "$ref": "DatabaseDatabase" }
                ]
            },
            {
                "name": "sqlTransactionSucceeded",
                "parameters": [
                    { "name": "transactionId", "type": "integer" },
                    { "name": "columnNames", "type": "array", "items": { "type": "string" } },
                    { "name": "values", "type": "array", "items": { "type": "string or number" }}
                ]
            },
            {
                "name": "sqlTransactionFailed",
                "parameters": [
                    { "name": "transactionId", "type": "integer" },
                    { "name": "sqlError", "$ref": "DatabaseError" }
                ]
            }
        ]
    },
    {
        "domain": "DOMStorage",
        "types": [],
        "commands": [
            {
                "name": "getDOMStorageEntries",
                "parameters": [
                    { "name": "storageId", "type": "integer" }
                ],
                "returns": [
                    { "name": "entries", "type": "array", "items": { "$ref" : "DOMStorageEntry"} }
                ]
            },
            {
                "name": "setDOMStorageItem",
                "parameters": [
                    { "name": "storageId", "type": "integer" },
                    { "name": "key", "type": "string" },
                    { "name": "value", "type": "string" }
                ],
                "returns": [
                    { "name": "success", "type": "boolean" }
                ]
            },
            {
                "name": "removeDOMStorageItem",
                "parameters": [
                    { "name": "storageId", "type": "integer" },
                    { "name": "key", "type": "string" }
                ],
                "returns": [
                    { "name": "success", "type": "boolean" }
                ]
            }
        ],
        "events": [
            {
                "name": "addDOMStorage",
                "parameters": [
                    { "name": "storage", "$ref": "DOMStorageStorage" }
                ]
            },
            {
                "name": "updateDOMStorage",
                "parameters": [
                    { "name": "storageId", "type": "integer" }
                ]
            }
        ]
    },
    {
        "domain": "ApplicationCache",
        "types": [],
        "commands": [
            {
                "name": "getApplicationCaches",
                "returns": [
                    { "name": "applicationCaches", "$ref": "AppCache" }
                ]
            }
        ],
        "events": [
            {
                "name": "updateApplicationCacheStatus",
                "parameters": [
                    { "name": "status", "type": "integer" }
                ]
            },
            {
                "name": "updateNetworkState",
                "parameters": [
                    { "name": "isNowOnline", "type": "boolean" }
                ]
            }
        ]
    },
    {
        "domain": "DOM",
        "description": "This domain exposes DOM read/write operations. Each DOM Node is represented with its mirror object that has an <code>id</code>. This <code>id</code> can be used to get additional information on the Node, convert it into the JavaScript object, 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 is client's responsibility to collect information about the nodes that were sent to the client.",
        "types": [
            {
                "id": "DOMNode",
                "type": "object",
                "properties": {
                    "id": { "type": "integer", "description": "Node identifier 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 client." },
                    "nodeType": { "type": "integer",  "description": "<code>Node</code>'s nodeType." },
                    "nodeName": { "type": "string", "description": "<code>Node</code>'s nodeName." },
                    "localName": { "type": "string", "description": "<code>Node</code>'s localName." },
                    "nodeValue": { "type": "string", "description": "<code>Node</code>'s nodeValue." },
                    "childNodeCount": { "type": "integer", "optional": true, "description": "Child count for <code>Container</code> nodes." },
                    "children": { "type": "array", "optional": true, "items": { "$ref" : "DOMNode" }, "description": "Child nodes of this node when requested with children." },
                    "attributes": { "type": "array", "optional": true, "items": { "type" : "string" }, "description": "Attributes of the <code>Element</code> node in the form of flat array <code>[name1, value1, name2, value2]</code>." },
                    "documentURL": { "type": "string", "optional": true, "description": "Document URL that <code>Document</code> or <code>FrameOwner</code> node points to." },
                    "publicId": { "type": "string", "optional": true, "description": "<code>DocumentType</code>'s publicId. // FIXME" },
                    "systemId": { "type": "string", "optional": true, "description": "<code>DocumentType</code>'s systemId. // FIXME" },
                    "internalSubset": { "type": "string", "optional": true, "description": "<code>DocumentType</code>'s internalSubset. // FIXME" },
                    "name": { "type": "string", "optional": true, "description": "<code>Attr</code>'s name. // FIXME" },
                    "value": { "type": "string", "optional": true, "description": "<code>Attr</code>'s value. // FIXME" }
                },
                "description": "DOM interaction is implemented in terms of mirror objects that represent the actual DOM nodes. DOMNode is a base node mirror type."
            },
            {
                "id": "DOMEventListener",
                "type": "object",
                "properties": {
                    "type": { "type": "string", "description": "<code>EventListener</code>'s type." },
                    "useCapture": { "type": "boolean", "description": "<code>EventListener</code>'s useCapture." },
                    "isAttribute": { "type": "boolean", "description": "<code>EventListener</code>'s isAttribute." },
                    "nodeId": { "type": "integer",  "description": "Target <code>DOMNode</code> id." },
                    "listenerBody": { "type": "string", "description": "Listener function body." },
                    "sourceName": { "type": "string", "optional" : true, "description": "Handler location source name." },
                    "lineNumber": { "type": "number", "optional" : true, "description": "Handler location line number." }
                },
                "description": "DOM interaction is implemented in terms of mirror objects that represent the actual DOM nodes. DOMNode is a base node mirror type."
            }
        ],
        "commands": [
            {
                "name": "getDocument",
                "returns": [
                    { "name": "root", "$ref": "DOMNode", "description": "Resulting node." }
                ],
                "description": "Returns the root DOM node to the caller."
            },
            {
                "name": "getChildNodes",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to get children for." }
                ],
                "description": "Requests that children of the node with given id are returned to the caller in form of <code>setChildNodes</code> events."
            },
            {
                "name": "querySelector",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to query upon." },
                    { "name": "selectors", "type": "string", "description": "Selector string." },
                    { "name": "documentWide", "type": "boolean", "description": "Set to true to start querying from the node's document." }
                ],
                "returns": [
                    { "name": "elementId", "type": "integer", "description": "Query selector result." }
                ],
                "description": "Executes <code>querySelector</code> on a given node. Setting <code>documentWide</code> to true starts selecting from the document node."
            },
            {
                "name": "querySelectorAll",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to query upon." },
                    { "name": "selectors", "type": "string", "description": "Selector string." },
                    { "name": "documentWide", "type": "boolean", "description": "Set to true to start querying from the node's document." }
                ],
                "returns": [
                    { "name": "nodeIds", "type": "array", "items": { "type": "integer" }, "description": "Query selector result."  }
                ],
                "description": "Executes <code>querySelectorAll</code> on a given node. Setting <code>documentWide</code> to true starts selecting from the document node."
            },
            {
                "name": "setNodeName",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to set name for."  },
                    { "name": "name", "type": "string", "description": "New node's name." }
                ],
                "returns": [
                    { "name": "outNodeId", "type": "integer", "description": "New node's id." }
                ],
                "description": "Sets node name for a node with given id."
            },
            {
                "name": "setNodeValue",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to set value for." },
                    { "name": "value", "type": "string", "description": "New node's value." }
                ],
                "description": "Sets node value for a node with given id."
            },
            {
                "name": "removeNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to remove." }
                ],
                "description": "Removes node with given id."
            },
            {
                "name": "setAttribute",
                "parameters": [
                    { "name": "elementId", "type": "integer", "description": "Id of the element to set attribute for." },
                    { "name": "name", "type": "string", "description": "Attribute name." },
                    { "name": "value", "type": "string", "description": "Attribute value." }
                ],
                "description": "Sets attribute for an element with given id."
            },
            {
                "name": "removeAttribute",
                "parameters": [
                    { "name": "elementId", "type": "integer", "description": "Id of the element to remove attribute from." },
                    { "name": "name", "type": "string", "description": "Name of the attribute to remove." }
                ],
                "description": "Removes attribute with given name from an element with given id."
            },
            {
                "name": "getEventListenersForNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to get listeners for." }
                ],
                "returns": [
                    { "name": "listenersArray", "type": "array", "items": { "$ref" : "DOMEventListener"}, "description": "Array of relevant listeners." }
                ],
                "description": "Returns event listeners relevant to the node."
            },
            {
                "name": "copyNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to copy." }
                ],
                "description": "Copies node's HTML markup into the clipboard."
            },
            {
                "name": "getOuterHTML",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to get markup for." }
                ],
                "returns": [
                    { "name": "outerHTML", "type": "string", "description": "Outer HTML markup." }
                ],
                "description": "Returns node's HTML markup."
            },
            {
                "name": "setOuterHTML",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to set markup for." },
                    { "name": "outerHTML", "type": "string", "description": "Outer HTML markup to set." }
                ],
                "returns": [
                    { "name": "outNodeId", "type": "integer", "description": "Setting outer HTML can change node's id." }
                ],
                "description": "Sets node HTML markup, returns new node id."
            },
            {
                "name": "performSearch",
                "parameters": [
                    { "name": "query", "type": "string", "description": "Plain text or query selector or XPath search query." },
                    { "name": "runSynchronously", "type": "boolean", "description": "When set to true, performing search synchronously (can block user interaction)." }
                ],
                "description": "Starts asynchronous search for a given string in the DOM tree. Use <code>cancelSearch</code> to stop given asynchronous search task."
            },
            {
                "name": "cancelSearch",
                "description": "Cancels asynchronous search started with <code>performSearch</code>."
            },
            {
                "name": "pushNodeToFrontend",
                "parameters": [
                    { "name": "objectId", "type": "string", "description": "JavaScript object id to convert into node." }
                ],
                "returns": [
                    { "name": "nodeId", "type": "integer", "description": "Node id for given object." }
                ],
                "description": "Requests that the node is sent to the caller given the JavaScript node object reference."
            },
            {
                "name": "setSearchingForNode",
                "parameters": [
                    { "name": "enabled", "type": "boolean" }
                ],
                "returns": [
                    { "name": "newState", "type": "boolean" }
                ]
            },
            {
                "name": "highlightDOMNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer" }
                ]
            },
            {
                "name": "hideDOMNodeHighlight"
            },
            {
                "name": "highlightFrame",
                "parameters": [
                    { "name": "frameId", "type": "string" }
                ]
            },
            {
                "name": "hideFrameHighlight"
            },

            {
                "name": "pushNodeByPathToFrontend",
                "parameters": [
                    { "name": "path", "type": "string", "description": "Path to node in the proprietary format." }
                ],
                "returns": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node for given path." }
                ],
                "description": "Requests that the node is sent to the caller given its path. // FIXME, use XPath"
            },
            {
                "name": "resolveNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Id of the node to resolve." }
                ],
                "returns": [
                    { "name": "object", "$ref": "Object", "description": "JavaScript object wrapper for given node." }
                ],
                "description": "Resolves JavaScript node object for given node id."
            }
        ],
        "events": [
            {
                "name": "documentUpdated",
                "description": "Fired when <code>Document</code> has been totally updated. Node ids are no longer valid."
            },
            {
                "name": "setChildNodes",
                "parameters": [
                    { "name": "parentId", "type": "integer", "description": "Parent node id to populate with children." },
                    { "name": "nodes", "type": "array", "items": { "$ref" : "DOMNode"}, "description": "Child nodes array." }
                ],
                "description": "Fired when backend wants to provide client with the missing DOM structure. This happens upon most of the calls requesting node ids."
            },
            {
                "name": "attributesUpdated",
                "parameters": [
                    { "name": "id", "type": "integer", "description": "Id of the node that has changed." },
                    { "name": "attributes", "type": "array", "items": { "$ref" : "DOMAttribute"}, "description": "New attributes value." }
                ],
                "description": "Fired when <code>Element</code>'s attributes are updated."
            },
            {
                "name": "characterDataModified",
                "parameters": [
                    { "name": "id", "type": "integer", "description": "Id of the node that has changed." },
                    { "name": "newValue", "type": "string", "description": "New text value." }
                ],
                "description": "Mirrors <code>DOMCharacterDataModified</code> event."
            },
            {
                "name": "childNodeCountUpdated",
                "parameters": [
                    { "name": "id", "type": "integer", "description": "Id of the node that has changed." },
                    { "name": "newValue", "type": "integer", "description": "New node count." }
                ],
                "description": "Fired when <code>Container</code>'s child node count has changed."
            },
            {
                "name": "childNodeInserted",
                "parameters": [
                    { "name": "parentId", "type": "integer", "description": "Id of the node that has changed." },
                    { "name": "prevId", "type": "integer", "description": "If of the previous siblint." },
                    { "name": "node", "$ref": "DOMNode", "description": "Inserted node data." }
                ],
                "description": "Mirrors <code>DOMNodeInserted</code> event."
            },
            {
                "name": "childNodeRemoved",
                "parameters": [
                    { "name": "parentId", "type": "integer", "description": "Parent id." },
                    { "name": "id", "type": "integer", "description": "Id of the node that has been removed." }
                ],
                "description": "Mirrors <code>DOMNodeRemoved</code> event."
            },
            {
                "name": "searchResults",
                "parameters": [
                    { "name": "nodeIds", "type": "array", "items": { "type": "integer" }, "description": "Ids of the search result nodes." }
                ],
                "description": "Pushes search results initiated using <code>performSearch</code> to the client."
            }
        ]
    },
    {
        "domain": "CSS",
        "types": [],
        "commands": [
            {
                "name": "getStylesForNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer" }
                ],
                "returns": [
                    { "name": "styles", "$ref": "CSSNodeStyles" }
                ]
            },
            {
                "name": "getComputedStyleForNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer" }
                ],
                "returns": [
                    { "name": "style", "$ref": "CSSComputedStyle" }
                ]
            },
            {
                "name": "getInlineStyleForNode",
                "parameters": [
                    { "name": "nodeId", "type": "integer" }
                ],
                "returns": [
                    { "name": "style", "$ref": "CSSStyle" }
                ]
            },
            {
                "name": "getAllStyleSheets",
                "returns": [
                    { "name": "styleSheetInfos", "type": "array", "items": { "$ref": "CSSStyleSheetInfo" } }
                ]
            },
            {
                "name": "getStyleSheet",
                "parameters": [
                    { "name": "styleSheetId", "type": "string" }
                ],
                "returns": [
                    { "name": "styleSheet", "$ref": "CSSStyleSheet" }
                ]
            },
            {
                "name": "getStyleSheetText",
                "parameters": [
                    { "name": "styleSheetId", "type": "string" }
                ],
                "returns": [
                    { "name": "url", "type": "string" },
                    { "name": "text", "type": "string" }
                ]
            },
            {
                "name": "setStyleSheetText",
                "parameters": [
                    { "name": "styleSheetId", "type": "string" },
                    { "name": "text", "type": "string" }
                ],
                "returns": [
                    { "name": "success", "type": "boolean" }
                ]
            },
            {
                "name": "setPropertyText",
                "parameters": [
                    { "name": "styleId", "$ref": "CSSStyleId" },
                    { "name": "propertyIndex", "type": "integer" },
                    { "name": "text", "type": "string" },
                    { "name": "overwrite", "type": "boolean" }
                ],
                "returns": [
                    { "name": "style", "$ref": "CSSStyle" }
                ]
            },
            {
                "name": "toggleProperty",
                "parameters": [
                    { "name": "styleId", "$ref": "CSSStyleId" },
                    { "name": "propertyIndex", "type": "integer" },
                    { "name": "disable", "type": "boolean" }
                ],
                "returns": [
                    { "name": "style", "$ref": "CSSStyle" }
                ]
            },
            {
                "name": "setRuleSelector",
                "parameters": [
                    { "name": "ruleId", "$ref": "CSSRuleId" },
                    { "name": "selector", "type": "string" }
                ],
                "returns": [
                    { "name": "rule", "$ref": "CSSRule" }
                ]
            },
            {
                "name": "addRule",
                "parameters": [
                    { "name": "contextNodeId", "type": "integer" },
                    { "name": "selector", "type": "string" }
                ],
                "returns": [
                    { "name": "rule", "$ref": "CSSRule" }
                ]
            },
            {
                "name": "getSupportedCSSProperties",
                "returns": [
                    { "name": "cssProperties", "type": "array", "items": { "type": "string" } }
                ]
            }
        ]
    },
    {
        "domain": "Timeline",
        "description": "Timeline provides its clients with instrumentation records that are generated during the page runtime. Timeline instrumentation can be started and stopped using corresponding commands. While timeline is started, it is generating timeline event records.",
        "types": [
            {
                "id": "TimelineRecord",
                "type": "object",
                "properties": {
                    "type": { "type": "string", "description": "Event type." },
                    "data": { "type": "object", "description": "Event data." },
                    "children": { "type": "array", "optional" : true, "items": { "$ref": "TimelineRecord" }, "description": "Nested records." }
                },
                "description": "Timeline record contains information about the recorded activity."
            }
        ],
        "commands": [
            {
                "name": "start",
                "description": "Starts capturing instrumentation events."
            },
            {
                "name": "stop",
                "description": "Stops capturing instrumentation events."
            }
        ],
        "events": [
            {
                "name": "started",
                "description": "Fired when timeline has been started."
            },
            {
                "name": "stopped",
                "description": "Fired when timeline has been stopped."
            },
            {
                "name": "eventRecorded",
                "parameters": [
                    { "name": "record", "$ref": "TimelineRecord", "description": "Timeline record data." }
                ],
                "description": "Fired for every instrumentation event while timeline is started."
            }
        ]
    },
    {
        "domain": "Debugger",
        "description": "Debugger domain exposes JavaScript debugging functions. It allows setting and removing breakpoints, stepping through execution, exploring stack traces, etc.",
        "types": [
            {
                "id": "Location",
                "type": "object",
                "properties": {
                    "sourceID": { "type": "string",  "description": "Script identifier as reported by the <code>scriptParsed</code>" },
                    "lineNumber": { "type": "integer", "description": "Line number in the script." },
                    "columnNumber": { "type": "integer", "description": "Column number in the script." }
                },
                "description": "Location in the source code."
            },
            {
                "id": "CallFrame",
                "type": "object",
                "properties": {
                    "id": { "type": "string",  "description": "Call frame identifier" },
                    "type": { "type": "string", "description": "Call frame type. // FIXME" },
                    "functionName": { "type": "string", "description": "Name of the function called on this frame." },
                    "sourceID": { "type": "string", "description": "Script identifier." },
                    "line": { "type": "integer", "description": "Line number in the script." },
                    "column": { "type": "integer", "description": "Column number in the script." },
                    "scopeChain": { "type": "array", "items": { "type": "object" }, "description": "Scope chain for given call frame. // FIXME" }
                },
                "description": "Debugger call frame. Array of call frames form call stack."
            }
        ],
        "commands": [
            {
                "name": "enable",
                "description": "Enables debugger for given page."
            },
            {
                "name": "disable",
                "description": "Disables debugger for given page."
            },
            {
                "name": "setBreakpointsActive",
                "parameters": [
                    { "name": "active", "type": "boolean", "description": "New value for breakpoints active state." }
                ],
                "description": "Activates / deactivates all breakpoints on the page."
            },
            {
                "name": "setBreakpointByUrl",
                "parameters": [
                    { "name": "url", "type": "string", "description": "URL of the resource to set breakpoint on." },
                    { "name": "lineNumber", "type": "integer", "description": "Line number to set breakpoint at." },
                    { "name": "columnNumber", "type": "integer", "optional": true, "description": "Offset in the line to set breakpoint at." },
                    { "name": "condition", "type": "string", "optional": true, "description": "Expression to use as a breakpoint condition. When specified, debugger will only stop on the breakpoint if this expression evaluates to true." },
                    { "name": "enabled", "type": "boolean", "optional": true, "description": "Determines initial state for the breakpoint." }
                ],
                "returns": [
                    { "name": "breakpointId", "type": "string", "description": "Id of the created breakpoint for further manipulations." },
                    { "name": "locations", "type": "array", "items": { "$ref" : "Location"}, "description": "List of the locations this breakpoint resolved into."  }
                ],
                "description": "Sets JavaScript breakpoint at a given location specified by URL. This breakpoint will survive page reload."
            },
            {
                "name": "setBreakpoint",
                "parameters": [
                    { "name": "sourceId", "type": "string", "description": "Source ID of the resource to set breakpoint on (as reported by <code>scriptParsed</code>)." },
                    { "name": "lineNumber", "type": "integer", "description": "Line number to set breakpoint at." },
                    { "name": "columnNumber", "type": "integer", "optional": true, "description": "Offset in the line to set breakpoint at." },
                    { "name": "condition", "type": "string", "optional": true, "description": "Expression to use as a breakpoint condition. When specified, debugger will only stop on the breakpoint if this expression evaluates to true." },
                    { "name": "enabled", "type": "boolean", "optional": true, "description": "Determines initial state for the breakpoint." }
                ],
                "returns": [
                    { "name": "breakpointId", "type": "string", "description": "Id of the created breakpoint for further manipulations." },
                    { "name": "actualLineNumber", "type": "integer", "description": "Line number in the script." },
                    { "name": "actualColumnNumber", "type": "integer", "description": "Column number in the script." }
                ],
                "description": "Sets JavaScript breakpoint at a given location."
            },
            {
                "name": "removeBreakpoint",
                "parameters": [
                    { "name": "breakpointId", "type": "string" }
                ],
                "description": "Removes JavaScript breakpoint."
            },
            {
                "name": "continueToLocation",
                "parameters": [
                    { "name": "sourceId", "type": "string", "description": "Source ID of the resource to continue to (as reported by <code>scriptParsed</code>)." },
                    { "name": "lineNumber", "type": "integer", "description": "Line number to stop at." },
                    { "name": "columnNumber", "type": "integer", "description": "Column number to stop at." }
                ],
                "description": "Continues execution until specific location is reached."
            },
            {
                "name": "stepOver",
                "description": "Steps over the statement."
            },
            {
                "name": "stepInto",
                "description": "Steps into the statement."
            },
            {
                "name": "stepOut",
                "description": "Steps out of the function."
            },
            {
                "name": "pause",
                "description": "Stops on the next JavaScript statement."
            },
            {
                "name": "resume",
                "description": "Resumes JavaScript execution."
            },
            {
                "name": "editScriptSource",
                "parameters": [
                    { "name": "sourceID", "type": "string", "description": "Id of the script to edit." },
                    { "name": "newContent", "type": "string", "description": "New content of the script." }
                ],
                "returns": [
                    { "name": "result", "type": "string", "description": "New content of the script." },
                    { "name": "stackFrames", "type": "array", "items": { "$ref" : "CallFrame"}, "description": "New stack trace in case editing has happened while VM was stopped." }
                ],
                "description": "Edits JavaScript script live."
            },
            {
                "name": "getScriptSource",
                "parameters": [
                    { "name": "sourceID", "type": "string", "description": "Id of the script to get source for." }
                ],
                "returns": [
                    { "name": "scriptSource", "type": "string", "description": "Script source." }
                ],
                "description": "Returns source for the script with given ID."
            },
            {
                "name": "setPauseOnExceptionsState",
                "parameters": [
                    { "name": "pauseOnExceptionsState", "type": "integer", "description": "Pause on exceptions mode. // FIXME, make enumerable." }
                ],
                "description": "Defines pause on exceptions state. Can be set to stop on all exceptions, uncaught exceptions or no exceptions."
            },
            {
                "name": "evaluateOnCallFrame",
                "parameters": [
                    { "name": "callFrameId", "type": "string", "description": "Call frame identifier to evaluate on. This identifier is a part of backtrace reported by the <code>pausedScript</code>." },
                    { "name": "expression", "type": "string", "description": "Expression to evaluate." },
                    { "name": "objectGroup", "type": "string", "description": "String object group name to put result into (allows rapid releasing resulting object handles using <code>releaseObjectGroup</code>)." },
                    { "name": "includeCommandLineAPI", "type": "boolean", "optional": true, "description": "Specifies whether command line API should be available to the evaluated expression, defaults to false." }
                ],
                "returns": [
                    { "name": "result", "$ref": "Object", "description": "Object wrapper for the evaluation result." }
                ],
                "description": "Evaluates expression on a given call frame."
            }
        ],
        "events": [
            {
                "name": "debuggerWasEnabled",
                "description": "Fired when debugger gets enabled."
            },
            {
                "name": "debuggerWasDisabled",
                "description": "Fired when debugger gets disabled."
            },
            {
                "name": "scriptParsed",
                "parameters": [
                    { "name": "sourceID", "type": "string", "description": "Identifier of the script parsed." },
                    { "name": "url", "type": "string", "description": "URL of the script parsed (if any)." },
                    { "name": "lineOffset", "type": "integer", "description": "Line offset of the script within the resource with given URL (for script tags)." },
                    { "name": "columnOffset", "type": "integer", "description": "Column offset of the script within the resource with given URL." },
                    { "name": "length", "type": "integer", "description": "Length of the script" },
                    { "name": "scriptWorldType", "type": "integer", "description": "Script type. // FIXME." }
                ],
                "description": "Fired when virtual machine parses script. This even is also fired for all known scripts upon enabling debugger."
            },
            {
                "name": "scriptFailedToParse",
                "parameters": [
                    { "name": "url", "type": "string", "description": "URL of the script that failed to parse." },
                    { "name": "data", "type": "string", "description": "Source text of the script that failed to parse." },
                    { "name": "firstLine", "type": "integer", "description": "Line offset of the script within the resource." },
                    { "name": "errorLine", "type": "integer", "description": "Line with error." },
                    { "name": "errorMessage", "type": "string", "description": "Parse error message." }
                ],
                "description": "Fired when virtual machine fails to parse the script."
            },
            {
                "name": "breakpointResolved",
                "parameters": [
                    { "name": "breakpointId", "type": "string", "description": "Breakpoint unique identifier." },
                    { "name": "sourceId", "type": "string", "description": "Identifier of the script breakpoint is set in." },
                    { "name": "lineNumber", "type": "integer", "description": "Line number of the statement breakpoint is set on." },
                    { "name": "columnNumber", "type": "integer", "description": "Column offset of the statement breakpoint is set on." }
                ],
                "description": "Fired when breakpoint is resolved to an actual script and location."
            },
            {
                "name": "paused",
                "parameters": [
                    { 
                        "name": "details",
                        "type": "object",
                        "properties": {
                            "callFrames": { "type": "array", "items": { "$ref": "CallFrame" }, "description": "Call stack the virtual machine stopped on." }
                        },
                        "description": "Call stack information."
                    }
                ],
                "description": "Fired when the virtual machine stopped on breakpoint or exception or any other stop criteria."
            },
            {
                "name": "resumed",
                "description": "Fired when the virtual machine resumed execution."
            }
        ]
    },
    {
        "domain": "BrowserDebugger",
        "description": "Browser debugging allows setting breakpoints on particular DOM operations and events. JavaScript execution will stop on these operations as if there was a regular breakpoint set.",
        "commands": [
            {
                "name": "setDOMBreakpoint",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Identifier of the node to set breakpoint on." },
                    { "name": "type", "type": "integer", "description": "Type of the operation to stop upon." }
                ],
                "description": "Sets breakpoint on particular operation with DOM. "
            },
            {
                "name": "removeDOMBreakpoint",
                "parameters": [
                    { "name": "nodeId", "type": "integer", "description": "Identifier of the node to remove breakpoint from." },
                    { "name": "type", "type": "integer", "description": "Type of the breakpoint to remove." }
                ],
                "description": "Removes DOM breakpoint that was set using <code>setDOMBreakpoint</code>."
            },
            {
                "name": "setEventListenerBreakpoint",
                "parameters": [
                    { "name": "eventName", "type": "string", "description": "Event name to stop on (any DOM event will do)." }
                ],
                "description": "Sets breakpoint on particular DOM event."
            },
            {
                "name": "removeEventListenerBreakpoint",
                "parameters": [
                    { "name": "eventName", "type": "string", "description": "Event name." }
                ],
                "description": "Removes breakpoint on particular DOM event."
            },
            {
                "name": "setXHRBreakpoint",
                "parameters": [
                    { "name": "url", "type": "string", "description": "Resource URL substring. All XHRs having this substring in the URL will get stopped upon." }
                ],
                "description": "Sets breakpoint on XMLHttpRequest."
            },
            {
                "name": "removeXHRBreakpoint",
                "parameters": [
                    { "name": "url", "type": "string", "description": "Resource URL substring." }
                ],
                "description": "Removes breakpoint from XMLHttpRequest."
            }
        ]
    },
    {
        "domain": "Profiler",
        "types": [],
        "commands": [
            {
                "name": "enable"
            },
            {
                "name": "disable"
            },
            {
                "name": "isEnabled",
                "returns": [
                    { "name": "state", "type": "boolean" }
                ]
            },
            {
                "name": "start"
            },
            {
                "name": "stop"
            },
            {
                "name": "getProfileHeaders",
                "returns": [
                    { "name": "headers", "type": "array", "items": { "$ref" : "ProfileHeader"} }
                ]
            },
            {
                "name": "getProfile",
                "parameters": [
                    { "name": "type", "type": "string" },
                    { "name": "uid", "type": "integer" }
                ],
                "returns": [
                    { "name": "profile", "$ref": "Profile" }
                ]
            },
            {
                "name": "removeProfile",
                "parameters": [
                    { "name": "type", "type": "string" },
                    { "name": "uid", "type": "integer" }
                ]
            },
            {
                "name": "clearProfiles"
            },
            {
                "name": "takeHeapSnapshot",
                "parameters": [
                    { "name": "detailed", "type": "boolean" }
                ]
            },
            {
                "name": "collectGarbage"
            }
        ],
        "events": [
            {
                "name": "profilerWasEnabled"
            },
            {
                "name": "profilerWasDisabled"
            },
            {
                "name": "addProfileHeader",
                "parameters": [
                    { "name": "header", "$ref": "ProfileHeader" }
                ]
            },
            {
                "name": "addHeapSnapshotChunk",
                "parameters": [
                    { "name": "uid", "type": "integer" },
                    { "name": "chunk", "type": "string" }
                ]
            },
            {
                "name": "finishHeapSnapshot",
                "parameters": [
                    { "name": "uid", "type": "integer" }
                ]
            },
            {
                "name": "setRecordingProfile",
                "parameters": [
                    { "name": "isProfiling", "type": "boolean" }
                ]
            },
            {
                "name": "resetProfiles"
            },
            {
                "name": "reportHeapSnapshotProgress",
                "parameters": [
                    { "name": "done", "type": "integer" },
                    { "name": "total", "type": "integer" }
                ]
            }
        ]
    }
]