
Security News
MCP Community Begins Work on Official MCP Metaregistry
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
django-simpletwitchauth
Advanced tools
Use this simple module to easily enable authorization in your Django application via Twitch API
| Wanna enable your awesome Django application to register and authenticate user using Twitch profiles? | This application was created especially for your needs
Ensure that Django āsitesā framework
_ is enabled.
Python package:
::
pip install django-simpletwitchauth
settings.py:
~~~~~~~~~~~~
Add ``twitch_auth`` to INSTALLED\_APPS
Add ``twitch_auth.backends.OAuth2Backend`` to AUTHENTICATION\_BACKENDS
Set `Twitch application`_ settings
Example using django-environ:
::
env = environ.Env()
TWITCH_AUTH_CLIENT_ID = env('TWITCH_CLIENT_ID', default='some_client_id')
TWITCH_AUTH_CLIENT_SECRET = env('TWITCH_CLIENT_SECRET', default='some_client_secret')
All available settings:
^^^^^^^^^^^^^^^^^^^^^^^
TWITCH\_AUTH\_SCOPE
'''''''''''''''''''
Defines OAuth2 token scope
Defaults to ``user_read``
TWITCH\_AUTH\_PROTOCOL
''''''''''''''''''''''
Defines protocol that is used to build full authentication callback URI
Defaults to ``http://``
TWITCH\_AUTH\_CLIENT\_ID
''''''''''''''''''''''''
Defines Twitch application client ID
TWITCH\_AUTH\_CLIENT\_SECRET
''''''''''''''''''''''''''''
Defines Twitch application client secret
TWITCH\_AUTH\_REDIRECT\_URI
'''''''''''''''''''''''''''
Defines default redirect URI after successful authentication
Defaults to ``/``
Usage
-----
- Run migrations to create database tables for entities.
- Add somewhere in your templates link to url ``login_twitch``
.. _Django āsitesā framework: https://docs.djangoproject.com/en/1.11/ref/contrib/sites/
.. _Twitch application: https://www.twitch.tv/settings/connections
FAQs
Use this simple module to easily enable authorization in your Django application via Twitch API
We found that django-simpletwitchauth demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Ā It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
Research
Security News
Socket uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
Research
Security News
Malicious npm packages posing as developer tools target macOS Cursor IDE users, stealing credentials and modifying files to gain persistent backdoor access.