Tiny HTTP router
Project description
tiny-router
A tiny HTTP router like this:
from tiny_router import SimpleRouter router = SimpleRouter() @router.get("/users") def list_users(): ... @router.post("/users") def create_user(): ... another_router = SimpleRouter() router.include(another_router) route = router.resolve("GET", "/users")
Features
SimpleRouter
: exact-match routerSimpleRegexRouter
: simple regex-based router- Abstract
Router
: user can implement their own routers - Support for type hints
Usage
See examples/
directory of repository.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tiny-router-0.0.6.tar.gz
(4.5 kB
view hashes)
Built Distribution
Close
Hashes for tiny_router-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c699e5182684d5a8ac5ae411e24165eee72667981ac5f3ac769ed52180a52e46 |
|
MD5 | 29c62a0ab939d4256551e19c5b90350d |
|
BLAKE2-256 | 07994628f624fe54242256717e73c01cdee738d485f2cad4dadb0eb3930d427c |