On Sep 18, 2016 12:56 PM, "sabari rangan" <sabari....@gmail.com> wrote:
>
> i am using django.contrib.auth module for authentication system in my django rest framework app, when i post data i couldn't able to authenticate the user it return 403 response code . but during get request it works fine. i have attached the sessionid in cookies in both above. kindly help me with this i got stuck.
>
Can you post the relevant Django views for the GET and POST requests?
-James
@api_view(['POST'])when i print the content of response object it shows
def example(request):
return Response({'usernmae': request.user.username},status=status.HTTP_200_OK)