Skip to main content

A common utility framework for web microservices

Project description


The goal of this project is to remove some boilerplate and add few standard routes to flask applications.


Add common routes to the flask application:

from mworks import CommonRoutes
from flask import Flask

app = Flask(__name__)
mworks = CommonRoutes(app)

You can optionally add authorisation for sensitive endpoints:

is_admin = lambda: request.remote_addr == ''
mworks = CommonRoutes(app, auth_checks=[is_admin])


CommonRoutes has the following endpoints implemented:

  • /healthz - Always returns HTTP 200, useful for healthchecks
  • /varz - Get variables for service monitoring. Customizable.
  • /docz - Read from the application and render it.
  • /logz - Render logs from the application in the browser.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for mworks, version 2.0.0
Filename, size File type Python version Upload date Hashes
Filename, size mworks-2.0.0-py2.py3-none-any.whl (3.7 kB) File type Wheel Python version py2.py3 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page