Turn Twitter into Gmail Notifier

You can get Gmail notifications (via tweets) as soon as soon a new e-mail messages lands in your mail box on your twitter timeline. You don’t have to learn programming to do this; setting it up is easy and you can be up and running in 5 minutes.



get Gmail notifications (via tweets)

Step #1 Create new twitter app with gmail
Create new twitter app with gmail

1.1 To get started go to twitter.com/signup and create a new Twitter account for your Gmail Inbox.
Create new twitter app with gmail

1.2 Confirm your email address, and then open the Twitter settings page. Check the option “Protect My Tweets” and uncheck the option “Let others find me by my email address.” This is essential in order to stop search engines, or any other Twitter user, to see your Gmail tweets.
open the Twitter settings page

open the Twitter settings page

1.3 Go to dev.twitter.com, sign-in using your new Twitter account and use the following values to create a New Twitter App.
Add Name and Description.
Visit this page.
On Callback URL Enter https://spreadsheets.google.com/macros
Go to dev.twitter.com

Go to dev.twitter.com

1.4 Ensure no empty spaces are left in the URL fields or else Twitter may present an “Invalid URL format” warning. Agree to twitters terms and conditions, fill in the CAPTCHA and submit the form to create your first Twitter application.
fill in the CAPTCHA and submit the form

1.5 Next, go to the Settings navigation Tab of your Twitter Application and change the “Access” mode from “Read only” to “Read and Write” to enable you publish tweets on Google Docs.
go to the Settings navigation Tab

go to the Settings navigation Tab

1.6 Save the Settings, then switch to the tab that says ‘OAuth Tool’ and copy the Consumer Key and the Consumer Secret Key.
Save the Settings

Step #2: Link Google Docs and Twitter
2.0 Go to the link on your screen and make a copy of this spreadsheet in your own Docs account.
2.1 From Tools – > Script Editor, replace the values of TWITTER_CONSUMER_KEY and TWITTER_CONSUMER_SECRET with their actual values.
replace the values

replace the values

2.2 Go to Resources – > Current Script’s triggers and create a new Time-driven event for “sendTweet” that triggers every minute.
a new Time-driven event

2.3 Save the trigger. Click Authorize (Grant Access) so that this script can automatically read your Gmail inbox at set period to check for new mails.
Save the trigger

2.4 Go to Run – > SendTweet and it should show another “Authorization required” message from Twitter. Click Authorize – > when you authorize the app, it allows Google app script to publish tweets to your twitter Gmail account.
Authorization required

Step #3: Follow Gmail on Twitter
3.1 Log in to your old Twitter account. Search for your new twitter account and send a follow request.
Follow Gmail on Twitter

3.2 Log in to your new twitter Gmail account and approve the “follow request.
Log in to your new twitter Gmail account

And we are done. You should now see tweets for Gmail as they arrive to your twitter timeline.