2👍
✅
Throttle key is based on authentication.get_identifier
function.
Default implementation of this function returns a combination of IP address and hostname.
Edit
Other implementations (i.e. BasicAuthentication, ApiKeyAuthentication) returns username of the currently logged user or nouser
string.
2👍
Tomasz is mostly right, but some of the authentication classes have a get_identifier
method that returns the username of the currently logged in user, otherwise ‘nouser’. I plan on standardizing this soon.
- [Django]-How to access model data when overriding Django admin templates?
- [Django]-How to get xml format in Django Rest Framework
- [Django]-Django html2text anchor breaking
- [Django]-How to extend UserCreationForm with fields from UserProfile
Source:stackexchange.com