I hit the same problem and since then there has been the addition of noHeader, see below;
https://hackage.haskell.org/package/servant-0.9.1.1/docs/Servant-API-ResponseHeaders.html#v:noHeader
You may need to upgrade to get it.
n
On Thursday, 20 October 2016 15:35:29 UTC+1, ruslan yurov wrote:
Hi all)
I'm using Servant (very good library :-) ) and it is interesting for me to know is there any way to have header optional?
type GetNames = "names" :> Get '[JSON] (Maybe(Headers '[Header "smth" String]) [Name]) or
type GetNames = "names" :> Get '[JSON] (Headers '[Maybe(Header "smth" String)] [Name])
--