Standalone product HTTP Server, HTTP/2, gRPC & Google Cloud

sgcHTTP: HTTP Server, HTTP/2, gRPC & Google Cloud Components for Delphi & C++ Builder

An HTTP server and five client components. TsgcHTTPServer publishes HTTP endpoints and static files from your own application: set Port, handle OnCommandGet, set Active. TsgcHTTP2Client speaks HTTP/2 with multiplexed streams over one TLS connection and HPACK header compression. TsgcGRPCClient is a gRPC client built on top of it, for unary and streaming Protocol Buffers calls. Three more classes reach Google Cloud over plain HTTPS: Pub/Sub, Calendar and Firebase Cloud Messaging. sgcHTTP is standalone, it bundles the sgcWebSockets Core runtime that the server and all five clients are built on.

Full source code
Delphi 7 to 13 & C++ Builder
Bundled runtime sgcWebSockets Core The HTTP server, plus the HTTP, TLS and JSON runtime under every client
HTTP/2 TsgcHTTP2Client
gRPC TsgcGRPCClient

See sgcHTTP in Two Minutes

An HTTP server, HTTP/2 and gRPC clients for Delphi and C++Builder, plus ready-made Google Cloud, Amazon and Apple Push integrations.

3 Palette components HTTP server, HTTP/2 client & gRPC client, one page on the palette
5 Client classes total HTTP/2, gRPC and three Google Cloud clients
3 Google Cloud services Pub/Sub, Calendar and Firebase Cloud Messaging
100% Source code included The HTTP server, all five clients and the bundled Core runtime
12 Months of updates Every release published while your license is active

Two Things Worth Knowing First

What sgcHTTP needs from you, and what it does not. Both answers are short.

sgcHTTP is self-contained

Standalone, the sgcWebSockets Core runtime is included: the HTTP server, the HTTP/TLS client stack every client sends its requests through, and the JSON layer that decodes Google Cloud responses. One SKU, one installer.

Full source code ships with every license, so the HTTP server, all five clients and the runtime under them step through in your own debugger rather than disappearing into a binary.

Add-on required for two of five

HTTP/2 & gRPC need sgcCustomIndy

HTTP/2 negotiates the h2 protocol with ALPN during the TLS handshake, and the standard Indy library that ships with RAD Studio does not support ALPN. sgcHTTP's HTTP/2 client and gRPC client are built on sgcCustomIndy instead, which is always included when you order sgcHTTP, and the price shown already covers it.

The three Google Cloud clients, Pub/Sub, Calendar and Firebase Cloud Messaging, are plain HTTPS. They run on the bare Core runtime and do not need sgcCustomIndy at all.

Three Palette Components, Three Google Cloud Clients

The HTTP server, the HTTP/2 client and the gRPC client are non-visual components on the SGC HTTP palette page. The server is declared in the sgcHTTP_Server unit of the bundled Core runtime, the two clients in the sgcHTTP unit. Drop one on a form or create it in code, set the connection options, wire the events, then call the typed request methods. The three Google Cloud clients live in the same unit as code-only classes, there is nothing to drop on a form: create one, set GoogleCloudOptions, and call its methods directly.

HTTP Server1 component

Publish HTTP endpoints and static files

TsgcHTTPServer turns your Delphi or C++ Builder application into an HTTP server. Set Port, handle OnCommandGet, set Active to true, and every request reaches your code with its request and response objects, while OnCommandOther covers verbs such as PUT and DELETE. Point DocumentRoot at a folder and the server returns static files from it. HTTPCompression compresses responses, KeepAlive reuses connections, SessionState with OnSessionStart and OnSessionEnd tracks sessions, MaxRequestBodySize caps request bodies and HTTPUploadFiles saves uploaded files to disk. For production, SSL and SSLOptions enable TLS, Authentication and OnAuthentication protect your endpoints, and ThreadPool and MaxConnections control how it scales. It is the same engine as the sgcWebSockets WebSocket server without the WebSocket part, and it ships with the bundled Core runtime.

TsgcHTTPServer Ships with the Core runtime
HTTP/21 component

Multiplexed streams over one TLS connection

