C# Plurk API 2.0 Library
C#
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
Entities Initial commit of rsPlurkLib. Jan 25, 2013
Examples
Properties
.gitignore Initial commit Dec 29, 2012
HttpUtil.cs Initial commit of rsPlurkLib. Jan 25, 2013
IOAuthClient.cs Fix #3: Reworked UrlEncode, also found a bug in interface declaration. Apr 6, 2013
LEGAL.md Initial commit of rsPlurkLib. Jan 25, 2013
LICENSE.md Initial commit of rsPlurkLib. Jan 25, 2013
OAuthException.cs
OAuthInstance.cs Fixed #3 finally. Problem caused by minimum digits enforcement. Apr 7, 2013
PlurkEnums.cs Initial commit of rsPlurkLib. Jan 25, 2013
PlurkException.cs Initial commit of rsPlurkLib. Jan 25, 2013
PlurkHelper.cs Fix #1: Rework the libraries to expose functions through interfaces. Apr 2, 2013
README.md Minor revision of README format. Apr 8, 2013
rsPlurkLib.csproj Renamed project file. Apr 6, 2013

README.md

rsPlurkLib

Introduction

rsPlurkLib is a Plurk API 2.0 library bulit on top of .NET Framework. Written in C#, rsPlurkLib is clean, elegant, and minimally assembly-dependent.

Prerequisites

  • .NET Framework 3.0 is the current project target. Might work under a .NET 2.0 build, but still not tested.
  • JSON.NET is the current JSON parser. Neither its binary nor source is included in project, so you'll need to correct the project assembly dependency on your machine.

To build

  1. Clone the repository to your project folder.
  2. Reconfigure the project reference to use a proper version of JSON.NET, source or binary.
  3. Fill in your application key and secret under OAuthInstance.cs
  4. Save, build & run.

Structure

  • OAuthInstance.cs provides methods to acquire and exchange OAuth token, sending raw requests.
  • PlurkHelper.cs wraps Plurk API as a single callable static class.
  • Entities folder holds the JSON entity type Plurk will return.

Usage

  • Create a new instance of PlurkHelper.
  • Acquire a token using methods under PlurkHelper.Client.
  • Make use of methods under PlurkHelper class for matching API calls.

If you aren't building an interactive client, you may directly assign a token, which significantly reduces the amount of code like this:

PlurkHelper helper = new PlurkHelper();
helper.Client.Token = new OAuthToken("AsDfGhIlB5Zd", "GUjneXpk91a7G32c8X6q9527", OAuthTokenType.Permanent);
helper.AddPlurk("says", "Hello Plurk!");

More examples can be found under Examples folder, with a typical OAuth authentication walkthrough available as a console implementation.

Contribute

You can provide recommendations or report bugs at our issue tracker.

To-dos

  • Expand API coverage. Currently only basic /APP/Timeline/ and /APP/Responses/ features implemented.
  • Document the entity classes under Entities.

The offical Plurk API documentation can be found here.

Author

You can follow @RSChiang on Plurk.

License

rsPlurkLib is released under MIT License.