Spynl - write a web app you can manage

Spynl is a Python web framework which extends the Pyramid web framework.

Spynl helps you to manage your web application:

  • Build your app (via Jenkins)
  • Deploy your app (via Docker)
  • Serve endpoint documentation for frontend devs (via Swagger)
  • Inspect settings and meta-data of running instances in the browser
  • Aggregate performance indicators and error messages in NewRelic and/or Sentry

Spynl also has a few other in-built utilities which are often necessary in a modern professional web application but easily take a few days to get right:

  • Manage translations (via Babel)
  • Send templatable, translatable HTML emails
  • validate JSON input and output with Schemas


Here is a (very) quick How-To for installing Spynl:

$ pip install spynl
$ spynl dev.serve

Now you can visit Spynl’s in-built /about endpoint:

$ curl http://localhost:6543/about

And you should get a reponse like this:

    "status": "ok",
    "language": "en",
    "time": "2017-02-03T10:13:41+0000",
    "plugins": {},
    "message": "This is a Spynl web application. You can get more information at about/endpoints, about/ini, about/versions, about/build and about/environment.",
    "spynl_version": "6.0.1"

So you see there are a few endpoints with more specific information. Try visiting http://localhost:6543/about/endpoints to see the documentation for in-built endpoints and http://localhost:6543/about/ini to see possible settings.

The plugins part is empty because we haven’t written any code of our own yet. See the next section for that.