I am a newbie to swagger and i am stuck after doing the following things on an error:
I am using the following dependencies:
"com.iheart" %% "play-swagger" % "0.2.1-PLAY2.5",
"org.webjars" % "swagger-ui" % "2.1.4"
Following are the routes:
![image](https://cloud.githubusercontent.com/assets/17196401/17802393/b06e7f1a-660d-11e6-83af-fa56935c2b6e.png)
Following is the expected response type:
case class Output(response: JsValue)
This is the screenshot of where i am getting struck:
![image](https://cloud.githubusercontent.com/assets/17196401/17802377/a0d4a3f4-660d-11e6-88d5-33788c03a8cc.png)
This is what i get in the auto generated json file(where it gets struck with error : fetching resource list):
{"paths":{"/assets/{file}":{"get":{"tags":["routes"],"parameters":[{"name":"path","type":"string","required":true,"in":"query"},{"name":"file","type":"asset","required":true,"in":"path"}]}},"/docs/swagger.json":{"get":{"tags":["routes"],"summary":"swagger definition","description":"for swagger UI to consume"}},"/client/view":{"get":{"tags":["routes"],"responses":{"200":{"description":"success","schema":{"$ref":"#/definitions/models.Output"}}}}}},"definitions":{"models.Output":{"properties":{"response":{"type":"play.api.libs.json.jsvalue","required":true}},"required":["response"]}},"tags":[{"name":"routes"}]}
and this is my default swagger.json file(which i have created) :
{
"swagger": "2.0",
"info": {
"version": "1.0.0",
"title": "Weather API",
"description": "A sample API that uses a Mashape weather API as an example to demonstrate features in the swagger-2.0 specification",
"termsOfService": "http://helloreverb.com/terms/",
"contact": {
"name": "Tom Johnson",
"email": "[email protected]",
"url": "localhost:9000"
},
"license": {
"name": "MIT",
"url": "http://opensource.org/licenses/MIT"
}
},
"host": "localhost:9000",
"basePath" : "localhost:9000",
"schemes": [
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/text"
]
}