title: How to document function-based views parameters?
body: <p>I'm developing a REST API with Django 1.11 and Django REST Framework 3.7. I installed <a href="https://github.com/marcgibbons/django-rest-swagger" rel="noreferrer">Django REST Swagger</a> 2.1 to generate the documentation.</p>
  
  <p>I'm using a function-based view like this:</p>
  
  <pre><code>from rest_framework.decorators import api_view, permission_classes
  
  @api_view(['POST'])
  @permission_classes((permissions.AllowAny,))
  def jwt_auth(request, provider, format=None):
      """
      View description here
      """
      pass
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/GOXD3.png" rel="noreferrer"><img src="https://i.stack.imgur.com/GOXD3.png" alt="Generated documentation by Swagger"></a></p>
  
  <p>As you can see, my view is recognized by Swagger and it has the correct description: "<em>View description here</em>".</p>
  
  <p>However:</p>
  
  <ul>
  <li>You can see the "<em>Description</em>" column is empty for the <code>provider</code> URL parameter.</li>
  <li>The POST parameters are not documented (obviously, because there is no way for Swagger to know them)</li>
  </ul>
  
  <p><strong>How can I write documentation for the URL and POST parameters of a function-based view, as well as the responses?</strong></p>
  
  <p>I tried <a href="http://django-rest-swagger.readthedocs.io/en/stable-0.3.x/yaml.html" rel="noreferrer">YAML Docstrings</a> but it seems it's for the old version (0.3.x) and it doesn't work with version 2.x.</p>