TsgcHTTP2Client speaks HTTP/2 (RFC 9113): multiple requests share a single TCP connection as independent streams, so one slow response does not block the others behind it. Headers are compressed with HPACK, and the h2 protocol is negotiated during the TLS handshake through ALPN, the reason the component is built on sgcCustomIndy rather than the standard Indy library. Every verb is covered, Connect, Get, Post, Put, Patch, Delete and Options, each with a synchronous call and an Async twin. Events surface the connection lifecycle: OnHTTP2Connect, OnHTTP2Response, OnHTTP2ResponseFragment for chunked bodies, OnHTTP2PushPromise for server push, OnHTTP2GoAway and OnHTTP2Disconnect. HTTP2Options configures the local settings frame, and TLSOptions and Authentication carry over from the rest of the sgc HTTP stack.

TsgcHTTP2Client Requires sgcCustomIndy
gRPC1 component

Unary and streaming RPC on the HTTP/2 client

TsgcGRPCClient is built on the HTTP/2 client, so it inherits the multiplexed connection and adds the gRPC wire format on top: length-prefixed Protocol Buffers messages over HTTP/2 streams. Call and CallAsync cover unary RPCs, ServerStreamingCall handles a stream of responses to one request, and OpenClientStream/SendStreamMessage/CloseClientStream plus OpenBidiStream/SendBidiMessage/CloseBidiStream cover client-streaming and bidirectional-streaming RPCs. OnGRPCResponse, OnGRPCStreamMessage and OnGRPCStreamEnd deliver the traffic, and RetryPolicy, Interceptors and ServiceConfig add retry behavior, cross-cutting logic and service configuration without touching the call sites. Like the HTTP/2 client it is built on, it needs sgcCustomIndy for ALPN.

TsgcGRPCClient Requires sgcCustomIndy
Google Cloud3 classes

Pub/Sub, Calendar and push notifications, plain HTTPS

Three more classes reach Google Cloud services over plain HTTPS, authenticated with a Google service account, and none of them need sgcCustomIndy. TsgcHTTPGoogleCloud_PubSub_Client publishes and pulls messages and manages topics, subscriptions and snapshots: Publish, Pull, Acknowledge, CreateTopic, CreateSubscription and the rest of the Pub/Sub REST surface. TsgcHTTPGoogleCloud_Calendar_Client wraps the Google Calendar API v3: NewCalendar, NewEvent, LoadEvents and LoadCalendars, with OnGetCalendar and OnGetCalendarEvent events for synchronization. TsgcHTTPGoogleCloud_FCM_Client sends a push notification payload to a Firebase project with one call, SendMessage. All three are code-only classes: create one, set GoogleCloudOptions, call the methods.

TsgcHTTPGoogleCloud_PubSub_Client TsgcHTTPGoogleCloud_Calendar_Client TsgcHTTPGoogleCloud_FCM_Client

Two Dependencies, Not Five

The five classes split cleanly by what they need underneath. HTTP/2 and gRPC need ALPN, which means sgcCustomIndy. Google Cloud needs nothing beyond HTTPS and a service account, which the bundled Core runtime already provides.

HTTP/2 needs ALPN, so it needs sgcCustomIndy

Application-Layer Protocol Negotiation picks h2 during the TLS handshake, and the standard Indy library that ships with RAD Studio has no ALPN support. TsgcHTTP2Client is built on sgcCustomIndy, eSeGeCe's custom Indy build, instead.

gRPC is Protocol Buffers riding on the HTTP/2 client

TsgcGRPCClient does not open its own connection, its Client property is a TsgcHTTP2Client. Unary, server-streaming, client-streaming and bidirectional calls all travel as HTTP/2 streams underneath.

Google Cloud is HTTPS plus a service account

The three Google Cloud clients authenticate with GoogleCloudOptions.JWT, a Google service account's project id, client email and private key, and call the REST APIs over the Core runtime's plain HTTPS stack. OnAuthToken and OnAuthTokenError surface the token exchange.

The Core runtime is in the box

