Nilhcem / FakeSMTP

Dummy SMTP server with GUI for testing emails in applications easily.
http://nilhcem.github.com/FakeSMTP/
Other
991 stars 318 forks source link

Ability to read emails via API #84

Open yasin3061 opened 5 years ago

yasin3061 commented 5 years ago

It would be nice to have a feature that allows the user to read the emails via some API.

This feature can be used in UI automation or end-to-end tests where the email's content can be verified.

SpyroTEQ commented 5 years ago

I used to think the same, but since this project does not evolve a lot (and I don't want to make a PR to add this feature, further more seeing 17 opened PR already!), I've actually fallen back to simply read the EML file that FakeSMTP saves. In other words, you can simply browser files in the email-saved (or so) folder where FakeSMTP stores the EML. EML parsing is pretty standard (and even pretty straightforward actually). You can also delete files from there if needed, or get the email saving date from the file name.