I am trying to set up authentication using django-rest-auth and django-allauth. The user exists in the database and I can login to the django admin site. When I try to login using the rest-auth/login/ endpoint posting email/password, I receive a 400 error with the following response:
{
"non_field_errors": [
"Unable to log in with provided credentials."
]
}
I followed the instructions here: http://django-allauth.readthedocs.io/en/latest/configuration.html#configuration
In my settings file I have the following:
ACCOUNT_EMAIL_REQUIRED = True
ACCOUNT_UNIQUE_EMAIL = True
ACCOUNT_AUTHENTICATION_METHOD = 'email'
If I comment out the three lines above and use the same endpoint but add the username it works. It seems to only not work with email only mode.
Thanks for your help!
I had the same issue, resolved by putting the right authentication backends. Here's my settings: