Skip to content

Instantly share code, notes, and snippets.

@maxpoletaev
Created June 17, 2018 16:47
Show Gist options
  • Save maxpoletaev/7daeb6b0f53e0de4c7cf1f6b6a3916bb to your computer and use it in GitHub Desktop.
Save maxpoletaev/7daeb6b0f53e0de4c7cf1f6b6a3916bb to your computer and use it in GitHub Desktop.
# Rest Framework
# https://www.django-rest-framework.org/api-guide/settings/
REST_FRAMEWORK = {
'DEFAULT_FILTER_BACKENDS': ('django_filters.rest_framework.DjangoFilterBackend',),
'DEFAULT_RENDERER_CLASSES': ('rest_framework.renderers.JSONRenderer',),
'DEFAULT_PARSER_CLASSES': ('rest_framework.parsers.JSONParser',),
'EXCEPTION_HANDLER': 'exams.utils.error_handler.api_exception_handler',
'DEFAULT_AUTHENTICATION_CLASSES': (),
'DEFAULT_METADATA_CLASS': None,
'NON_FIELD_ERRORS_KEY': '__all__',
'UNAUTHENTICATED_USER': None,
'PAGE_SIZE': 100,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment