servant-client-core

Core functionality and class for client function generation for servant APIs http://haskell-servant.readthedocs.org/

Latest on Hackage:0.17

See all snapshots servant-client-core appears in

BSD-3-Clause licensed by Servant Contributors
Maintained by [email protected]

Module documentation for 0.13.0.1

This version can be pinned in stack with:[email protected]:ad2ddf037b3f67f3eb9e7b5620216aa7e87d5810456a29847b5becdffa9b747f,3392

servant-client-core

servant

HTTP-client-agnostic client functions for servant APIs.

This library should mainly be of interest to backend- and combinator-writers.

For backend-writers

If you are creating a new backend, you’ll need to:

  1. Define a RunClient instance for your datatype (call it MyMonad)
  2. Define a ClientLike instance. This will look like:
instance ClientLike (MyMonad a) (MyMonad a) where
  mkClient = id
  1. Re-export the module Servant.Client.Core.Reexport so that your end-users can be blissfully unaware of ‘servant-client-core’, and so each backend-package comes closer to the warm hearth of the drop-in-replacement equivalence class.

For combinator-writers

You’ll need to define a new HasClient instance for your combinator. There are plenty of examples to guide you in the HasClient module.

Changes

The latest version of this document is on GitHub. Changelog for servant package contains significant entries for all core packages.

0.13.0.1

  • Support base-compat-0.10

0.13

  • Streaming endpoint support. (#836)
  • servant Add Servant.API.Modifiers (#873)

0.12

  • First version. Factored out of servant-client all the functionality that was independent of the http-client backend.