The set of standard http constants for headers and statuses
Project description
Http Constants
A set of constants for HTTP statuses and headers.
Installation
You can install Http Constants from PyPI:
pip install http-constants
The library is supported on Python 3.7+.
Usage
Headers
from http_constants.headers import HttpHeaders
HttpHeaders.ACCEPT
> 'Accept'
HttpHeaders.CONTENT_TYPE_VALUES.json
> 'application/json'
Statuses
from http_constants.status import HttpStatus
> HttpStatus.SERVICE_UNAVAILABLE
<HttpStatus.SERVICE_UNAVAILABLE: (503, 'Service Unavailable')>
HttpStatus.SERVICE_UNAVAILABLE.get_value()
> 503
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
http-constants-0.3.0.tar.gz
(2.8 kB
view hashes)
Built Distribution
Close
Hashes for http_constants-0.3.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98337b08c68db3f7769aed9395ff86f2425678e8a35fe4de6773355fc9895acc |
|
MD5 | 5a73ec2c2a24837d4203a8a1ca289dbd |
|
BLAKE2b-256 | 7a0830792a4d47a65eed8f1725f4d3b946272bb59560e67c7d74f8396f2be3ee |