Skip to content
This repository was archived by the owner on Apr 10, 2018. It is now read-only.
fubar-coder edited this page Nov 13, 2014 · 7 revisions

Overview

RestSharp.Portable is a portable library with classes similar to RestSharp.

License

[BSD 2-Clause License](BSD 2-Clause License)

Features

  • Portable
  • Async API
  • API very similar to RestSharp
  • Configurable content encoding support

Supported platforms

  • .NET Framework 4
  • .NET for Windows Store apps
  • .NET Native
  • Windows Phone 8
  • Silverlight 5
  • Portable Class Libraries

Dependencies

Core library

Encodings

OAuth 1.0

Small example

The following is an example to get the ticker from the bitstamp.net website.

The result class

    public class TickerResult
    {
        public decimal Last { get; set; }
        public decimal High { get; set; }
        public decimal Low { get; set; }
        public decimal Volume { get; set; }
        public decimal Bid { get; set; }
        public decimal Ask { get; set; }
    }

We use the class with:

    var client = new RestClient(new Uri("https://www.bitstamp.net/api/"));
    var request = new RestRequest("ticker", HttpMethod.Get);
    var result = await client.Execute<TickerResult>(request);
Clone this wiki locally