Warpsock
Python bindings for the Warpsock HTTP client with TLS, HTTP/2, HTTP/3, RFC 6455 WebSocket, and RFC 8441 Extended CONNECT support.
Supported Chrome fingerprints are warpsock.FingerprintProfile.Chrome142 through warpsock.FingerprintProfile.Chrome148. Supported Firefox fingerprints are warpsock.FingerprintProfile.Firefox133 through warpsock.FingerprintProfile.Firefox151, plus ESR branches FirefoxEsr115, FirefoxEsr128, and FirefoxEsr140; examples use Chrome148, the latest implemented Chrome profile.
Installation
pip install warpsock
HTTP
Synchronous HTTP:
import warpsock
builder = warpsock.SyncClient.builder()
builder.fingerprint(warpsock.FingerprintProfile.Chrome148)
client = builder.build()
response = client.get("https://example.com/").send()
print(response.status)
print(response.text())
Async HTTP:
import warpsock
builder = warpsock.AsyncClient.builder()
builder.fingerprint(warpsock.FingerprintProfile.Chrome148)
client = builder.build()
response = await client.get("https://example.com/").send()
print(response.status)
print(response.text())
RFC 6455 WebSockets
import warpsock
builder = warpsock.Client.builder()
builder.cookie_store(True)
client = builder.build()
ws_builder = client.websocket("wss://example.com/socket")
ws_builder.subprotocol("chat.v1")
ws = await ws_builder.connect()
await ws.send_text("hello")
message = await ws.next()
await ws.close(warpsock.CloseFrame(warpsock.CLOSE_NORMAL, "done"))
RFC 8441 HTTP/2 Tunnels
import warpsock
builder = warpsock.Client.builder()
builder.http2_prior_knowledge(True)
client = builder.build()
tunnel = await client.websocket_h2("https://example.com/h2-tunnel").connect()
await tunnel.send_bytes(b"raw bytes", end_stream=False)
data = await tunnel.recv_bytes()
await tunnel.close_send()
RFC 6455 framed WebSockets and RFC 8441 raw HTTP/2 tunnels are separate APIs by design.
License
MIT
Metadata
Release files for warpsock 4.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| warpsock-4.3.1.tar.gz | 2.5 MB | Without provenance | Details for warpsock-4.3.1.tar.gz |
Built distributions (wheels)
| File | Actions Reset | |||
|---|---|---|---|---|
| warpsock-4.3.1-cp310-abi3-manylinux_2_28_x86_64.whl | CPython 3.10 | abi3 | Linux glibc 2.28+ x86-64 | Details for warpsock-4.3.1-cp310-abi3-manylinux_2_28_x86_64.whl |
| warpsock-4.3.1-cp310-abi3-manylinux_2_28_aarch64.whl | CPython 3.10 | abi3 | Linux glibc 2.28+ ARM64 | Details for warpsock-4.3.1-cp310-abi3-manylinux_2_28_aarch64.whl |
| warpsock-4.3.1-cp310-abi3-macosx_11_0_arm64.whl | CPython 3.10 | abi3 | macOS 11.0+ ARM64 | Details for warpsock-4.3.1-cp310-abi3-macosx_11_0_arm64.whl |
| warpsock-4.3.1-cp310-abi3-macosx_10_13_x86_64.whl | CPython 3.10 | abi3 | macOS 10.13+ x86-64 | Details for warpsock-4.3.1-cp310-abi3-macosx_10_13_x86_64.whl |
Total release size: 33.3 MB
Release files / warpsock-4.3.1.tar.gz
| Download URL | warpsock-4.3.1.tar.gz |
|---|---|
| Size | 2.5 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cf9216702867f7b09af53ae738c62c781ca36a10002471c76ad5dccba09db6c7
|
|
BLAKE2b-256 checksum How to use checksums |
18fe41a868a03562413ec6ab64a90a8c58ff303406067c36d75d5e84abc5de0f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Release files / warpsock-4.3.1-cp310-abi3-manylinux_2_28_x86_64.whl
| Download URL | warpsock-4.3.1-cp310-abi3-manylinux_2_28_x86_64.whl |
|---|---|
| Size | 12.3 MB |
| Tags | CPython 3.10 Linux glibc 2.28+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
0af2fc9e8c9348d859a4f03e331d1238bd71ced4286f26f0734e03579f64e3ea
|
|
BLAKE2b-256 checksum How to use checksums |
cb94a79fe826a3a935aa82d0e700fb58a7e029da9742cb25d63f659a665445ad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Release files / warpsock-4.3.1-cp310-abi3-manylinux_2_28_aarch64.whl
| Download URL | warpsock-4.3.1-cp310-abi3-manylinux_2_28_aarch64.whl |
|---|---|
| Size | 11.5 MB |
| Tags | CPython 3.10 Linux glibc 2.28+ ARM64 abi3 |
|
SHA-256 checksum How to use checksums |
9cc2ec1a17b6848450ce1cc67337bf5c68433c9013cac7f9a65e02431b527afa
|
|
BLAKE2b-256 checksum How to use checksums |
fb9ec927685cf2d299bec77149db48b1642ce6ad9bc2d8bc29bd7bd4f52dd840
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Release files / warpsock-4.3.1-cp310-abi3-macosx_11_0_arm64.whl
| Download URL | warpsock-4.3.1-cp310-abi3-macosx_11_0_arm64.whl |
|---|---|
| Size | 3.4 MB |
| Tags | CPython 3.10 abi3 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
2f25b80e84613e2704a6c45e3b4878fa03d19ffce310f00c97d4b5886d9a8585
|
|
BLAKE2b-256 checksum How to use checksums |
7f2be76733dbef4060516121360bfcbd06d147ef280ffb3e05e703056254c58b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Release files / warpsock-4.3.1-cp310-abi3-macosx_10_13_x86_64.whl
| Download URL | warpsock-4.3.1-cp310-abi3-macosx_10_13_x86_64.whl |
|---|---|
| Size | 3.6 MB |
| Tags | CPython 3.10 abi3 macOS 10.13+ x86-64 |
|
SHA-256 checksum How to use checksums |
cb72eaf817ae9bdbf908c85bd151d1c39ef68e7776a9b9e40a3b3090d2aa3aec
|
|
BLAKE2b-256 checksum How to use checksums |
83a875e092a5ff196b75d4c76c82c2caf551facb1539645135096640b5bd2a9c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Security for warpsock 4.3.1
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.