Solved

Connect To API (without a wsdl) and Call Methods

Posted on 2013-05-29
3
294 Views
Last Modified: 2013-06-10
I need to connect to a web API that has no wsdl file.  It's a RESTful JSON service.  So, first off, I'm guessing that I can't add it as a service reference in my project.  Once I connect I need to be able to call various methods.  Can someone provide me with a good example of this?  I've looked in a few spots including http://www.asp.net/web-api/overview/web-api-clients/calling-a-web-api-from-a-net-client but the example does not seem to include a call to a method.

Thanks
0
Comment
Question by:cat4larry
  • 2
3 Comments
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 39205811
RESTful services don't use WSDLs--SOAP services do. A RESTful service relies on the existing HTTP protocol to send requests and receive responses from a server. You can basically think of it like your browser requesting a web page--sans browser.

Were you given any documention describing the API?



...and no, you cannot "Add Service Reference" to a RESTful service  : )
0
 

Accepted Solution

by:
cat4larry earned 0 total points
ID: 39206563
I'm really embarrassed actually.  I should have RTFM a little further.  It gives complete examples.  I just need to chose the correct endpoints and then perform the correct action (insert, update, delete).  simple request/response JSON stuff.  For some reason I thought there would be much more to it than that.
0
 

Author Closing Comment

by:cat4larry
ID: 39234131
I figured it out myself
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now