servant-swagger
servant-swagger copied to clipboard
Swagger for Servant
Like definining ToSample in servant-docs. (Actually, I'm not sure what is the relation between servant-swagger and servant-docs, but defining ToSample won't change the default example in servant-swagger)
cf. - https://github.com/commercialhaskell/stackage/commit/1c6c98101710b7301d267b54030d1cf558dd77ce - https://github.com/commercialhaskell/stackage/issues/6485
The [link works](https://github.com/haskell-servant/servant-swagger/blob/master/example) when navigating from https://github.com/haskell-servant/servant-swagger. However it references [nonexistent resource](http://hackage.haskell.org/package/servant-swagger-1.1.7.1/servant-swagger-1.1.7.1/src/example) when navigating from http://hackage.haskell.org/package/servant-swagger.
This will work better after https://github.com/GetShopTV/swagger2/pull/195 has been merged, which will also require some minor changes here. Just opening this to keep track of what's going on upstream.
https://swagger.io/docs/specification/paths-and-operations/ This is dependent on https://github.com/haskell-servant/servant/pull/1378
Suppose this API: ``` haskell type SampleAPI = "sample" :> Get '[JSON, FormUrlEncoded, XML] Sample ``` Should we use a `body` param with Swagger Schema or `formData` params? With swagger...
This is what I've been using: ``` haskell type WithSwagger api = api : ("swagger.json" :> Get '[JSON] Swagger) serveWithSwagger :: forall layout. HasServer layout => Swagger -> Proxy layout...
Currently when installing `servant-swagger` it also pulls in `QuickCheck` and `hspec`. Are there any plans to remove this, or make it configurable via a flag?
We’ve implemented a new handler (for streaming responses) by providing instances of `HasServer`, `HasClient`, `Accept`, and `HasSwagger`. This works reasonably well, but now we've run into an issue where the...