ApiShare Tunnel
Expose your local API service to the public internet through the ApiShare platform.
Installation
pip install apishare
Client Usage
Expose a local API service running on port 8000:
apishare -k YOUR_TOKEN -p 8000
Your service is now accessible through the platform.
Server Usage (Platform Admin)
Run the tunnel server:
apishare serve --port 3397
Options
-k, --key Platform auth token (required for client mode)
-p, --port Local service port (required for client mode)
--host Local service address (default: localhost)
-s, --server Tunnel server address (default: apishare.cc)
--server accepts a plain host (apishare.cc, default wss://), host:port,
or a full ws:// / wss:// URL for self-hosted servers.
v1.1.0 — reliability upgrade (engineered after samaidev/aitun)
- Large responses no longer stall: bodies over 64KB are streamed as 128KB chunks instead of one giant WebSocket frame.
- Idle SSE keepalive: LLM generations with long silent gaps stay alive (empty keepalive chunks every 30s of upstream silence).
- Smarter reconnects: exponential backoff capped at 30s + jitter; a
4009close code ("replaced by a newer client with the same token") stops reconnecting instead of fighting the other instance. - Safe concurrent sends: parallel requests share one serialized send path, so heartbeats and response chunks can no longer interleave.
- Port pre-flight: warns immediately when nothing listens on
-p PORT.
The client remains fully protocol-compatible with older servers.
Metadata
Release files for apishare-tunnel 1.1.0
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 |
|---|---|---|---|---|
| apishare_tunnel-1.1.0.tar.gz | 2.4 kB | Without provenance | Details for apishare_tunnel-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| apishare_tunnel-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for apishare_tunnel-1.1.0-py3-none-any.whl |
Total release size: 4.6 kB
Security for apishare-tunnel 1.1.0
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.