tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

bookmarks.json (17047B)


      1 [
      2  {
      3    "namespace": "manifest",
      4    "types": [
      5      {
      6        "$extend": "OptionalPermission",
      7        "choices": [
      8          {
      9            "type": "string",
     10            "enum": ["bookmarks"]
     11          }
     12        ]
     13      }
     14    ]
     15  },
     16  {
     17    "namespace": "bookmarks",
     18    "description": "Use the <code>browser.bookmarks</code> API to create, organize, and otherwise manipulate bookmarks. Also see $(topic:override)[Override Pages], which you can use to create a custom Bookmark Manager page.",
     19    "permissions": ["bookmarks"],
     20    "types": [
     21      {
     22        "id": "BookmarkTreeNodeUnmodifiable",
     23        "type": "string",
     24        "enum": ["managed"],
     25        "description": "Indicates the reason why this node is unmodifiable. The <var>managed</var> value indicates that this node was configured by the system administrator or by the custodian of a supervised user. Omitted if the node can be modified by the user and the extension (default)."
     26      },
     27      {
     28        "id": "BookmarkTreeNodeType",
     29        "type": "string",
     30        "enum": ["bookmark", "folder", "separator"],
     31        "description": "Indicates the type of a BookmarkTreeNode, which can be one of bookmark, folder or separator."
     32      },
     33      {
     34        "id": "BookmarkTreeNode",
     35        "type": "object",
     36        "description": "A node (either a bookmark or a folder) in the bookmark tree.  Child nodes are ordered within their parent folder.",
     37        "properties": {
     38          "id": {
     39            "type": "string",
     40            "description": "The unique identifier for the node. IDs are unique within the current profile, and they remain valid even after the browser is restarted."
     41          },
     42          "parentId": {
     43            "type": "string",
     44            "optional": true,
     45            "description": "The <code>id</code> of the parent folder.  Omitted for the root node."
     46          },
     47          "index": {
     48            "type": "integer",
     49            "optional": true,
     50            "description": "The 0-based position of this node within its parent folder."
     51          },
     52          "url": {
     53            "type": "string",
     54            "optional": true,
     55            "description": "The URL navigated to when a user clicks the bookmark. Omitted for folders."
     56          },
     57          "title": {
     58            "type": "string",
     59            "description": "The text displayed for the node."
     60          },
     61          "dateAdded": {
     62            "type": "number",
     63            "optional": true,
     64            "description": "When this node was created, in milliseconds since the epoch (<code>new Date(dateAdded)</code>)."
     65          },
     66          "dateGroupModified": {
     67            "type": "number",
     68            "optional": true,
     69            "description": "When the contents of this folder last changed, in milliseconds since the epoch."
     70          },
     71          "unmodifiable": {
     72            "$ref": "BookmarkTreeNodeUnmodifiable",
     73            "optional": true,
     74            "description": "Indicates the reason why this node is unmodifiable. The <var>managed</var> value indicates that this node was configured by the system administrator or by the custodian of a supervised user. Omitted if the node can be modified by the user and the extension (default)."
     75          },
     76          "type": {
     77            "$ref": "BookmarkTreeNodeType",
     78            "optional": true,
     79            "description": "Indicates the type of the BookmarkTreeNode, which can be one of bookmark, folder or separator."
     80          },
     81          "children": {
     82            "type": "array",
     83            "optional": true,
     84            "items": { "$ref": "BookmarkTreeNode" },
     85            "description": "An ordered list of children of this node."
     86          }
     87        }
     88      },
     89      {
     90        "id": "CreateDetails",
     91        "description": "Object passed to the create() function.",
     92        "type": "object",
     93        "properties": {
     94          "parentId": {
     95            "type": "string",
     96            "optional": true,
     97            "description": "Defaults to the Other Bookmarks folder."
     98          },
     99          "index": {
    100            "type": "integer",
    101            "minimum": 0,
    102            "optional": true
    103          },
    104          "title": {
    105            "type": "string",
    106            "optional": true
    107          },
    108          "url": {
    109            "type": "string",
    110            "optional": true
    111          },
    112          "type": {
    113            "$ref": "BookmarkTreeNodeType",
    114            "optional": true,
    115            "description": "Indicates the type of BookmarkTreeNode to create, which can be one of bookmark, folder or separator."
    116          }
    117        }
    118      }
    119    ],
    120    "functions": [
    121      {
    122        "name": "get",
    123        "type": "function",
    124        "description": "Retrieves the specified BookmarkTreeNode(s).",
    125        "async": "callback",
    126        "parameters": [
    127          {
    128            "name": "idOrIdList",
    129            "description": "A single string-valued id, or an array of string-valued ids",
    130            "choices": [
    131              {
    132                "type": "string"
    133              },
    134              {
    135                "type": "array",
    136                "items": {
    137                  "type": "string"
    138                },
    139                "minItems": 1
    140              }
    141            ]
    142          },
    143          {
    144            "type": "function",
    145            "name": "callback",
    146            "parameters": [
    147              {
    148                "name": "results",
    149                "type": "array",
    150                "items": { "$ref": "BookmarkTreeNode" }
    151              }
    152            ]
    153          }
    154        ]
    155      },
    156      {
    157        "name": "getChildren",
    158        "type": "function",
    159        "description": "Retrieves the children of the specified BookmarkTreeNode id.",
    160        "async": "callback",
    161        "parameters": [
    162          {
    163            "type": "string",
    164            "name": "id"
    165          },
    166          {
    167            "type": "function",
    168            "name": "callback",
    169            "parameters": [
    170              {
    171                "name": "results",
    172                "type": "array",
    173                "items": { "$ref": "BookmarkTreeNode" }
    174              }
    175            ]
    176          }
    177        ]
    178      },
    179      {
    180        "name": "getRecent",
    181        "type": "function",
    182        "description": "Retrieves the recently added bookmarks.",
    183        "async": "callback",
    184        "parameters": [
    185          {
    186            "type": "integer",
    187            "minimum": 1,
    188            "name": "numberOfItems",
    189            "description": "The maximum number of items to return."
    190          },
    191          {
    192            "type": "function",
    193            "name": "callback",
    194            "parameters": [
    195              {
    196                "name": "results",
    197                "type": "array",
    198                "items": { "$ref": "BookmarkTreeNode" }
    199              }
    200            ]
    201          }
    202        ]
    203      },
    204      {
    205        "name": "getTree",
    206        "type": "function",
    207        "description": "Retrieves the entire Bookmarks hierarchy.",
    208        "async": "callback",
    209        "parameters": [
    210          {
    211            "type": "function",
    212            "name": "callback",
    213            "parameters": [
    214              {
    215                "name": "results",
    216                "type": "array",
    217                "items": { "$ref": "BookmarkTreeNode" }
    218              }
    219            ]
    220          }
    221        ]
    222      },
    223      {
    224        "name": "getSubTree",
    225        "type": "function",
    226        "description": "Retrieves part of the Bookmarks hierarchy, starting at the specified node.",
    227        "async": "callback",
    228        "parameters": [
    229          {
    230            "type": "string",
    231            "name": "id",
    232            "description": "The ID of the root of the subtree to retrieve."
    233          },
    234          {
    235            "type": "function",
    236            "name": "callback",
    237            "parameters": [
    238              {
    239                "name": "results",
    240                "type": "array",
    241                "items": { "$ref": "BookmarkTreeNode" }
    242              }
    243            ]
    244          }
    245        ]
    246      },
    247      {
    248        "name": "search",
    249        "type": "function",
    250        "description": "Searches for BookmarkTreeNodes matching the given query. Queries specified with an object produce BookmarkTreeNodes matching all specified properties.",
    251        "async": "callback",
    252        "parameters": [
    253          {
    254            "name": "query",
    255            "description": "Either a string of words 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.",
    256            "choices": [
    257              {
    258                "type": "string",
    259                "description": "A string of words that are matched against bookmark URLs and titles."
    260              },
    261              {
    262                "type": "object",
    263                "description": "An object specifying properties and values to match when searching. Produces bookmarks matching all properties.",
    264                "properties": {
    265                  "query": {
    266                    "type": "string",
    267                    "optional": true,
    268                    "description": "A string of words that are matched against bookmark URLs and titles."
    269                  },
    270                  "url": {
    271                    "type": "string",
    272                    "format": "url",
    273                    "optional": true,
    274                    "description": "The URL of the bookmark; matches verbatim. Note that folders have no URL."
    275                  },
    276                  "title": {
    277                    "type": "string",
    278                    "optional": true,
    279                    "description": "The title of the bookmark; matches verbatim."
    280                  }
    281                }
    282              }
    283            ]
    284          },
    285          {
    286            "type": "function",
    287            "name": "callback",
    288            "parameters": [
    289              {
    290                "name": "results",
    291                "type": "array",
    292                "items": { "$ref": "BookmarkTreeNode" }
    293              }
    294            ]
    295          }
    296        ]
    297      },
    298      {
    299        "name": "create",
    300        "type": "function",
    301        "description": "Creates a bookmark or folder under the specified parentId.  If url is NULL or missing, it will be a folder.",
    302        "async": "callback",
    303        "parameters": [
    304          {
    305            "$ref": "CreateDetails",
    306            "name": "bookmark"
    307          },
    308          {
    309            "type": "function",
    310            "name": "callback",
    311            "optional": true,
    312            "parameters": [
    313              {
    314                "name": "result",
    315                "$ref": "BookmarkTreeNode"
    316              }
    317            ]
    318          }
    319        ]
    320      },
    321      {
    322        "name": "move",
    323        "type": "function",
    324        "description": "Moves the specified BookmarkTreeNode to the provided location.",
    325        "async": "callback",
    326        "parameters": [
    327          {
    328            "type": "string",
    329            "name": "id"
    330          },
    331          {
    332            "type": "object",
    333            "name": "destination",
    334            "properties": {
    335              "parentId": {
    336                "type": "string",
    337                "optional": true
    338              },
    339              "index": {
    340                "type": "integer",
    341                "minimum": 0,
    342                "optional": true
    343              }
    344            }
    345          },
    346          {
    347            "type": "function",
    348            "name": "callback",
    349            "optional": true,
    350            "parameters": [
    351              {
    352                "name": "result",
    353                "$ref": "BookmarkTreeNode"
    354              }
    355            ]
    356          }
    357        ]
    358      },
    359      {
    360        "name": "update",
    361        "type": "function",
    362        "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.",
    363        "async": "callback",
    364        "parameters": [
    365          {
    366            "type": "string",
    367            "name": "id"
    368          },
    369          {
    370            "type": "object",
    371            "name": "changes",
    372            "properties": {
    373              "title": {
    374                "type": "string",
    375                "optional": true
    376              },
    377              "url": {
    378                "type": "string",
    379                "optional": true
    380              }
    381            }
    382          },
    383          {
    384            "type": "function",
    385            "name": "callback",
    386            "optional": true,
    387            "parameters": [
    388              {
    389                "name": "result",
    390                "$ref": "BookmarkTreeNode"
    391              }
    392            ]
    393          }
    394        ]
    395      },
    396      {
    397        "name": "remove",
    398        "type": "function",
    399        "description": "Removes a bookmark or an empty bookmark folder.",
    400        "async": "callback",
    401        "parameters": [
    402          {
    403            "type": "string",
    404            "name": "id"
    405          },
    406          {
    407            "type": "function",
    408            "name": "callback",
    409            "optional": true,
    410            "parameters": []
    411          }
    412        ]
    413      },
    414      {
    415        "name": "removeTree",
    416        "type": "function",
    417        "description": "Recursively removes a bookmark folder.",
    418        "async": "callback",
    419        "parameters": [
    420          {
    421            "type": "string",
    422            "name": "id"
    423          },
    424          {
    425            "type": "function",
    426            "name": "callback",
    427            "optional": true,
    428            "parameters": []
    429          }
    430        ]
    431      }
    432    ],
    433    "events": [
    434      {
    435        "name": "onCreated",
    436        "type": "function",
    437        "description": "Fired when a bookmark or folder is created.",
    438        "parameters": [
    439          {
    440            "type": "string",
    441            "name": "id"
    442          },
    443          {
    444            "$ref": "BookmarkTreeNode",
    445            "name": "bookmark"
    446          }
    447        ]
    448      },
    449      {
    450        "name": "onRemoved",
    451        "type": "function",
    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.",
    453        "parameters": [
    454          {
    455            "type": "string",
    456            "name": "id"
    457          },
    458          {
    459            "type": "object",
    460            "name": "removeInfo",
    461            "properties": {
    462              "parentId": { "type": "string" },
    463              "index": { "type": "integer" },
    464              "node": { "$ref": "BookmarkTreeNode" }
    465            }
    466          }
    467        ]
    468      },
    469      {
    470        "name": "onChanged",
    471        "type": "function",
    472        "description": "Fired when a bookmark or folder changes.  <b>Note:</b> Currently, only title and url changes trigger this.",
    473        "parameters": [
    474          {
    475            "type": "string",
    476            "name": "id"
    477          },
    478          {
    479            "type": "object",
    480            "name": "changeInfo",
    481            "properties": {
    482              "title": { "type": "string" },
    483              "url": {
    484                "type": "string",
    485                "optional": true
    486              }
    487            }
    488          }
    489        ]
    490      },
    491      {
    492        "name": "onMoved",
    493        "type": "function",
    494        "description": "Fired when a bookmark or folder is moved to a different parent folder.",
    495        "parameters": [
    496          {
    497            "type": "string",
    498            "name": "id"
    499          },
    500          {
    501            "type": "object",
    502            "name": "moveInfo",
    503            "properties": {
    504              "parentId": { "type": "string" },
    505              "index": { "type": "integer" },
    506              "oldParentId": { "type": "string" },
    507              "oldIndex": { "type": "integer" }
    508            }
    509          }
    510        ]
    511      },
    512      {
    513        "name": "onChildrenReordered",
    514        "unsupported": true,
    515        "type": "function",
    516        "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().",
    517        "parameters": [
    518          {
    519            "type": "string",
    520            "name": "id"
    521          },
    522          {
    523            "type": "object",
    524            "name": "reorderInfo",
    525            "properties": {
    526              "childIds": {
    527                "type": "array",
    528                "items": { "type": "string" }
    529              }
    530            }
    531          }
    532        ]
    533      },
    534      {
    535        "name": "onImportBegan",
    536        "unsupported": true,
    537        "type": "function",
    538        "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        "parameters": []
    540      },
    541      {
    542        "name": "onImportEnded",
    543        "unsupported": true,
    544        "type": "function",
    545        "description": "Fired when a bookmark import session is ended.",
    546        "parameters": []
    547      }
    548    ]
    549  }
    550 ]