Implementations of flask response in many formats like: json, xml, html...
Project description
Flask-ResponseBuilder
=====================
Implementations of flask response in many formats: base64, csv, json, xml, html, yaml.
Based on PyYAML, xmltodict, dicttoxml. See their documentation for other options.
Decorator for http response status 201 CREATED
Decorator for http response status 204 NO_CONTENT
Support for case notation checker and converter. See ``Case`` class.
Quickstart
~~~~~~~~~~
Install ``flask_response_builder`` using ``pip``:
::
$ pip install Flask-ResponseBuilder
.. _section-1:
Example usage
^^^^^^^^^^^^^
For example usage see ``test.py`` file in example folder.
.. _section-2:
Configuration
^^^^^^^^^^^^^
1. ``RB_DEFAULT_ENCODE``: *(default: utf-8)*
2. ``RB_DEFAULT_DUMP_INDENT``: *(default: None)*
3. ``RB_BASE64_ALTCHARS``: *(default: None)*
4. ``RB_BASE64_CONTENT_TYPE``: *(default: text/plain)*
5. ``RB_HTML_DEFAULT_TEMPLATE``: *(default: None)*
6. ``RB_YAML_ALLOW_UNICODE``: *(default: True)*
7. ``RB_CSV_DEFAULT_NAME``: *(default: filename)*
7. ``RB_CSV_QUOTING``: *(default: True)*
8. ``RB_CSV_DELIMITER``: *(default: ;)*
10. ``RB_CSV_QUOTING_CHAR``: *(default: ")*
11. ``RB_CSV_DIALECT``: *(default: excel-tab)*
12. ``RB_XML_CDATA``: *(default: False)*
13. ``RB_XML_ROOT``: *(default: root)*
License MIT
=====================
Implementations of flask response in many formats: base64, csv, json, xml, html, yaml.
Based on PyYAML, xmltodict, dicttoxml. See their documentation for other options.
Decorator for http response status 201 CREATED
Decorator for http response status 204 NO_CONTENT
Support for case notation checker and converter. See ``Case`` class.
Quickstart
~~~~~~~~~~
Install ``flask_response_builder`` using ``pip``:
::
$ pip install Flask-ResponseBuilder
.. _section-1:
Example usage
^^^^^^^^^^^^^
For example usage see ``test.py`` file in example folder.
.. _section-2:
Configuration
^^^^^^^^^^^^^
1. ``RB_DEFAULT_ENCODE``: *(default: utf-8)*
2. ``RB_DEFAULT_DUMP_INDENT``: *(default: None)*
3. ``RB_BASE64_ALTCHARS``: *(default: None)*
4. ``RB_BASE64_CONTENT_TYPE``: *(default: text/plain)*
5. ``RB_HTML_DEFAULT_TEMPLATE``: *(default: None)*
6. ``RB_YAML_ALLOW_UNICODE``: *(default: True)*
7. ``RB_CSV_DEFAULT_NAME``: *(default: filename)*
7. ``RB_CSV_QUOTING``: *(default: True)*
8. ``RB_CSV_DELIMITER``: *(default: ;)*
10. ``RB_CSV_QUOTING_CHAR``: *(default: ")*
11. ``RB_CSV_DIALECT``: *(default: excel-tab)*
12. ``RB_XML_CDATA``: *(default: False)*
13. ``RB_XML_ROOT``: *(default: root)*
License MIT
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
File details
Details for the file Flask-ResponseBuilder-0.0.1.tar.gz
.
File metadata
- Download URL: Flask-ResponseBuilder-0.0.1.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.29.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4e879aa2d120178d41eebd73437ddf6fd5c89dd4bb1f583d88c5f405a6c04f80 |
|
MD5 | 649c2e8da5bb44bf2a158a1d5a0aa8f8 |
|
BLAKE2b-256 | 3c25ef16de7e36461d8bdceb07f54f68e6d78104e99fa450346ec2c841629452 |
File details
Details for the file Flask_ResponseBuilder-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: Flask_ResponseBuilder-0.0.1-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.29.1 CPython/3.6.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 46b2939a79a8729ac0595d8052660ee5ac8b562f5ee9b23a2a1c645c00b55a5a |
|
MD5 | d265042a84fe90611f85c4039c83ac3c |
|
BLAKE2b-256 | 01526cb1767c960591add46ce1c44b41920b6ed8236d8d390f7442bcf700a85d |