MailExtensions Calendar: calendars/items API
Categories
(Thunderbird :: Add-Ons: Extensions API, enhancement)
Tracking
(Not tracked)
People
(Reporter: Fallen, Assigned: Fallen)
References
(Blocks 2 open bugs)
Details
Attachments
(1 external file)
This issue is to implement the messenger.calendar.calendars and messenger.calendar.items APIs, to make a start into getting calendar APIs into Thunderbird.
| Assignee | ||
Comment 1•7 months ago
|
||
Updated•5 months ago
|
| Assignee | ||
Updated•5 months ago
|
Updated•1 month ago
|
Updated•1 month ago
|
Comment 2•1 month ago
|
||
Feedback from an add-on that would use this API, following up on comment 2 of bug 2042677.
Commonpost (https://github.com/commonpost/thunderbird-mcp) lets AI assistants list, create
and update calendar events through an Experiment today. I could not open D296842, so this is
based on the calendar Experiment schema in thunderbird/webext-experiments (April 2026); please
correct me where the patch differs.
What the schema already covers for us: calendars.query/get, items.query with
rangeStart/rangeEnd and expand, items.create/update/remove/move, events and tasks. Passing
items as iCal or jCal is a good fit: STATUS and TRANSP travel as they are, which matters to
us (an assistant's "free" event must not become "tentative").
What we would still need:
- A way to open Thunderbird's own event or task editor pre-filled with an item, so the user
reviews it before it is saved, like compose.beginNew for mail. Every event an assistant
creates goes through that review in Commonpost; items.create alone would make direct
creation the only option. - A result limit on items.query (we cap results for assistants).
- If possible, separate permissions for reading and for writing calendar items, so an add-on
can be given read-only access to the calendar.
We have a lab that drives a real headless Thunderbird
(https://github.com/commonpost/thunderbird-mcp-lab) and can test the API on Beta or Daily
once it lands.
Feedback from NC Connector for Thunderbird (https://github.com/nc-connector/NC_Connector_for_Thunderbird), following up on a conversation between its maintainer (DeBaschdi on GitHub) and Philipp in the Add-on Developers channel.
Use case: after the user signs in to Nextcloud, the add-on registers their Nextcloud calendars as regular CalDAV calendars, the same way the "New Calendar" dialog does. Thunderbird's own provider then handles synchronization. Work in progress: https://github.com/nc-connector/NC_Connector_for_Thunderbird/pull/54
calendars.create() in D296842 already supports this for type: "caldav". To create a calendar that behaves like one from the dialog, we would also need:
username: proposed in https://github.com/thunderbird/webext-experiments/pull/68refreshInterval: proposed in https://github.com/thunderbird/webext-experiments/pull/75- A way to enable the offline cache (
cache.enabled) at creation time. Setting it afterwards makes CalCalendarManager re-create the calendar under a new id (changeCalendarCache), so an add-on that tracks its calendars by id cannot do it as a follow-upupdate(). Neither the experiment nor D296842 covers this yet.
Would you take 1 and 2 into D296842 or a follow-up, and where should the cache option go? We are happy to write the patch for whichever part helps.
Credentials (making the server login available without a prompt) are a separate question; we will raise that, and CardDAV creation in addressBooks, in their own bugs.
Description
•