Created
June 4, 2012 13:11
-
-
Save Dynyx/2868278 to your computer and use it in GitHub Desktop.
Tweet using Twitter API
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Requires the use of the Twitterer Nuget package | |
public static RequestResult Tweet(string message) | |
{ | |
var authTokens = new OAuthTokens | |
{ | |
AccessToken = ConfigurationManager.AppSettings["AccessToken"], | |
AccessTokenSecret = ConfigurationManager.AppSettings["AccessTokenSecret"], | |
ConsumerKey = ConfigurationManager.AppSettings["ConsumerKey"], | |
ConsumerSecret = ConfigurationManager.AppSettings["ConsumerSecret"] | |
}; | |
return TwitterStatus.Update(authTokens, message).Result; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment