webext-schema 2.0.2 → 2.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -331,6 +331,22 @@
331
331
  "$ref": "extensionTypes.RunAt",
332
332
  "optional": true,
333
333
  "description": "The soonest that the JavaScript or CSS will be injected into the tab. Defaults to \"document_idle\"."
334
+ },
335
+ "cookieStoreId": {
336
+ "choices": [
337
+ {
338
+ "type": "array",
339
+ "minItems": 1,
340
+ "items": {
341
+ "type": "string"
342
+ }
343
+ },
344
+ {
345
+ "type": "string"
346
+ }
347
+ ],
348
+ "optional": true,
349
+ "description": "limit the set of matched tabs to those that belong to the given cookie store id"
334
350
  }
335
351
  }
336
352
  },
@@ -1772,6 +1788,27 @@
1772
1788
  "description": "The fully-qualified URL to the resource."
1773
1789
  }
1774
1790
  },
1791
+ {
1792
+ "name": "getFrameId",
1793
+ "type": "function",
1794
+ "allowedContexts": [
1795
+ "content",
1796
+ "devtools"
1797
+ ],
1798
+ "description": "Get the frameId of any window global or frame element.",
1799
+ "parameters": [
1800
+ {
1801
+ "type": "any",
1802
+ "name": "target",
1803
+ "description": "A WindowProxy or a Browsing Context container element (IFrame, Frame, Embed, Object) for the target frame."
1804
+ }
1805
+ ],
1806
+ "allowCrossOriginArguments": true,
1807
+ "returns": {
1808
+ "type": "number",
1809
+ "description": "The frameId of the target frame, or -1 if it doesn't exist."
1810
+ }
1811
+ },
1775
1812
  {
1776
1813
  "name": "setUninstallURL",
1777
1814
  "type": "function",
@@ -2696,7 +2733,7 @@
2696
2733
  {
2697
2734
  "name": "getCurrent",
2698
2735
  "type": "function",
2699
- "async": true,
2736
+ "async": "callback",
2700
2737
  "description": "Returns the current theme for the specified window or the last focused window.",
2701
2738
  "parameters": [
2702
2739
  {
@@ -2704,6 +2741,16 @@
2704
2741
  "name": "windowId",
2705
2742
  "optional": true,
2706
2743
  "description": "The window for which we want the theme."
2744
+ },
2745
+ {
2746
+ "type": "function",
2747
+ "name": "callback",
2748
+ "optional": true,
2749
+ "parameters": [
2750
+ {
2751
+ "$ref": "ThemeType"
2752
+ }
2753
+ ]
2707
2754
  }
2708
2755
  ]
2709
2756
  },
@@ -3197,7 +3244,7 @@
3197
3244
  {
3198
3245
  "name": "onSearchRequest",
3199
3246
  "type": "function",
3200
- "description": "Creates a read-only addressbook that fires this event when searching for a contact. Note: This event may change in future releases of Thunderbird.",
3247
+ "description": "Registering this listener will create and list a read-only address book in Thunderbird's address book window, similar to LDAP address books. When selecting this address book, users will first see no contacts, but they can search for them, which will fire this event. Contacts returned by the listener callback will be displayed as contact cards in the address book. Several listeners can be registered, to create multiple address books.\n\nThe event also fires for each registered listener (for each created read-only address book), when users type something into the mail composer's <code>To:</code> field, or into similar fields like the calendar meeting attendees field. Contacts returned by the listener callback will be added to the autocomplete results in the dropdown of that field.\n\nExample: <literalinclude>includes/addressBooks/onSearchRequest.js<lang>JavaScript</lang></literalinclude>",
3201
3248
  "parameters": [
3202
3249
  {
3203
3250
  "name": "node",
@@ -3219,22 +3266,23 @@
3219
3266
  "extraParameters": [
3220
3267
  {
3221
3268
  "name": "parameters",
3269
+ "description": "Descriptions for the address book created by registering this listener.",
3222
3270
  "type": "object",
3223
3271
  "properties": {
3224
3272
  "addressBookName": {
3225
3273
  "type": "string",
3226
3274
  "optional": true,
3227
- "description": "The initial name of the address book."
3275
+ "description": "The name of the created address book."
3228
3276
  },
3229
3277
  "isSecure": {
3230
3278
  "type": "boolean",
3231
3279
  "optional": true,
3232
- "description": "Whether the address book is searched securely."
3280
+ "description": "Whether the address book search queries are using encrypted protocols like HTTPS."
3233
3281
  },
3234
3282
  "id": {
3235
3283
  "type": "string",
3236
3284
  "optional": true,
3237
- "description": "The id of the address book."
3285
+ "description": "The unique ID of the created address book. If several listeners have been added, the ``id`` allows to identify which address book initiated the search request. If not provided, a unique ID will be generated for you."
3238
3286
  }
3239
3287
  }
3240
3288
  }
@@ -3335,11 +3383,24 @@
3335
3383
  {
3336
3384
  "name": "list",
3337
3385
  "type": "function",
3338
- "async": true,
3386
+ "async": "callback",
3339
3387
  "parameters": [
3340
3388
  {
3341
3389
  "name": "parentId",
3342
3390
  "type": "string"
3391
+ },
3392
+ {
3393
+ "type": "function",
3394
+ "name": "callback",
3395
+ "optional": true,
3396
+ "parameters": [
3397
+ {
3398
+ "type": "array",
3399
+ "items": {
3400
+ "$ref": "ContactNode"
3401
+ }
3402
+ }
3403
+ ]
3343
3404
  }
3344
3405
  ],
3345
3406
  "description": "Gets all the contacts in the address book with the id <code>parentId</code>."
@@ -3347,7 +3408,7 @@
3347
3408
  {
3348
3409
  "name": "quickSearch",
3349
3410
  "type": "function",
3350
- "async": true,
3411
+ "async": "callback",
3351
3412
  "parameters": [
3352
3413
  {
3353
3414
  "name": "parentId",
@@ -3397,18 +3458,41 @@
3397
3458
  }
3398
3459
  }
3399
3460
  ]
3461
+ },
3462
+ {
3463
+ "type": "function",
3464
+ "name": "callback",
3465
+ "optional": true,
3466
+ "parameters": [
3467
+ {
3468
+ "type": "array",
3469
+ "items": {
3470
+ "$ref": "ContactNode"
3471
+ }
3472
+ }
3473
+ ]
3400
3474
  }
3401
3475
  ],
3402
- "description": "Gets all contacts matching <code>searchString</code> in the address book with the id <code>parentId</code>."
3476
+ "description": "Gets all contacts matching ``queryInfo`` in the address book with the id ``parentId``."
3403
3477
  },
3404
3478
  {
3405
3479
  "name": "get",
3406
3480
  "type": "function",
3407
- "async": true,
3481
+ "async": "callback",
3408
3482
  "parameters": [
3409
3483
  {
3410
3484
  "name": "id",
3411
3485
  "type": "string"
3486
+ },
3487
+ {
3488
+ "type": "function",
3489
+ "name": "callback",
3490
+ "optional": true,
3491
+ "parameters": [
3492
+ {
3493
+ "$ref": "ContactNode"
3494
+ }
3495
+ ]
3412
3496
  }
3413
3497
  ],
3414
3498
  "description": "Gets a single contact."
@@ -3416,7 +3500,7 @@
3416
3500
  {
3417
3501
  "name": "create",
3418
3502
  "type": "function",
3419
- "async": true,
3503
+ "async": "callback",
3420
3504
  "parameters": [
3421
3505
  {
3422
3506
  "name": "parentId",
@@ -3431,6 +3515,17 @@
3431
3515
  {
3432
3516
  "name": "properties",
3433
3517
  "$ref": "ContactProperties"
3518
+ },
3519
+ {
3520
+ "type": "function",
3521
+ "name": "callback",
3522
+ "optional": true,
3523
+ "parameters": [
3524
+ {
3525
+ "type": "string",
3526
+ "description": "The ID of the new contact."
3527
+ }
3528
+ ]
3434
3529
  }
3435
3530
  ],
3436
3531
  "description": "Adds a new contact to the address book with the id <code>parentId</code>."
@@ -3570,11 +3665,24 @@
3570
3665
  {
3571
3666
  "name": "list",
3572
3667
  "type": "function",
3573
- "async": true,
3668
+ "async": "callback",
3574
3669
  "parameters": [
3575
3670
  {
3576
3671
  "name": "parentId",
3577
3672
  "type": "string"
3673
+ },
3674
+ {
3675
+ "type": "function",
3676
+ "name": "callback",
3677
+ "optional": true,
3678
+ "parameters": [
3679
+ {
3680
+ "type": "array",
3681
+ "items": {
3682
+ "$ref": "MailingListNode"
3683
+ }
3684
+ }
3685
+ ]
3578
3686
  }
3579
3687
  ],
3580
3688
  "description": "Gets all the mailing lists in the address book with id <code>parentId</code>."
@@ -3582,11 +3690,21 @@
3582
3690
  {
3583
3691
  "name": "get",
3584
3692
  "type": "function",
3585
- "async": true,
3693
+ "async": "callback",
3586
3694
  "parameters": [
3587
3695
  {
3588
3696
  "name": "id",
3589
3697
  "type": "string"
3698
+ },
3699
+ {
3700
+ "type": "function",
3701
+ "name": "callback",
3702
+ "optional": true,
3703
+ "parameters": [
3704
+ {
3705
+ "$ref": "MailingListNode"
3706
+ }
3707
+ ]
3590
3708
  }
3591
3709
  ],
3592
3710
  "description": "Gets a single mailing list."
@@ -3594,7 +3712,7 @@
3594
3712
  {
3595
3713
  "name": "create",
3596
3714
  "type": "function",
3597
- "async": true,
3715
+ "async": "callback",
3598
3716
  "parameters": [
3599
3717
  {
3600
3718
  "name": "parentId",
@@ -3616,6 +3734,17 @@
3616
3734
  "optional": true
3617
3735
  }
3618
3736
  }
3737
+ },
3738
+ {
3739
+ "type": "function",
3740
+ "name": "callback",
3741
+ "optional": true,
3742
+ "parameters": [
3743
+ {
3744
+ "type": "string",
3745
+ "description": "The ID of the new mailing list."
3746
+ }
3747
+ ]
3619
3748
  }
3620
3749
  ],
3621
3750
  "description": "Creates a new mailing list in the address book with id <code>parentId</code>."
@@ -3680,11 +3809,24 @@
3680
3809
  {
3681
3810
  "name": "listMembers",
3682
3811
  "type": "function",
3683
- "async": true,
3812
+ "async": "callback",
3684
3813
  "parameters": [
3685
3814
  {
3686
3815
  "name": "id",
3687
3816
  "type": "string"
3817
+ },
3818
+ {
3819
+ "type": "function",
3820
+ "name": "callback",
3821
+ "optional": true,
3822
+ "parameters": [
3823
+ {
3824
+ "type": "array",
3825
+ "items": {
3826
+ "$ref": "contacts.ContactNode"
3827
+ }
3828
+ }
3829
+ ]
3688
3830
  }
3689
3831
  ],
3690
3832
  "description": "Gets all contacts that are members of the mailing list with id <code>id</code>."
@@ -3810,7 +3952,7 @@
3810
3952
  "items": {
3811
3953
  "$ref": "ThemeIcons"
3812
3954
  },
3813
- "description": "Specifies icons to use for dark and light themes"
3955
+ "description": "Specifies dark and light icons to be used with themes. The ``light`` icon is used on dark backgrounds and vice versa. Note: The default theme uses the ``default_icon`` for light backgrounds (if specified)."
3814
3956
  },
3815
3957
  "default_popup": {
3816
3958
  "type": "string",
@@ -4550,15 +4692,15 @@
4550
4692
  "properties": {
4551
4693
  "browser_style": {
4552
4694
  "type": "boolean",
4553
- "description": "Enable browser styles. See the `MDN documentation <https://developer.mozilla.org/docs/Mozilla/Add-ons/WebExtensions/user_interface/Browser_styles>`__ for more information.",
4695
+ "description": "Enable browser styles in the ``management_url`` page. See the `MDN documentation <https://developer.mozilla.org/docs/Mozilla/Add-ons/WebExtensions/user_interface/Browser_styles>`__ for more information.",
4554
4696
  "optional": true,
4555
4697
  "default": false
4556
4698
  },
4557
4699
  "data_format": {
4558
4700
  "type": "string",
4559
4701
  "optional": true,
4560
- "default": "ArrayBuffer",
4561
- "description": "Determines the format of the ``data`` argument in ``onFileUpload``.",
4702
+ "default": "File",
4703
+ "description": "Determines the format of the ``data`` argument in ``onFileUpload``. Support for ArrayBuffer will be removed in Thunderbird 102.",
4562
4704
  "enum": [
4563
4705
  "ArrayBuffer",
4564
4706
  "File"
@@ -4584,7 +4726,8 @@
4584
4726
  "service_url": {
4585
4727
  "type": "string",
4586
4728
  "optional": true,
4587
- "description": "URL to the web page of the cloud file service."
4729
+ "deprecated": true,
4730
+ "description": "This property is no longer used. The ``service_url`` property of the :ref:`cloudFile.CloudFileTemplateInfo` object returned by the :ref:`cloudFile.onFileUpload` event can be used to add a ``Learn more about`` link to the footer of the cloud file attachment element."
4588
4731
  }
4589
4732
  },
4590
4733
  "optional": true
@@ -4605,17 +4748,17 @@
4605
4748
  {
4606
4749
  "name": "onFileUpload",
4607
4750
  "type": "function",
4608
- "description": "Fired when a file should be uploaded to the cloud file provider",
4751
+ "description": "Fired when a file should be uploaded to the cloud file provider.",
4609
4752
  "parameters": [
4610
4753
  {
4611
4754
  "name": "account",
4612
4755
  "$ref": "CloudFileAccount",
4613
- "description": "The created account"
4756
+ "description": "The account used for the file upload."
4614
4757
  },
4615
4758
  {
4616
4759
  "name": "fileInfo",
4617
4760
  "$ref": "CloudFile",
4618
- "description": "The file to upload"
4761
+ "description": "The file to upload."
4619
4762
  },
4620
4763
  {
4621
4764
  "name": "tab",
@@ -4628,12 +4771,29 @@
4628
4771
  "properties": {
4629
4772
  "aborted": {
4630
4773
  "type": "boolean",
4631
- "description": "Set this to true if the file upload was aborted",
4774
+ "description": "Set this to true if the file upload was aborted.",
4775
+ "optional": true
4776
+ },
4777
+ "error": {
4778
+ "choices": [
4779
+ {
4780
+ "type": "boolean"
4781
+ },
4782
+ {
4783
+ "type": "string"
4784
+ }
4785
+ ],
4786
+ "description": "Report an error to the user. Set this to true for showing a generic error message, or set a specific error message.",
4632
4787
  "optional": true
4633
4788
  },
4634
4789
  "url": {
4635
4790
  "type": "string",
4636
- "description": "The URL where the uploaded file can be accessed",
4791
+ "description": "The URL where the uploaded file can be accessed.",
4792
+ "optional": true
4793
+ },
4794
+ "templateInfo": {
4795
+ "$ref": "CloudFileTemplateInfo",
4796
+ "description": "Defines information to be used in the cloud file entry added to the message.",
4637
4797
  "optional": true
4638
4798
  }
4639
4799
  }
@@ -4646,13 +4806,13 @@
4646
4806
  {
4647
4807
  "name": "account",
4648
4808
  "$ref": "CloudFileAccount",
4649
- "description": "The created account"
4809
+ "description": "The account used for the file upload."
4650
4810
  },
4651
4811
  {
4652
4812
  "type": "integer",
4653
4813
  "name": "fileId",
4654
4814
  "minimum": 1,
4655
- "description": "An identifier for this file"
4815
+ "description": "An identifier for this file."
4656
4816
  },
4657
4817
  {
4658
4818
  "name": "tab",
@@ -4661,21 +4821,71 @@
4661
4821
  }
4662
4822
  ]
4663
4823
  },
4824
+ {
4825
+ "name": "onFileRename",
4826
+ "type": "function",
4827
+ "description": "Fired when an already uploaded file should be renamed.",
4828
+ "parameters": [
4829
+ {
4830
+ "name": "account",
4831
+ "$ref": "CloudFileAccount",
4832
+ "description": "The account used for the file upload."
4833
+ },
4834
+ {
4835
+ "type": "integer",
4836
+ "name": "fileId",
4837
+ "minimum": 1,
4838
+ "description": "An identifier for the file which should be renamed."
4839
+ },
4840
+ {
4841
+ "type": "string",
4842
+ "name": "newName",
4843
+ "description": "The new name of the file."
4844
+ },
4845
+ {
4846
+ "name": "tab",
4847
+ "$ref": "tabs.Tab",
4848
+ "description": "The tab where the rename was initiated. Currently only available for the message composer."
4849
+ }
4850
+ ],
4851
+ "returns": {
4852
+ "type": "object",
4853
+ "properties": {
4854
+ "error": {
4855
+ "choices": [
4856
+ {
4857
+ "type": "boolean"
4858
+ },
4859
+ {
4860
+ "type": "string"
4861
+ }
4862
+ ],
4863
+ "description": "Report an error to the user. Set this to true for showing a generic error message, or set a specific error message.",
4864
+ "optional": true
4865
+ },
4866
+ "url": {
4867
+ "type": "string",
4868
+ "description": "The URL where the renamed file can be accessed.",
4869
+ "optional": true
4870
+ }
4871
+ }
4872
+ }
4873
+ },
4664
4874
  {
4665
4875
  "name": "onFileDeleted",
4666
4876
  "type": "function",
4667
- "description": "Fired when a file previously uploaded should be deleted",
4877
+ "description": "Fired when a file previously uploaded should be deleted.",
4668
4878
  "parameters": [
4669
4879
  {
4670
4880
  "name": "account",
4671
4881
  "$ref": "CloudFileAccount",
4672
- "description": "The created account"
4882
+ "description": "The account used for the file upload."
4673
4883
  },
4674
4884
  {
4675
4885
  "type": "integer",
4676
4886
  "name": "fileId",
4677
4887
  "minimum": 1,
4678
- "description": "An identifier for this file"
4888
+ "description": "An identifier for this file."
4679
4889
  },
4680
4890
  {
4681
4891
  "name": "tab",
@@ -4687,24 +4897,24 @@
4687
4897
  {
4688
4898
  "name": "onAccountAdded",
4689
4899
  "type": "function",
4690
- "description": "Fired when a cloud file account of this add-on was created",
4900
+ "description": "Fired when a cloud file account of this add-on was created.",
4691
4901
  "parameters": [
4692
4902
  {
4693
4903
  "name": "account",
4694
4904
  "$ref": "CloudFileAccount",
4695
- "description": "The created account"
4905
+ "description": "The created account."
4696
4906
  }
4697
4907
  ]
4698
4908
  },
4699
4909
  {
4700
4910
  "name": "onAccountDeleted",
4701
4911
  "type": "function",
4702
- "description": "Fired when a cloud file account of this add-on was deleted",
4912
+ "description": "Fired when a cloud file account of this add-on was deleted.",
4703
4913
  "parameters": [
4704
4914
  {
4705
4915
  "name": "accountId",
4706
4916
  "type": "string",
4707
- "description": "The id of the removed account"
4917
+ "description": "The id of the removed account."
4708
4918
  }
4709
4919
  ]
4710
4920
  }
@@ -4713,11 +4923,11 @@
4713
4923
  {
4714
4924
  "id": "CloudFileAccount",
4715
4925
  "type": "object",
4716
- "description": "Information about a cloud file account",
4926
+ "description": "Information about a cloud file account.",
4717
4927
  "properties": {
4718
4928
  "id": {
4719
4929
  "type": "string",
4720
- "description": "Unique identifier of the account"
4930
+ "description": "Unique identifier of the account."
4721
4931
  },
4722
4932
  "configured": {
4723
4933
  "type": "boolean",
@@ -4752,19 +4962,68 @@
4752
4962
  }
4753
4963
  }
4754
4964
  },
4965
+ {
4966
+ "id": "CloudFileTemplateInfo",
4967
+ "type": "object",
4968
+ "description": "Defines information to be used in the cloud file entry added to the message.",
4969
+ "properties": {
4970
+ "service_icon": {
4971
+ "type": "string",
4972
+ "optional": true,
4973
+ "description": "A URL pointing to an icon to represent the used cloud file service. Defaults to the icon of the provider add-on."
4974
+ },
4975
+ "service_name": {
4976
+ "type": "string",
4977
+ "optional": true,
4978
+ "description": "A name to represent the used cloud file service. Defaults to the associated cloud file account name."
4979
+ },
4980
+ "service_url": {
4981
+ "type": "string",
4982
+ "optional": true,
4983
+ "description": "A URL pointing to a web page of the used cloud file service. Will be used in a ``Learn more about`` link in the footer of the cloud file attachment element."
4984
+ },
4985
+ "download_password_protected": {
4986
+ "type": "boolean",
4987
+ "optional": true,
4988
+ "description": "If set to true, the cloud file entry for this upload will include a hint, that the download link is password protected."
4989
+ },
4990
+ "download_limit": {
4991
+ "type": "integer",
4992
+ "optional": true,
4993
+ "description": "If set, the cloud file entry for this upload will include a hint, that the file has a download limit."
4994
+ },
4995
+ "download_expiry_date": {
4996
+ "type": "object",
4997
+ "optional": true,
4998
+ "description": "If set, the cloud file entry for this upload will include a hint, that the link will only be available for a limited time.",
4999
+ "properties": {
5000
+ "timestamp": {
5001
+ "type": "integer",
5002
+ "description": "The expiry date of the link as the number of milliseconds since the UNIX epoch."
5003
+ },
5004
+ "format": {
5005
+ "optional": true,
5006
+ "description": "A format options object as used by `Intl.DateTimeFormat <https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DateTimeFormat/DateTimeFormat>`__. Defaults to: <literalinclude>includes/cloudFile/defaultDateFormat.js<lang>JavaScript</lang></literalinclude>",
5007
+ "type": "object",
5008
+ "additionalProperties": true
5009
+ }
5010
+ }
5011
+ }
5012
+ }
5013
+ },
4755
5014
  {
4756
5015
  "id": "CloudFile",
4757
5016
  "type": "object",
4758
- "description": "Information about a cloud file",
5017
+ "description": "Information about a cloud file.",
4759
5018
  "properties": {
4760
5019
  "id": {
4761
5020
  "type": "integer",
4762
5021
  "minimum": 1,
4763
- "description": "An identifier for this file"
5022
+ "description": "An identifier for this file."
4764
5023
  },
4765
5024
  "name": {
4766
5025
  "type": "string",
4767
- "description": "Filename of the file to be transferred"
5026
+ "description": "Filename of the file to be transferred."
4768
5027
  },
4769
5028
  "data": {
4770
5029
  "choices": [
@@ -4772,13 +5031,13 @@
4772
5031
  "type": "object",
4773
5032
  "isInstanceOf": "ArrayBuffer",
4774
5033
  "additionalProperties": true,
4775
- "description": "Contents of the file to be transferred"
5034
+ "description": "Contents of the file to be transferred."
4776
5035
  },
4777
5036
  {
4778
5037
  "type": "object",
4779
5038
  "isInstanceOf": "File",
4780
5039
  "additionalProperties": true,
4781
- "description": "Contents of the file to be transferred"
5040
+ "description": "Contents of the file to be transferred."
4782
5041
  }
4783
5042
  ]
4784
5043
  }
@@ -4789,7 +5048,7 @@
4789
5048
  {
4790
5049
  "name": "getAccount",
4791
5050
  "type": "function",
4792
- "description": "Retrieve information about a single cloud file account",
5051
+ "description": "Retrieve information about a single cloud file account.",
4793
5052
  "allowedContexts": [
4794
5053
  "content"
4795
5054
  ],
@@ -4798,7 +5057,7 @@
4798
5057
  {
4799
5058
  "name": "accountId",
4800
5059
  "type": "string",
4801
- "description": "Unique identifier of the account"
5060
+ "description": "Unique identifier of the account."
4802
5061
  },
4803
5062
  {
4804
5063
  "type": "function",
@@ -4815,7 +5074,7 @@
4815
5074
  {
4816
5075
  "name": "getAllAccounts",
4817
5076
  "type": "function",
4818
- "description": "Retrieve all cloud file accounts for the current add-on",
5077
+ "description": "Retrieve all cloud file accounts for the current add-on.",
4819
5078
  "allowedContexts": [
4820
5079
  "content"
4821
5080
  ],
@@ -4839,7 +5098,7 @@
4839
5098
  {
4840
5099
  "name": "updateAccount",
4841
5100
  "type": "function",
4842
- "description": "Update a cloud file account",
5101
+ "description": "Update a cloud file account.",
4843
5102
  "allowedContexts": [
4844
5103
  "content"
4845
5104
  ],
@@ -4848,7 +5107,7 @@
4848
5107
  {
4849
5108
  "name": "accountId",
4850
5109
  "type": "string",
4851
- "description": "Unique identifier of the account"
5110
+ "description": "Unique identifier of the account."
4852
5111
  },
4853
5112
  {
4854
5113
  "name": "updateProperties",
@@ -5381,11 +5640,31 @@
5381
5640
  "permissions": [
5382
5641
  "compose"
5383
5642
  ],
5384
- "async": true,
5643
+ "async": "callback",
5385
5644
  "parameters": [
5386
5645
  {
5387
5646
  "name": "tabId",
5388
5647
  "type": "integer"
5648
+ },
5649
+ {
5650
+ "type": "function",
5651
+ "name": "callback",
5652
+ "optional": true,
5653
+ "parameters": [
5654
+ {
5655
+ "choices": [
5656
+ {
5657
+ "type": "array",
5658
+ "items": {
5659
+ "$ref": "ComposeAttachment"
5660
+ }
5661
+ },
5662
+ {
5663
+ "type": "any"
5664
+ }
5665
+ ]
5666
+ }
5667
+ ]
5389
5668
  }
5390
5669
  ]
5391
5670
  },
@@ -5396,7 +5675,7 @@
5396
5675
  "permissions": [
5397
5676
  "compose"
5398
5677
  ],
5399
- "async": true,
5678
+ "async": "callback",
5400
5679
  "parameters": [
5401
5680
  {
5402
5681
  "name": "tabId",
@@ -5417,6 +5696,23 @@
5417
5696
  "additionalProperties": true
5418
5697
  }
5419
5698
  }
5699
+ },
5700
+ {
5701
+ "type": "function",
5702
+ "name": "callback",
5703
+ "optional": true,
5704
+ "parameters": [
5705
+ {
5706
+ "choices": [
5707
+ {
5708
+ "$ref": "ComposeAttachment"
5709
+ },
5710
+ {
5711
+ "type": "any"
5712
+ }
5713
+ ]
5714
+ }
5715
+ ]
5420
5716
  }
5421
5717
  ]
5422
5718
  },
@@ -5427,7 +5723,7 @@
5427
5723
  "permissions": [
5428
5724
  "compose"
5429
5725
  ],
5430
- "async": true,
5726
+ "async": "callback",
5431
5727
  "parameters": [
5432
5728
  {
5433
5729
  "name": "tabId",
@@ -5453,6 +5749,23 @@
5453
5749
  "optional": true
5454
5750
  }
5455
5751
  }
5752
+ },
5753
+ {
5754
+ "type": "function",
5755
+ "name": "callback",
5756
+ "optional": true,
5757
+ "parameters": [
5758
+ {
5759
+ "choices": [
5760
+ {
5761
+ "$ref": "ComposeAttachment"
5762
+ },
5763
+ {
5764
+ "type": "any"
5765
+ }
5766
+ ]
5767
+ }
5768
+ ]
5456
5769
  }
5457
5770
  ]
5458
5771
  },
@@ -5580,7 +5893,7 @@
5580
5893
  "items": {
5581
5894
  "$ref": "ThemeIcons"
5582
5895
  },
5583
- "description": "Specifies icons to use for dark and light themes"
5896
+ "description": "Specifies dark and light icons to be used with themes. The ``light`` icon is used on dark backgrounds and vice versa. Note: The default theme uses the ``default_icon`` for light backgrounds (if specified)."
5584
5897
  },
5585
5898
  "default_popup": {
5586
5899
  "type": "string",
@@ -6061,11 +6374,21 @@
6061
6374
  "name": "isEnabled",
6062
6375
  "type": "function",
6063
6376
  "description": "Checks whether the composeAction is enabled.",
6064
- "async": true,
6377
+ "async": "callback",
6065
6378
  "parameters": [
6066
6379
  {
6067
6380
  "name": "details",
6068
6381
  "$ref": "Details"
6382
+ },
6383
+ {
6384
+ "type": "function",
6385
+ "name": "callback",
6386
+ "optional": true,
6387
+ "parameters": [
6388
+ {
6389
+ "type": "boolean"
6390
+ }
6391
+ ]
6069
6392
  }
6070
6393
  ]
6071
6394
  },
@@ -8185,12 +8508,29 @@
8185
8508
  "name": "getDisplayedMessage",
8186
8509
  "type": "function",
8187
8510
  "description": "Gets the currently displayed message in the specified tab. It returns null if no messages are displayed, or if multiple messages are displayed.",
8188
- "async": true,
8511
+ "async": "callback",
8189
8512
  "parameters": [
8190
8513
  {
8191
8514
  "name": "tabId",
8192
8515
  "type": "integer",
8193
8516
  "minimum": 1
8517
+ },
8518
+ {
8519
+ "type": "function",
8520
+ "name": "callback",
8521
+ "optional": true,
8522
+ "parameters": [
8523
+ {
8524
+ "choices": [
8525
+ {
8526
+ "$ref": "messages.MessageHeader"
8527
+ },
8528
+ {
8529
+ "type": "null"
8530
+ }
8531
+ ]
8532
+ }
8533
+ ]
8194
8534
  }
8195
8535
  ]
8196
8536
  },
@@ -8198,12 +8538,25 @@
8198
8538
  "name": "getDisplayedMessages",
8199
8539
  "type": "function",
8200
8540
  "description": "Gets an array of the currently displayed messages in the specified tab. The array is empty if no messages are displayed.",
8201
- "async": true,
8541
+ "async": "callback",
8202
8542
  "parameters": [
8203
8543
  {
8204
8544
  "name": "tabId",
8205
8545
  "type": "integer",
8206
8546
  "minimum": 1
8547
+ },
8548
+ {
8549
+ "type": "function",
8550
+ "name": "callback",
8551
+ "optional": true,
8552
+ "parameters": [
8553
+ {
8554
+ "type": "array",
8555
+ "items": {
8556
+ "$ref": "messages.MessageHeader"
8557
+ }
8558
+ }
8559
+ ]
8207
8560
  }
8208
8561
  ]
8209
8562
  }
@@ -8247,7 +8600,7 @@
8247
8600
  "items": {
8248
8601
  "$ref": "ThemeIcons"
8249
8602
  },
8250
- "description": "Specifies icons to use for dark and light themes"
8603
+ "description": "Specifies dark and light icons to be used with themes. The ``light`` icon is used on dark backgrounds and vice versa. Note: The default theme uses the ``default_icon`` for light backgrounds (if specified)."
8251
8604
  },
8252
8605
  "default_popup": {
8253
8606
  "type": "string",
@@ -8724,11 +9077,21 @@
8724
9077
  "name": "isEnabled",
8725
9078
  "type": "function",
8726
9079
  "description": "Checks whether the messageDisplayAction is enabled.",
8727
- "async": true,
9080
+ "async": "callback",
8728
9081
  "parameters": [
8729
9082
  {
8730
9083
  "name": "details",
8731
9084
  "$ref": "Details"
9085
+ },
9086
+ {
9087
+ "type": "function",
9088
+ "name": "callback",
9089
+ "optional": true,
9090
+ "parameters": [
9091
+ {
9092
+ "type": "boolean"
9093
+ }
9094
+ ]
8732
9095
  }
8733
9096
  ]
8734
9097
  },
@@ -8894,7 +9257,13 @@
8894
9257
  "headers": {
8895
9258
  "type": "object",
8896
9259
  "description": "An object of part headers, with the header name as key, and an array of header values as value",
8897
- "optional": true
9260
+ "optional": true,
9261
+ "additionalProperties": {
9262
+ "type": "array",
9263
+ "items": {
9264
+ "type": "string"
9265
+ }
9266
+ }
8898
9267
  },
8899
9268
  "name": {
8900
9269
  "type": "string",
@@ -9109,7 +9478,7 @@
9109
9478
  "name": "list",
9110
9479
  "type": "function",
9111
9480
  "description": "Gets all messages in a folder.",
9112
- "async": true,
9481
+ "async": "callback",
9113
9482
  "permissions": [
9114
9483
  "accountsRead"
9115
9484
  ],
@@ -9117,6 +9486,16 @@
9117
9486
  {
9118
9487
  "name": "folder",
9119
9488
  "$ref": "folders.MailFolder"
9489
+ },
9490
+ {
9491
+ "type": "function",
9492
+ "name": "callback",
9493
+ "optional": true,
9494
+ "parameters": [
9495
+ {
9496
+ "$ref": "MessageList"
9497
+ }
9498
+ ]
9120
9499
  }
9121
9500
  ]
9122
9501
  },
@@ -9124,11 +9503,21 @@
9124
9503
  "name": "continueList",
9125
9504
  "type": "function",
9126
9505
  "description": "Returns the next chunk of messages in a list. See :doc:`how-to/messageLists` for more information.",
9127
- "async": true,
9506
+ "async": "callback",
9128
9507
  "parameters": [
9129
9508
  {
9130
9509
  "name": "messageListId",
9131
9510
  "type": "string"
9511
+ },
9512
+ {
9513
+ "type": "function",
9514
+ "name": "callback",
9515
+ "optional": true,
9516
+ "parameters": [
9517
+ {
9518
+ "$ref": "MessageList"
9519
+ }
9520
+ ]
9132
9521
  }
9133
9522
  ]
9134
9523
  },
@@ -9136,11 +9525,21 @@
9136
9525
  "name": "get",
9137
9526
  "type": "function",
9138
9527
  "description": "Returns a specified message.",
9139
- "async": true,
9528
+ "async": "callback",
9140
9529
  "parameters": [
9141
9530
  {
9142
9531
  "name": "messageId",
9143
9532
  "type": "integer"
9533
+ },
9534
+ {
9535
+ "type": "function",
9536
+ "name": "callback",
9537
+ "optional": true,
9538
+ "parameters": [
9539
+ {
9540
+ "$ref": "MessageHeader"
9541
+ }
9542
+ ]
9144
9543
  }
9145
9544
  ]
9146
9545
  },
@@ -9148,23 +9547,43 @@
9148
9547
  "name": "getFull",
9149
9548
  "type": "function",
9150
9549
  "description": "Returns a specified message, including all headers and MIME parts.",
9151
- "async": true,
9550
+ "async": "callback",
9152
9551
  "parameters": [
9153
9552
  {
9154
9553
  "name": "messageId",
9155
9554
  "type": "integer"
9555
+ },
9556
+ {
9557
+ "type": "function",
9558
+ "name": "callback",
9559
+ "optional": true,
9560
+ "parameters": [
9561
+ {
9562
+ "$ref": "MessagePart"
9563
+ }
9564
+ ]
9156
9565
  }
9157
9566
  ]
9158
9567
  },
9159
9568
  {
9160
9569
  "name": "getRaw",
9161
9570
  "type": "function",
9162
- "description": "Returns the unmodified source of a message as a `binary string <https://developer.mozilla.org/en-US/docs/Web/API/DOMString/Binary>`__.",
9163
- "async": true,
9571
+ "description": "Returns the unmodified source of a message as a `binary string <https://developer.mozilla.org/en-US/docs/Web/API/DOMString/Binary>`__, which is a simple series of 8-bit values. If the message contains non-ASCII characters, the body parts in the binary string cannot be read directly and must be decoded according to their character sets. Use :ref:`messages.getFull` to get the correctly decoded parts. Manually decoding the raw message is probably too error-prone, especially if the message contains MIME parts with different character set encodings or attachments.\n\nTo get a readable version of the raw message as it appears in Thunderbird's message source view, it may be sufficient to decode the message according to the character set specified in its main ``content-type`` header (example: `text/html; charset=UTF-8`) using the following function (see MDN for `supported input encodings <https://developer.mozilla.org/en-US/docs/Web/API/Encoding_API/Encodings>`__): <literalinclude>includes/messages/decodeBinaryString.js<lang>JavaScript</lang></literalinclude>",
9572
+ "async": "callback",
9164
9573
  "parameters": [
9165
9574
  {
9166
9575
  "name": "messageId",
9167
9576
  "type": "integer"
9577
+ },
9578
+ {
9579
+ "type": "function",
9580
+ "name": "callback",
9581
+ "optional": true,
9582
+ "parameters": [
9583
+ {
9584
+ "type": "string"
9585
+ }
9586
+ ]
9168
9587
  }
9169
9588
  ]
9170
9589
  },
@@ -9172,11 +9591,24 @@
9172
9591
  "name": "listAttachments",
9173
9592
  "type": "function",
9174
9593
  "description": "Lists all of the attachments of a message.",
9175
- "async": true,
9594
+ "async": "callback",
9176
9595
  "parameters": [
9177
9596
  {
9178
9597
  "name": "messageId",
9179
9598
  "type": "integer"
9599
+ },
9600
+ {
9601
+ "type": "function",
9602
+ "name": "callback",
9603
+ "optional": true,
9604
+ "parameters": [
9605
+ {
9606
+ "type": "array",
9607
+ "items": {
9608
+ "$ref": "Attachment"
9609
+ }
9610
+ }
9611
+ ]
9180
9612
  }
9181
9613
  ]
9182
9614
  },
@@ -9184,7 +9616,7 @@
9184
9616
  "name": "getAttachmentFile",
9185
9617
  "type": "function",
9186
9618
  "description": "Gets the content of an attachment as a DOM <code>File</code> object.",
9187
- "async": true,
9619
+ "async": "callback",
9188
9620
  "parameters": [
9189
9621
  {
9190
9622
  "name": "messageId",
@@ -9194,6 +9626,18 @@
9194
9626
  "name": "partName",
9195
9627
  "type": "string",
9196
9628
  "pattern": "^\\d+(\\.\\d+)*$"
9629
+ },
9630
+ {
9631
+ "type": "function",
9632
+ "name": "callback",
9633
+ "optional": true,
9634
+ "parameters": [
9635
+ {
9636
+ "type": "object",
9637
+ "isInstanceOf": "File",
9638
+ "additionalProperties": true
9639
+ }
9640
+ ]
9197
9641
  }
9198
9642
  ]
9199
9643
  },
@@ -9201,12 +9645,17 @@
9201
9645
  "name": "query",
9202
9646
  "type": "function",
9203
9647
  "description": "Gets all messages that have the specified properties, or all messages if no properties are specified.",
9204
- "async": true,
9648
+ "async": "callback",
9205
9649
  "parameters": [
9206
9650
  {
9207
9651
  "type": "object",
9208
9652
  "name": "queryInfo",
9209
9653
  "properties": {
9654
+ "attachment": {
9655
+ "type": "boolean",
9656
+ "optional": true,
9657
+ "description": "If specified, returns only messages with or without attachments."
9658
+ },
9210
9659
  "author": {
9211
9660
  "type": "string",
9212
9661
  "optional": true,
@@ -9283,6 +9732,16 @@
9283
9732
  "description": "Returns only unread (or read if false) messages."
9284
9733
  }
9285
9734
  }
9735
+ },
9736
+ {
9737
+ "type": "function",
9738
+ "name": "callback",
9739
+ "optional": true,
9740
+ "parameters": [
9741
+ {
9742
+ "$ref": "MessageList"
9743
+ }
9744
+ ]
9286
9745
  }
9287
9746
  ]
9288
9747
  },
@@ -9405,8 +9864,22 @@
9405
9864
  "name": "listTags",
9406
9865
  "type": "function",
9407
9866
  "description": "Returns a list of tags that can be set on messages, and their human-friendly name, colour, and sort order.",
9408
- "async": true,
9409
- "parameters": []
9867
+ "async": "callback",
9868
+ "parameters": [
9869
+ {
9870
+ "type": "function",
9871
+ "name": "callback",
9872
+ "optional": true,
9873
+ "parameters": [
9874
+ {
9875
+ "type": "array",
9876
+ "items": {
9877
+ "$ref": "MessageTag"
9878
+ }
9879
+ }
9880
+ ]
9881
+ }
9882
+ ]
9410
9883
  }
9411
9884
  ]
9412
9885
  }