In tastypie-swagger, what should be the value for TASTYPIE_SWAGGER_API_MODULE in the installation file?

In tastypie-swagger , what should be the value of TASTYPIE_SWAGGER_API_MODULE in the settings file?

+4
source share
2 answers

From django-tastypie-swagger :

Define TASTYPIE_SWAGGER_API_MODULE in the settings. This should be the python path to your tastypie.api.Api instance:

 TASTYPIE_SWAGGER_API_MODULE = 'mainsite.urls.api' 
+2
source

In my case, I called my api instance a little different.

In ProjectName/urls.py I have:

 ... v1_api = Api(api_name='v1') ... 

which means I needed to put this in settings.py :

 TASTYPIE_SWAGGER_API_MODULE = 'ProjectName.urls.v1_api' 
0
source

All Articles