Authentication scheme for django rest framework that allow to use token in a url
Project description
drf-url-token-auth
Simple token based authentication using rest_framework. Clients should authenticate by passing the token key in the "?token=" HTTP parameter. The token parametter can be configured.
Quick start
- Add "gitlab_webhook" to INSTALLED_APPS:
INSTALLED_APPS = {
...
"drf_url_token_auth"
}
- Modify rest framework settings:
REST_FRAMEWORK = {
'DEFAULT_AUTHENTICATION_CLASSES': (
'drf_url_token_auth.authentication.UrlTokenAuthentication',
)
}
- Optionally, configure url parameter name (default: token)
DRF_URL_TOKEN_AUTH = {
'PARAM_NAME': 'token'
}
Dev notes: build package: python setup.py sdist install: pip install --user drf-url-token-auth/dist/drf-url-token-auth-01.tar.gz
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
drf-url-token-auth-0.1.tar.gz
(2.1 kB
view hashes)
Built Distribution
Close
Hashes for drf_url_token_auth-0.1-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b548851f7c23a9a7c6dfd7757ac34cb6e257d5717cf21ed003e74cec89359eb1 |
|
MD5 | fdfe03c794e1a4c09e889991f42f0b0b |
|
BLAKE2b-256 | 90226f14b28c8bae5110aef546aa020912b5213e4681247b99700f438731287c |