WICG / proposals

A home for well-formed proposed incubations for the web platform. All proposals welcome.
https://wicg.io/
Other
213 stars 9 forks source link

Email over HTTPS, with POST requests and webhooks, instead of SMTP #128

Open collimarco opened 7 months ago

collimarco commented 7 months ago

Introduction

Email is incredibly old and, despite the simple concept behind it (deliver a message), it is extremely complex to do from scratch.

Usually, when you need to send email from an application, you either need to use an extremely old and unnecessary complex MTA (like postfix or sendmail) or you need to send through proprietary and expensive third party services (Sendgrid, Mailgun, AWS SES, etc.).

I think that nowadays it would make sense to simplify email:

  1. reputation is associated to the domain and every message should be cryptographically signed with DKIM (or similar method)
  2. remove all unnecessary limitations and complexities that were accumulated over time (like SPF, IP reputation, etc.) that are a nightmare to manage in cloud native applications (e.g. in Kubernetes the IPs may vary)
  3. Sending should be a simple HTTP POST request
  4. The return path should be a simple HTTP webhook.

Use Cases

  1. Send emails from an application directly using HTTP POST (like a normal REST API)
  2. Receive emails in the web application directly through HTTP webhooks

Goals

Sending and receiving emails from an application would be much easier and you don't need to rely on MTAs or third-party services.

Proposed Solution

Email over HTTPS, with POST requests and webhooks, instead of SMTP.

Privacy & Security Considerations

This would not have any negative impact on spam, because all messages would be cryptographycally signed and associated to a domain (e.g. mandatory DKIM or similar technology).

Let’s Discuss

I am open to a discussion and feedback on this idea.

csarven commented 7 months ago

https://www.w3.org/TR/ldn/ should get you 80%+ of the way.

marcoscaceres commented 2 weeks ago

@collimarco there may be some overlap with https://github.com/WICG/proposals/issues/151 ?

It almost sounds like you want to do SMTP over HTTP? Would that be correct?