- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / common / extensions / api / web_request_internal.json
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 [
6   {
7     "namespace": "webRequestInternal",
8     "description": "none",
9     "functions": [
10       {
11         "name": "addEventListener",
12         "type": "function",
13         "description": "Used internally to implement the special form of addListener for the webRequest events.",
14         "parameters": [
15           {"type": "function", "name": "callback"},
16           {
17             "$ref": "webRequest.RequestFilter",
18             "name": "filter",
19             "description": "A set of filters that restricts the events that will be sent to this listener."
20           },
21           {
22             "type": "array",
23             "optional": true,
24             "name": "extraInfoSpec",
25             "description": "Array of extra information that should be passed to the listener function.",
26             "items": {
27               "type": "string",
28               "enum": ["requestHeaders", "responseHeaders", "blocking", "asyncBlocking", "requestBody"]
29             }
30           },
31           {"type": "string", "name": "eventName"},
32           {"type": "string", "name": "subEventName"},
33           {"type": "integer", "name": "webViewInstanceId"}
34         ]
35       },
36       {
37         "name": "eventHandled",
38         "type": "function",
39         "description": "Used internally to send a response for a blocked event.",
40         "parameters": [
41           {"type": "string", "name": "eventName"},
42           {"type": "string", "name": "subEventName"},
43           {"type": "string", "name": "requestId"},
44           {
45             "$ref": "webRequest.BlockingResponse",
46             "optional": true,
47             "name": "response"
48           }
49         ]
50       }
51     ]
52   }
53 ]