soap-0.2.3.6: SOAP client tools

Safe Haskell | None
Language | Haskell98

Network.SOAP.Transport.HTTP

Contents

- Initialization
- Making a request
- Processing a response
- Raw transport function
- Deprecated

Synopsis

- initTransportWithM :: ManagerSettings -> EndpointURL -> RequestProc -> BodyProc -> IO Transport
- type EndpointURL = String
- type RequestProc = Request -> IO Request
- printRequest :: RequestProc
- type BodyProc = ByteString -> IO ByteString
- printBody :: BodyProc
- runQueryM :: Manager -> EndpointURL -> RequestProc -> BodyProc -> Transport
- initTransport :: EndpointURL -> RequestP -> BodyP -> IO Transport
- initTransport_ :: EndpointURL -> IO Transport
- initTransportWith :: ManagerSettings -> EndpointURL -> RequestP -> BodyP -> IO Transport
- confTransport :: Text -> Config -> IO Transport
- confTransportWith :: ManagerSettings -> Text -> Config -> RequestP -> BodyP -> IO Transport
- type RequestP = Request -> Request
- traceRequest :: RequestP
- type BodyP = ByteString -> ByteString
- iconv :: EncodingName -> BodyP
- traceBody :: BodyP
- runQuery :: Manager -> EndpointURL -> RequestP -> BodyP -> Transport

# Initialization

initTransportWithM :: ManagerSettings -> EndpointURL -> RequestProc -> BodyProc -> IO Transport Source #

Create a http-client transport using manager settings (for plugging tls etc.).

type EndpointURL = String Source #

Web service URL. Configured at initialization, but you can tweak it dynamically with a request processor.

# Making a request

type RequestProc = Request -> IO Request Source #

Update request record after defaults and method-specific fields are set.

printRequest :: RequestProc Source #

# Processing a response

type BodyProc = ByteString -> IO ByteString Source #

Process response body to make it a nice UTF8-encoded XML document.

printBody :: BodyProc Source #

# Raw transport function

runQueryM :: Manager -> EndpointURL -> RequestProc -> BodyProc -> Transport Source #

Render document, submit it as a POST request and retrieve a body.

# Deprecated

initTransport :: EndpointURL -> RequestP -> BodyP -> IO Transport Source #

Create a http-client transport. Use identity transformers if you don't need any special treatment.

initTransport_ :: EndpointURL -> IO Transport Source #

Create a transport without any request and body processing.

initTransportWith :: ManagerSettings -> EndpointURL -> RequestP -> BodyP -> IO Transport Source #

Deprecated: Processors were lifted to IO.

confTransport :: Text -> Config -> IO Transport Source #

Load common transport parameters from a configurator file.

    soap {
      url = "https://vendor.tld/service/"
      trace = true
      timeout = 15
    }

Only url field is required.

    import Data.Configurator (load, Worth(Required))
    main = do
        transport <- confTransport "soap" =<< load [Required "etc/example.conf"]

confTransportWith :: ManagerSettings -> Text -> Config -> RequestP -> BodyP -> IO Transport Source #

A more extensible transport parameter loader.

type RequestP = Request -> Request Source #

Deprecated: Processors were lifted to IO.

traceRequest :: RequestP Source #

Deprecated: Processors were lifted to IO.

Show a debug dump of a request body.

type BodyP = ByteString -> ByteString Source #

Deprecated: Processors were lifted to IO.

iconv :: EncodingName -> BodyP Source #

Create an IConv-based processor.

traceBody :: BodyP Source #

Deprecated: Processors were lifted to IO.

Show a debug dump of a response body.

runQuery :: Manager -> EndpointURL -> RequestP -> BodyP -> Transport Source #

Deprecated: Processors were lifted to IO.