Rate limiting middleware for django
Python Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
djlimiter
doc
requirements
tests
.coveragerc
.gitignore
.travis.yml
CLASSIFIERS
HISTORY.rst
LICENSE.txt
MANIFEST.in
README.rst
manage.py
push-release.sh
setup.py
tag.sh
versioneer.py

README.rst

djlimiter

travis-ci coveralls pypi license

djlimiter provides rate limiting features to django via a middleware.

Quickstart

Add the rate limiter to your django projects' settings.py and enable a global rate limit for all views in your project:

MIDDLEWARE_CLASSES += ("djlimiter.Limiter",)
RATELIMIT_GLOBAL = "10/second"

If you only want to enable rate limits to certain endpoints, leave out the RATELIMIT_GLOBAL setting and use the decorator approach instead in the respective view function:

@limit("10/second")
def index(request):
   ...

For detailed documentation visit Read the docs