We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have a view that returns a httpresponse with a file.
def retrieve_file(self,request,*args,**kwargs): media =self.get_object() response = HttpResponse() response['Content-Type'] = media.mime_type response['X-Accel-Redirect'] = media.file.path response['Content-Disposition'] = f'form-data; name="{media.filename}";filename="{media.filename}"' return response
As this is not using a serializer, and auto_schema does not support httpresponses, how do I generate a schema for this?
Kind regards
The text was updated successfully, but these errors were encountered:
This is not possible. Use a serializer or annotate with response_body or manual_parameters.
response_body
manual_parameters
Sorry, something went wrong.
No branches or pull requests
I have a view that returns a httpresponse with a file.
As this is not using a serializer, and auto_schema does not support httpresponses, how do I generate a schema for this?
Kind regards
The text was updated successfully, but these errors were encountered: