[SOLVED] HTTPS SimpleFormPost with TFPHTTPClient : Headers Issue lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- tudi_x · 2017-07-15 11:43 hi All, i am trying to make a POST request with custom headers. the code is the below and attached. Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure TForm1.Button1Click(Sender: TObject);var  HTTPS: TFPHTTPClient;  POSTBody: TStringList;  DebugURL: string = 'https://requestb.in/1bqcc6f1';  err: string; begin  POSTBody := TStringList.Create;  POSTBody.Append('');  POSTBody.Append('');   try    HTTPS := TFPHTTPClient.Create(nil);     HTTPS.AddHeader('Authorization', 'Bearer ' + 'TOKEN xxxxxxx');    HTTPS.AddHeader('x-li-format', 'json');    HTTPS.AddHeader('Content-Type', 'application/json');     err := HTTPS.SimpleFormPost(DebugURL, POSTBody);    Memo1.Append(err);   finally    FreeAndNil(HTTPS);    FreeAndNil(POSTBody);  end;end;           it looks like the headers are not arriving to the web site - please see screen capture. please advise what i am missing. thank you! using Lazarus 1.6.4 64 bit on Windows 7 and https://indy.fulgan.com/SSL/openssl-1.0.2l-x64_86-win64.zip ---------------------------------------------------------------------- tudi_x · 2017-07-15 11:48 It looks it is working with  Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i err := HTTPS.FormPost(DebugURL, POSTBody); ---------------------------------------------------------------------- Leledumbo · 2017-07-15 16:22 SimpleFormPost is a class method, it doesn't read your AddHeader at all. That method simple creates volatile instance of TFPHTTPClient and call FormPost using URL and Body parameters that you give then return the result.