Can someone post a simple example of a JSON POST request to an API using Delphi 2005. I have found numerous examples using GET but the API provider does not allow requests via HTTP GET and does not support URL encoding parameters.
I am brand new to calling REST services (have used SOAP in the past) so please let me know if you require more information.
You would just use Indy’s
TIdHTTPcomponent and call thePostmethod. Pass the URL as the first argument and your JSON string as the second argument. Something like this:I’m assuming you are already able to encode and decode the JSON and that you were just asking how to perform an HTTP post using Delphi.