If you’re working with the REST client in Delphi XE5, XE6, Appmethod, and XE7 Firemonkey to consume REST APIs you may find it tricky to debug the HTTP data connections. There is a free application called Fiddler which can act like a proxy between your app and the REST server. Fiddler runs on your development machine but you could also connect to it’s proxy from your mobile device on the same network. Now Fiddler can automatically inserts itself into browser connections on your machine but in order for you to use it with the TRESTClient component you have to set TRESTClient.ProxyHost to 127.0.0.1 and TRESTClient.ProxyPort to 8888. It also supports SSL so you can even debug secure REST APIs. There are so many features packed into it’s unbelievable. Some of the features I use are things like Replay which will resend your REST request from Fiddler to the server again, viewing the entire HTTP request and response headers, displaying the HTTP request and response body (as raw, as a JSON tree, as an XML tree), 24+ different User Agent settings, simulated modem speeds, handling GZIP content, filtering for certain URLs, and much much more. Now the next piece of the toolset is the REST Debugger Tool that comes with the Firemonkey IDEs. The REST Debugger is available via the Tools menu in the IDE. It is a slimmed down version of what Fiddler offers but it also includes Object Pascal source code (in the samples section) if you want to modify it yourself. Jim McKeeth has a tutorial for modifying the REST Debugger Tool which allows you to set up your REST API URL in the REST Debugger Tool and then copy and paste the TRESTClient components out of it into your Firemonkey project. The XE7 version already has the modification added to it (just use the Copy To Clipboard button). You really have to watch his video tutorial to see how awesome and easy it is to setup and consume REST APIs with Firemonkey on Android, IOS, Windows, and OSX.
Use Fiddler With Delphi XE7 Firemonkey To Become A REST API Debugging Powerhouse by Delphi XE5 XE6 XE7 XE8 10 Seattle Berlin Firemonkey, Delphi Android, Delphi IOS is licensed under a Creative Commons Attribution 4.0 International License.