Question

I am quite new to Windows Store Apps developement and I need to consume a REST based web service.

My issue is that there has been so much movement in development technologies made for consuming modern web services during the last years, that in the end it is hard and confusing to find out what is easiest and, especially, what are the most up to date solutions to achieve that.

I want to use the Discogs API in a Windows Store Apps using C#. I only need to use GET.

Thanks.


Edit: The main reason why I ask what is the best way to consume REST services in Windows Store Apps, is because I need a solution compliant with asynchrony.

Was it helpful?

Solution

Well of course there's HttpWebRequest in .NET which is adequate. If you want some abstraction there are options like RestSharp ( http://restsharp.org/ ).

OTHER TIPS

Here is a post that contains several library recommendations when consuming REST from .NET

EDIT:

However, unless you are needing something that THIS framework provides...I'd just use the API interface that is already built for you!

I may as well jump on board with another option: the HttpClient class would be the "out-of-the-box" recommendation in .NET 4.5 (including Windows Store Apps) for your scenario. By default, it leverages HttpWebRequest.

There's a QuickStart: Connecting using HttpClient on the Dev Center that addresses the GET scenario that should get you pretty far. And there's a full HttpClient sample as well.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top