Api methods free of Token authentication in Django -
so have implemented token authentication system on django web server following guide tutorial: http://cheng.logdown.com/posts/2015/10/27/how-to-use-django-rest-frameworks-token-based-authentication token needed in every single api call otherwise unauthorised error. need have api calls free, meaning anyone, not registered user(who have token of course) can call it. how done?
looking @ article have set authentication scheme on global bases in settings.
if want have authentication few select views, must not set globally per view explained here:
http://www.django-rest-framework.org/api-guide/authentication/#setting-the-authentication-scheme
class exampleview(apiview): authentication_classes = (sessionauthentication, basicauthentication) permission_classes = (isauthenticated,)
Comments
Post a Comment