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

Unified Diff: chrome/common/extensions/api/web_request.json

Issue 10948033: Explicitly naming the data type for requestBody (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/api/web_request.json
diff --git a/chrome/common/extensions/api/web_request.json b/chrome/common/extensions/api/web_request.json
index 38edcc366ee954c5df5d89efb5efd558c82fa7c9..25a81e92766350a4ed6274fef60bcd64f7785c2e 100644
--- a/chrome/common/extensions/api/web_request.json
+++ b/chrome/common/extensions/api/web_request.json
@@ -104,6 +104,30 @@
}
},
"description": "Contains data uploaded in a URL request."
+ },
+ {
+ "id": "RequestBody",
+ "type": "object",
+ "description": "This is a container for request body data.",
Matt Perry 2012/09/19 19:07:58 I would copy part of the description of the variab
vabr (Chromium) 2012/09/19 19:18:15 Done.
+ "properties": {
+ "error": {"type": "string", "optional": true, "description": "Errors when obtaining request body data."},
+ "formData": {
+ "type": "object",
+ "optional": true,
+ "description": "If the request method is POST and the body is a sequence of key-value pairs encoded in UTF8, encoded as either multipart/form-data, or application/x-www-form-urlencoded, this dictionary is present and for each key contains the list of all values for that key. If the data is of another media type, or if it is malformed, the dictionary is not present. An example value of this dictionary is {'key': ['value1', 'value2']}.",
+ "properties": {},
+ "additionalProperties": {
+ "type": "array",
+ "items": { "type": "string" }
+ }
+ },
+ "raw" : {
+ "type": "array",
+ "optional": true,
+ "items": {"$ref": "UploadData"},
+ "description": "If the request method is PUT or POST, and the body is not already parsed in formData, then the unparsed request body elements are contained in this array."
+ }
+ }
}
],
"functions": [
@@ -132,28 +156,9 @@
"frameId": {"type": "integer", "description": "The value 0 indicates that the request happens in the main frame; a positive value indicates the ID of a subframe in which the request happens. If the document of a (sub-)frame is loaded (<code>type</code> is <code>main_frame</code> or <code>sub_frame</code>), <code>frameId</code> indicates the ID of this frame, not the ID of the outer frame. Frame IDs are unique within a tab."},
"parentFrameId": {"type": "integer", "description": "ID of frame that wraps the frame which sent the request. Set to -1 if no parent frame exists."},
"requestBody": {
- "type": "object",
+ "$ref": "RequestBody",
"optional": true,
- "description": "Experimental feature, only available in DEV or CANARY channels. Container for request body data. Only provided if extraInfoSpec contains 'requestBody'. Currently only request body elements containing byte data or files are reported.",
vabr (Chromium) 2012/09/19 08:16:09 I removed "Currently only request body elements co
- "properties": {
- "error": {"type": "string", "optional": true, "description": "Errors when obtaining request body data."},
- "formData": {
- "type": "object",
- "optional": true,
- "description": "If the request method is POST and the body is a sequence of key-value pairs encoded in UTF8, encoded as either multipart/form-data, or application/x-www-form-urlencoded, this dictionary is present and for each key contains the list of all values for that key. If the data is of another media type, or if it is malformed, the dictionary is not present. An example value of this dictionary is {'key': ['value1', 'value2']}.",
- "properties": {},
- "additionalProperties": {
- "type": "array",
- "items": { "type": "string" }
- }
- },
- "raw" : {
- "type": "array",
- "optional": true,
- "items": {"$ref": "UploadData"},
- "description": "If the request method is PUT or POST, and the body is not already parsed in formData, then the unparsed request body elements are contained in this array."
- }
- }
+ "description": "Contains the upload data of the request. Experimental feature, only available in DEV or CANARY channels. Only provided if extraInfoSpec contains 'requestBody'."
Matt Perry 2012/09/19 19:07:58 "Contains the upload data of the request." ? Makes
vabr (Chromium) 2012/09/19 19:18:15 Done.
},
"tabId": {"type": "integer", "description": "The ID of the tab in which the request takes place. Set to -1 if the request isn't related to a tab."},
"type": {"type": "string", "enum": ["main_frame", "sub_frame", "stylesheet", "script", "image", "object", "xmlhttprequest", "other"], "description": "How the requested resource will be used."},
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698