Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

REST service access using C# 4.0 dynamic programming

branch: master

This branch is 0 commits ahead and 0 commits behind master

Fetching latest commit…


Cannot retrieve the latest commit at this time

Octocat-spinner-32 DynamicRest.Testing
Octocat-spinner-32 DynamicRest.UnitTests
Octocat-spinner-32 DynamicRest
Octocat-spinner-32 Samples
Octocat-spinner-32 lib
Octocat-spinner-32 .gitattributes
Octocat-spinner-32 .gitignore
Octocat-spinner-32 DynamicRest.ncrunchsolution
Octocat-spinner-32 DynamicRest.sln
Octocat-spinner-32 License.txt

Dynamic REST

This is a small project demonstrating REST service access, working against JSON data and XML data using late-bound dynamic code using the new dynamic programming features being added to c# 4.0.

JSON data

REST client

Basic usage

  • To get an instance of RestClient use the RestClientBuilder fluent interface:

    var client = new RestClientBuilder()


  • Issue a GET

    var response = client.Get();
  • Navigate the response

    Given this response:

            { src:'http://some.uri/image1.png' },
            { src:'http://some.uri/image2.png' }

    You can navigate using the following dynamic syntax:

      var image2src = response.Result.article.images[1].src;
Something went wrong with that request. Please try again.