Unit 'fpHTTPClient' Package
[Overview][Constants][Types][Classes][Procedures and functions][Index] [#fcl]

TFPCustomHTTPClient

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

Base HTTP client class for making HTTP requests

Declaration

Source position: fphttpclient.pp line 111

type TFPCustomHTTPClient = class(TComponent)

public

  constructor Create(); override;

  

Creates a new HTTP client instance

  destructor Destroy; override;

  

Destroys the HTTP client instance

  property UnixSocketPath: string; [rw]

  

Path to Unix domain socket for local connections

  class procedure AddHeader();

  

Adds an HTTP header to a headers collection

  class function IndexOfHeader();

  

Returns the index of a header in a headers collection

  class function GetHeader();

  

Gets the value of a header from a headers collection

  procedure Terminate;

  

Terminates any ongoing HTTP operation

  procedure HTTPMethod(); virtual;

  

Executes an HTTP request with the specified method

  procedure Get();

  

Performs an HTTP GET request

  function GetEventSource();

  

Creates a Server-Sent Events connection

  class function IsRedirect(); virtual;

  

Checks if an HTTP status code indicates a redirect

  class function RedirectForcesGET(); virtual;

  

Checks if a redirect status code forces GET method

  class procedure SimpleGet();

  

Static method to perform a simple HTTP GET request

  procedure Post();

  

Performs an HTTP POST request

  class procedure SimplePost();

  

Static method to perform a simple HTTP POST request

  procedure Put();

  

Performs an HTTP PUT request

  class procedure SimplePut();

  

Static method to perform a simple HTTP PUT request

  procedure Delete();

  

Performs an HTTP DELETE request

  class procedure SimpleDelete();

  

Static method to perform a simple HTTP DELETE request

  procedure Patch();

  

Performs an HTTP PATCH request

  class procedure SimplePatch();

  

Static method to perform a simple HTTP PATCH request

  procedure Options();

  

Performs an HTTP OPTIONS request

  class procedure SimpleOptions();

  

Static method to perform a simple HTTP OPTIONS request

  class procedure Head();

  

Performs an HTTP HEAD request

  procedure FormPost();

  

Performs an HTTP POST request with form data

  class procedure SimpleFormPost();

  

Static method to perform a simple form POST request

  procedure FileFormPost();

  

Performs an HTTP POST request with file upload

  procedure StreamFormPost();

  

Performs an HTTP form POST with stream upload

  class procedure SimpleFileFormPost();

  

Static method to perform a simple file upload form POST

  property Terminated: Boolean; [r]

  

Indicates whether the HTTP operation has been terminated

end;

Inheritance

TFPCustomHTTPClient

  

Base HTTP client class for making HTTP requests

|

TComponent

|

TPersistent,IUnknown,IInterfaceComponentReference

|

TObject,IFPObserved

Description

TFPCustomHTTPClient is the base class for HTTP client functionality. It provides methods for all standard HTTP operations including GET, POST, PUT, DELETE, PATCH, OPTIONS, and HEAD requests.

The class supports SSL/TLS connections, HTTP redirects, authentication, cookies, form posting with file uploads, proxy connections, and Server-Sent Events. It handles connection management, timeout control, and provides various events for monitoring request progress.

See also

TFPHTTPClient

  

Full-featured HTTP client with published properties

TProxyData

  

Proxy server configuration data


Documentation generated on: Jan 27 2026