Standalone, the sgcWebSockets Core runtime is included. It contributes TsgcHTTPServer and the HTTP/TLS client stack every one of the five clients calls through, and its full source is part of the package like everything else.

HTTP Server, HTTP/2 and gRPC, Side by Side

The two clients are declared in the sgcHTTP unit and the server in sgcHTTP_Server, and TsgcGRPCClient carries its own HTTP/2 connection through its Client property. The same code compiles in Delphi 7 to 13 and C++ Builder.

uses
  sgcHTTP, sgcHTTP_Server;

var
  Server: TsgcHTTPServer;
  HTTP2: TsgcHTTP2Client;
  GRPC: TsgcGRPCClient;
begin
  // HTTP server: endpoints and static files
  Server := TsgcHTTPServer.Create(nil);
  Server.Port := 8080;
  Server.DocumentRoot := 'C:\www';
  Server.OnCommandGet := ServerCommandGet;
  Server.Active := True;

  // HTTP/2: multiplexed requests over one TLS connection
  HTTP2 := TsgcHTTP2Client.Create(nil);
  HTTP2.Host := 'https://api.example.com';
  HTTP2.OnHTTP2Response := HTTP2Response;
  HTTP2.Active := True;

  HTTP2.GetAsync('/v1/status');

  // gRPC: built on the HTTP/2 client, unary and streaming RPC
  GRPC := TsgcGRPCClient.Create(nil);
  GRPC.Client.Host := 'https://grpc.example.com';
  GRPC.OnGRPCResponse := GRPCResponse;

  GRPC.CallAsync('example.OrderService', 'GetOrder', RequestBytes);
end;

procedure TForm1.HTTP2Response(Sender: TObject;
  const Connection: TsgcHTTP2ConnectionClient;
  const Request: TsgcHTTP2RequestProperty;
  const Response: TsgcHTTP2ResponseProperty);
begin
  Memo1.Lines.Add(Response.DataString);
end;

procedure TForm1.GRPCResponse(Sender: TObject;
  const aResponse: TsgcGRPCResponse);
begin
  Memo1.Lines.Add(aResponse.DataString);
end;

procedure TForm1.ServerCommandGet(AContext: TIdContext;
  ARequestInfo: TIdHTTPRequestInfo; AResponseInfo: TIdHTTPResponseInfo);
begin
  if ARequestInfo.Document = '/api/status' then
  begin
    AResponseInfo.ContentType := 'application/json';
    AResponseInfo.ContentText := '{"status":"ok"}';
  end;
end;
// include: sgcHTTP.hpp, sgcHTTP_Server.hpp

// HTTP server: endpoints and static files
TsgcHTTPServer *Server = new TsgcHTTPServer(this);
Server->Port = 8080;
Server->DocumentRoot = "C:\\www";
Server->OnCommandGet = ServerCommandGet;
Server->Active = true;

// HTTP/2: multiplexed requests over one TLS connection
TsgcHTTP2Client *HTTP2 = new TsgcHTTP2Client(this);
HTTP2->Host = "https://api.example.com";
HTTP2->OnHTTP2Response = HTTP2Response;
HTTP2->Active = true;

HTTP2->GetAsync("/v1/status");

// gRPC: built on the HTTP/2 client, unary and streaming RPC
TsgcGRPCClient *GRPC = new TsgcGRPCClient(this);
GRPC->Client->Host = "https://grpc.example.com";
GRPC->OnGRPCResponse = GRPCResponse;

GRPC->CallAsync("example.OrderService", "GetOrder", RequestBytes);

void __fastcall TForm1::HTTP2Response(TObject *Sender,
    const TsgcHTTP2ConnectionClient* Connection,
    const TsgcHTTP2RequestProperty* Request,
    const TsgcHTTP2ResponseProperty* Response)
{
  Memo1->Lines->Add(Response->DataString);
}

void __fastcall TForm1::GRPCResponse(TObject *Sender,
    const TsgcGRPCResponse* aResponse)
{
  Memo1->Lines->Add(aResponse->DataString);
}

