Quantcast
Channel: Tweetinvi a friendly Twitter C# library
Viewing all articles
Browse latest Browse all 4126

Updated Release: Tweetinvi 0.9.2.x (Apr 11, 2014)

$
0
0

PublishTweet tweet with Media

The release 0.9.2.x allows developers to send media to the server.
This is particularly useful in order to send tweet with a media attached to it.

byte[] file = File.ReadAllBytes(filePath);
var tweet = Tweet.CreateTweetWithMedia(text, file);
var imageURL = tweet.Entities.Medias.First().MediaURL;

Please note that even if Twitter allows multiple files to be sent at once, most of the accounts are limited to post only 1 media with a tweet. If you add 2 and your account is not authorized to do so, the request will be processed but only the first media will be published.

Other updates

Filter stream by language

All the stream are now able to filter the tweets to be in a specific language.

var stream = Stream.CreateSampleStream();
stream.FilterTweetsToBeIn(Language.French);
stream.TweetReceived += (s, args) =>
{
    Console.WriteLine(args.Tweet.Text);
};
stream.StartStream();

Since parameter for search

The search did not have a since parameter before because the documentation does not mention it. Now it does. Keep in mind that the search may not go back as far as the date you specify!

var searchQuery = Search.GenerateSearchTweetParameter("tweetinvi");
searchQuery.Since = DateTime.Now;
var searchResult = Search.SearchTweets(searchQuery);

Search Json

You can now retrieve json from search results

var jsonResult = SearchJson.SearchTweets("tweetinvi");

Recursive Search

Recursive search now stops when the result set sent from Twitter is empty. This update allow to cope with the fact that twitter does not respect the Max parameter for search queries.

Tweetinvi 0.9.2.2

  • Add the FavouriteCount parameter to the Tweet interface
  • Correct a bug with Message.LastMessageSent that retrieve the message received.

Viewing all articles
Browse latest Browse all 4126

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>