Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add interface for third-party apps to provide images for email addresses #6218

Open
cketti opened this issue Aug 5, 2022 · 5 comments
Open
Labels
type: enhancement New features or improvements to existing features.

Comments

@cketti
Copy link
Member

cketti commented Aug 5, 2022

Right now we only display images in the message list when the sender's email address belongs to a system contact. Sometimes it would be nice to see pictures for the sender without having to add them to you contacts.

Examples:

  • GitHub's notification emails contain enough information to be able to fetch the avatar of the person who triggered the notification
  • Gravatar (allows finding an avatar using an email address)
  • Favicon (see Contact images like favicons #6128)

There's a lot of sources one could use. I don't want to include support for any specific provider in the app directly. Instead we should add an interface that allows third-party apps to provide an image given an email address and/or a specific email header field.

@cketti cketti added the type: enhancement New features or improvements to existing features. label Aug 5, 2022
@ByteHamster
Copy link
Collaborator

Are you thinking about an add-on manager within K-9 here? Simply sending a broadcast for all apps to hear could be a privacy problem. So it would need a screen where you can enable/disable allowed apps.

@cketti
Copy link
Member Author

cketti commented Aug 5, 2022

It would be similar to the crypto provider mechanism. I was hoping we could make the interface generic enough so the "image provider" apps could be used by other apps as well. At the very least this could also be useful to other email apps.

Stuff we need to specify for this:

  • discovery: A way to find the apps that implemented this interface and could be used by K-9 Mail to ask for images. It'll be up to the user to select one or more of these apps to be used.
  • provider requirements/permissions: Some image provider apps might require more information than just the email address. Example: The GitHub notification emails use notifications@github.com as From address. The GitHub user name is in the header X-GitHub-Sender. So we need a way for the provider to specify which headers it needs access to. The provider can also specify that it only supports a limited set of email addresses. In the GitHub example, we don't need to ask the provider to supply an image if the email address is something other than notifications@github.com.
  • image API: a way to provide the necessary data to the image provider so we get back an image (or a negative result if no image can be found)

@PanderMusubi
Copy link

This was a nice add-on for Thunderbird https://addons.thunderbird.net/en-us/thunderbird/addon/contact-photos/

Hope to see this supported in Thunderbird Android and normal Thunderbird.

@EnigmaSolved
Copy link

This was a nice add-on for Thunderbird https://addons.thunderbird.net/en-us/thunderbird/addon/contact-photos/

Hope to see this supported in Thunderbird Android and normal Thunderbird.

I used https://addons.thunderbird.net/en-US/thunderbird/addon/display-contact-photo/ for a long time, which was similar, but also long out of date. :)

@PanderMusubi
Copy link

I also used that as long as it lasted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New features or improvements to existing features.
Projects
None yet
Development

No branches or pull requests

4 participants