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.
7 "namespace": "bookmarks",
8 "description": "Use the <code>chrome.bookmarks</code> API to create, organize, and otherwise manipulate bookmarks. Also see <a href='override.html'>Override Pages</a>, which you can use to create a custom Bookmark Manager page.",
10 "MAX_WRITE_OPERATIONS_PER_HOUR": {
12 "description": "The maximum number of <code>move</code>, <code>update</code>, <code>create</code>, or <code>remove</code> operations that can be performed each hour. Updates that would cause this limit to be exceeded fail."
14 "MAX_SUSTAINED_WRITE_OPERATIONS_PER_MINUTE": {
16 "description": "The maximum number of <code>move</code>, <code>update</code>, <code>create</code>, or <code>remove</code> operations that can be performed each minute, sustained over 10 minutes. Updates that would cause this limit to be exceeded fail."
21 "id": "BookmarkTreeNode",
23 "description": "A node (either a bookmark or a folder) in the bookmark tree. Child nodes are ordered within their parent folder.",
28 "description": "The unique identifier for the node. IDs are unique within the current profile, and they remain valid even after the browser is restarted."
34 "description": "The <code>id</code> of the parent folder. Omitted for the root node."
39 "description": "The 0-based position of this node within its parent folder."
44 "description": "The URL navigated to when a user clicks the bookmark. Omitted for folders."
48 "description": "The text displayed for the node."
53 "description": "When this node was created, in milliseconds since the epoch (<code>new Date(dateAdded)</code>)."
55 "dateGroupModified": {
58 "description": "When the contents of this folder last changed, in milliseconds since the epoch."
63 "items": { "$ref": "BookmarkTreeNode" },
64 "description": "An ordered list of children of this node."
69 "id": "CreateDetails",
70 "description": "Object passed to the create() function.",
76 "serialized_type": "int64",
78 "description": "Defaults to the Other Bookmarks folder."
100 "description": "Retrieves the specified BookmarkTreeNode(s).",
103 "name": "idOrIdList",
104 "description": "A single string-valued id, or an array of string-valued ids",
108 "serialized_type": "int64"
114 "serialized_type": "int64"
127 "items": { "$ref": "BookmarkTreeNode" }
134 "name": "getChildren",
136 "description": "Retrieves the children of the specified BookmarkTreeNode id.",
140 "serialized_type": "int64",
150 "items": { "$ref": "BookmarkTreeNode"}
159 "description": "Retrieves the recently added bookmarks.",
164 "name": "numberOfItems",
165 "description": "The maximum number of items to return."
174 "items": { "$ref": "BookmarkTreeNode" }
183 "description": "Retrieves the entire Bookmarks hierarchy.",
192 "items": { "$ref": "BookmarkTreeNode" }
199 "name": "getSubTree",
201 "description": "Retrieves part of the Bookmarks hierarchy, starting at the specified node.",
205 "serialized_type": "int64",
207 "description": "The ID of the root of the subtree to retrieve."
216 "items": { "$ref": "BookmarkTreeNode" }
225 "description": "Searches for BookmarkTreeNodes matching the given query. Queries specified with an object produce BookmarkTreeNodes matching all specified properties.",
229 "description": "Either a string of words and quoted phrases that are matched against bookmark URLs and titles, or an object. If an object, the properties <code>query</code>, <code>url</code>, and <code>title</code> may be specified and bookmarks matching all specified properties will be produced.",
233 "description": "A string of words and quoted phrases that are matched against bookmark URLs and titles."
237 "description": "An object specifying properties and values to match when searching. Produces bookmarks matching all properties.",
242 "description": "A string of words and quoted phrases that are matched against bookmark URLs and titles."
247 "description": "The URL of the bookmark; matches verbatim. Note that folders have no URL."
252 "description": "The title of the bookmark; matches verbatim."
265 "items": { "$ref": "BookmarkTreeNode" }
274 "description": "Creates a bookmark or folder under the specified parentId. If url is NULL or missing, it will be a folder.",
277 "$ref": "CreateDetails",
287 "$ref": "BookmarkTreeNode"
296 "description": "Moves the specified BookmarkTreeNode to the provided location.",
300 "serialized_type": "int64",
305 "name": "destination",
325 "$ref": "BookmarkTreeNode"
334 "description": "Updates the properties of a bookmark or folder. Specify only the properties that you want to change; unspecified properties will be left unchanged. <b>Note:</b> Currently, only 'title' and 'url' are supported.",
338 "serialized_type": "int64",
362 "$ref": "BookmarkTreeNode"
371 "description": "Removes a bookmark or an empty bookmark folder.",
375 "serialized_type": "int64",
387 "name": "removeTree",
389 "description": "Recursively removes a bookmark folder.",
393 "serialized_type": "int64",
407 "description": "Imports bookmarks from a chrome html bookmark file",
421 "description": "Exports bookmarks to a chrome html bookmark file",
437 "description": "Fired when a bookmark or folder is created.",
444 "$ref": "BookmarkTreeNode",
452 "description": "Fired when a bookmark or folder is removed. When a folder is removed recursively, a single notification is fired for the folder, and none for its contents.",
460 "name": "removeInfo",
462 "parentId": { "type": "string" },
463 "index": { "type": "integer" }
471 "description": "Fired when a bookmark or folder changes. <b>Note:</b> Currently, only title and url changes trigger this.",
479 "name": "changeInfo",
481 "title": { "type": "string" },
493 "description": "Fired when a bookmark or folder is moved to a different parent folder.",
503 "parentId": { "type": "string" },
504 "index": { "type": "integer" },
505 "oldParentId": { "type": "string" },
506 "oldIndex": { "type": "integer" }
512 "name": "onChildrenReordered",
514 "description": "Fired when the children of a folder have changed their order due to the order being sorted in the UI. This is not called as a result of a move().",
522 "name": "reorderInfo",
526 "items": { "type": "string" }
533 "name": "onImportBegan",
535 "description": "Fired when a bookmark import session is begun. Expensive observers should ignore onCreated updates until onImportEnded is fired. Observers should still handle other notifications immediately.",
539 "name": "onImportEnded",
541 "description": "Fired when a bookmark import session is ended.",