I am planning on a simple standalone, non-webapp Twitter demo for the purpose of getting my hands wet with spring-social; there is no frontend. For simplicity, everything will be run off method main
for the demo and the consumerKey
, consumerSecret
, accessToken
, and accessTokenSecret
are all visible.
Twitter twitter = new TwitterTemplate(consumerKey, consumerSecret,
accessToken, accessTokenSecret);
Does interacting with twitter.xxOperations()
protect the underlying keys and secrets?
I am not sure what you mean by this, but still try to give you an explanation of what I have learned so far.
When you use
TwitterTemplate()
you are allowing everyone (every User who have access to your service) to accessxxxOperations()
, this is Anonymous Twitter Connection.Whereas if you use
Twitter()
constructor as demonstrated in this tutorial you restrict Users and force them to login to Twitter.com to accessxxxOperations()
provided by your service.I just pushed my experiments with Spring-Social-Twitter in my Github repo, you might wanna checkout. Hope this helps.