A simple web server with websocket support based on starlette and uvicorn
Project description
moonlette
A simple web server with websockets support based on starlette, uvicorn and authlib.
Installation
pip install moonlette
Example usage (http)
from mooonlette.server import Server
server = Server(port=8081, host="localhost")
def handler(path, headers, path_parameters, query_parameters, request_body):
return (200, b"It Worked!", "text/plain", {})
server.attach_handler("GET", "/test", handler)
server.run()
Example usage (websocckets)
Coming soon
Documentation
Coming Soon
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
moonlette-0.0.2.tar.gz
(5.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file moonlette-0.0.2.tar.gz.
File metadata
- Download URL: moonlette-0.0.2.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9a59f62fe351428169876a21015888b2b63e91e9deec99c675f48d5b1e702999
|
|
| MD5 |
12e3d0a6e27715fadf485f5c1036228e
|
|
| BLAKE2b-256 |
30db3deac229b7ee7db5f6b540c9ede6688059dec2b82c525b6cf1b61a8c2d85
|
File details
Details for the file moonlette-0.0.2-py3-none-any.whl.
File metadata
- Download URL: moonlette-0.0.2-py3-none-any.whl
- Upload date:
- Size: 6.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0601ce73fcaf7eb41e748a3114fccc945511de1447ea87662194a4cb3ec5114e
|
|
| MD5 |
09132643a94358407ee80d13ceca344b
|
|
| BLAKE2b-256 |
466432192f822d0af127ac4e6d3cd5e85f57d6ac3f9615c2d459f470df65de73
|