Pages

Tweeting without using OAuth

Since twitter.com removed the basic authentication it has been more difficult for small embedded devices such as Arduino to post tweets. However there is a solution in the form of http://www.supertweet.net/.

To use this you’ll have to register with the site then allow it to access your twitter account. Once you have your supertweet setup, you’ll need to modify the code. This is based on the twitter client example in the current library:


static uint8_t websrvip[4] = { 72,2,118,214 };


#define WEBSERVER_VHOST "api.supertweet.net"


// The BLOGGACCOUNT Authorization code can be generated from
// username and password of your supertweet account
// by using this encoder: http://tuxgraphics.org/~guido/javascript/base64-javascript.html

// The password is NOT your twitter.com password, but the one setup in
// supertweet.net for your username.
// It is up to you if you wish to keep them the same, but for security reasons
// this is not recommended.
#define BLOGGACCOUNT "Authorization: Basic xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"


es.ES_client_http_post(PSTR("/1/statuses/update.xml"), PSTR(WEBSERVER_VHOST), PSTR(BLOGGACCOUNT), PSTR("POST "), statusstr, &browserresult_callback);

Thats all, with the above lines updated then you should then see your tweets coming through.

Bookmark this post: bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark bookmark

1 comment to Tweeting without using OAuth