flask-restful-swagger icon indicating copy to clipboard operation
flask-restful-swagger copied to clipboard

how can I add two resource in one page?

Open aibati2008 opened this issue 8 years ago • 1 comments

I add the API resource like below( omit some code), but I can only open the API1 link and see the two APIs under one resource. Please guide..

image

api1 = swagger.docs(Api(app), apiVersion='0.1', basePath='http://10.24.32.5:10001', resourcePath='/', produces=["application/json", "text/html"], api_spec_url='/api1', description='extract Top3 keywords from text') api2 = swagger.docs(Api(app), apiVersion='0.1', basePath='http://10.24.32.5:10001', resourcePath='/', produces=["application/json", "text/html"], api_spec_url='/api2', description='search related news') ... api1.add_resource(KeywordModel, '/docs/api1') api2.add_resource(SearchModel, '/docs/test')

aibati2008 avatar May 18 '16 03:05 aibati2008

Hi @aibati2008

There is a similar open issue here: https://github.com/rantav/flask-restful-swagger/issues/35

See the comment made by lounagen.

kevwo avatar Jul 02 '16 06:07 kevwo