<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span class="hs-comment">{-
   OpenAPI Petstore

   This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \&quot; \\

   OpenAPI Version: 3.0.1
   OpenAPI Petstore API version: 1.0.0
   Generated by OpenAPI Generator (https://openapi-generator.tech)
-}</span><span>
</span><span id="line-10"></span><span>
</span><span id="line-11"></span><span class="annot"><span class="hs-comment">{-|
Module : OpenAPIPetstore.Client
-}</span></span><span>
</span><span id="line-14"></span><span>
</span><span id="line-15"></span><span class="hs-pragma">{-# LANGUAGE OverloadedStrings #-}</span><span>
</span><span id="line-16"></span><span class="hs-pragma">{-# LANGUAGE RankNTypes #-}</span><span>
</span><span id="line-17"></span><span class="hs-pragma">{-# LANGUAGE RecordWildCards #-}</span><span>
</span><span id="line-18"></span><span class="hs-pragma">{-# LANGUAGE FlexibleContexts #-}</span><span>
</span><span id="line-19"></span><span class="hs-pragma">{-# LANGUAGE ScopedTypeVariables #-}</span><span>
</span><span id="line-20"></span><span class="hs-pragma">{-# LANGUAGE DeriveFunctor #-}</span><span>
</span><span id="line-21"></span><span class="hs-pragma">{-# LANGUAGE DeriveFoldable #-}</span><span>
</span><span id="line-22"></span><span class="hs-pragma">{-# LANGUAGE DeriveTraversable #-}</span><span>
</span><span id="line-23"></span><span class="hs-pragma">{-# OPTIONS_GHC -fno-warn-unused-binds -fno-warn-unused-imports #-}</span><span>
</span><span id="line-24"></span><span>
</span><span id="line-25"></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">OpenAPIPetstore.Client</span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-26"></span><span>
</span><span id="line-27"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html"><span class="hs-identifier">OpenAPIPetstore.Core</span></a></span><span>
</span><span id="line-28"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Logging.html"><span class="hs-identifier">OpenAPIPetstore.Logging</span></a></span><span>
</span><span id="line-29"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html"><span class="hs-identifier">OpenAPIPetstore.MimeTypes</span></a></span><span>
</span><span id="line-30"></span><span>
</span><span id="line-31"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Control.Exception.Safe</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">E</span></span><span>
</span><span id="line-32"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Control.Monad.IO.Class</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">P</span></span><span>
</span><span id="line-33"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Control.Monad</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">P</span></span><span>
</span><span id="line-34"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.Aeson.Types</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">A</span></span><span>
</span><span id="line-35"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.ByteString</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">B</span></span><span>
</span><span id="line-36"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.ByteString.Char8</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">BC</span></span><span>
</span><span id="line-37"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.ByteString.Lazy</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">BL</span></span><span>
</span><span id="line-38"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.ByteString.Lazy.Char8</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">BCL</span></span><span>
</span><span id="line-39"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.Proxy</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">P</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier">Proxy</span></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-40"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.Text</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">T</span></span><span>
</span><span id="line-41"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Data.Text.Encoding</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">T</span></span><span>
</span><span id="line-42"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Network.HTTP.Client</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">NH</span></span><span>
</span><span id="line-43"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Network.HTTP.Client.MultipartFormData</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">NH</span></span><span>
</span><span id="line-44"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Network.HTTP.Types</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">NH</span></span><span>
</span><span id="line-45"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Web.FormUrlEncoded</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">WH</span></span><span>
</span><span id="line-46"></span><span class="hs-keyword">import</span><span> </span><span class="hs-keyword">qualified</span><span> </span><span class="annot"><span class="hs-identifier">Web.HttpApiData</span></span><span> </span><span class="hs-keyword">as</span><span> </span><span class="annot"><span class="hs-identifier">WH</span></span><span>
</span><span id="line-47"></span><span>
</span><span id="line-48"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><span class="hs-identifier">Data.Function</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-operator">(&amp;)</span></span><span class="hs-special">)</span><span>
</span><span id="line-49"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><span class="hs-identifier">Data.Monoid</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-operator">(&lt;&gt;)</span></span><span class="hs-special">)</span><span>
</span><span id="line-50"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><span class="hs-identifier">Data.Text</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier">Text</span></span><span class="hs-special">)</span><span>
</span><span id="line-51"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><span class="hs-identifier">GHC.Exts</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier">IsString</span></span><span class="hs-special">(</span><span class="hs-glyph">..</span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-52"></span><span>
</span><span id="line-53"></span><span class="annot"><span class="hs-comment">-- * Dispatch</span></span><span>
</span><span id="line-54"></span><span>
</span><span id="line-55"></span><span class="annot"><span class="hs-comment">-- ** Lbs</span></span><span>
</span><span id="line-56"></span><span>
</span><span id="line-57"></span><span class="annot"><span class="hs-comment">-- | send a request returning the raw http response</span></span><span>
</span><span id="line-58"></span><span id="local-6989586621679157121"><span id="local-6989586621679157122"><span id="local-6989586621679157124"><span id="local-6989586621679157128"><span class="annot"><a href="OpenAPIPetstore.Client.html#dispatchLbs"><span class="hs-identifier hs-type">dispatchLbs</span></a></span><span>
</span><span id="line-59"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#Produces"><span class="hs-identifier hs-type">Produces</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157121"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157122"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157124"><span class="hs-identifier hs-type">contentType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-60"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Manager</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http-client Connection manager</span></span><span>
</span><span id="line-61"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-62"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreRequest"><span class="hs-identifier hs-type">OpenAPIPetstoreRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157121"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157124"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157128"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157122"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ request</span></span><span>
</span><span id="line-63"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">NH.Response</span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">BCL.ByteString</span></span><span class="hs-special">)</span></span></span></span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ response</span></span><span>
</span><span id="line-64"></span><span id="dispatchLbs"><span class="annot"><span class="annottext">dispatchLbs :: forall req accept contentType res.
(Produces req accept, MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchLbs"><span class="hs-identifier hs-var hs-var">dispatchLbs</span></a></span></span><span> </span><span id="local-6989586621679157402"><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157402"><span class="hs-identifier hs-var">manager</span></a></span></span><span> </span><span id="local-6989586621679157403"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157403"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span id="local-6989586621679157404"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157404"><span class="hs-identifier hs-var">request</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-65"></span><span>  </span><span id="local-6989586621679157405"><span class="annot"><span class="annottext">InitRequest req contentType res accept
</span><a href="#local-6989586621679157405"><span class="hs-identifier hs-var">initReq</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (InitRequest req contentType res accept)
forall accept contentType req res.
(MimeType accept, MimeType contentType) =&gt;
OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (InitRequest req contentType res accept)
</span><a href="OpenAPIPetstore.Client.html#_toInitRequest"><span class="hs-identifier hs-var">_toInitRequest</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157403"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157404"><span class="hs-identifier hs-var">request</span></a></span><span>
</span><span id="line-66"></span><span>  </span><span class="annot"><span class="annottext">Manager
-&gt; OpenAPIPetstoreConfig
-&gt; InitRequest req contentType res accept
-&gt; IO (Response ByteString)
forall req contentType res accept.
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; InitRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchInitUnsafe"><span class="hs-identifier hs-var">dispatchInitUnsafe</span></a></span><span> </span><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157402"><span class="hs-identifier hs-var">manager</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157403"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">InitRequest req contentType res accept
</span><a href="#local-6989586621679157405"><span class="hs-identifier hs-var">initReq</span></a></span><span>
</span><span id="line-67"></span><span>
</span><span id="line-68"></span><span class="annot"><span class="hs-comment">-- ** Mime</span></span><span>
</span><span id="line-69"></span><span>
</span><span id="line-70"></span><span class="annot"><span class="hs-comment">-- | pair of decoded http body and http response</span></span><span>
</span><span id="line-71"></span><span class="hs-keyword">data</span><span> </span><span id="MimeResult"><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeResult"><span class="hs-identifier hs-var">MimeResult</span></a></span></span><span> </span><span id="local-6989586621679157147"><span class="annot"><a href="#local-6989586621679157147"><span class="hs-identifier hs-type">res</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-72"></span><span>  </span><span id="MimeResult"><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeResult"><span class="hs-identifier hs-var">MimeResult</span></a></span></span><span> </span><span class="hs-special">{</span><span> </span><span id="mimeResult"><span class="annot"><span class="annottext">forall res. MimeResult res -&gt; Either MimeError res
</span><a href="OpenAPIPetstore.Client.html#mimeResult"><span class="hs-identifier hs-var hs-var">mimeResult</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Either</span></span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-type">MimeError</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157147"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ decoded http body</span></span><span>
</span><span id="line-73"></span><span>             </span><span class="hs-special">,</span><span> </span><span id="mimeResultResponse"><span class="annot"><span class="annottext">forall res. MimeResult res -&gt; Response ByteString
</span><a href="OpenAPIPetstore.Client.html#mimeResultResponse"><span class="hs-identifier hs-var hs-var">mimeResultResponse</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Response</span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">BCL.ByteString</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http response</span></span><span>
</span><span id="line-74"></span><span>             </span><span class="hs-special">}</span><span>
</span><span id="line-75"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679157413"><span id="local-6989586621679157423"><span id="local-6989586621679157427"><span class="annot"><span class="annottext">Int -&gt; MimeResult res -&gt; ShowS
[MimeResult res] -&gt; ShowS
MimeResult res -&gt; String
(Int -&gt; MimeResult res -&gt; ShowS)
-&gt; (MimeResult res -&gt; String)
-&gt; ([MimeResult res] -&gt; ShowS)
-&gt; Show (MimeResult res)
forall res. Show res =&gt; Int -&gt; MimeResult res -&gt; ShowS
forall res. Show res =&gt; [MimeResult res] -&gt; ShowS
forall res. Show res =&gt; MimeResult res -&gt; String
forall a.
(Int -&gt; a -&gt; ShowS) -&gt; (a -&gt; String) -&gt; ([a] -&gt; ShowS) -&gt; Show a
$cshowsPrec :: forall res. Show res =&gt; Int -&gt; MimeResult res -&gt; ShowS
showsPrec :: Int -&gt; MimeResult res -&gt; ShowS
$cshow :: forall res. Show res =&gt; MimeResult res -&gt; String
show :: MimeResult res -&gt; String
$cshowList :: forall res. Show res =&gt; [MimeResult res] -&gt; ShowS
showList :: [MimeResult res] -&gt; ShowS
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679157433"><span id="local-6989586621679157437"><span class="annot"><span class="annottext">(forall a b. (a -&gt; b) -&gt; MimeResult a -&gt; MimeResult b)
-&gt; (forall a b. a -&gt; MimeResult b -&gt; MimeResult a)
-&gt; Functor MimeResult
forall a b. a -&gt; MimeResult b -&gt; MimeResult a
forall a b. (a -&gt; b) -&gt; MimeResult a -&gt; MimeResult b
forall (f :: * -&gt; *).
(forall a b. (a -&gt; b) -&gt; f a -&gt; f b)
-&gt; (forall a b. a -&gt; f b -&gt; f a) -&gt; Functor f
$cfmap :: forall a b. (a -&gt; b) -&gt; MimeResult a -&gt; MimeResult b
fmap :: forall a b. (a -&gt; b) -&gt; MimeResult a -&gt; MimeResult b
$c&lt;$ :: forall a b. a -&gt; MimeResult b -&gt; MimeResult a
&lt;$ :: forall a b. a -&gt; MimeResult b -&gt; MimeResult a
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Functor</span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679157442"><span id="local-6989586621679157448"><span id="local-6989586621679157454"><span id="local-6989586621679157459"><span id="local-6989586621679157462"><span id="local-6989586621679157465"><span id="local-6989586621679157468"><span id="local-6989586621679157471"><span id="local-6989586621679157474"><span id="local-6989586621679157477"><span id="local-6989586621679157480"><span id="local-6989586621679157483"><span id="local-6989586621679157486"><span id="local-6989586621679157491"><span id="local-6989586621679157496"><span id="local-6989586621679157501"><span id="local-6989586621679157506"><span class="annot"><span class="annottext">(forall m. Monoid m =&gt; MimeResult m -&gt; m)
-&gt; (forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m)
-&gt; (forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m)
-&gt; (forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b)
-&gt; (forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b)
-&gt; (forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b)
-&gt; (forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b)
-&gt; (forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a)
-&gt; (forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a)
-&gt; (forall a. MimeResult a -&gt; [a])
-&gt; (forall a. MimeResult a -&gt; Bool)
-&gt; (forall a. MimeResult a -&gt; Int)
-&gt; (forall a. Eq a =&gt; a -&gt; MimeResult a -&gt; Bool)
-&gt; (forall a. Ord a =&gt; MimeResult a -&gt; a)
-&gt; (forall a. Ord a =&gt; MimeResult a -&gt; a)
-&gt; (forall a. Num a =&gt; MimeResult a -&gt; a)
-&gt; (forall a. Num a =&gt; MimeResult a -&gt; a)
-&gt; Foldable MimeResult
forall a. Eq a =&gt; a -&gt; MimeResult a -&gt; Bool
forall a. Num a =&gt; MimeResult a -&gt; a
forall a. Ord a =&gt; MimeResult a -&gt; a
forall m. Monoid m =&gt; MimeResult m -&gt; m
forall a. MimeResult a -&gt; Bool
forall a. MimeResult a -&gt; Int
forall a. MimeResult a -&gt; [a]
forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a
forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m
forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
forall (t :: * -&gt; *).
(forall m. Monoid m =&gt; t m -&gt; m)
-&gt; (forall m a. Monoid m =&gt; (a -&gt; m) -&gt; t a -&gt; m)
-&gt; (forall m a. Monoid m =&gt; (a -&gt; m) -&gt; t a -&gt; m)
-&gt; (forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; t a -&gt; b)
-&gt; (forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; t a -&gt; b)
-&gt; (forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; t a -&gt; b)
-&gt; (forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; t a -&gt; b)
-&gt; (forall a. (a -&gt; a -&gt; a) -&gt; t a -&gt; a)
-&gt; (forall a. (a -&gt; a -&gt; a) -&gt; t a -&gt; a)
-&gt; (forall a. t a -&gt; [a])
-&gt; (forall a. t a -&gt; Bool)
-&gt; (forall a. t a -&gt; Int)
-&gt; (forall a. Eq a =&gt; a -&gt; t a -&gt; Bool)
-&gt; (forall a. Ord a =&gt; t a -&gt; a)
-&gt; (forall a. Ord a =&gt; t a -&gt; a)
-&gt; (forall a. Num a =&gt; t a -&gt; a)
-&gt; (forall a. Num a =&gt; t a -&gt; a)
-&gt; Foldable t
$cfold :: forall m. Monoid m =&gt; MimeResult m -&gt; m
fold :: forall m. Monoid m =&gt; MimeResult m -&gt; m
$cfoldMap :: forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m
foldMap :: forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m
$cfoldMap' :: forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m
foldMap' :: forall m a. Monoid m =&gt; (a -&gt; m) -&gt; MimeResult a -&gt; m
$cfoldr :: forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
foldr :: forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
$cfoldr' :: forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
foldr' :: forall a b. (a -&gt; b -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
$cfoldl :: forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
foldl :: forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
$cfoldl' :: forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
foldl' :: forall b a. (b -&gt; a -&gt; b) -&gt; b -&gt; MimeResult a -&gt; b
$cfoldr1 :: forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a
foldr1 :: forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a
$cfoldl1 :: forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a
foldl1 :: forall a. (a -&gt; a -&gt; a) -&gt; MimeResult a -&gt; a
$ctoList :: forall a. MimeResult a -&gt; [a]
toList :: forall a. MimeResult a -&gt; [a]
$cnull :: forall a. MimeResult a -&gt; Bool
null :: forall a. MimeResult a -&gt; Bool
$clength :: forall a. MimeResult a -&gt; Int
length :: forall a. MimeResult a -&gt; Int
$celem :: forall a. Eq a =&gt; a -&gt; MimeResult a -&gt; Bool
elem :: forall a. Eq a =&gt; a -&gt; MimeResult a -&gt; Bool
$cmaximum :: forall a. Ord a =&gt; MimeResult a -&gt; a
maximum :: forall a. Ord a =&gt; MimeResult a -&gt; a
$cminimum :: forall a. Ord a =&gt; MimeResult a -&gt; a
minimum :: forall a. Ord a =&gt; MimeResult a -&gt; a
$csum :: forall a. Num a =&gt; MimeResult a -&gt; a
sum :: forall a. Num a =&gt; MimeResult a -&gt; a
$cproduct :: forall a. Num a =&gt; MimeResult a -&gt; a
product :: forall a. Num a =&gt; MimeResult a -&gt; a
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Foldable</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621679157516"><span id="local-6989586621679157524"><span id="local-6989586621679157530"><span id="local-6989586621679157535"><span class="annot"><span class="annottext">Functor MimeResult
Foldable MimeResult
Functor MimeResult
-&gt; Foldable MimeResult
-&gt; (forall (f :: * -&gt; *) a b.
    Applicative f =&gt;
    (a -&gt; f b) -&gt; MimeResult a -&gt; f (MimeResult b))
-&gt; (forall (f :: * -&gt; *) a.
    Applicative f =&gt;
    MimeResult (f a) -&gt; f (MimeResult a))
-&gt; (forall (m :: * -&gt; *) a b.
    Monad m =&gt;
    (a -&gt; m b) -&gt; MimeResult a -&gt; m (MimeResult b))
-&gt; (forall (m :: * -&gt; *) a.
    Monad m =&gt;
    MimeResult (m a) -&gt; m (MimeResult a))
-&gt; Traversable MimeResult
forall (t :: * -&gt; *).
Functor t
-&gt; Foldable t
-&gt; (forall (f :: * -&gt; *) a b.
    Applicative f =&gt;
    (a -&gt; f b) -&gt; t a -&gt; f (t b))
-&gt; (forall (f :: * -&gt; *) a. Applicative f =&gt; t (f a) -&gt; f (t a))
-&gt; (forall (m :: * -&gt; *) a b.
    Monad m =&gt;
    (a -&gt; m b) -&gt; t a -&gt; m (t b))
-&gt; (forall (m :: * -&gt; *) a. Monad m =&gt; t (m a) -&gt; m (t a))
-&gt; Traversable t
forall (m :: * -&gt; *) a.
Monad m =&gt;
MimeResult (m a) -&gt; m (MimeResult a)
forall (f :: * -&gt; *) a.
Applicative f =&gt;
MimeResult (f a) -&gt; f (MimeResult a)
forall (m :: * -&gt; *) a b.
Monad m =&gt;
(a -&gt; m b) -&gt; MimeResult a -&gt; m (MimeResult b)
forall (f :: * -&gt; *) a b.
Applicative f =&gt;
(a -&gt; f b) -&gt; MimeResult a -&gt; f (MimeResult b)
$ctraverse :: forall (f :: * -&gt; *) a b.
Applicative f =&gt;
(a -&gt; f b) -&gt; MimeResult a -&gt; f (MimeResult b)
traverse :: forall (f :: * -&gt; *) a b.
Applicative f =&gt;
(a -&gt; f b) -&gt; MimeResult a -&gt; f (MimeResult b)
$csequenceA :: forall (f :: * -&gt; *) a.
Applicative f =&gt;
MimeResult (f a) -&gt; f (MimeResult a)
sequenceA :: forall (f :: * -&gt; *) a.
Applicative f =&gt;
MimeResult (f a) -&gt; f (MimeResult a)
$cmapM :: forall (m :: * -&gt; *) a b.
Monad m =&gt;
(a -&gt; m b) -&gt; MimeResult a -&gt; m (MimeResult b)
mapM :: forall (m :: * -&gt; *) a b.
Monad m =&gt;
(a -&gt; m b) -&gt; MimeResult a -&gt; m (MimeResult b)
$csequence :: forall (m :: * -&gt; *) a.
Monad m =&gt;
MimeResult (m a) -&gt; m (MimeResult a)
sequence :: forall (m :: * -&gt; *) a.
Monad m =&gt;
MimeResult (m a) -&gt; m (MimeResult a)
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Traversable</span></span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-76"></span><span>
</span><span id="line-77"></span><span class="annot"><span class="hs-comment">-- | pair of unrender/parser error and http response</span></span><span>
</span><span id="line-78"></span><span class="hs-keyword">data</span><span> </span><span id="MimeError"><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-var">MimeError</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-79"></span><span>  </span><span id="MimeError"><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-var">MimeError</span></a></span></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-80"></span><span>    </span><span id="mimeError"><span class="annot"><span class="annottext">MimeError -&gt; String
</span><a href="OpenAPIPetstore.Client.html#mimeError"><span class="hs-identifier hs-var hs-var">mimeError</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">String</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ unrender/parser error</span></span><span>
</span><span id="line-81"></span><span>  </span><span class="hs-special">,</span><span> </span><span id="mimeErrorResponse"><span class="annot"><span class="annottext">MimeError -&gt; Response ByteString
</span><a href="OpenAPIPetstore.Client.html#mimeErrorResponse"><span class="hs-identifier hs-var hs-var">mimeErrorResponse</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Response</span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">BCL.ByteString</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http response</span></span><span>
</span><span id="line-82"></span><span>  </span><span class="hs-special">}</span><span> </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679157545"><span id="local-6989586621679157553"><span id="local-6989586621679157556"><span class="annot"><span class="annottext">Int -&gt; MimeError -&gt; ShowS
[MimeError] -&gt; ShowS
MimeError -&gt; String
(Int -&gt; MimeError -&gt; ShowS)
-&gt; (MimeError -&gt; String)
-&gt; ([MimeError] -&gt; ShowS)
-&gt; Show MimeError
forall a.
(Int -&gt; a -&gt; ShowS) -&gt; (a -&gt; String) -&gt; ([a] -&gt; ShowS) -&gt; Show a
$cshowsPrec :: Int -&gt; MimeError -&gt; ShowS
showsPrec :: Int -&gt; MimeError -&gt; ShowS
$cshow :: MimeError -&gt; String
show :: MimeError -&gt; String
$cshowList :: [MimeError] -&gt; ShowS
showList :: [MimeError] -&gt; ShowS
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-83"></span><span>
</span><span id="line-84"></span><span class="annot"><span class="hs-comment">-- | send a request returning the 'MimeResult'</span></span><span>
</span><span id="line-85"></span><span class="annot"><a href="OpenAPIPetstore.Client.html#dispatchMime"><span class="hs-identifier hs-type">dispatchMime</span></a></span><span>
</span><span id="line-86"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-keyword">forall</span><span> </span><span id="local-6989586621679157207"><span class="annot"><a href="#local-6989586621679157207"><span class="hs-identifier hs-type">req</span></a></span></span><span> </span><span id="local-6989586621679157211"><span class="annot"><a href="#local-6989586621679157211"><span class="hs-identifier hs-type">contentType</span></a></span></span><span> </span><span id="local-6989586621679157209"><span class="annot"><a href="#local-6989586621679157209"><span class="hs-identifier hs-type">res</span></a></span></span><span> </span><span id="local-6989586621679157208"><span class="annot"><a href="#local-6989586621679157208"><span class="hs-identifier hs-type">accept</span></a></span></span><span class="hs-operator">.</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#Produces"><span class="hs-identifier hs-type">Produces</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157207"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157208"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeUnrender"><span class="hs-identifier hs-type">MimeUnrender</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157208"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157209"><span class="hs-identifier hs-type">res</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157211"><span class="hs-identifier hs-type">contentType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-87"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Manager</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http-client Connection manager</span></span><span>
</span><span id="line-88"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-89"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreRequest"><span class="hs-identifier hs-type">OpenAPIPetstoreRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157207"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157211"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157209"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157208"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ request</span></span><span>
</span><span id="line-90"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeResult"><span class="hs-identifier hs-type">MimeResult</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157209"><span class="hs-identifier hs-type">res</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="hs-comment">-- ^ response</span></span><span>
</span><span id="line-91"></span><span id="dispatchMime"><span class="annot"><span class="annottext">dispatchMime :: forall req contentType res accept.
(Produces req accept, MimeUnrender accept res,
 MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (MimeResult res)
</span><a href="OpenAPIPetstore.Client.html#dispatchMime"><span class="hs-identifier hs-var hs-var">dispatchMime</span></a></span></span><span> </span><span id="local-6989586621679157596"><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157596"><span class="hs-identifier hs-var">manager</span></a></span></span><span> </span><span id="local-6989586621679157597"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157597"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span id="local-6989586621679157598"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157598"><span class="hs-identifier hs-var">request</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-92"></span><span>  </span><span id="local-6989586621679157599"><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (Response ByteString)
forall req accept contentType res.
(Produces req accept, MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchLbs"><span class="hs-identifier hs-var">dispatchLbs</span></a></span><span> </span><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157596"><span class="hs-identifier hs-var">manager</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157597"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157598"><span class="hs-identifier hs-var">request</span></a></span><span>
</span><span id="line-93"></span><span>  </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679157600"><span class="annot"><span class="annottext">statusCode :: Int
</span><a href="#local-6989586621679157600"><span class="hs-identifier hs-var hs-var">statusCode</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Status -&gt; Int
</span><span class="hs-identifier hs-var">NH.statusCode</span></span><span> </span><span class="annot"><span class="annottext">(Status -&gt; Int)
-&gt; (Response ByteString -&gt; Status) -&gt; Response ByteString -&gt; Int
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Response ByteString -&gt; Status
forall body. Response body -&gt; Status
</span><span class="hs-identifier hs-var">NH.responseStatus</span></span><span> </span><span class="annot"><span class="annottext">(Response ByteString -&gt; Int) -&gt; Response ByteString -&gt; Int
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span><span>
</span><span id="line-94"></span><span>  </span><span id="local-6989586621679157604"><span class="annot"><span class="annottext">Either MimeError res
</span><a href="#local-6989586621679157604"><span class="hs-identifier hs-var">parsedResult</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span>
</span><span id="line-95"></span><span>    </span><span class="annot"><span class="annottext">Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec IO (Either MimeError res)
forall (m :: * -&gt; *) a.
(MonadCatch m, MonadIO m) =&gt;
Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLogWithExceptions"><span class="hs-identifier hs-var">runConfigLogWithExceptions</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Client&quot;</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157597"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">LogExec IO (Either MimeError res)
-&gt; LogExec IO (Either MimeError res)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span>
</span><span id="line-96"></span><span>    </span><span class="hs-keyword">do</span><span> </span><span class="hs-keyword">if</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679157600"><span class="hs-identifier hs-var">statusCode</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Ord a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">&gt;=</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">400</span></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679157600"><span class="hs-identifier hs-var">statusCode</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Bool
forall a. Ord a =&gt; a -&gt; a -&gt; Bool
</span><span class="hs-operator hs-var">&lt;</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">600</span></span><span class="hs-special">)</span><span>
</span><span id="line-97"></span><span>         </span><span class="hs-keyword">then</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-98"></span><span>           </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679157613"><span class="annot"><span class="annottext">s :: String
</span><a href="#local-6989586621679157613"><span class="hs-identifier hs-var hs-var">s</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;error statusCode: &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; ShowS
forall a. [a] -&gt; [a] -&gt; [a]
</span><span class="hs-operator hs-var">++</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; String
forall a. Show a =&gt; a -&gt; String
</span><span class="hs-identifier hs-var">show</span></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621679157600"><span class="hs-identifier hs-var">statusCode</span></a></span><span>
</span><span id="line-99"></span><span>           </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Client&quot;</span></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelError"><span class="hs-identifier hs-var">levelError</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679157613"><span class="hs-identifier hs-var">s</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-100"></span><span>           </span><span class="annot"><span class="annottext">Either MimeError res -&gt; KatipT IO (Either MimeError res)
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">MimeError -&gt; Either MimeError res
forall a b. a -&gt; Either a b
</span><span class="hs-identifier hs-var">Left</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Response ByteString -&gt; MimeError
</span><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-var">MimeError</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679157613"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-101"></span><span>         </span><span class="hs-keyword">else</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">Proxy accept -&gt; ByteString -&gt; Either String res
forall mtype o.
MimeUnrender mtype o =&gt;
Proxy mtype -&gt; ByteString -&gt; Either String o
</span><a href="OpenAPIPetstore.MimeTypes.html#mimeUnrender"><span class="hs-identifier hs-var">mimeUnrender</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Proxy accept
forall {k} (t :: k). Proxy t
</span><span class="hs-identifier hs-var">P.Proxy</span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">P.Proxy</span></span><span> </span><span class="annot"><a href="#local-6989586621679157208"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Response ByteString -&gt; ByteString
forall body. Response body -&gt; body
</span><span class="hs-identifier hs-var">NH.responseBody</span></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-102"></span><span>           </span><span class="annot"><span class="hs-identifier hs-type">Left</span></span><span> </span><span id="local-6989586621679157621"><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679157621"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-103"></span><span>             </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Client&quot;</span></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelError"><span class="hs-identifier hs-var">levelError</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679157621"><span class="hs-identifier hs-var">s</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-104"></span><span>             </span><span class="annot"><span class="annottext">Either MimeError res -&gt; KatipT IO (Either MimeError res)
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">MimeError -&gt; Either MimeError res
forall a b. a -&gt; Either a b
</span><span class="hs-identifier hs-var">Left</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Response ByteString -&gt; MimeError
</span><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-var">MimeError</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621679157621"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-105"></span><span>           </span><span class="annot"><span class="hs-identifier hs-type">Right</span></span><span> </span><span id="local-6989586621679157622"><span class="annot"><span class="annottext">res
</span><a href="#local-6989586621679157622"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Either MimeError res -&gt; KatipT IO (Either MimeError res)
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">res -&gt; Either MimeError res
forall a b. b -&gt; Either a b
</span><span class="hs-identifier hs-var">Right</span></span><span> </span><span class="annot"><span class="annottext">res
</span><a href="#local-6989586621679157622"><span class="hs-identifier hs-var">r</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-106"></span><span>  </span><span class="annot"><span class="annottext">MimeResult res -&gt; IO (MimeResult res)
forall a. a -&gt; IO a
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><span class="hs-identifier hs-var">return</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Either MimeError res -&gt; Response ByteString -&gt; MimeResult res
forall res.
Either MimeError res -&gt; Response ByteString -&gt; MimeResult res
</span><a href="OpenAPIPetstore.Client.html#MimeResult"><span class="hs-identifier hs-var">MimeResult</span></a></span><span> </span><span class="annot"><span class="annottext">Either MimeError res
</span><a href="#local-6989586621679157604"><span class="hs-identifier hs-var">parsedResult</span></a></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157599"><span class="hs-identifier hs-var">httpResponse</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-107"></span><span>
</span><span id="line-108"></span><span class="annot"><span class="hs-comment">-- | like 'dispatchMime', but only returns the decoded http body</span></span><span>
</span><span id="line-109"></span><span id="local-6989586621679157251"><span id="local-6989586621679157252"><span id="local-6989586621679157253"><span id="local-6989586621679157254"><span class="annot"><a href="OpenAPIPetstore.Client.html#dispatchMime%27"><span class="hs-identifier hs-type">dispatchMime'</span></a></span><span>
</span><span id="line-110"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#Produces"><span class="hs-identifier hs-type">Produces</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157251"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157252"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeUnrender"><span class="hs-identifier hs-type">MimeUnrender</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157252"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157253"><span class="hs-identifier hs-type">res</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157254"><span class="hs-identifier hs-type">contentType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-111"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Manager</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http-client Connection manager</span></span><span>
</span><span id="line-112"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-113"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreRequest"><span class="hs-identifier hs-type">OpenAPIPetstoreRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157251"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157254"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157253"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157252"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ request</span></span><span>
</span><span id="line-114"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">Either</span></span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeError"><span class="hs-identifier hs-type">MimeError</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157253"><span class="hs-identifier hs-type">res</span></a></span><span class="hs-special">)</span></span></span></span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ response</span></span><span>
</span><span id="line-115"></span><span id="dispatchMime%27"><span class="annot"><span class="annottext">dispatchMime' :: forall req accept res contentType.
(Produces req accept, MimeUnrender accept res,
 MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (Either MimeError res)
</span><a href="OpenAPIPetstore.Client.html#dispatchMime%27"><span class="hs-identifier hs-var hs-var">dispatchMime'</span></a></span></span><span> </span><span id="local-6989586621679157632"><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157632"><span class="hs-identifier hs-var">manager</span></a></span></span><span> </span><span id="local-6989586621679157633"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157633"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span id="local-6989586621679157634"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157634"><span class="hs-identifier hs-var">request</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-116"></span><span>    </span><span class="annot"><a href="OpenAPIPetstore.Client.html#MimeResult"><span class="hs-identifier hs-type">MimeResult</span></a></span><span> </span><span id="local-6989586621679157635"><span class="annot"><span class="annottext">Either MimeError res
</span><a href="#local-6989586621679157635"><span class="hs-identifier hs-var">parsedResult</span></a></span></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (MimeResult res)
forall req contentType res accept.
(Produces req accept, MimeUnrender accept res,
 MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (MimeResult res)
</span><a href="OpenAPIPetstore.Client.html#dispatchMime"><span class="hs-identifier hs-var">dispatchMime</span></a></span><span> </span><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157632"><span class="hs-identifier hs-var">manager</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157633"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157634"><span class="hs-identifier hs-var">request</span></a></span><span>
</span><span id="line-117"></span><span>    </span><span class="annot"><span class="annottext">Either MimeError res -&gt; IO (Either MimeError res)
forall a. a -&gt; IO a
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><span class="hs-identifier hs-var">return</span></span><span> </span><span class="annot"><span class="annottext">Either MimeError res
</span><a href="#local-6989586621679157635"><span class="hs-identifier hs-var">parsedResult</span></a></span><span>
</span><span id="line-118"></span><span>
</span><span id="line-119"></span><span class="annot"><span class="hs-comment">-- ** Unsafe</span></span><span>
</span><span id="line-120"></span><span>
</span><span id="line-121"></span><span class="annot"><span class="hs-comment">-- | like 'dispatchReqLbs', but does not validate the operation is a 'Producer' of the &quot;accept&quot; 'MimeType'.  (Useful if the server's response is undocumented)</span></span><span>
</span><span id="line-122"></span><span id="local-6989586621679157259"><span id="local-6989586621679157260"><span id="local-6989586621679157261"><span id="local-6989586621679157262"><span class="annot"><a href="OpenAPIPetstore.Client.html#dispatchLbsUnsafe"><span class="hs-identifier hs-type">dispatchLbsUnsafe</span></a></span><span>
</span><span id="line-123"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157259"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157260"><span class="hs-identifier hs-type">contentType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-124"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Manager</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http-client Connection manager</span></span><span>
</span><span id="line-125"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-126"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreRequest"><span class="hs-identifier hs-type">OpenAPIPetstoreRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157261"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157260"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157262"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157259"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ request</span></span><span>
</span><span id="line-127"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">NH.Response</span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">BCL.ByteString</span></span><span class="hs-special">)</span></span></span></span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ response</span></span><span>
</span><span id="line-128"></span><span id="dispatchLbsUnsafe"><span class="annot"><span class="annottext">dispatchLbsUnsafe :: forall accept contentType req res.
(MimeType accept, MimeType contentType) =&gt;
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchLbsUnsafe"><span class="hs-identifier hs-var hs-var">dispatchLbsUnsafe</span></a></span></span><span> </span><span id="local-6989586621679157642"><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157642"><span class="hs-identifier hs-var">manager</span></a></span></span><span> </span><span id="local-6989586621679157643"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157643"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span id="local-6989586621679157644"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157644"><span class="hs-identifier hs-var">request</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-129"></span><span>  </span><span id="local-6989586621679157645"><span class="annot"><span class="annottext">InitRequest req contentType res accept
</span><a href="#local-6989586621679157645"><span class="hs-identifier hs-var">initReq</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (InitRequest req contentType res accept)
forall accept contentType req res.
(MimeType accept, MimeType contentType) =&gt;
OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (InitRequest req contentType res accept)
</span><a href="OpenAPIPetstore.Client.html#_toInitRequest"><span class="hs-identifier hs-var">_toInitRequest</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157643"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157644"><span class="hs-identifier hs-var">request</span></a></span><span>
</span><span id="line-130"></span><span>  </span><span class="annot"><span class="annottext">Manager
-&gt; OpenAPIPetstoreConfig
-&gt; InitRequest req contentType res accept
-&gt; IO (Response ByteString)
forall req contentType res accept.
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; InitRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchInitUnsafe"><span class="hs-identifier hs-var">dispatchInitUnsafe</span></a></span><span> </span><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157642"><span class="hs-identifier hs-var">manager</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157643"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">InitRequest req contentType res accept
</span><a href="#local-6989586621679157645"><span class="hs-identifier hs-var">initReq</span></a></span><span>
</span><span id="line-131"></span><span>
</span><span id="line-132"></span><span class="annot"><span class="hs-comment">-- | dispatch an InitRequest</span></span><span>
</span><span id="line-133"></span><span id="local-6989586621679157143"><span id="local-6989586621679157144"><span id="local-6989586621679157145"><span id="local-6989586621679157146"><span class="annot"><a href="OpenAPIPetstore.Client.html#dispatchInitUnsafe"><span class="hs-identifier hs-type">dispatchInitUnsafe</span></a></span><span>
</span><span id="line-134"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Manager</span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ http-client Connection manager</span></span><span>
</span><span id="line-135"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-136"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157143"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157144"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157145"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157146"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ init request</span></span><span>
</span><span id="line-137"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">NH.Response</span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">BCL.ByteString</span></span><span class="hs-special">)</span></span></span></span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ response</span></span><span>
</span><span id="line-138"></span><span id="dispatchInitUnsafe"><span class="annot"><span class="annottext">dispatchInitUnsafe :: forall req contentType res accept.
Manager
-&gt; OpenAPIPetstoreConfig
-&gt; InitRequest req contentType res accept
-&gt; IO (Response ByteString)
</span><a href="OpenAPIPetstore.Client.html#dispatchInitUnsafe"><span class="hs-identifier hs-var hs-var">dispatchInitUnsafe</span></a></span></span><span> </span><span id="local-6989586621679157668"><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157668"><span class="hs-identifier hs-var">manager</span></a></span></span><span> </span><span id="local-6989586621679157669"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157669"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span id="local-6989586621679157671"><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-139"></span><span>  </span><span class="annot"><span class="annottext">Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec IO (Response ByteString)
forall (m :: * -&gt; *) a.
(MonadCatch m, MonadIO m) =&gt;
Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLogWithExceptions"><span class="hs-identifier hs-var">runConfigLogWithExceptions</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var">src</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157669"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">LogExec IO (Response ByteString)
-&gt; LogExec IO (Response ByteString)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span>
</span><span id="line-140"></span><span>    </span><span class="hs-keyword">do</span><span> </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var">src</span></a></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelInfo"><span class="hs-identifier hs-var">levelInfo</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157674"><span class="hs-identifier hs-var">requestLogMsg</span></a></span><span>
</span><span id="line-141"></span><span>       </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var">src</span></a></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelDebug"><span class="hs-identifier hs-var">levelDebug</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157676"><span class="hs-identifier hs-var">requestDbgLogMsg</span></a></span><span>
</span><span id="line-142"></span><span>       </span><span id="local-6989586621679157677"><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157677"><span class="hs-identifier hs-var">res</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">IO (Response ByteString) -&gt; KatipT IO (Response ByteString)
forall a. IO a -&gt; KatipT IO a
forall (m :: * -&gt; *) a. MonadIO m =&gt; IO a -&gt; m a
</span><span class="hs-identifier hs-var">P.liftIO</span></span><span> </span><span class="annot"><span class="annottext">(IO (Response ByteString) -&gt; KatipT IO (Response ByteString))
-&gt; IO (Response ByteString) -&gt; KatipT IO (Response ByteString)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">Request -&gt; Manager -&gt; IO (Response ByteString)
</span><span class="hs-identifier hs-var">NH.httpLbs</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span> </span><span class="annot"><span class="annottext">Manager
</span><a href="#local-6989586621679157668"><span class="hs-identifier hs-var">manager</span></a></span><span>
</span><span id="line-143"></span><span>       </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var">src</span></a></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelInfo"><span class="hs-identifier hs-var">levelInfo</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Response ByteString -&gt; Text
forall {body}. Response body -&gt; Text
</span><a href="#local-6989586621679157680"><span class="hs-identifier hs-var">responseLogMsg</span></a></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157677"><span class="hs-identifier hs-var">res</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-144"></span><span>       </span><span class="annot"><span class="annottext">Text -&gt; LogLevel -&gt; Text -&gt; KatipT IO ()
forall (m :: * -&gt; *).
(Applicative m, Katip m) =&gt;
Text -&gt; LogLevel -&gt; Text -&gt; m ()
</span><a href="OpenAPIPetstore.LoggingKatip.html#_log"><span class="hs-identifier hs-var">_log</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var">src</span></a></span><span> </span><span class="annot"><span class="annottext">LogLevel
</span><a href="OpenAPIPetstore.LoggingKatip.html#levelDebug"><span class="hs-identifier hs-var">levelDebug</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Text)
-&gt; (Response ByteString -&gt; String) -&gt; Response ByteString -&gt; Text
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Response ByteString -&gt; String
forall a. Show a =&gt; a -&gt; String
</span><span class="hs-identifier hs-var">show</span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157677"><span class="hs-identifier hs-var">res</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-145"></span><span>       </span><span class="annot"><span class="annottext">Response ByteString -&gt; KatipT IO (Response ByteString)
forall a. a -&gt; KatipT IO a
forall (m :: * -&gt; *) a. Monad m =&gt; a -&gt; m a
</span><span class="hs-identifier hs-var">return</span></span><span> </span><span class="annot"><span class="annottext">Response ByteString
</span><a href="#local-6989586621679157677"><span class="hs-identifier hs-var">res</span></a></span><span>
</span><span id="line-146"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-147"></span><span>    </span><span id="local-6989586621679157672"><span class="annot"><span class="annottext">src :: Text
</span><a href="#local-6989586621679157672"><span class="hs-identifier hs-var hs-var">src</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Client&quot;</span></span><span>
</span><span id="line-148"></span><span>    </span><span id="local-6989586621679157689"><span class="annot"><span class="annottext">endpoint :: Text
</span><a href="#local-6989586621679157689"><span class="hs-identifier hs-var hs-var">endpoint</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-149"></span><span>      </span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Text) -&gt; String -&gt; Text
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span>
</span><span id="line-150"></span><span>      </span><span class="annot"><span class="annottext">ByteString -&gt; String
</span><span class="hs-identifier hs-var">BC.unpack</span></span><span> </span><span class="annot"><span class="annottext">(ByteString -&gt; String) -&gt; ByteString -&gt; String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span>
</span><span id="line-151"></span><span>      </span><span class="annot"><span class="annottext">Request -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.method</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; ByteString -&gt; ByteString
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><span class="hs-string">&quot; &quot;</span></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; ByteString -&gt; ByteString
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Request -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.host</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; ByteString -&gt; ByteString
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Request -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.path</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; ByteString -&gt; ByteString
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Request -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.queryString</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span>
</span><span id="line-152"></span><span>    </span><span id="local-6989586621679157674"><span class="annot"><span class="annottext">requestLogMsg :: Text
</span><a href="#local-6989586621679157674"><span class="hs-identifier hs-var hs-var">requestLogMsg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;REQ:&quot;</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157689"><span class="hs-identifier hs-var">endpoint</span></a></span><span>
</span><span id="line-153"></span><span>    </span><span id="local-6989586621679157676"><span class="annot"><span class="annottext">requestDbgLogMsg :: Text
</span><a href="#local-6989586621679157676"><span class="hs-identifier hs-var hs-var">requestDbgLogMsg</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-154"></span><span>      </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Headers=&quot;</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Text)
-&gt; (RequestHeaders -&gt; String) -&gt; RequestHeaders -&gt; Text
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">RequestHeaders -&gt; String
forall a. Show a =&gt; a -&gt; String
</span><span class="hs-identifier hs-var">show</span></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request -&gt; RequestHeaders
</span><span class="hs-identifier hs-var">NH.requestHeaders</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot; Body=&quot;</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span>
</span><span id="line-155"></span><span>      </span><span class="hs-special">(</span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">Request -&gt; RequestBody
</span><span class="hs-identifier hs-var">NH.requestBody</span></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157671"><span class="hs-identifier hs-var">req</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-156"></span><span>         </span><span class="annot"><span class="hs-identifier hs-type">NH.RequestBodyLBS</span></span><span> </span><span id="local-6989586621679157715"><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157715"><span class="hs-identifier hs-var">xs</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; Text
</span><span class="hs-identifier hs-var">T.decodeUtf8</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ByteString -&gt; ByteString
</span><span class="hs-identifier hs-var">BL.toStrict</span></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157715"><span class="hs-identifier hs-var">xs</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-157"></span><span>         </span><span class="annot"><span class="annottext">RequestBody
</span><span class="hs-identifier">_</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;&lt;RequestBody&gt;&quot;</span></span><span class="hs-special">)</span><span>
</span><span id="line-158"></span><span>    </span><span id="local-6989586621679157719"><span class="annot"><span class="annottext">responseStatusCode :: Response body -&gt; Text
</span><a href="#local-6989586621679157719"><span class="hs-identifier hs-var hs-var">responseStatusCode</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">String -&gt; Text
</span><span class="hs-identifier hs-var">T.pack</span></span><span> </span><span class="annot"><span class="annottext">(String -&gt; Text) -&gt; (Int -&gt; String) -&gt; Int -&gt; Text
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Int -&gt; String
forall a. Show a =&gt; a -&gt; String
</span><span class="hs-identifier hs-var">show</span></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">(Int -&gt; Text) -&gt; (Response body -&gt; Int) -&gt; Response body -&gt; Text
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Status -&gt; Int
</span><span class="hs-identifier hs-var">NH.statusCode</span></span><span> </span><span class="annot"><span class="annottext">(Status -&gt; Int)
-&gt; (Response body -&gt; Status) -&gt; Response body -&gt; Int
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Response body -&gt; Status
forall body. Response body -&gt; Status
</span><span class="hs-identifier hs-var">NH.responseStatus</span></span><span>
</span><span id="line-159"></span><span>    </span><span id="local-6989586621679157680"><span class="annot"><span class="annottext">responseLogMsg :: Response body -&gt; Text
</span><a href="#local-6989586621679157680"><span class="hs-identifier hs-var hs-var">responseLogMsg</span></a></span></span><span> </span><span id="local-6989586621679157727"><span class="annot"><span class="annottext">Response body
</span><a href="#local-6989586621679157727"><span class="hs-identifier hs-var">res</span></a></span></span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-160"></span><span>      </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;RES:statusCode=&quot;</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Response body -&gt; Text
forall {body}. Response body -&gt; Text
</span><a href="#local-6989586621679157719"><span class="hs-identifier hs-var">responseStatusCode</span></a></span><span> </span><span class="annot"><span class="annottext">Response body
</span><a href="#local-6989586621679157727"><span class="hs-identifier hs-var">res</span></a></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot; (&quot;</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157689"><span class="hs-identifier hs-var">endpoint</span></a></span><span> </span><span class="annot"><span class="annottext">Text -&gt; Text -&gt; Text
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;)&quot;</span></span><span>
</span><span id="line-161"></span><span>
</span><span id="line-162"></span><span class="annot"><span class="hs-comment">-- * InitRequest</span></span><span>
</span><span id="line-163"></span><span>
</span><span id="line-164"></span><span class="annot"><span class="hs-comment">-- | wraps an http-client 'Request' with request/response type parameters</span></span><span>
</span><span id="line-165"></span><span class="hs-keyword">newtype</span><span> </span><span id="InitRequest"><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-var">InitRequest</span></a></span></span><span> </span><span id="local-6989586621679157286"><span class="annot"><a href="#local-6989586621679157286"><span class="hs-identifier hs-type">req</span></a></span></span><span> </span><span id="local-6989586621679157287"><span class="annot"><a href="#local-6989586621679157287"><span class="hs-identifier hs-type">contentType</span></a></span></span><span> </span><span id="local-6989586621679157288"><span class="annot"><a href="#local-6989586621679157288"><span class="hs-identifier hs-type">res</span></a></span></span><span> </span><span id="local-6989586621679157289"><span class="annot"><a href="#local-6989586621679157289"><span class="hs-identifier hs-type">accept</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="InitRequest"><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-var">InitRequest</span></a></span></span><span>
</span><span id="line-166"></span><span>  </span><span class="hs-special">{</span><span> </span><span id="unInitRequest"><span class="annot"><span class="annottext">forall req contentType res accept.
InitRequest req contentType res accept -&gt; Request
</span><a href="OpenAPIPetstore.Client.html#unInitRequest"><span class="hs-identifier hs-var hs-var">unInitRequest</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Request</span></span><span>
</span><span id="line-167"></span><span>  </span><span class="hs-special">}</span><span> </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621679157730"><span id="local-6989586621679157735"><span id="local-6989586621679157739"><span class="annot"><span class="annottext">Int -&gt; InitRequest req contentType res accept -&gt; ShowS
[InitRequest req contentType res accept] -&gt; ShowS
InitRequest req contentType res accept -&gt; String
(Int -&gt; InitRequest req contentType res accept -&gt; ShowS)
-&gt; (InitRequest req contentType res accept -&gt; String)
-&gt; ([InitRequest req contentType res accept] -&gt; ShowS)
-&gt; Show (InitRequest req contentType res accept)
forall a.
(Int -&gt; a -&gt; ShowS) -&gt; (a -&gt; String) -&gt; ([a] -&gt; ShowS) -&gt; Show a
forall req contentType res accept.
Int -&gt; InitRequest req contentType res accept -&gt; ShowS
forall req contentType res accept.
[InitRequest req contentType res accept] -&gt; ShowS
forall req contentType res accept.
InitRequest req contentType res accept -&gt; String
$cshowsPrec :: forall req contentType res accept.
Int -&gt; InitRequest req contentType res accept -&gt; ShowS
showsPrec :: Int -&gt; InitRequest req contentType res accept -&gt; ShowS
$cshow :: forall req contentType res accept.
InitRequest req contentType res accept -&gt; String
show :: InitRequest req contentType res accept -&gt; String
$cshowList :: forall req contentType res accept.
[InitRequest req contentType res accept] -&gt; ShowS
showList :: [InitRequest req contentType res accept] -&gt; ShowS
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-168"></span><span>
</span><span id="line-169"></span><span class="annot"><span class="hs-comment">-- |  Build an http-client 'Request' record from the supplied config and request</span></span><span>
</span><span id="line-170"></span><span id="local-6989586621679157139"><span id="local-6989586621679157140"><span id="local-6989586621679157141"><span id="local-6989586621679157142"><span class="annot"><a href="OpenAPIPetstore.Client.html#_toInitRequest"><span class="hs-identifier hs-type">_toInitRequest</span></a></span><span>
</span><span id="line-171"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157139"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="OpenAPIPetstore.MimeTypes.html#MimeType"><span class="hs-identifier hs-type">MimeType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157140"><span class="hs-identifier hs-type">contentType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-172"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ config</span></span><span>
</span><span id="line-173"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreRequest"><span class="hs-identifier hs-type">OpenAPIPetstoreRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157141"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157140"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157142"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157139"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="annot"><span class="hs-comment">-- ^ request</span></span><span>
</span><span id="line-174"></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">IO</span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157141"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157140"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157142"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157139"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">)</span></span></span></span></span><span> </span><span class="annot"><span class="hs-comment">-- ^ initialized request</span></span><span>
</span><span id="line-175"></span><span id="_toInitRequest"><span class="annot"><span class="annottext">_toInitRequest :: forall accept contentType req res.
(MimeType accept, MimeType contentType) =&gt;
OpenAPIPetstoreConfig
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; IO (InitRequest req contentType res accept)
</span><a href="OpenAPIPetstore.Client.html#_toInitRequest"><span class="hs-identifier hs-var hs-var">_toInitRequest</span></a></span></span><span> </span><span id="local-6989586621679157782"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span id="local-6989586621679157783"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157783"><span class="hs-identifier hs-var">req0</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span>
</span><span id="line-176"></span><span>  </span><span class="annot"><span class="annottext">Text
-&gt; OpenAPIPetstoreConfig
-&gt; LogExec IO (InitRequest req contentType res accept)
forall (m :: * -&gt; *) a.
(MonadCatch m, MonadIO m) =&gt;
Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLogWithExceptions"><span class="hs-identifier hs-var">runConfigLogWithExceptions</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><span class="hs-string">&quot;Client&quot;</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">LogExec IO (InitRequest req contentType res accept)
-&gt; LogExec IO (InitRequest req contentType res accept)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="hs-keyword">do</span><span>
</span><span id="line-177"></span><span>    </span><span id="local-6989586621679157784"><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157784"><span class="hs-identifier hs-var">parsedReq</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">IO Request -&gt; KatipT IO Request
forall a. IO a -&gt; KatipT IO a
forall (m :: * -&gt; *) a. MonadIO m =&gt; IO a -&gt; m a
</span><span class="hs-identifier hs-var">P.liftIO</span></span><span> </span><span class="annot"><span class="annottext">(IO Request -&gt; KatipT IO Request)
-&gt; IO Request -&gt; KatipT IO Request
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; IO Request
forall (m :: * -&gt; *). MonadThrow m =&gt; String -&gt; m Request
</span><span class="hs-identifier hs-var">NH.parseRequest</span></span><span> </span><span class="annot"><span class="annottext">(String -&gt; IO Request) -&gt; String -&gt; IO Request
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; String
</span><span class="hs-identifier hs-var">BCL.unpack</span></span><span> </span><span class="annot"><span class="annottext">(ByteString -&gt; String) -&gt; ByteString -&gt; String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; ByteString -&gt; ByteString
</span><span class="hs-identifier hs-var">BCL.append</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; ByteString
</span><a href="OpenAPIPetstore.Core.html#configHost"><span class="hs-identifier hs-var">configHost</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[ByteString] -&gt; ByteString
</span><span class="hs-identifier hs-var">BCL.concat</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept -&gt; [ByteString]
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept -&gt; [ByteString]
</span><a href="OpenAPIPetstore.Core.html#rUrlPath"><span class="hs-identifier hs-var">rUrlPath</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157783"><span class="hs-identifier hs-var">req0</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-178"></span><span>    </span><span id="local-6989586621679157791"><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157791"><span class="hs-identifier hs-var">req1</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">IO (OpenAPIPetstoreRequest req contentType res accept)
-&gt; KatipT IO (OpenAPIPetstoreRequest req contentType res accept)
forall a. IO a -&gt; KatipT IO a
forall (m :: * -&gt; *) a. MonadIO m =&gt; IO a -&gt; m a
</span><span class="hs-identifier hs-var">P.liftIO</span></span><span> </span><span class="annot"><span class="annottext">(IO (OpenAPIPetstoreRequest req contentType res accept)
 -&gt; KatipT IO (OpenAPIPetstoreRequest req contentType res accept))
-&gt; IO (OpenAPIPetstoreRequest req contentType res accept)
-&gt; KatipT IO (OpenAPIPetstoreRequest req contentType res accept)
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreConfig
-&gt; IO (OpenAPIPetstoreRequest req contentType res accept)
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreConfig
-&gt; IO (OpenAPIPetstoreRequest req contentType res accept)
</span><a href="OpenAPIPetstore.Core.html#_applyAuthMethods"><span class="hs-identifier hs-var">_applyAuthMethods</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157783"><span class="hs-identifier hs-var">req0</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span>
</span><span id="line-179"></span><span>    </span><span class="annot"><span class="annottext">Bool -&gt; KatipT IO () -&gt; KatipT IO ()
forall (f :: * -&gt; *). Applicative f =&gt; Bool -&gt; f () -&gt; f ()
</span><span class="hs-identifier hs-var">P.when</span></span><span>
</span><span id="line-180"></span><span>        </span><span class="hs-special">(</span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; Bool
</span><a href="OpenAPIPetstore.Core.html#configValidateAuthMethods"><span class="hs-identifier hs-var">configValidateAuthMethods</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">&amp;&amp;</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Bool -&gt; Bool
</span><span class="hs-identifier hs-var">not</span></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Bool)
-&gt; (OpenAPIPetstoreRequest req contentType res accept -&gt; Bool)
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; Bool
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">[TypeRep] -&gt; Bool
forall a. [a] -&gt; Bool
forall (t :: * -&gt; *) a. Foldable t =&gt; t a -&gt; Bool
</span><span class="hs-identifier hs-var">null</span></span><span> </span><span class="annot"><span class="annottext">([TypeRep] -&gt; Bool)
-&gt; (OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep])
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; Bool
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep]
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep]
</span><a href="OpenAPIPetstore.Core.html#rAuthTypes"><span class="hs-identifier hs-var">rAuthTypes</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157791"><span class="hs-identifier hs-var">req1</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-181"></span><span>        </span><span class="hs-special">(</span><span class="annot"><span class="annottext">AuthMethodException -&gt; KatipT IO ()
forall (m :: * -&gt; *) e a. (MonadThrow m, Exception e) =&gt; e -&gt; m a
</span><span class="hs-identifier hs-var">E.throw</span></span><span> </span><span class="annot"><span class="annottext">(AuthMethodException -&gt; KatipT IO ())
-&gt; AuthMethodException -&gt; KatipT IO ()
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; AuthMethodException
</span><a href="OpenAPIPetstore.Core.html#AuthMethodException"><span class="hs-identifier hs-var">AuthMethodException</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; AuthMethodException) -&gt; String -&gt; AuthMethodException
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><span class="hs-operator hs-var">$</span></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;AuthMethod not configured: &quot;</span></span><span> </span><span class="annot"><span class="annottext">String -&gt; ShowS
forall a. Semigroup a =&gt; a -&gt; a -&gt; a
</span><span class="hs-operator hs-var">&lt;&gt;</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">TypeRep -&gt; String
forall a. Show a =&gt; a -&gt; String
</span><span class="hs-identifier hs-var">show</span></span><span> </span><span class="annot"><span class="annottext">(TypeRep -&gt; String)
-&gt; (OpenAPIPetstoreRequest req contentType res accept -&gt; TypeRep)
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; String
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">[TypeRep] -&gt; TypeRep
forall a. HasCallStack =&gt; [a] -&gt; a
</span><span class="hs-identifier hs-var">head</span></span><span> </span><span class="annot"><span class="annottext">([TypeRep] -&gt; TypeRep)
-&gt; (OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep])
-&gt; OpenAPIPetstoreRequest req contentType res accept
-&gt; TypeRep
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep]
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept -&gt; [TypeRep]
</span><a href="OpenAPIPetstore.Core.html#rAuthTypes"><span class="hs-identifier hs-var">rAuthTypes</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157791"><span class="hs-identifier hs-var">req1</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-182"></span><span>    </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679157805"><span class="annot"><span class="annottext">req2 :: OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157805"><span class="hs-identifier hs-var hs-var">req2</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157791"><span class="hs-identifier hs-var">req1</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
-&gt; (OpenAPIPetstoreRequest req contentType res accept
    -&gt; OpenAPIPetstoreRequest req contentType res accept)
-&gt; OpenAPIPetstoreRequest req contentType res accept
forall a b. a -&gt; (a -&gt; b) -&gt; b
</span><span class="hs-operator hs-var">&amp;</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreRequest req contentType res accept
forall req contentType res accept.
MimeType contentType =&gt;
OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreRequest req contentType res accept
</span><a href="OpenAPIPetstore.Core.html#_setContentTypeHeader"><span class="hs-identifier hs-var">_setContentTypeHeader</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
-&gt; (OpenAPIPetstoreRequest req contentType res accept
    -&gt; OpenAPIPetstoreRequest req contentType res accept)
-&gt; OpenAPIPetstoreRequest req contentType res accept
forall a b. a -&gt; (a -&gt; b) -&gt; b
</span><span class="hs-operator hs-var">&amp;</span></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreRequest req contentType res accept
forall req contentType res accept.
MimeType accept =&gt;
OpenAPIPetstoreRequest req contentType res accept
-&gt; OpenAPIPetstoreRequest req contentType res accept
</span><a href="OpenAPIPetstore.Core.html#_setAcceptHeader"><span class="hs-identifier hs-var">_setAcceptHeader</span></a></span><span>
</span><span id="line-183"></span><span>        </span><span id="local-6989586621679157808"><span class="annot"><span class="annottext">params :: Params
</span><a href="#local-6989586621679157808"><span class="hs-identifier hs-var hs-var">params</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept -&gt; Params
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept -&gt; Params
</span><a href="OpenAPIPetstore.Core.html#rParams"><span class="hs-identifier hs-var">rParams</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157805"><span class="hs-identifier hs-var">req2</span></a></span><span>
</span><span id="line-184"></span><span>        </span><span id="local-6989586621679157817"><span class="annot"><span class="annottext">reqHeaders :: RequestHeaders
</span><a href="#local-6989586621679157817"><span class="hs-identifier hs-var hs-var">reqHeaders</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">HeaderName
</span><span class="hs-string">&quot;User-Agent&quot;</span></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">Text -&gt; ByteString
forall a. ToHttpApiData a =&gt; a -&gt; ByteString
</span><span class="hs-identifier hs-var">WH.toHeader</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; Text
</span><a href="OpenAPIPetstore.Core.html#configUserAgent"><span class="hs-identifier hs-var">configUserAgent</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">(HeaderName, ByteString) -&gt; RequestHeaders -&gt; RequestHeaders
forall a. a -&gt; [a] -&gt; [a]
</span><span class="hs-glyph hs-var">:</span></span><span> </span><span class="annot"><span class="annottext">Params -&gt; RequestHeaders
</span><a href="OpenAPIPetstore.Core.html#paramsHeaders"><span class="hs-identifier hs-var">paramsHeaders</span></a></span><span> </span><span class="annot"><span class="annottext">Params
</span><a href="#local-6989586621679157808"><span class="hs-identifier hs-var">params</span></a></span><span>
</span><span id="line-185"></span><span>        </span><span id="local-6989586621679157821"><span class="annot"><span class="annottext">reqQuery :: ByteString
</span><a href="#local-6989586621679157821"><span class="hs-identifier hs-var hs-var">reqQuery</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621679157822"><span class="annot"><span class="annottext">query :: Query
</span><a href="#local-6989586621679157822"><span class="hs-identifier hs-var hs-var">query</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Params -&gt; Query
</span><a href="OpenAPIPetstore.Core.html#paramsQuery"><span class="hs-identifier hs-var">paramsQuery</span></a></span><span> </span><span class="annot"><span class="annottext">Params
</span><a href="#local-6989586621679157808"><span class="hs-identifier hs-var">params</span></a></span><span>
</span><span id="line-186"></span><span>                       </span><span id="local-6989586621679157824"><span class="annot"><span class="annottext">queryExtraUnreserved :: ByteString
</span><a href="#local-6989586621679157824"><span class="hs-identifier hs-var hs-var">queryExtraUnreserved</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; ByteString
</span><a href="OpenAPIPetstore.Core.html#configQueryExtraUnreserved"><span class="hs-identifier hs-var">configQueryExtraUnreserved</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157782"><span class="hs-identifier hs-var">config</span></a></span><span>
</span><span id="line-187"></span><span>                   </span><span class="hs-keyword">in</span><span> </span><span class="hs-keyword">if</span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; Bool
</span><span class="hs-identifier hs-var">B.null</span></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157824"><span class="hs-identifier hs-var">queryExtraUnreserved</span></a></span><span>
</span><span id="line-188"></span><span>                        </span><span class="hs-keyword">then</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; Query -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.renderQuery</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span> </span><span class="annot"><span class="annottext">Query
</span><a href="#local-6989586621679157822"><span class="hs-identifier hs-var">query</span></a></span><span>
</span><span id="line-189"></span><span>                        </span><span class="hs-keyword">else</span><span> </span><span class="annot"><span class="annottext">Bool -&gt; PartialEscapeQuery -&gt; ByteString
</span><span class="hs-identifier hs-var">NH.renderQueryPartialEscape</span></span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">ByteString -&gt; Query -&gt; PartialEscapeQuery
</span><a href="OpenAPIPetstore.Core.html#toPartialEscapeQuery"><span class="hs-identifier hs-var">toPartialEscapeQuery</span></a></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157824"><span class="hs-identifier hs-var">queryExtraUnreserved</span></a></span><span> </span><span class="annot"><span class="annottext">Query
</span><a href="#local-6989586621679157822"><span class="hs-identifier hs-var">query</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-190"></span><span>        </span><span id="local-6989586621679157830"><span class="annot"><span class="annottext">pReq :: Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var hs-var">pReq</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157784"><span class="hs-identifier hs-var">parsedReq</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">method :: ByteString
</span><span class="hs-identifier hs-var">NH.method</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept -&gt; ByteString
forall req contentType res accept.
OpenAPIPetstoreRequest req contentType res accept -&gt; ByteString
</span><a href="OpenAPIPetstore.Core.html#rMethod"><span class="hs-identifier hs-var">rMethod</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreRequest req contentType res accept
</span><a href="#local-6989586621679157805"><span class="hs-identifier hs-var">req2</span></a></span><span>
</span><span id="line-191"></span><span>                        </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">requestHeaders :: RequestHeaders
</span><span class="hs-identifier hs-var">NH.requestHeaders</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">RequestHeaders
</span><a href="#local-6989586621679157817"><span class="hs-identifier hs-var">reqHeaders</span></a></span><span>
</span><span id="line-192"></span><span>                        </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">queryString :: ByteString
</span><span class="hs-identifier hs-var">NH.queryString</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157821"><span class="hs-identifier hs-var">reqQuery</span></a></span><span>
</span><span id="line-193"></span><span>                        </span><span class="hs-special">}</span><span>
</span><span id="line-194"></span><span>    </span><span id="local-6989586621679157832"><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157832"><span class="hs-identifier hs-var">outReq</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">Params -&gt; ParamBody
</span><a href="OpenAPIPetstore.Core.html#paramsBody"><span class="hs-identifier hs-var">paramsBody</span></a></span><span> </span><span class="annot"><span class="annottext">Params
</span><a href="#local-6989586621679157808"><span class="hs-identifier hs-var">params</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-195"></span><span>        </span><span class="annot"><span class="annottext">ParamBody
</span><a href="OpenAPIPetstore.Core.html#ParamBodyNone"><span class="hs-identifier hs-var">ParamBodyNone</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Request -&gt; KatipT IO Request
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var">pReq</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">requestBody :: RequestBody
</span><span class="hs-identifier hs-var">NH.requestBody</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">RequestBody
forall a. Monoid a =&gt; a
</span><span class="hs-identifier hs-var">mempty</span></span><span> </span><span class="hs-special">}</span><span class="hs-special">)</span><span>
</span><span id="line-196"></span><span>        </span><span class="annot"><a href="OpenAPIPetstore.Core.html#ParamBodyB"><span class="hs-identifier hs-type">ParamBodyB</span></a></span><span> </span><span id="local-6989586621679157836"><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157836"><span class="hs-identifier hs-var">bs</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Request -&gt; KatipT IO Request
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var">pReq</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">requestBody :: RequestBody
</span><span class="hs-identifier hs-var">NH.requestBody</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; RequestBody
</span><span class="hs-identifier hs-var">NH.RequestBodyBS</span></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157836"><span class="hs-identifier hs-var">bs</span></a></span><span> </span><span class="hs-special">}</span><span class="hs-special">)</span><span>
</span><span id="line-197"></span><span>        </span><span class="annot"><a href="OpenAPIPetstore.Core.html#ParamBodyBL"><span class="hs-identifier hs-type">ParamBodyBL</span></a></span><span> </span><span id="local-6989586621679157839"><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157839"><span class="hs-identifier hs-var">bl</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Request -&gt; KatipT IO Request
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var">pReq</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">requestBody :: RequestBody
</span><span class="hs-identifier hs-var">NH.requestBody</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; RequestBody
</span><span class="hs-identifier hs-var">NH.RequestBodyLBS</span></span><span> </span><span class="annot"><span class="annottext">ByteString
</span><a href="#local-6989586621679157839"><span class="hs-identifier hs-var">bl</span></a></span><span> </span><span class="hs-special">}</span><span class="hs-special">)</span><span>
</span><span id="line-198"></span><span>        </span><span class="annot"><a href="OpenAPIPetstore.Core.html#ParamBodyFormUrlEncoded"><span class="hs-identifier hs-type">ParamBodyFormUrlEncoded</span></a></span><span> </span><span id="local-6989586621679157841"><span class="annot"><span class="annottext">Form
</span><a href="#local-6989586621679157841"><span class="hs-identifier hs-var">form</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Request -&gt; KatipT IO Request
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var">pReq</span></a></span><span> </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">requestBody :: RequestBody
</span><span class="hs-identifier hs-var">NH.requestBody</span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">ByteString -&gt; RequestBody
</span><span class="hs-identifier hs-var">NH.RequestBodyLBS</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Form -&gt; ByteString
</span><span class="hs-identifier hs-var">WH.urlEncodeForm</span></span><span> </span><span class="annot"><span class="annottext">Form
</span><a href="#local-6989586621679157841"><span class="hs-identifier hs-var">form</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">}</span><span class="hs-special">)</span><span>
</span><span id="line-199"></span><span>        </span><span class="annot"><a href="OpenAPIPetstore.Core.html#ParamBodyMultipartFormData"><span class="hs-identifier hs-type">ParamBodyMultipartFormData</span></a></span><span> </span><span id="local-6989586621679157844"><span class="annot"><span class="annottext">[Part]
</span><a href="#local-6989586621679157844"><span class="hs-identifier hs-var">parts</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[Part] -&gt; Request -&gt; KatipT IO Request
forall (m :: * -&gt; *). MonadIO m =&gt; [Part] -&gt; Request -&gt; m Request
</span><span class="hs-identifier hs-var">NH.formDataBody</span></span><span> </span><span class="annot"><span class="annottext">[Part]
</span><a href="#local-6989586621679157844"><span class="hs-identifier hs-var">parts</span></a></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157830"><span class="hs-identifier hs-var">pReq</span></a></span><span>
</span><span id="line-200"></span><span>
</span><span id="line-201"></span><span>    </span><span class="annot"><span class="annottext">InitRequest req contentType res accept
-&gt; KatipT IO (InitRequest req contentType res accept)
forall a. a -&gt; KatipT IO a
forall (f :: * -&gt; *) a. Applicative f =&gt; a -&gt; f a
</span><span class="hs-identifier hs-var">pure</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request -&gt; InitRequest req contentType res accept
forall req contentType res accept.
Request -&gt; InitRequest req contentType res accept
</span><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-var">InitRequest</span></a></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157832"><span class="hs-identifier hs-var">outReq</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-202"></span><span>
</span><span id="line-203"></span><span class="annot"><span class="hs-comment">-- | modify the underlying Request</span></span><span>
</span><span id="line-204"></span><span id="local-6989586621679157363"><span id="local-6989586621679157364"><span id="local-6989586621679157365"><span id="local-6989586621679157366"><span class="annot"><a href="OpenAPIPetstore.Client.html#modifyInitRequest"><span class="hs-identifier hs-type">modifyInitRequest</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157363"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157364"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157365"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157366"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">NH.Request</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Request</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157363"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157364"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157365"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157366"><span class="hs-identifier hs-type">accept</span></a></span></span></span></span></span><span>
</span><span id="line-205"></span><span id="modifyInitRequest"><span class="annot"><span class="annottext">modifyInitRequest :: forall req contentType res accept.
InitRequest req contentType res accept
-&gt; (Request -&gt; Request) -&gt; InitRequest req contentType res accept
</span><a href="OpenAPIPetstore.Client.html#modifyInitRequest"><span class="hs-identifier hs-var hs-var">modifyInitRequest</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span id="local-6989586621679157847"><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157847"><span class="hs-identifier hs-var">req</span></a></span></span><span class="hs-special">)</span><span> </span><span id="local-6989586621679157848"><span class="annot"><span class="annottext">Request -&gt; Request
</span><a href="#local-6989586621679157848"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Request -&gt; InitRequest req contentType res accept
forall req contentType res accept.
Request -&gt; InitRequest req contentType res accept
</span><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-var">InitRequest</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request -&gt; Request
</span><a href="#local-6989586621679157848"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157847"><span class="hs-identifier hs-var">req</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-206"></span><span>
</span><span id="line-207"></span><span class="annot"><span class="hs-comment">-- | modify the underlying Request (monadic)</span></span><span>
</span><span id="line-208"></span><span id="local-6989586621679157371"><span id="local-6989586621679157372"><span id="local-6989586621679157373"><span id="local-6989586621679157374"><span id="local-6989586621679157375"><span class="annot"><a href="OpenAPIPetstore.Client.html#modifyInitRequestM"><span class="hs-identifier hs-type">modifyInitRequestM</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Monad</span></span><span> </span><span class="annot"><a href="#local-6989586621679157371"><span class="hs-identifier hs-type">m</span></a></span><span> </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157372"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157373"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157374"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157375"><span class="hs-identifier hs-type">accept</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">NH.Request</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621679157371"><span class="hs-identifier hs-type">m</span></a></span><span> </span><span class="annot"><span class="hs-identifier hs-type">NH.Request</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621679157371"><span class="hs-identifier hs-type">m</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157372"><span class="hs-identifier hs-type">req</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157373"><span class="hs-identifier hs-type">contentType</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157374"><span class="hs-identifier hs-type">res</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157375"><span class="hs-identifier hs-type">accept</span></a></span><span class="hs-special">)</span></span></span></span></span></span><span>
</span><span id="line-209"></span><span id="modifyInitRequestM"><span class="annot"><span class="annottext">modifyInitRequestM :: forall (m :: * -&gt; *) req contentType res accept.
Monad m =&gt;
InitRequest req contentType res accept
-&gt; (Request -&gt; m Request)
-&gt; m (InitRequest req contentType res accept)
</span><a href="OpenAPIPetstore.Client.html#modifyInitRequestM"><span class="hs-identifier hs-var hs-var">modifyInitRequestM</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-type">InitRequest</span></a></span><span> </span><span id="local-6989586621679157855"><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157855"><span class="hs-identifier hs-var">req</span></a></span></span><span class="hs-special">)</span><span> </span><span id="local-6989586621679157856"><span class="annot"><span class="annottext">Request -&gt; m Request
</span><a href="#local-6989586621679157856"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Request -&gt; InitRequest req contentType res accept)
-&gt; m Request -&gt; m (InitRequest req contentType res accept)
forall a b. (a -&gt; b) -&gt; m a -&gt; m b
forall (f :: * -&gt; *) a b. Functor f =&gt; (a -&gt; b) -&gt; f a -&gt; f b
</span><span class="hs-identifier hs-var">fmap</span></span><span> </span><span class="annot"><span class="annottext">Request -&gt; InitRequest req contentType res accept
forall req contentType res accept.
Request -&gt; InitRequest req contentType res accept
</span><a href="OpenAPIPetstore.Client.html#InitRequest"><span class="hs-identifier hs-var">InitRequest</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Request -&gt; m Request
</span><a href="#local-6989586621679157856"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">Request
</span><a href="#local-6989586621679157855"><span class="hs-identifier hs-var">req</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-210"></span><span>
</span><span id="line-211"></span><span class="annot"><span class="hs-comment">-- ** Logging</span></span><span>
</span><span id="line-212"></span><span>
</span><span id="line-213"></span><span class="annot"><span class="hs-comment">-- | Run a block using the configured logger instance</span></span><span>
</span><span id="line-214"></span><span id="local-6989586621679157381"><span id="local-6989586621679157382"><span class="annot"><a href="OpenAPIPetstore.Client.html#runConfigLog"><span class="hs-identifier hs-type">runConfigLog</span></a></span><span>
</span><span id="line-215"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">P.MonadIO</span></span><span> </span><span class="annot"><a href="#local-6989586621679157381"><span class="hs-identifier hs-type">m</span></a></span><span>
</span><span id="line-216"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.LoggingKatip.html#LogExec"><span class="hs-identifier hs-type">LogExec</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157381"><span class="hs-identifier hs-type">m</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157382"><span class="hs-identifier hs-type">a</span></a></span></span></span><span>
</span><span id="line-217"></span><span id="runConfigLog"><span class="annot"><span class="annottext">runConfigLog :: forall (m :: * -&gt; *) a.
MonadIO m =&gt;
OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLog"><span class="hs-identifier hs-var hs-var">runConfigLog</span></a></span></span><span> </span><span id="local-6989586621679157860"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157860"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; LogExecWithContext
</span><a href="OpenAPIPetstore.Core.html#configLogExecWithContext"><span class="hs-identifier hs-var">configLogExecWithContext</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157860"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; LogContext
</span><a href="OpenAPIPetstore.Core.html#configLogContext"><span class="hs-identifier hs-var">configLogContext</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157860"><span class="hs-identifier hs-var">config</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-218"></span><span>
</span><span id="line-219"></span><span class="annot"><span class="hs-comment">-- | Run a block using the configured logger instance (logs exceptions)</span></span><span>
</span><span id="line-220"></span><span id="local-6989586621679157233"><span id="local-6989586621679157234"><span class="annot"><a href="OpenAPIPetstore.Client.html#runConfigLogWithExceptions"><span class="hs-identifier hs-type">runConfigLogWithExceptions</span></a></span><span>
</span><span id="line-221"></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="hs-identifier hs-type">E.MonadCatch</span></span><span> </span><span class="annot"><a href="#local-6989586621679157233"><span class="hs-identifier hs-type">m</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="hs-identifier hs-type">P.MonadIO</span></span><span> </span><span class="annot"><a href="#local-6989586621679157233"><span class="hs-identifier hs-type">m</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-222"></span><span>  </span><span class="hs-glyph">=&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">T.Text</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.Core.html#OpenAPIPetstoreConfig"><span class="hs-identifier hs-type">OpenAPIPetstoreConfig</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="OpenAPIPetstore.LoggingKatip.html#LogExec"><span class="hs-identifier hs-type">LogExec</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157233"><span class="hs-identifier hs-type">m</span></a></span><span> </span><span class="annot"><a href="#local-6989586621679157234"><span class="hs-identifier hs-type">a</span></a></span></span></span><span>
</span><span id="line-223"></span><span id="runConfigLogWithExceptions"><span class="annot"><span class="annottext">runConfigLogWithExceptions :: forall (m :: * -&gt; *) a.
(MonadCatch m, MonadIO m) =&gt;
Text -&gt; OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLogWithExceptions"><span class="hs-identifier hs-var hs-var">runConfigLogWithExceptions</span></a></span></span><span> </span><span id="local-6989586621679157873"><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157873"><span class="hs-identifier hs-var">src</span></a></span></span><span> </span><span id="local-6989586621679157874"><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157874"><span class="hs-identifier hs-var">config</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig -&gt; LogExec m a
forall (m :: * -&gt; *) a.
MonadIO m =&gt;
OpenAPIPetstoreConfig -&gt; LogExec m a
</span><a href="OpenAPIPetstore.Client.html#runConfigLog"><span class="hs-identifier hs-var">runConfigLog</span></a></span><span> </span><span class="annot"><span class="annottext">OpenAPIPetstoreConfig
</span><a href="#local-6989586621679157874"><span class="hs-identifier hs-var">config</span></a></span><span> </span><span class="annot"><span class="annottext">LogExec m a -&gt; (KatipT m a -&gt; KatipT m a) -&gt; LogExec m a
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><span class="hs-operator hs-var">.</span></span><span> </span><span class="annot"><span class="annottext">Text -&gt; KatipT m a -&gt; KatipT m a
forall (m :: * -&gt; *) a.
(Katip m, MonadCatch m, Applicative m) =&gt;
Text -&gt; m a -&gt; m a
</span><a href="OpenAPIPetstore.LoggingKatip.html#logExceptions"><span class="hs-identifier hs-var">logExceptions</span></a></span><span> </span><span class="annot"><span class="annottext">Text
</span><a href="#local-6989586621679157873"><span class="hs-identifier hs-var">src</span></a></span><span>
</span><span id="line-224"></span></pre></body></html>