Skip to content
Jesse Ash edited this page Dec 18, 2018 · 10 revisions

Casablanca aka cpprestsdk 2.9.1 is one of the latest CppRestApis being utilized by the software engineering community. Many native applications being developed need to access databases over the internet in order to meet specified requirements for the client. Whether the application is being developed on a windows or a linux os- the CppRestApi provides a means of linking native applications to back end server side code- without having to concern one's self with the extra baggage of JVMs or CLRs which depending on what framework you are using may not be compatible on another machine with a different version of a CLR or JVM. This is a general example of how to consume a PHP web service using CppRestApi. Through my searches I have not come across any CppRest examples that demonstrate how to consume a PHP web service or a .net web service for that matter so I thought I would post my example for the benefit of the software engineering community. From this example you can easily add functionality to the web service that connects to a database and processes requested data from a native client application-likewise you can add your own hash keys and values to the consumer's request which can be accessed by your web service from the json object. You can find an example of a CppRestApi consuming a .net service here ...Below is the console output of the CasablancaConsumer program.

Output

Clone this wiki locally