Closed Bug 544805 Opened 14 years ago Closed 26 days ago

Open message by message-id, from command line

Categories

(Thunderbird :: General, enhancement)

x86
Linux
enhancement

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: stlman, Unassigned)

Details

Attachments

(1 obsolete file)

User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.6) Gecko/20100116 Gentoo Firefox/3.5.6
Build Identifier: 

Thunderbird should enable referring to *mail* messages by their message-ids just like it does for news today. TB should also open messages specified on its command line. With such a functionality users could set up their desktop environments to support "msgid:" url scheme and. This would be handy in several scenarios:

1. Taking notes in some productivity programmes.
2. Workgroup discussions when it is certain that everyone has received the messages one would like to refer to.

  

Reproducible: Always
Not sure if it matters, but this is exactly what I was hoping for as well.
Ping?
The extension ThunderLink https://addons.mozilla.org/en-us/thunderbird/addon/thunderlink/ allows to open an email by its Message-ID. 
But it would be cool if that would become a built-in feature.

I was needing this exact feature. Unfortunately it seems that Thunderlink does no longer work (stayed at TB version 68).

My situation is this:

In an external CRM we want to create "permalinks" to "emails" we exchange with providers and clients. We are currently using this extension https://github.com/garoose/copy-message-id to get the Message-Id as a copied text. This allows at least "permanent reference" for future usage.

Now we want to be able to "open an email" given it's Message-ID by clicking a link on the CRM. We expected to be opening it on Thunderbird.

Any help?

Finding and accessing e-mails is one of the core functionalities of an e-mail client. Since message ids are intended to identify e-mails, that's really a functionality to be added to Thunderbird that would greatly improve it's potential for interaction with other tools and workflows. Since the functionality to find mails by message id exists (through the search interface), this should even be not too difficult to add.

This AddOn https://github.com/CamielBouchier/cb_thunderlink replaces Thunderlink and is working great.

Flags: needinfo?(john)

What I can say is that our WebExtension API supports to search by header message id.
https://webextension-api.thunderbird.net/en/91/messages.html#query-queryinfo

What the API currently is not able to do is to actually load the message. The linked add-on is using a legacy approach to do this. This missing API is on the list for the next few months.

Flags: needinfo?(john)

Hi, John.

I became a contributor of https://github.com/garoose/copy-message-id a while ago.

I have never done a TB extension before and even in this one I'm a contributor I am in a part "far from the TB thing", contributing more in functional testing and so.

I am more interested in this WebExtension API thing you mention. But that link you provide is overwhelming in information. I even don't know the "very basics" on how to do a TB extension.

Questions from newbie:

  • Is the "WebExtension API" thought for "doing extension for TB"? If so, why is it called "WEB" and not only "Extension API"?

  • I am a bit confused on the releases... you say "our WebExtension API supports to search by header message id" and in the next lines "This missing API is on the list for the next few months". Is this meaning that the PART that is missing is the part of loading a message? Or the whole thing is missing and the "search that is supported" is like "only for selected developers but not generally available"?

  • Can I do a simple "HelloWorld" extension using the WebApi in less than 5 minutes to get a sense of what are we talking about? (***)

  • If the search is available, would this mean that I could do an extension such taht I put [<xxx@xxx.xxx>] in the search box and it returns me the list of all messages containinng [Message-Id: <xxx@xxx.xxx>] in the headers?

  • Would this search be done locally or sent to the IMAP server?

  • If question (***) was "yes", then, May I do a simple "HelloWorld Search" in less than 1 hour?

Sorry for the low level of the questions... but I think that understanding all this can position me on only in asking for extensions but also contributing to develop them and this will potentially help the community.

thnx!

Hi Xavi,

  • Is the "WebExtension API" thought for "doing extension for TB"? If so, why is it called "WEB" and not only "Extension API"?

The concept of independent APIs for extensions was introduced by Chrome, and Firefox followed soon after. Since Browser extensions mostly are related to web things, they named them "WebExtension APIs". We depend on code coming from Firefox, so Thunderbird decided to follow the change as well to be able to use as much code from them (which saves us maintenance work). Thunderbird supports a few of the original WebExtension APIs we inherit from Firefox, but we also add our own APIs, which some of us call "MailExtension APIs". An extension which is not only using WebExtension APIs but also MailExtensionAPIs (and thus only works in Thunderbird) is often referred to as a "MailExtension". This is also described in the introduction of our add-on developer guide:

https://developer.thunderbird.net/add-ons/about-add-ons

  • I am a bit confused on the releases... you say "our WebExtension API supports to search by header message id" and in the next lines "This missing API is on the list for the next few months". Is this meaning that the PART that is missing is the part of loading a message? Or the whole thing is missing and the "search that is supported" is like "only for selected developers but not generally available"?

What is currently missing is the ability for MailExtensions to actually load (view) a message. You are able to find a specific message based on a headerMessageId, you can read it and analyze its content, you can open a "reply" or "forward" composer window for a given message, but you cannot tell Thunderbird to view a given message to the user. This is of course suboptimal and is scheduled to be added soon (Q4 2021).

  • Can I do a simple "HelloWorld" extension using the WebApi in less than 5 minutes to get a sense of what are we talking about? (***)

We have a couple of example add-ons here:
https://github.com/thundernest/sample-extensions

Those two a very basic:

  • If the search is available, would this mean that I could do an extension such taht I put [<xxx@xxx.xxx>] in the search box and it returns me the list of all messages containinng [Message-Id: <xxx@xxx.xxx>] in the headers?

We currently do not support altering the search box (but I guess we will add APIs for that as well). What you can do is to use a so called browser_action popup, which opens a small html popup where you can place your own search input field and then search the users messages. There is currently also no API to manually populate the search results, but this will be done together with the possibility to intercept the search input field.

So what you are trying to do is currently not supported, but there are similar requests. APIs for that area will be added.

  • Would this search be done locally or sent to the IMAP server?

Currently only local. IMAP search has been requested and is being looked into already.

Sorry for the low level of the questions... but I think that understanding all this can position me on only in asking for extensions but also contributing to develop them and this will potentially help the community.

That is totally fine. We tried to put everything needed in our add-on developer guide:
https://developer.thunderbird.net/add-ons/mailextensions

Feedback on what is missing to get developers started is appreciated.

The detailed documentation for the supported WebExtension APIs and our own MailExtension APIs is here:
https://webextension-api.thunderbird.net/en/91/

For further question, you can also reach me on matrix for quick questions, or can join our add-on developer mailing list:
https://developer.thunderbird.net/add-ons/community

I'm not familiar with the "msgid:" URL scheme, but the RFC 2392 "mid:" URL scheme does the same thing and works right now with Thunderbird 87.0 and later:

thunderbird should support the mid: URL scheme defined in RFC 2392

https://bugzilla.mozilla.org/show_bug.cgi?id=264270

For example, running this command:

thunderbird mid:YWGMjtin0IvbrVEq@pryan.ekaia.org

will open the release email for Debian 10.11.

Note that this functionality is implemented in core Thunderbird, no addons required.

Severity: normal → S3
Attachment #9386616 - Attachment is obsolete: true

I think this can be closed, see comment 10.

Status: UNCONFIRMED → RESOLVED
Closed: 26 days ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: