Stormpath for Django Rest Framework

We use the Django Rest Framework to create an API that supports AngularJS applications. The goal is to use Stormpath to authenticate oauth2 and to store backend authorization information. However, all the examples I found using Stormpath with Django are for Django web pages (not REST APIs) using username and password, not tokens.

How do you integrate Django REST Framework authentication with Stormpath using oauth2?

+4
source share
1 answer

In this case, you will really rely on the Django Rest Framework to support OAuth2, not Stormpath. Stormpath will only provide the User model that DRF uses in the backend - nothing more.

This was the design decision we made to simplify the data model.

I am currently exploring ways to add OAuth2 as a first-class Stormpath function in Django, but currently this is the way down the line.

+3
source

Source: https://habr.com/ru/post/1629021/


All Articles