OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 [ | 5 [ |
6 { | 6 { |
7 "namespace": "cookies", | 7 "namespace": "cookies", |
8 "types": [ | 8 "types": [ |
9 { | 9 { |
10 "id": "Cookie", | 10 "id": "Cookie", |
11 "type": "object", | 11 "type": "object", |
12 "description": "Represents information about an HTTP cookie.", | 12 "description": "Represents information about an HTTP cookie.", |
13 "properties": { | 13 "properties": { |
14 "name": {"type": "string", "description": "The name of the cookie."}, | 14 "name": {"type": "string", "description": "The name of the cookie."}, |
15 "value": {"type": "string", "description": "The value of the cookie."}
, | 15 "value": {"type": "string", "description": "The value of the cookie."}
, |
16 "domain": {"type": "string", "description": "The domain of the cookie
(e.g. \"www.google.com\", \"example.com\")."}, | 16 "domain": {"type": "string", "description": "The domain of the cookie
(e.g. \"www.google.com\", \"example.com\")."}, |
17 "hostOnly": {"type": "boolean", "description": "True if the cookie is
a host-only cookie (i.e. a request's host must exactly match the domain of the c
ookie)."}, | 17 "hostOnly": {"type": "boolean", "description": "True if the cookie is
a host-only cookie (i.e. a request's host must exactly match the domain of the c
ookie)."}, |
18 "path": {"type": "string", "description": "The path of the cookie."}, | 18 "path": {"type": "string", "description": "The path of the cookie."}, |
19 "secure": {"type": "boolean", "description": "True if the cookie is ma
rked as Secure (i.e. its scope is limited to secure channels, typically HTTPS)."
}, | 19 "secure": {"type": "boolean", "description": "True if the cookie is ma
rked as Secure (i.e. its scope is limited to secure channels, typically HTTPS)."
}, |
20 "httpOnly": {"type": "boolean", "description": "True if the cookie is
marked as HttpOnly (i.e. the cookie is inaccessible to client-side scripts)."}, | 20 "httpOnly": {"type": "boolean", "description": "True if the cookie is
marked as HttpOnly (i.e. the cookie is inaccessible to client-side scripts)."}, |
| 21 "priority": {"type": "string", "description": "The retention priority
of the cookie."}, |
21 "session": {"type": "boolean", "description": "True if the cookie is a
session cookie, as opposed to a persistent cookie with an expiration date."}, | 22 "session": {"type": "boolean", "description": "True if the cookie is a
session cookie, as opposed to a persistent cookie with an expiration date."}, |
22 "expirationDate": {"type": "number", "optional": true, "description":
"The expiration date of the cookie as the number of seconds since the UNIX epoch
. Not provided for session cookies."}, | 23 "expirationDate": {"type": "number", "optional": true, "description":
"The expiration date of the cookie as the number of seconds since the UNIX epoch
. Not provided for session cookies."}, |
23 "storeId": {"type": "string", "description": "The ID of the cookie sto
re containing this cookie, as provided in getAllCookieStores()."} | 24 "storeId": {"type": "string", "description": "The ID of the cookie sto
re containing this cookie, as provided in getAllCookieStores()."} |
24 } | 25 } |
25 }, | 26 }, |
26 { | 27 { |
27 "id": "CookieStore", | 28 "id": "CookieStore", |
28 "type": "object", | 29 "type": "object", |
29 "description": "Represents a cookie store in the browser. An incognito m
ode window, for instance, uses a separate cookie store from a non-incognito wind
ow.", | 30 "description": "Represents a cookie store in the browser. An incognito m
ode window, for instance, uses a separate cookie store from a non-incognito wind
ow.", |
30 "properties": { | 31 "properties": { |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 "name": "details", | 101 "name": "details", |
101 "description": "Details about the cookie being set.", | 102 "description": "Details about the cookie being set.", |
102 "properties": { | 103 "properties": { |
103 "url": {"type": "string", "description": "The request-URI to assoc
iate with the setting of the cookie. This value can affect the default domain an
d path values of the created cookie. If host permissions for this URL are not sp
ecified in the manifest file, the API call will fail."}, | 104 "url": {"type": "string", "description": "The request-URI to assoc
iate with the setting of the cookie. This value can affect the default domain an
d path values of the created cookie. If host permissions for this URL are not sp
ecified in the manifest file, the API call will fail."}, |
104 "name": {"type": "string", "optional": true, "description": "The n
ame of the cookie. Empty by default if omitted."}, | 105 "name": {"type": "string", "optional": true, "description": "The n
ame of the cookie. Empty by default if omitted."}, |
105 "value": {"type": "string", "optional": true, "description": "The
value of the cookie. Empty by default if omitted."}, | 106 "value": {"type": "string", "optional": true, "description": "The
value of the cookie. Empty by default if omitted."}, |
106 "domain": {"type": "string", "optional": true, "description": "The
domain of the cookie. If omitted, the cookie becomes a host-only cookie."}, | 107 "domain": {"type": "string", "optional": true, "description": "The
domain of the cookie. If omitted, the cookie becomes a host-only cookie."}, |
107 "path": {"type": "string", "optional": true, "description": "The p
ath of the cookie. Defaults to the path portion of the url parameter."}, | 108 "path": {"type": "string", "optional": true, "description": "The p
ath of the cookie. Defaults to the path portion of the url parameter."}, |
108 "secure": {"type": "boolean", "optional": true, "description": "Wh
ether the cookie should be marked as Secure. Defaults to false."}, | 109 "secure": {"type": "boolean", "optional": true, "description": "Wh
ether the cookie should be marked as Secure. Defaults to false."}, |
109 "httpOnly": {"type": "boolean", "optional": true, "description": "
Whether the cookie should be marked as HttpOnly. Defaults to false."}, | 110 "httpOnly": {"type": "boolean", "optional": true, "description": "
Whether the cookie should be marked as HttpOnly. Defaults to false."}, |
| 111 "priority": {"type": "string", "optional": true, "description": "T
he retention priority of the cookie."}, |
110 "expirationDate": {"type": "number", "optional": true, "descriptio
n": "The expiration date of the cookie as the number of seconds since the UNIX e
poch. If omitted, the cookie becomes a session cookie."}, | 112 "expirationDate": {"type": "number", "optional": true, "descriptio
n": "The expiration date of the cookie as the number of seconds since the UNIX e
poch. If omitted, the cookie becomes a session cookie."}, |
111 "storeId": {"type": "string", "optional": true, "description": "Th
e ID of the cookie store in which to set the cookie. By default, the cookie is s
et in the current execution context's cookie store."} | 113 "storeId": {"type": "string", "optional": true, "description": "Th
e ID of the cookie store in which to set the cookie. By default, the cookie is s
et in the current execution context's cookie store."} |
112 } | 114 } |
113 }, | 115 }, |
114 { | 116 { |
115 "type": "function", | 117 "type": "function", |
116 "name": "callback", | 118 "name": "callback", |
117 "optional": true, | 119 "optional": true, |
118 "min_version": "11.0.674.0", | 120 "min_version": "11.0.674.0", |
119 "parameters": [ | 121 "parameters": [ |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 "removed": {"type": "boolean", "description": "True if a cookie wa
s removed."}, | 192 "removed": {"type": "boolean", "description": "True if a cookie wa
s removed."}, |
191 "cookie": {"$ref": "Cookie", "description": "Information about the
cookie that was set or removed."}, | 193 "cookie": {"$ref": "Cookie", "description": "Information about the
cookie that was set or removed."}, |
192 "cause": {"min_version": "12.0.707.0", "type": "string", "enum": [
"evicted", "expired", "explicit", "expired_overwrite", "overwrite"], "descriptio
n": "The underlying reason behind the cookie's change. If a cookie was inserted,
or removed via an explicit call to \"chrome.cookies.remove\", \"cause\" will be
\"explicit\". If a cookie was automatically removed due to expiry, \"cause\" wi
ll be \"expired\". If a cookie was removed due to being overwritten with an alre
ady-expired expiration date, \"cause\" will be set to \"expired_overwrite\". If
a cookie was automatically removed due to garbage collection, \"cause\" will be
\"evicted\". If a cookie was automatically removed due to a \"set\" call that
overwrote it, \"cause\" will be \"overwrite\". Plan your response accordingly."} | 194 "cause": {"min_version": "12.0.707.0", "type": "string", "enum": [
"evicted", "expired", "explicit", "expired_overwrite", "overwrite"], "descriptio
n": "The underlying reason behind the cookie's change. If a cookie was inserted,
or removed via an explicit call to \"chrome.cookies.remove\", \"cause\" will be
\"explicit\". If a cookie was automatically removed due to expiry, \"cause\" wi
ll be \"expired\". If a cookie was removed due to being overwritten with an alre
ady-expired expiration date, \"cause\" will be set to \"expired_overwrite\". If
a cookie was automatically removed due to garbage collection, \"cause\" will be
\"evicted\". If a cookie was automatically removed due to a \"set\" call that
overwrote it, \"cause\" will be \"overwrite\". Plan your response accordingly."} |
193 } | 195 } |
194 } | 196 } |
195 ] | 197 ] |
196 } | 198 } |
197 ] | 199 ] |
198 } | 200 } |
199 ] | 201 ] |
OLD | NEW |