@@ -89,9 +89,19 @@ instance (HasClient a, HasClient b) => HasClient (a :<|> b) where
8989 clientWithRoute (Proxy :: Proxy a) req :<|>
9090 clientWithRoute (Proxy :: Proxy b) req
9191
92−-- | TODO docs
92+-- | Singleton type representing a client for an empty API.
9393data EmptyAPIClient = EmptyAPIClient
9494
95+-- | The client for 'EmptyAPI' is simply 'EmptyAPIClient'.
96+--
97+-- > type MyAPI = "books" :> Get '[JSON] [Book] -- GET /books
98+-- > :<|> "nothing" :> EmptyAPI
99+-- >
100+-- > myApi :: Proxy MyApi
101+-- > myApi = Proxy
102+-- >
103+-- > getAllBooks :: ClientM [Book]
104+-- > (getAllBooks :<|> EmptyAPIClient) = client myApi
95105instance HasClient EmptyAPI where
96106 type Client EmptyAPI = EmptyAPIClient
97107 clientWithRoute Proxy _ = EmptyAPIClient