Is there any way to get Django Rest Framework's Token Auth scheme working with a websocket connection (Channels)? I'm essentially looking to authenticate the user in the same way I do my Rest API, by passing the authorization Token in the header of the request. Right now I get a 503, but using the http session decorator I can get it to work when logged in through the Browsable API.
Asked
Active
Viewed 1,294 times
4
-
See this issue in the Django Channels repo: https://github.com/django/channels/issues/510 and this Gist posted by a Github user there: https://gist.github.com/leonardoo/9574251b3c7eefccd84fc38905110ce4. I haven't been able to get this working so far, and am extremely interested in a good solution to this problem too. – ergusto May 30 '17 at 18:11
-
See this other StackOverFlow [post](https://stackoverflow.com/q/43392889/11729954). I hope it gets you somewhere – Beast Jul 01 '22 at 12:12