Like everybody that has had the same email acount for a while, I receive a lot of emails. Most of them are automatic responses or update from sites like twitter.com, linkedin.com, facebook.com, plus.google.com, etc.. Others are mailing lists I signed up for and lost interest in, and so on.
Sometimes I get tired of the amount of emails to manage, and I just want to tell Gmail: "delete all emails coming from host.com", for any number of hosts.
My email managemenet workflow goes something like this:
I got tired of doing this by hand and I wrote a script to automate this task.
Here's how the resulting Apps Script looks like (you need to be logged into Gmail for it to work).
The script is also able to archive emails coming from a certain host, and/or mark them as important.
Apps Script uses caja under the hood, so a lot of things are not allowed (e.g.: it did not allow me to add pictures, like a loading gif, or svg, to the page).
All in all it was a fun experience and I think AppScript is definitely a very useful tool to have in your toolbox if you use Google products like Gmail or Spreadsheets.