adjutant/stacktask/api/docs.py
adrian-turjak 73e5018c9e Core library requirements update
Rather than cap libraries at older versions, I'm updating the code
to work with the newest libraries and methods.

Now using KeystoneAuth and Keystone Middleware via a specific auth
plugin and setting domain info.

Also fixing a minor bug in "user_store.py" which cropped up due to
issues when updating libraries.

Change-Id: I3e9e2f4ff3b6a1be94857622f171425ce70de969
2016-08-09 12:02:42 +01:00

11 lines
415 B
Python

from rest_framework.decorators import api_view, renderer_classes
from rest_framework import response, schemas
from rest_framework_swagger.renderers import OpenAPIRenderer, SwaggerUIRenderer
@api_view()
@renderer_classes([OpenAPIRenderer, SwaggerUIRenderer])
def docs_view(request):
generator = schemas.SchemaGenerator(title='StackTask API')
return response.Response(generator.get_schema(request=request))