Python Web - Web Server Gateway Interface (WSGI)

Card Puncher Data Processing

About

The Web Server Gateway Interface (WSGI) is a interface that specify how web servers should forward requests to web applications or frameworks.

It's written in the Python programming language.

Example

A basic “Hello World” application in WSGI without the help of a library such as Werkzeug looks like:

def application(environ, start_response):
    start_response('200 OK', [('Content-Type', 'text/plain')])
    return ['Hello World!']

where application is a WSGI application that you can call with the following arguments:

  • environ is an environment dict containing all incoming information.
  • start_response is a callable (a function) that can be used to indicate the start of the response.

Library

Documentation





Discover More
Flask Idea Nodebug
Python Web - Flask

Flask is web framework to create web application. The idea of Flask is to build a good foundation for all applications. Everything else is up to you or extensions. Flask is just not designed for large...
Card Puncher Data Processing
Python Web - Werkzeug (WSGI)

Werkzeug is a HTTP and WSGI library request and response objects are provided to work with them. The request data takes the environ object and allows you to access the data from that environ in a...



Share this page:
Follow us:
Task Runner