CoreTweet travis-ci

Yet Another .NET Twitter Library

CoreTweet

Build Status on Travis CI Build Status on AppVeyor

Yet Another .NET Twitter Library…

Simplest authorizing:

var session = OAuth.Authorize("consumer_key", "consumer_secret");
var tokens = OAuth.GetTokens(session, "PINCODE");

Tweeting is very easy:

tokens.Statuses.Update(status => "hello");

We provide the most modern way to use Twitter’s API asynchronously:

var tokenSource = new CancellationTokenSource();
var task = tokens.Statuses.UpdateWithMediaAsync(
    new { status = "Yummy!", media = new FileInfo(@"C:\test.jpg") },
    tokenSource.Token
);
// oh! that was a photo of my dog!!
tokenSource.Cancel();

Go with the Streaming API and LINQ:

var sampleStream = tokens.Streaming.Sample()
    .OfType<StatusMessage>()
    .Select(x => x.Status);
foreach(var status in sampleStream)
    Console.WriteLine("{0}: {1}", status.User.ScreenName, status.Text);

Get fantastic experiences with Rx:

var disposable = tokens.Streaming.FilterAsObservable(track => "tea")
    .OfType<StatusMessage>()
    .Subscribe(x => Console.WriteLine("{0} says about tea: {1}", x.Status.User.ScreenName, x.Status.Text));

await Task.Delay(30 * 1000);
disposable.Dispose();

Various types of method overloads:

tokens.Statuses.Update(status => "hello");

tokens.Statuses.Update(new { status = "hello" });

tokens.Statuses.Update(new YourClass("hello"));

tokens.Statuses.Update(status: "hello");

tokens.Statuses.Update(new Dictionary<string, object>()
{
    {"status", "hello"}
});

Oh yes why don’t you throw away any StatusUpdateOptions and it kinds???

Latest Build Results

Platforms

We support both of Windows .NET and Mono, and CoreTweet works on following platforms:

  • .NET Framework 3.5 (without Rx support)
  • .NET Framework 4.0
  • .NET Framework 4.5
  • .NET Core App
  • Windows 8.1
  • Windows Phone 8.1
  • Xamarin Android / iOS

Documentation

Documents of API is here.

Visit Wiki to get more information such as examples.

Install

Now available on NuGet!

PM> Install-Package CoreTweet

Or please download a binary from Releases.

Build

You can’t build PCL/WindowsRT binaries on Mono (on Linux) because they require non-free libraries.

On Windows

Requires

  • .NET Framework 4.6
  • Windows PowerShell
  • Visual Studio 2015
  • .NET Core 1.0 SDK
  • Doxygen (optional: used to generate documentation)

Step

  • Run PowerShell as an admin and execute
Set-ExecutionPolicy AllSigned
  • Run build.ps1

On Linux and other Unix-like

Requires

  • Mono 4.x or above
  • make
  • XBuild
  • Doxygen (optional: used to generate documentation)

Step

  • Run make

Contributing

Please report to Issues if you find any problems.

We seriously need your help for writing documents.

Please go to Wiki and write API documents, articles or/and some tips!

Pull requests are welcome.

License

This software is licensed under the MIT License.

Related Repositories

CoreTweet

CoreTweet

Yet Another .NET Twitter Library ...

CoreTweetSupplement

CoreTweetSupplement

An utility for client developers with CoreTweet ...

Kbtter4

Kbtter4

Twitter Client with WPF,Livet,CoreTweet,JSON.NET... ...

Kbtter3

Kbtter3

Kbtter3 Polystyrene - Twitter Client with CoreTweet,Livet, and more... ...


Top Contributors

azyobuzin cannorin chitoku-k a4lg laco0416 kb10uy Terminus-IMRC cucmberium MihaMarkic rhenium

Releases

-   0.7_2 zip tar
-   0.7_1 zip tar
-   0.7_0 zip tar
-   0.6_4 zip tar
-   0.6_3 zip tar
-   0.6_2 zip tar
-   0.6_1 zip tar
-   0.6_0 zip tar
-   0.5_4-beta2 zip tar
-   0.5_4-beta zip tar
-   0.5_3 zip tar
-   0.5_2 zip tar
-   0.5_1 zip tar
-   0.5_0 zip tar
-   0.4_3 zip tar
-   0.4_2 zip tar
-   0.4_1 zip tar
-   0.4_0 zip tar
-   0.3_4 zip tar
-   0.3_3 zip tar
-   0.3_2 zip tar
-   0.3_1 zip tar
-   0.3_0 zip tar
-   0.2_4 zip tar
-   0.2_3 zip tar
-   0.2_2 zip tar
-   0.2_1 zip tar
-   0.2_0 zip tar
-   0.1_8 zip tar
-   0.1_7 zip tar