/// <summary> /// Updates the authenticating user's profile background image. T /// </summary> /// <param name="oAuth"></param> /// <param name="image">The background image for the profile, base64-encoded. Must be a valid GIF, JPG, or PNG image of less than 800 kilobytes in size.</param> /// <param name="tile">Whether or not to tile the background image. </param> /// <param name="include_entities">The entities node will not be included when set to false.</param> /// <param name="skip_status">When set to either true, t or 1 statuses will not be included in the returned user objects.</param> /// <param name="use">Determines whether to display the profile background image or not</param> /// <returns></returns> public JArray Post_Account_Update_Profile_Background_Image(oAuthTwitter oAuth, string image, string tile, bool include_entities, bool skip_status, bool use) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostAccountUpdateProfileBackgroungImageUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("include_entities", include_entities.ToString()); strdic.Add("skip_status", skip_status.ToString()); strdic.Add("use", use.ToString()); if (image != null) { strdic.Add("image", image); } if (tile != null) { strdic.Add("tile", tile); } string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
//#region OAuth ///// <summary> ///// This Method Will Check That User is Authenticated Or Not Using OAUTH ///// </summary> ///// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> ///// <returns>Return Xml Text With User Details</returns> //public XmlDocument Verify_Credentials(oAuthTwitter OAuth) //{ // string response = OAuth.oAuthWebRequest(oAuthTwitter.Method.GET, Globals.VerifyCredentialsUrl, String.Empty); // xmlResult.Load(new StringReader(response)); // return xmlResult; //} /// <summary> /// This method Will Check Rate Limit Of Account Using OAUTH /// </summary> /// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <returns>Return Xml Text With User Details</returns> public XmlDocument Rate_Limit_Status(oAuthTwitter OAuth, SortedDictionary <string, string> strdic) { string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.GET, Globals.RateLimitStatusUrl, strdic); xmlResult.Load(new StringReader(response)); return(xmlResult); }
/// <summary> /// Sets one or more hex values that control the color scheme of the authenticating user's profile page on twitter.com. /// </summary> /// <param name="oAuth"></param> /// <param name="profile_background_color">Profile background color.</param> /// <param name="profile_link_color">Profile link color.</param> /// <param name="profile_sidebar_border_color">Profile sidebar's border color.</param> /// <param name="profile_sidebar_fill_color">Profile sidebar's background color.</param> /// <param name="profile_text_color">Profile text color.</param> /// <param name="include_entities">The entities node will not be included when set to false.</param> /// <param name="skip_status">When set to either true, t or 1 statuses will not be included in the returned user objects.</param> /// <returns></returns> public JArray Post_Account_Update_Profile_Colors(oAuthTwitter oAuth, string profile_background_color, string profile_link_color, string profile_sidebar_border_color, string profile_sidebar_fill_color, string profile_text_color, bool include_entities, bool skip_status, bool use) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostAccountUpdateProfileColorUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("include_entities", include_entities.ToString()); strdic.Add("skip_status", skip_status.ToString()); strdic.Add("&use", use.ToString()); if (profile_background_color != null) { strdic.Add("profile_background_color", profile_background_color); } if (profile_link_color != null) { strdic.Add("profile_link_color", profile_link_color); } if (profile_sidebar_border_color != null) { strdic.Add("profile_sidebar_border_color", profile_sidebar_border_color); } if (profile_sidebar_fill_color != null) { strdic.Add("profile_sidebar_fill_color", profile_sidebar_fill_color); } if (profile_text_color != null) { strdic.Add("profile_text_color", profile_text_color); } string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Sets values that users are able to set under the "Account" tab of their settings page. /// </summary> /// <param name="oAuth"></param> /// <param name="name">Full name associated with the profile. Maximum of 20 characters.</param> /// <param name="url">URL associated with the profile. Will be prepended with "http://" if not present. </param> /// <param name="location">The city or country describing where the user of the account is located.</param> /// <param name="description">A description of the user owning the account. Maximum of 160 characters.</param> /// <param name="include_entities">The entities node will not be included when set to false.</param> /// <param name="skip_status">When set to either true, t or 1 statuses will not be included in the returned user objects.</param> /// <returns></returns> public JArray Post_Account_Update_Profile(oAuthTwitter oAuth, string name, string url, string location, string description, bool include_entities, bool skip_status) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostAccountUpdateProfileUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("include_entities", include_entities.ToString()); strdic.Add("skip_status", skip_status.ToString()); if (name != null) { strdic.Add("name", name); } if (url != null) { strdic.Add("url", url); } if (location != null) { strdic.Add("location", location); } if (description != null) { strdic.Add("description", description); } string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Follow Twitter User Using OAUTH /// </summary> /// <param name="twitterUser">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <param name="UserToFollow">ScreenName Of Whom You Want To Follow</param> /// <returns>Returm Xml</returns> public XmlDocument Friendships_Create(oAuthTwitter oAuth, string ScreenName, SortedDictionary <string, string> strdic) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.FollowerUrl + ScreenName; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); xmlResult.Load(new StringReader(response)); return(xmlResult); }
/// <summary> /// Get All Mentions Of User Using OAUTH,Twitter Api Version 1.0, Socioboard.Twitter Version 1.0.0.0, /// This method is depricated now. /// </summary> /// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <param name="Count">Number Of Tweets</param> /// <returns>Return XmlText Of Mentionc Of User</returns> /// public XmlDocument Status_Mention(oAuthTwitter OAuth, string Count, SortedDictionary <string, string> strdic) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.MentionUrl + Count; string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); xmlResult.Load(new StringReader(response)); return(xmlResult); }
/// <summary> /// Returns the most recent tweets authored by the authenticating user that have been retweeted by others. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Statuses_Retweet_Of_Me(oAuthTwitter oAuth) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.statusesRetweetsOfMeUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); return(JArray.Parse(response)); }
public string RelatnFriendshipByUserId(oAuthTwitter OAuth, string userId) { SortedDictionary <string, string> stringDictionary = new SortedDictionary <string, string>(); stringDictionary.Add("target_id", userId); string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetFriendshipsShowUrl; string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, stringDictionary); return(response); }
//////////////////////////////////////////////////////////////////////////////////////////////////////////// /// <summary> /// Returns most recent direct messages sent to the authenticating user. Includes detailed information about the sender and recipient user. /// </summary> /// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <param name="Count">Number Of DirectMessage</param> /// <returns></returns> public JArray Get_Direct_Messages(oAuthTwitter oAuth, int count) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("count", count.ToString()); string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetDirectMesagesUrl; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); return(JArray.Parse(response)); }
public string BlocksUserByScreenName(oAuthTwitter OAuth, string screenName) { SortedDictionary <string, string> stringDictionary = new SortedDictionary <string, string>(); stringDictionary.Add("screen_name", screenName); string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostBlockCreateUrl; string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, stringDictionary); return(response); }
/// <summary> /// Returns a collection of the most recent Tweets and retweets posted by the authenticating user and the users they follow. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Statuses_Home_Timeline(oAuthTwitter oAuth) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.statusesHomeTimelineUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("count", "100"); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); return(JArray.Parse(response)); }
public string UnBlocksUserByUserId(oAuthTwitter OAuth, string userId) { SortedDictionary <string, string> stringDictionary = new SortedDictionary <string, string>(); stringDictionary.Add("user_id", userId); string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostBlocksDestroyUrl; string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, stringDictionary); return(response); }
/// <summary> /// Removes the uploaded profile banner for the authenticating user. Returns HTTP 200 upon success /// </summary> /// <param name="oAuth"></param> /// <param name="image"></param> /// <param name="include_entities"></param> /// <param name="skip_status"></param> /// <returns></returns> public string Post_Account_Remove_Profile_Banner(oAuthTwitter oAuth) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostAccountRemoveProfileBannerUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); return(response); }
/// <summary> /// This Method Will Check That User is Authenticated Or Not Using OAUTH /// </summary> /// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <returns>Return Xml Text With User Details</returns> public JArray Verify_Credentials(oAuthTwitter OAuth) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string response = OAuth.OAuthWebRequest(oAuthTwitter.Method.GET, Globals.VerifyCredentialsUrl, strdic); //xmlResult.Load(new StringReader(response)); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Destroys the status specified by the required ID parameter. The authenticating user must be the author of the specified status. Returns the destroyed status if successful. /// </summary> /// <param name="oAuth"></param> /// <param name="UserId"></param> /// <returns></returns> public JArray Post_Statuses_DestroyById(oAuthTwitter oAuth, string UserId) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string RequestUrl = Socioboard.Twitter.App.Core.Globals.StatusDestroyByIdUrl + UserId + ".json"; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Get_User_Followers(oAuthTwitter oAuth) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetFollowersListUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Returns a collection of numeric IDs for every protected user for whom the authenticating user has a pending follow request. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Friendships_Outgoing(oAuthTwitter oAuth) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetFrienshipsOutgoingUrl; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// This Method Will Update Tweets On Twitter Using OAUTH /// </summary> /// <param name="oAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <param name="StatusText">Status Messages</param> /// <returns>Return Xml Text Of Details</returns> public XmlDocument UpdateStatus(oAuthTwitter oAuth, string StatusText, SortedDictionary <string, string> strdic) { try { string RequestUrl = Socioboard.Twitter.App.Core.Globals.UpdateStatusUrl + "?status="; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); xmlResult.Load(new StringReader(response)); } catch { } return(xmlResult); }
/// <summary> /// Returns an HTTP 200 OK response code and a representation of the requesting user if authentication was successful; /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Account_Verify_Credentials(oAuthTwitter oAuth) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetAccountVerifyCredentialsUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Get_Statuses_User_Timeline(oAuthTwitter oAuth, string ProfileId) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.statusesUserTimelineUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("user_id", ProfileId); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); return(JArray.Parse(response)); }
/// <summary> /// Returns the most recent direct messages sent by the authenticating user. Includes detailed information about the sender and recipient user. /// </summary> /// <param name="OAuth">OAuth Keys Token, TokenSecret, ConsumerKey, ConsumerSecret</param> /// <param name="Count">Number Of DirectMessage</param> /// <returns></returns> public JArray Get_Direct_Messages_Sent(oAuthTwitter oAuth, int count) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetDirectMessagesSentUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("count", count.ToString()); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Get_Friends_ById(oAuthTwitter oauth, string Userid) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetFriendsIdUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("user_id", Userid); string response = oauth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Post_report_as_spammer(oAuthTwitter oAuth, string userScreaanNameorId) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostUserReportAsSpammerById; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("screen_name", userScreaanNameorId); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Allows the authenticating user to unfollow the user specified in the ID parameter. /// </summary> /// <param name="oAuth"></param> /// <param name="UserId"></param> /// <returns></returns> /// public JArray Post_Friendship_Destroy(oAuthTwitter oAuth, string UserId) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostFriendshipsDestroyUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("user_id", UserId); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> ///Returns fully-hydrated user objects for up to 100 users per request, as specified by comma-separated values passed to the screen_name /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Users_LookUp_ByScreenName(oAuthTwitter oAuth, string screen_name) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("screen_name", screen_name); string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetUsersLookUpUrl; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Post_favorites(oAuthTwitter oAuth, string desirestatusId) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.PostStatusFavoritesById; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("id", desirestatusId); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
public JArray Post_StatusesUpdate(oAuthTwitter oAuth, string statuses) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.StatusUpdateUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("status", statuses); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.POST, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> ///Provides a simple, relevance-based search interface to public user accounts on Twitter. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Users_Search(oAuthTwitter oAuth, string keyword, string count) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetUsersSearchUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("q", keyword); strdic.Add("count", count); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> ///Returns a map of the available size variations of the specified user's profile banner. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Users_Profile_Banner(oAuthTwitter oAuth, string user_id) { string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetUsersProfileBannerUrl; SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("user_id", user_id); string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }
/// <summary> /// Returns detailed information about the relationship between two arbitrary users. /// </summary> /// <param name="oAuth"></param> /// <returns></returns> public JArray Get_Friendships_Show(oAuthTwitter oAuth, string source_screenname, string getScreenname) { SortedDictionary <string, string> strdic = new SortedDictionary <string, string>(); strdic.Add("source_screen_name", source_screenname); strdic.Add("target_screen_name", getScreenname); string RequestUrl = Socioboard.Twitter.App.Core.Globals.GetFriendshipsShowUrl; string response = oAuth.OAuthWebRequest(oAuthTwitter.Method.GET, RequestUrl, strdic); if (!response.StartsWith("[")) { response = "[" + response + "]"; } return(JArray.Parse(response)); }