Re: DRF and React - request.user is "Anonymous user"

2022-09-20 Thread Deep Chirag
yes On Tue, Sep 20, 2022 at 9:49 AM Jackson Patrick wrote: > Do i need to pass token in headers? > > On Tue, 20 Sep, 2022, 9:44 am Mohammad Ehsan Ansari, > wrote: > >> make sure you have listed auth as jwt and added permission class for >> authentication >> >> On Monday, 12 September 2022 at 09

Re: DRF and React - request.user is "Anonymous user"

2022-09-19 Thread Mohammad Ehsan Ansari
yes you need On Tue, 20 Sept 2022 at 09:49, Jackson Patrick wrote: > Do i need to pass token in headers? > > On Tue, 20 Sep, 2022, 9:44 am Mohammad Ehsan Ansari, > wrote: > >> make sure you have listed auth as jwt and added permission class for >> authentication >> >> On Monday, 12 September 20

Re: DRF and React - request.user is "Anonymous user"

2022-09-19 Thread Jackson Patrick
Do i need to pass token in headers? On Tue, 20 Sep, 2022, 9:44 am Mohammad Ehsan Ansari, wrote: > make sure you have listed auth as jwt and added permission class for > authentication > > On Monday, 12 September 2022 at 09:52:22 UTC+5:30 jacks...@gmail.com > wrote: > >> I have used simple JWT fo

Re: DRF and React - request.user is "Anonymous user"

2022-09-19 Thread Mohammad Ehsan Ansari
make sure you have listed auth as jwt and added permission class for authentication On Monday, 12 September 2022 at 09:52:22 UTC+5:30 jacks...@gmail.com wrote: > I have used simple JWT for authentication and i have successfully logged > in and am getting tokens also. But when i do a request.us

DRF and React - request.user is "Anonymous user"

2022-09-11 Thread Jackson Patrick
I have used simple JWT for authentication and i have successfully logged in and am getting tokens also. But when i do a request.user in backend i get "Annonymous user". Tried passing Authorization header in axios post in FE REACT but it throws error. Am setting both refresh and access in a state va