我目前正在使用django-rest-passwordreset软件包,但是当我去重置密码端点DRF浏览器API无效时(软件包文档提到可浏览的API支持可用)。
urlpatterns = [
path('password-reset/', include('django_rest_passwordreset.urls', namespace='password_reset')),
]
有什么设置我必须改变吗?
从setting.py中删除所有默认的身份验证和权限类,然后尝试
REST_FRAMEWORK = {
'DEFAULT_AUTHENTICATION_CLASSES': (
'rest_framework.authentication.BasicAuthentication',
'rest_framework.authentication.SessionAuthentication',
)
}
你把它添加到你的设置,py删除这个BasicAuthentication,SessionAuthentication。如果仍然没有使用浏览图像发布问题