Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Nov 17, 2020. It is now read-only.

menecio/django-api-bouncer

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

97 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

API Bouncer

build-status-image coverage-image pypi-version

API Bouncer is a simple Django app to provide an API Gateway for micro-services.

It's heavily inspired by Kong

Requirements

  • Python (3.5, 3.6)
  • Django (1.10, 1.11)
  • Django Rest Framework (3.6)
  • PostgreSQL (9.4+)
  • psycopg2 (2.5.4+)

Quick start

Add "api_bouncer" to your INSTALLED_APPS setting like this:

    INSTALLED_APPS = [
        # all other Django apss you have...
        'api_bouncer',
    ]

Activate the key-auth plugin by adding the middleware on your settings.py:

    MIDDLEWARE = [
        # all other middleware...
        'api_bouncer.middleware.bouncer.BouncerMiddleware',  # required
        'api_bouncer.middleware.key_auth.KeyAuthMiddleware',
    ]

Important! Note that you need to include BouncerMiddleware before the rest of plugin middleware. Otherwise it will not work.

Include the api_bouncer URLconf in your project urls.py like this:

    url(r'^', include('api_bouncer.urls', namespace='api_bouncer')),

Run python manage.py migrate to create the api_bouncer models.

Available plugins

Authenticacion

  • Key authentication: Add key authentication to your API

Security

  • ACL: Control which consumers have access to your API
  • IP restriction: Blacklist or whilelist IPs that can access your API

Traffic Control

  • Request termination: Terminate all request with a specific response.

Documentation

Documentation can be found in the docs directory or here

Packages

No packages published

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.