Metadata-Version: 2.1
Name: http-status-codes
Version: 1.0.3
Summary: The set of standard http constants
Home-page: https://github.com/alewkinr/http-constants
Author: Ramil Aleshkin
Author-email: alewkinr@gmail.com
License: MIT
Download-URL: https://github.com/alewkinr/http-constants/archive/v1.0.0.tar.gz
Platform: UNKNOWN
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Python: >=3.6.0
Description-Content-Type: text/markdown


# HTTP Status Constants

A set of constants for HTTP statuses and headers. Improve your code readability.

## Installation

You can install Http Constants from [PyPI](https://pypi.org/project/http-status-codes/):

    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
```
In[1]: 
    from http_constants import status
    status.SERVICE_UNAVAILABLE
Out[1]:
    503
---
In[2]: 
    from http_constants.status import HttpStatus
    HttpStatus(500).get_meaning()

Out[2]: 
    'Internal Server Error'
```

### Methods
```
In[1]: 
    from http_constants import method
    method.GET
Out[1]:
    "GET"
```

### URI Schemas
```
In[1]: 
    from http_constants import schema
    schema.HTTP
Out[1]:
    "http"
```

