skip to navigation
skip to content

Not Logged In

Flask-Heroku-Auth 0.0.5

Flask Based Heroku Authentication.


A set of Flask Route decorators to enable either Session-Based Authentication via Heroku’s OAuth mechanism, or Basic Stateless Authentication via Heroku’s API Key facilities.


pip install flask-heroku-auth


To enable regex routes within your application

from flask import Flask
from flask_heroku_auth import HerokuAuth

app = Flask(__name__)


from flask import Flask
from flask_heroku_auth import HerokuAuth

auth = HerokuAuth()

def create_app():
    app = Flask(__name__)
    return app

From here, it is a matter of decorating the appropriate routes.

For example, the following would implement authentication via the Heroku OAuth facility

def index():
    return "Ok"

On the other hand, you may wish to authenticate via the Heroku API Key facility. In this case, the credentials are sent through with every request as an ‘Authorization’ header

def index():
    return "Ok"

You can also restrict access to a Heroku user who has an email address.

def index():
    return "Ok"


0.0.5 (14/11/2012)

  • Introduced a template filter for the current user.

0.0.4 (1/11/2012)

  • Minor Tweaks.

0.0.3 (16/09/2012)

  • User field is now not required for sudo operations.

0.0.2 (24/08/2012)

  • Checking for ‘herokai_only’ now occurs only if the user is logged in.

0.0.1 (24/08/2012)

  • Conception
  • Initial Commit of Package to GitHub.
File Type Py Version Uploaded on Size
Flask-Heroku-Auth-0.0.5.tar.gz (md5) Source 2013-11-13 5KB
  • Downloads (All Versions):
  • 15 downloads in the last day
  • 106 downloads in the last week
  • 501 downloads in the last month