void __fastcall TForm1::ServerCommandGet(TIdContext *AContext,
    TIdHTTPRequestInfo *ARequestInfo, TIdHTTPResponseInfo *AResponseInfo)
{
  if (ARequestInfo->Document == "/api/status")
  {
    AResponseInfo->ContentType = "application/json";
    AResponseInfo->ContentText = "{\"status\":\"ok\"}";
  }
}

One Dependency for Two Clients, None for Three

The HTTP/2 client and the gRPC client build on sgcCustomIndy, which covers the same platform range as sgcWebSockets itself. The Google Cloud clients are plain HTTPS, so they run wherever the Core runtime does.

TsgcHTTP2Client & TsgcGRPCClient Built on sgcCustomIndy for ALPN
Windows Win32 Windows Win64 Linux64 macOS iOS Android
Google Cloud clients Plain HTTPS, no sgcCustomIndy needed
Windows Win32 Windows Win64 Linux64 macOS iOS Android
IDE support One source tree, design-time packages per version
Delphi 7 to 13 C++ Builder
Trial installer The sgcWebSockets All-Access trial includes the sgcHTTP components
One download, the server and all five clients

Download the trial installer →

A Standalone Package

sgcHTTP is licensed on its own, starting at €398 for a single developer. All licenses include full source code, 1 year of updates and a 50% to 70% renewal discount: 50% when you renew one pack, 60% for two, 70% for three or more. sgcAI, sgcMQ, sgcSocial, sgcCustomIndy, sgcAuth, sgcHTTP and sgcREST each count as a pack. sgcHTTP is also included in the All-Access bundle.

sgcHTTP

€398

Single, Team and Site licenses available.

  • HTTP server with static files, sessions & TLS
  • HTTP/2 client with multiplexing & HPACK
  • gRPC client, unary & streaming RPC
  • Google Cloud Pub/Sub, Calendar & FCM clients
  • sgcWebSockets Core runtime included
  • Delphi 7 to 13 & C++ Builder
  • Full source code
  • 1 year of updates

HTTP/2 and gRPC need the sgcCustomIndy add-on. It is always included in your order, and the price shown already covers it.

Checkout lists three items: the sgcWebSockets Core runtime entitlement, charged at zero, the sgcHTTP pack itself, and the sgcCustomIndy add-on, always included. Full pricing details.

3,000+Developers
20+Years
761+Components
30+API Integrations
5Platforms
30-Day Money-Back GuaranteeNot satisfied? Request a full refund within 30 days of purchase. See refund policy

Modern HTTP, gRPC and Google Cloud from Native Code

An HTTP server, multiplexed HTTP/2, streaming gRPC and three Google Cloud clients, with the runtime bundled in and full source code in the box. Download the All-Access trial installer and try every component today.

Other Products by eSeGeCe

Pair sgcHTTP with our other Delphi, C++ Builder and .NET component libraries.

sgcCustomIndy

The custom Indy library sgcHTTP's HTTP/2 and gRPC clients are built on: ALPN, TLS 1.3 and static OpenSSL linking.

Learn more →

sgcWebSockets

The full library: WebSocket clients and servers, HTTP/2, gRPC, IoT, P2P and AI components. Its Enterprise edition includes gRPC too.

Learn more →

sgcAI

AI, LLM and MCP components. One chat component reaches OpenAI, Anthropic, Gemini, DeepSeek, Ollama, Grok and Mistral.

Learn more →

sgcMQ

Native MQTT 3.1.1/5.0, AMQP 0.9.1, AMQP 1.0, Apache Kafka and STOMP client components, with the Core runtime bundled.

Learn more →

sgcCrypto

Symmetric and asymmetric ciphers, hashing and post-quantum algorithms. Ships free from sgcWebSockets Standard up.

Learn more →

sgcSocial

WhatsApp Business Cloud API and Telegram TDLib client components, with the Core runtime bundled.

Learn more →

sgcQUIC

QUIC (RFC 9000) and HTTP/3 (RFC 9114) client and server components built on the native OpenSSL 3.5 QUIC engine.

Learn more →

sgcWebRTC

Full WebRTC media engine: audio/video calls, data channels and screen share. An add-on for sgcWebSockets Enterprise.

Learn more →