Skip to main content

A modern Python web framework filled with asynchronous salsa.

Project description

A modern Python web framework filled with asynchronous salsa.


travis python downloads pypi black license

Bocadillo

Bocadillo is a Python web framework that provides a sane toolkit for quickly building performant web applications and services, while encouraging best practices and keeping developer experience in mind.

Under the hood, it uses the Starlette ASGI toolkit and the lightning-fast uvicorn ASGI server.

Read the documentation

Quick start

Install it:

pip install bocadillo

Build something:

# api.py
import bocadillo

api = bocadillo.API()

@api.route('/')
async def index(req, res):
    res.html = await api.template('index.html')

@api.route('/greet/{person}')
def greet(req, res, person):
    res.media = {'message': f'Hi, {person}!'}

if __name__ == '__main__':
    api.run()

Launch:

python api.py

Make requests!

curl http://localhost:8000/greet/Bocadillo
{"message": "Hi, Bocadillo!"}

Hungry for more? Head to the docs.

Contributing

See CONTRIBUTING for contribution guidelines.

Changelog

See CHANGELOG for a chronological log of changes to Bocadillo.

Roadmap

To see what has already been implemented for the next release, see the Unreleased section of our changelog.

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

bocadillo-0.6.0.tar.gz (14.6 kB view details)

Uploaded Source

Built Distribution

bocadillo-0.6.0-py3-none-any.whl (20.2 kB view details)

Uploaded Python 3

File details

Details for the file bocadillo-0.6.0.tar.gz.

File metadata

  • Download URL: bocadillo-0.6.0.tar.gz
  • Upload date:
  • Size: 14.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.3

File hashes

Hashes for bocadillo-0.6.0.tar.gz
Algorithm Hash digest
SHA256 c927376de7e5a3487696038912971d4e5e5b5ab1f9f473cae2f709650f3e7f0e
MD5 877321d7ee3f25f3a094e21d2d2c7409
BLAKE2b-256 cc324634463f221771943c3f58ec365edc3806918d919c0b426f266dbd370074

See more details on using hashes here.

File details

Details for the file bocadillo-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: bocadillo-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 20.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.3

File hashes

Hashes for bocadillo-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f611748c142a30ed44a8839330412b57c6b9526563622d9e00cacfc4144b68c8
MD5 b222fef554f4b17c95b652ad16a8c014
BLAKE2b-256 9ffcdd57ce3a8f5bd84fbc012ce4eef1de6a290dc0ea65411fd13e9b23d44042

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page