0

How can I send 'get' request from the server to API and get result with json data? I heard about HTTPClient in .net 4.5 maybe there is something like that in .net 4.0?

1 Answer 1

1

For older Framework version You can use either WebClient which is really simple class for downloading/uploading data, or use HttpWebRequest. WebRequest is lower level, but You can define method(GET,POST), UserAgent etc. Here You can find example about using WebRequest to do POST.

If You just want to get returned JSON from adress, WebClient should be sufficent.

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

Comments

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.