I am using django-rest-framwork and django-rest-swagger.
The problem is that I'm fetching data directly from the body of the request:
def put(self, request, format=None):
"""
This text is the description for this API
username -- username
password -- password
"""
username = request.DATA['username']
password = request.DATA['password']
but when I try the request from the swagger-ui I can't specify the "parameter type" (it's by default query and can't find a way to change it from the docstring)
I have managed to get around my problem by changing some line in the function build_query_params_from_docstring from the file "introspectors.py" but I was wondering if there is another way to do it.