I'm trying to make an application in Delphi to integrate the ERP to Free Market, and when using the REST Debugger (for testing) this is returning me an HTML and not Json, has anyone ever gone through this?
If you use Postman it returns the correct Json, however by Delphi or REST Debugger it only returns HTML.
Code used:
RESTClient.Accept := 'application/json';
RESTClient.BaseURL := 'api.mercadolibre.com/currencies?id=BRL';
RESTClient.AcceptCharset := 'UTF-8';
RESTClient.ContentType := 'application/json';
RESTRequest.Method := TRESTRequestMethod.rmGET;
RESTRequest.Execute;
Should return
{ "id": "BRL", "symbol": "R$", "description": "Real", "decimal_places": 2}
Returns
<!DOCTYPE html><!--if lt IE 7 ]> <span class="nt">"id"</span><span class="p">:</span> <span class="s2">"BRL"</span>