Re: Implementing Microsoft Single Sign On (0365 SSO)

2023-09-21 Thread Stats Student
On Tue, Sep 19, 2023 at 9:40 AM Django REST framework < adebusolay...@gmail.com> wrote: > Hello, > I want to implement Microsoft single sign-on in my Django rest framework > project as well as Google sign-on. Please I need help with it as I have not > been able to find good resources, especially

django-rest-framework-social-oauth2 & Client secret

2021-04-19 Thread Stats Student
Hi, I am working on setting up django-rest-framework-social-oauth2 and I am able to get the tests in the official README to run. However, the few examples in the docs require the Client Secret in the URL. As I don't want to publish the Client Secret in an SPA, I am wondering if there is another

ModelViewSet with additional methods

2021-03-07 Thread Stats Student
Hi, I have a ModelViewSet implementation which is routed through the DefaultRouter and everything works fine. router = routers.DefaultRouter() router.register(r'item', views.ItemViewSet, 'item') class ItemViewSet(viewsets.ModelViewSet): serializer_class = ItemSerializer I would now like to

DRF JWT, accessing the token

2021-01-06 Thread Stats Student
Hi, I am using DRF JWT ( https://jpadilla.github.io/django-rest-framework-jwt/) and as part of the authentication process (receiving / verifying the token), I also need to send the token to another endpoint (provided by the authentication service) to obtain additional user information. I have a

Re: Updating foreign key

2021-01-06 Thread Stats Student
. Use a public ID of some >> sort, you can use a UUID or generate your own complex ID. >> There should be no reason you should not be able to access a record with >> a company name. There is nothing in Django or DRF that would prevent that. >> You must have something in your code

Re: Updating foreign key

2021-01-06 Thread Stats Student
be able to access a record with a > company name. There is nothing in Django or DRF that would prevent that. > You must have something in your code that is preventing it. > > ~Carl > > On Sun, Jan 3, 2021 at 2:35 AM Stats Student > wrote: > >> Hi, I have a basic on

Updating foreign key

2021-01-02 Thread Stats Student
Hi, I have a basic one-to-many foreign key relationship (each product has a company associated with it, one company can have multiple products). I do not specify an explicit serializer relation for this field (e.g. PrimaryKeyRelatedField) so it's using the FK definition from the models ( company =

Re: Returning subset of fields after POST

2020-09-24 Thread Stats Student
heck out >> https://github.com/yezyilomo/django-restql >> >> On Fri, 18 Sep 2020 at 02:10, Stats Student wrote: >>> >>> Hi, how do I go about returning only a subset of fields that are in my >>> Serializer? Or similarly, how can I exclude certain fields

Returning subset of fields after POST

2020-09-17 Thread Stats Student
Hi, how do I go about returning only a subset of fields that are in my Serializer? Or similarly, how can I exclude certain fields from being included in the JSON that DRF sends back after a successful POST? TIA -- You received this message because you are subscribed to the Google Groups

Return existing from generics.CreateAPIView

2020-09-04 Thread Stats Student
Hi, I have a view for creating new objects which inherits from generics.CreateAPIView. Inside I override perform_create() like so: u1 = get_object_or_404 (Usr.objects, login = self.request.user) serialize.save(usr = u1) I'd like to add logic to check whether the object to be created is already