Serve Swagger docs via middleware

This commit is contained in:
domaindrivendev
2016-02-03 23:41:31 -08:00
parent 58691903fb
commit df4b9c80c9
12 changed files with 54 additions and 89 deletions

View File

@@ -1,6 +1,9 @@
SwaggerRails.configure do |c|
# Specify the API version and hence discovery_url (e.g. swagger/v1/swagger.json)
# that will be used to power the embedded swagger-ui
c.target_api_version = 'v1'
# List the names and paths of Swagger
# documents you'd like to expose in your swagger-ui
c.swagger_docs = {
'API V1' => '/swagger/v1/swagger.json',
'API V2' => '/swagger/v2/swagger.json'
}
end