Oleg Grenrus
acbcebc1d3
Fix Show UrlReq
2017-05-15 19:06:06 +03:00
Oleg Grenrus
4ae8b1898f
Merge pull request #740 from stevana/client/include-request-in-failure-response
...
Include the request that failed in FailureResponse.
2017-05-15 12:32:45 +03:00
Stevan Andjelkovic
29c9d85ade
Use BaseUrl and Req instead of Request.
2017-05-05 17:05:55 +02:00
Stevan Andjelkovic
bf9c84eccb
Two failed responses can be equal even though they don't come from
...
the same request.
2017-05-05 15:55:21 +02:00
Stevan Andjelkovic
b8de9c8527
Include the request that failed in FailureResponse.
2017-05-05 15:31:38 +02:00
Edsko de Vries
507f021919
Make sure path components get escaped
...
The derived client for an API containing `Capture` has a bug: it does not
escape characters, so that if the string is "a/b", the URL becomes
`".../a/b/..."` instead of `".../a%2Fb/..."`, causing the corresponding servant
server to return a 404.
This relies on https://github.com/fizruk/http-api-data/pull/47
2017-02-07 16:51:56 +01:00
Oleg Grenrus
6fafaec51a
Change Semigroup (ClientM a) to Alt ClientM
2017-01-20 14:26:26 +02:00
Oleg Grenrus
fdf86b0e15
Add Semigroup instances
2017-01-19 20:11:54 +02:00
Catherine Galkina
aa4b10c9ca
Add comments for GClientLikeP and GClientLikeL classes
2017-01-17 16:29:24 +03:00
Catherine Galkina
9d52cff1bb
Fix ghc-7.8.4 build
2017-01-17 16:29:24 +03:00
Catherine Galkina
01324754da
Update comment in Servant.Client.Generic
2017-01-17 16:29:24 +03:00
Catherine Galkina
5fa99bee93
Expand left-nested APIs by default
2017-01-17 16:29:24 +03:00
Catherine Galkina
06217ace66
Fix typos in examples
2017-01-17 16:29:24 +03:00
Catherine Galkina
682d7ead5c
Update example in Servant.Client.Generic
2017-01-17 16:29:24 +03:00
Catherine Galkina
31e1ceb6d0
Add Servant.Client.Generic module
2017-01-17 16:29:24 +03:00
Oleg Grenrus
5168157757
Make Handler a newtype
2017-01-16 12:18:49 +02:00
Oleg Grenrus
cfaa7a06be
Merge pull request #665 from phadej/client-monad-control
...
Add MonadBaseControl IO ClientM instance
2017-01-16 10:25:35 +02:00
Oleg Grenrus
b548f8df86
Add MonadBaseControl IO ClientM instance
2017-01-16 09:51:39 +02:00
Andres Loeh
bc04d120ec
Allow more flexbility in setting the request body.
...
Rather than hard-coding the `RequestBodyLBS` constructor and be
limited to lazy bytestrings, the new function `setReqBody` just
takes any value of type `RequestBody`.
The old function `setRQBody` has been renamed to `setReqBodyLBS`.
The old name is still available, but deprecated.
The change has the advantage the we can define new servant API
combinators that use streaming request bodies such as for example
constructed by the `streamFile` function in http-client.
The behaviour for the existing `ReqBody` API combinator is
unaffected by this change.
2017-01-12 14:08:50 +01:00
Oleg Grenrus
1abf84feca
servant-client asks for any content-type in Accept contentTypes ne-list
2016-11-10 21:22:00 +02:00
Hamish Mackenzie
49931913c9
Derive MonadThrow and MonadCatch for ClientM
2016-10-27 22:32:41 +13:00
Sönke Hahn
79f53cef3e
servant-client: use base-compat in order to use less CPP
2016-10-17 11:52:40 -04:00
VyacheslavHashov
c0c1f0fa25
Fixed haddocs in correspondence with the change ClientM to ReaderT
2016-10-09 16:19:14 -04:00
Christian Klinger
7a7f7d7cf5
changed ClientM to be a Reader of ClientEnv
2016-09-08 00:17:13 +02:00
Sönke Hahn
b1f143010e
servant-client: fix compilation when building with http-client < 0.4.30
2016-08-14 20:27:50 +02:00
Oleg Grenrus
197ed0548a
Use parseRequest
2016-07-18 14:40:05 +02:00
Jonathan Lange
7fb9a95711
servant-client support for CaptureAll
2016-07-11 14:46:31 +01:00
Sönke Hahn
d45c7c5897
support http-client-0.5
2016-07-09 18:36:00 +02:00
Sönke Hahn
5effdfdbbb
Rename type variables 'layout' and 'sublayout' to 'api'
2016-07-03 22:46:46 +08:00
Julian K. Arni
023368c396
CPP deprecated parseUrl function.
2016-07-03 22:43:52 +08:00
Sönke Hahn
29be5761ce
servant-client: add Eq instance for ServantError
2016-04-21 15:27:08 +08:00
Sönke Hahn
933a2c4445
re-export ClientM
from Servant.Client
.
2016-04-05 17:51:25 +08:00
Alexander Kjeldaas
4f558971d1
Removed FromText references from docs.
2016-04-01 22:56:19 +02:00
mbg
9e1ba9221d
Manager and BaseUrl are now explicit parameters of all client functions, instead of ReaderTs
2016-03-30 22:41:39 +01:00
mbg
316737c16d
Updated documentation in Client.hs to reflect the changes to the client function
2016-03-28 14:56:50 +01:00
mbg
7379b7486a
Moved BaseUrl and Manager parameters from the client function to the Client type as discussed in #428
2016-03-28 14:51:07 +01:00
aaron levin
b3af5a8d95
Move general authentication to Experimental module
...
Removes the UndecidableInstances extension in the module containing the
HasServer instances.
2016-03-09 22:30:34 +01:00
aaron levin
29f8e64e1c
Add Experimental warnings on combinators
2016-03-09 22:30:34 +01:00
aaron levin
23da4879ef
Add general auth support to servant-client
2016-03-09 22:30:34 +01:00
aaron levin
d989d15e4c
Add basic-auth support to servant-client
2016-03-08 23:13:05 +01:00
Sönke Hahn
8ef4d4543b
renaming: Config -> Context
2016-03-07 23:12:24 +08:00
Sönke Hahn
2176fecfda
config: added instances for all interpretations
2016-01-21 17:55:02 +01:00
Sönke Hahn
b20b8d9770
add HasClient instance for HttpVersion
2016-01-18 12:28:29 +01:00
Julian K. Arni
f1b6603c52
Review fixes
2016-01-08 18:03:28 +01:00
Julian K. Arni
783a849c67
Make NoContent still take an arg.
...
For consistency with other combinators, and to make using headers
easier.
2016-01-07 14:30:08 +01:00
Julian K. Arni
cda8bcf17c
Simplify verb combinators.
...
Create a single 'Verb' combinator with parameters for status code and
method. Make existing combinators type synonyms of 'Verb'.
2016-01-07 13:47:07 +01:00
Julian K. Arni
79d4f944a4
less OverlappingInstances noise
2016-01-04 13:09:11 -05:00
Julian K. Arni
afc76b8f6c
Remove MatrixParam.
...
In servant, servant-server, and servant-client.
2015-10-13 21:37:07 +02:00
Julian K. Arni
c2a06bc090
More generous acceptable status codes for servant-client
2015-10-11 21:12:05 +02:00
Alp Mestanogullari
444a72eac6
Merge pull request #245 from arianvp/servant-client-hspec-discover-fix
...
Fix servant-client tests to properly use hspec-discover.
2015-10-10 02:40:24 +02:00