April 15th, 2010

An idea for a better webmail

Written by Dave BarkerTopics: Thoughts, Idea

Currently webmail is broken, Squirrelmail looks old and dated, Roundcube got me hacked and Gmail isn't opensource and on my server.

So here's how to fix it, write a restful JSON API to perform all the functions like connecting, listing messages, sending emails etc. that works in the same way as CouchDB.

Next make a PHP theme to use this new API to create a Squirrelmail clone, another one for use from mobile devices and a third snazzy theme using just HTML and Javascript for desktop use.

The API could be written in anything but I suggest PHP just for practical deployment everywhere that Squirrelmail worked.

I would call it Davemail and lay it out something like this:

davemail/api/* - for all the actual requests to access imap

davemail/themes/* - for the different themes, one per directory that can be easily indexed dynamically so people can just chuck new themes inside and use them without any configuration

davemail/config/ - Everything inside the config directory would get read by davemail for all the configuration details. That way it could just be a symlink to /etc/davemail/ or wherever. The files would set which imap server to use, login details, email domains accepted etc

Once Davemail takes off the API can be re-written in whatever language or with whatever optimization tricks that we might want in the future and all the themes will still work.

The first step is writing the API, I think we should start with the Squirrelmail IMAP includes and modify them to return the JSON expected.