Skip to main content

hgraph-web

C++-first HTTP/S and WebSocket transports for hgraph, implementing the contract in hgraph RFC 0024. The extension covers all four transports — HTTP(S) server, HTTP(S) client, WebSocket server, and WebSocket client — and exposes the same service model to native C++ and Python graphs.

One path-bound, multi-interface service_impl owns the sockets, TLS contexts, and worker threads for a configuration. Serving a route and connecting a WebSocket are subscription services keyed by the immutable route or connection key; responding, sending frames, and calling a remote endpoint are request/reply services; events and statistics are reference services. Graph output reaches the transport through the implementation's sink inputs, and requests, frames, delivery reports, events, and stats re-enter the root graph through bounded push sources. Listeners and clients are created on graph start and stopped with the graph; there is no user-held server or client object.

Routing lives in the transport rather than the graph. The route key set arrives as TSS deltas, is compiled into a native route table, and requests are delivered already keyed by route. Duplicate and ordered headers, multi-value query parameters, and binary bodies are preserved end to end.

The server speaks HTTP/1.1 and WebSocket over Asio/Beast; the client speaks HTTP/1.1, HTTP/2, and WebSocket over libcurl. The server ships the complete HTTP/2 seam — the ALPN callback, protocol dispatch, and configuration placeholders — and rejects h2 in server ALPN until the nghttp2 session lands in a v1.x release. TLS termination, mTLS, SNI, and ALPN use OpenSSL on every platform.

The core hgraph wheel owns a guarded compatibility shim at hgraph.adaptors.web which delegates to this extension when it is installed. The released hgraph.adaptors.tornado HTTP/REST/WebSocket APIs delegate to hgraph_web.compat and hgraph_web.compat_client, including the libcurl client transport. The hgraph[web] extra needs no Tornado dependency. The extension wheel installs only hgraph_web; it never contributes files to the core hgraph package.

Status

The HTTP/1.1, HTTP/2 client, and WebSocket service implementations, schemas, service interfaces, endpoint decorators, and codec helpers are available. Runnable HTTP server/client and WebSocket loopback examples are in python/examples.

Build and test

This is a first-party extension in the hgraph monorepo. It remains a separate CMake package and Python distribution: the top-level core package does not link curl, Boost, nghttp2, or OpenSSL, and does not install these modules.

For an in-tree native development build from the repository root:

cmake -S . -B build-web \
  -DHGRAPH_BUILD_WEB_EXTENSION=ON \
  -DBUILD_TESTING=ON
cmake --build build-web --parallel
ctest --test-dir build-web --output-on-failure

The extension can still be configured independently against an installed hgraph SDK:

cmake -S . -B build -DCMAKE_PREFIX_PATH=/path/to/hgraph/install
cmake --build build --parallel
ctest --test-dir build --output-on-failure

Each third-party dependency arrives with the translation unit that links it, resolved with find_package(... CONFIG QUIET) first and falling back to a pinned static FetchContent build. The skeleton links only hgraph::core.

Build its separately deployable ABI3 wheel from the repository root after making the matching hgraph SDK discoverable through CMAKE_PREFIX_PATH:

CMAKE_PREFIX_PATH=/path/to/hgraph/sdk \
  uv build --wheel --package hgraph-web --python 3.12

The deterministic suite runs against the extension's fake transport, which exercises routing, pacing, reservation, and lifecycle without sockets. A live loopback subset acts as the transport oracle.

Wheel builds require the SDK installed by a stable-ABI hgraph wheel. The extension rejects an SDK that links Python::Python, because that would pin the nominal ABI3 module to the build interpreter.

Metadata

Release files for hgraph-web 0.8.41

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hgraph-web 0.8.41
File Size Uploaded Provenance Actions
hgraph_web-0.8.41.tar.gz 219.2 kB With provenance Details for hgraph_web-0.8.41.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for hgraph-web 0.8.41
File Interpreter ABI Platform Actions
hgraph_web-0.8.41-cp312-abi3-win_amd64.whl CPython 3.12 abi3 Windows x86-64 Details for hgraph_web-0.8.41-cp312-abi3-win_amd64.whl
hgraph_web-0.8.41-cp312-abi3-manylinux_2_28_x86_64.whl CPython 3.12 abi3 Linux glibc 2.28+ x86-64 Details for hgraph_web-0.8.41-cp312-abi3-manylinux_2_28_x86_64.whl
hgraph_web-0.8.41-cp312-abi3-macosx_26_0_arm64.whl CPython 3.12 abi3 macOS 26.0+ ARM64 Details for hgraph_web-0.8.41-cp312-abi3-macosx_26_0_arm64.whl

Total release size: 15.4 MB

Release files / hgraph_web-0.8.41.tar.gz

Download URL hgraph_web-0.8.41.tar.gz
Size 219.2 kB
Tags Source
SHA-256 checksum
How to use checksums
53a0f53c77a2c814f72f2ef8bee16ae8b1125fc2939fa5415b56ce1dcff1d9ae
BLAKE2b-256 checksum
How to use checksums
6c6e952c902359753f7f06b5df4f8d04f3d0880fbccdf24dedd92b3b0e633e41
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Release files / hgraph_web-0.8.41-cp312-abi3-win_amd64.whl

Download URL hgraph_web-0.8.41-cp312-abi3-win_amd64.whl
Size 3.6 MB
Tags CPython 3.12 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
e7a7b8750b8ed6cf29c08d949744e2c0e74f1ececa2ab11014fe43d33c1c6e3c
BLAKE2b-256 checksum
How to use checksums
cc6247e12446f63ccf66d87254039fd247f9f9c53e478ff77bb6fc39558c71bb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Release files / hgraph_web-0.8.41-cp312-abi3-manylinux_2_28_x86_64.whl

Download URL hgraph_web-0.8.41-cp312-abi3-manylinux_2_28_x86_64.whl
Size 8.4 MB
Tags CPython 3.12 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
eb6986fdf93de909be1073917c9cd3e155e44abd9c00d26080b51e623a4bb941
BLAKE2b-256 checksum
How to use checksums
f00035b73133e8ccecb950d0444dc2f514fd672b6a2ac9c15d0285d18c34ad1a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Release files / hgraph_web-0.8.41-cp312-abi3-macosx_26_0_arm64.whl

Download URL hgraph_web-0.8.41-cp312-abi3-macosx_26_0_arm64.whl
Size 3.1 MB
Tags CPython 3.12 abi3 macOS 26.0+ ARM64
SHA-256 checksum
How to use checksums
ebaead2de628758139151037a7f30b40097b1568a0302a94dfdbf3af5283074e
BLAKE2b-256 checksum
How to use checksums
ae0d5444f72ab24cc76ed9422e75c5508f8bead2fc32a29c0c666eb42f467d0a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

Security for hgraph-web 0.8.41

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 4 files in this release have been uploaded with provenance metadata.

Select from 4 files

Attestation for hgraph_web-0.8.41.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 16, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.8.41 This release

4 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page