0

We've to implement a REST API to access some features of our current server, which is written in C#. So, we'd like to expose some of its functionality (currently done through TCP) using a REST API.

Can you post some pointers to the right docs and ideas about how to get it implemented?

The server is not a "aspx" server but a service app.

0

4 Answers 4

4

Microsoft's MSDN contains information on how to create RESTful services with WCF.

Sign up to request clarification or add additional context in comments.

1 Comment

Out dated and old page. Oh, see they updated it. Couple of monthes ago, there was still a REST Starter Kit
2

For now primary REST technology in Microsoft stack is ASP.NET Web API http://www.asp.net/web-api (former WCF Web API)

Visit web site for ASP.NET Web API, there are a lot of tutorials on how to make it.

Comments

0

First I recommend to take a look at my different REST approach.

  • Don't use nested complex paths, keep it simple flat list of services and actions.
  • Don't use custom HTTP methods, use the path to specify the action.
  • Don't use custom HTTP error codes, that will mix your applicative errors with the HTTP protocol errors and will prevent complex error codes or partial success.
  • Support multi-request, which is multiple applicative requests in each HTTP request.

I also introduce simple C# simple REST server example for your convenience.

Comments

-1

I have worked with a REST API in a project:

RestSharpis a simple, open source REST client for .NET designed primarily for consuming third-party HTTP APIs.

It took a lot of work out of my hands - i don't want to miss it ;-)

The Author of the Library John Sheehan is also on StackOverflow and usually helps really fast with specific problems!

1 Comment

Ok, but AFAIK this is useful to create clients... I need a server :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.