HTTP API for Python using builtin SimpleHTTPServer
Project description
Description
This is a basic HTTP API based on the processes that Flask uses, but in a simple (and more limitating) way. It's meant to be easy to use and short to the point
I described a lot the process in the source. Don't be shy to check it out if you want to understand it There's also an example.py with some basics inside
Functionnalities
- Routes with variables
- Request handler
- Security handler (which can be modified with an abstract class already present)
Basic example :
from http_api.server import HTTPServerAPI
http = HTTPServerAPI()
@http.url("/")
def index():
# Do something
http.run()
Security concerns
HTTPServer : https://docs.python.org/3/library/http.server.html
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
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 http-api-0.2.2.tar.gz.
File metadata
- Download URL: http-api-0.2.2.tar.gz
- Upload date:
- Size: 7.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9a2727e3aef8a6c8798767152a5cb4a5a99368f853cee6ffe429ce8f43e74043
|
|
| MD5 |
a7d5e34efcf3491532215b1a5e93ea31
|
|
| BLAKE2b-256 |
cf84ec3e2a95a1d45b6290d8e83b3388f4e27199761a126d079b5cea5f2aa5ae
|
File details
Details for the file http_api-0.2.2-py3-none-any.whl.
File metadata
- Download URL: http_api-0.2.2-py3-none-any.whl
- Upload date:
- Size: 24.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
75ec8a88e719a6988c37eff738be7ceb3af5729423037dae5086174a1cca3475
|
|
| MD5 |
310547e179479f2905b8650a1b63a203
|
|
| BLAKE2b-256 |
14a95d1044a876179c41b8c4bf877abd0d336218b0558a6f44f78e910f55e9de
|