flasgger / flasgger

Easy OpenAPI specs and Swagger UI for your Flask API

Home Page:http://flasgger.pythonanywhere.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Using `current_app` instead of `self.app`.

phawks-coviance opened this issue · comments

I am trying to generate OpenAPI docs for a subset of the endpoints in my app. To do this, I am creating a second Flask instance with only the endpoints I want to document, and then passing that instance to Swagger. However, this does not work, because flasgger is calling Flask.current_app instead of using the app that I pass in to add routes to the documentation.

Is there any way around this? Can I force flasgger to use the app that I pass in, or tell an instance of Swagger to only document a subset of my endpoints?