{      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz None{0send the headers as well, necessary for a proxy |{|{|None}~request method  status code }~}~NoneNone None8A simple representation of the HTTP response created by  lbsConsumer. host/port *Response containing unparseable redirect. List of encountered responses containing redirects in reverse chronological order; including last redirect, which triggered the exception and was not followed. ?Define a HTTP proxy, consisting of a hostname and port number. !The host name of the HTTP proxy. #The port number of the HTTP proxy. When using one of the    /  constructors,  you must ensure  that the Source- can be called multiple times. Usually this  is not a problem. The  will send a chunked request 8 body, note that not all servers support this. Only use   if you know the server you're - sending to supports chunked request bodies. $KAll information on how to connect to a host and what should be sent in the  HTTP request. /If you simply wish to download from a URL, see parseUrl. KThe constructor for this data type is not exposed. Instead, you should use  either the def+ method to retrieve a default instance, or parseUrl to M construct from a URL, and then use the records below to make modifications. H This approach allows http-conduit to add configuration options without # breaking backwards compatibility. GFor example, to construct a POST request, you could do something like:  3 initReq <- parseUrl "http://www.example.com/path"  let req = initReq  { method = "POST"  } !For more information, please see   +http://www.yesodweb.com/book/settings-types. %#HTTP request method, eg GET, POST. & Whether to use HTTPS (ie, SSL). 'SSL client certificates *.Everything from the host to the query string. ,Custom HTTP request headers CAs already stated in the introduction, the Content-Length and Host I headers are set automatically by this module, and shall not be added to  requestHeaders. CMoreover, the Accept-Encoding header is set implicitly to gzip for H convenience by default. This behaviour can be overridden if needed, by J setting the header explicitly to a different value. In order to omit the 6 Accept-Header altogether, set it to the empty string "". If you need an J empty Accept-Header (i.e. requesting the identity encoding), set it to a $ non-empty white-space string, e.g. " " . See RFC 2616 section 14.3 for J details about the semantics of the Accept-Header field. If you request a H content-encoding not supported by this module, you will have to decode  it yourself (see also the 2 field). ENote: Multiple header fields with the same field-name will result in 3 multiple header fields being sent and therefore it's the responsibility G of the client code to ensure that the rules from RFC 2616 section 4.2  are honoured. .Optional HTTP proxy. /Optional SOCKS proxy. 0 Optional resolved host address.  Since 1.8.9 1If True, a chunked and/or gzipped body will not be  decoded. Use with caution. 24Predicate to specify whether gzipped data should be  decompressed on the fly (see alwaysDecompress and  browserDecompress). Default: browserDecompress. 3EHow many redirects to follow when getting a resource. 0 means follow " no redirects. Default value: 10. 4GCheck the status code. Note that this will run after all redirects are  performed. Default: return a StatusCodeException on non-2XX responses. 52Number of microseconds to wait for a response. If Nothing , will wait # indefinitely. Default: 5 seconds. 6DWraps the calls for getting new connections. This can be useful for G instituting some kind of timeouts. The first argument is the value of  responseTimeout3. Second argument is the exception to be thrown on  failure.  Default: If responseTimeout is Nothing, does nothing. Otherwise, 4 institutes timeout, and returns remaining time for responseTimeout. Exported since 1.8.8  Since 1.8.7  Since 1.8.7  Since 1.1.2. E  !"#$%&'()*+,-./0123456;  !"#$%&'()*+,-./0123456  #"! $%&'()*+,-./0123456 NoneConnKey& consists of a hostname, a port and a Bool  specifying whether to use SSL. #Hostname or resolved host address. 70Keeps track of open connections for keep-alive. ( If possible, you should share a single 7( between multiple threads and requests. Nothing' indicates that the manager is closed. This is a per-ConnKey value. !Check if a certificate is valid. %Cache of validated certificates. The UTCTime gives the expiration / time for the validity of the certificate. The Ascii is the hostname. 8Settings for a Manager. Please use the  function and then modify  individual settings. 9CNumber of connections to a single host to keep alive. Default: 10. :CCheck if the server certificate is valid. Only relevant for HTTPS. ;ALoad up the certificate store. By default uses the system store. <-Check certificates using the operating system's certificate checker. DAdd a new element to the list, up to the given maximum number. If we're ; already at the maximum, return the new value as leftover. = Create a 7. You must manually call @ to shut it down. Creating a new 75 is an expensive operation, you are advised to share  a single 7 between requests instead. +Collect and destroy any stale connections. >LCreate a new manager, use it in the provided function, and then release it. GThis function uses the default manager settings. For more control, use  ?. ?cCreate a new manager with provided settings, use it in the provided function, and then release it. @Close all connections in a 7. Afterwards, the  7 can be reused if desired. !This function needs to acquire a ConnInfo- either from the Manager or  via I/O, and register it with the  ResourceT so it is guaranteed to be - either released or returned to the manager. ICreate an exception to be thrown if the connection for the given request  fails. ,789:;<=>?@optional socks proxy host port optional socks proxy  Target host  Target port  Proxy host  Proxy port optional SOCKS proxy 789:;<=>?@789:;<=>?@ None AConvert a URL into a $. $This defaults some of the values in $, such as setting % to  GET and , to []. Since this function uses +, the return monad can be anything that is  an instance of  , such as  or . BAdd a ? to the request. If it is absolute (includes a host name), add  it as per D9; if it is relative, merge it with the existing request. C Extract a  from the request. D Validate a , then add it to the request. E'Always decompress a compressed stream. F:Decompress a compressed stream unless the content-type is 'application/x-tar'. GKAdd a Basic Auth header (with the specified user name and password) to the ' given Request. Ignore error handling: applyBasicAuth user pass $ fromJust $ parseUrl url HFAdd a proxy to the Request so that the Request when executed will use  the provided proxy. I"Add url-encoded parameters to the $. This sets a new -), adds a content-type request header and  changes the % to POST. ABCDEFGHIresponse headers 9  !"#$%&'()*+,-./0123456ABCDEFGHI ABCDEFGHI NoneJJIf a request is a redirection (status code 3xx) this function will create J a new request from the old request, the server headers returned with the E redirection, and the redirection code itself. This function returns  ' if the code is not a 3xx, there is no location header included, or if the  redirected response couldn't be parsed with A. JIf a user of this library wants to know the url chain that results from a N specific request, that user has to re-implement the redirect-following logic 6 themselves. An example of that might look like this: J myHttp req man = E.catch (runResourceT $ http req' man >> return [req']) B (\ (StatusCodeException status headers) -> do P l <- myHttp (fromJust $ nextRequest status headers) man + return $ req' : l) , where req' = req { redirectCount = 0 } ` nextRequest status headers = getRedirectedRequest req' headers $ W.statusCode status K Convert a  that has a  body to one with a lazy   body. This function can'/t be a Conduit, since it would lose leftovers. New version of  sinkHeaders that doesn' t use attoparsec. Should create  more meaningful exceptions.  Since 1.8.7 JK  JKJK None 8This corresponds to the subcomponent algorithm entitled "Domain Matching" detailed  in section 5.1.3 8This corresponds to the subcomponent algorithm entitled "Paths" detailed  in section 5.1.4 8This corresponds to the subcomponent algorithm entitled " Path-Match" detailed  in section 5.1.4 8Are we configured to reject cookies for domains such as "com"? \DThis corresponds to the eviction algorithm described in Section 5.3 " Storage Model" ]This applies the ^ to a given Request ^;This corresponds to the algorithm described in Section 5.4 "The Cookie Header" _ This applies ` to a given Response `;This corresponds to the algorithm described in Section 5.3 " Storage Model" # This function consists of calling b followed by a. 4 Use this function if you plan to do both in a row.  b and a2 are only provided for more fine-grained control. aSInsert a cookie created by generateCookie into the cookie jar (or not if it shouldn't be allowed in) b/Turn a SetCookie into a Cookie, if it is valid empty cookie jar 'LMNOPQRSTUVWXYZ[\Input cookie jar Value that should be used as "now" Filtered cookie jar ]The request to insert into Current cookie jar Value that should be used as "now" C(Ouptut request, Updated cookie jar (last-access-time is updated)) ^Input request Current cookie jar Value that should be used as "now" .Whether or not this request is coming from an "http"/ source (not javascript or anything like that) (Contents of a "Cookie"; header, Updated cookie jar (last-access-time is updated)) _Response received from server %Request which generated the response Value that should be used as "now" Current cookie jar Q(Updated cookie jar with cookies from the Response, The response stripped of any " Set-Cookie" header) `The  the cookie jar is receiving :The request that originated the response that yielded the  Value that should be used as "now" .Whether or not this request is coming from an "http"/ source (not javascript or anything like that) Input cookie jar to modify Updated cookie jar aThe  the cookie jar is receiving Input cookie jar to modify .Whether or not this request is coming from an "http"/ source (not javascript or anything like that) Updated (or not) cookie jar bThe  we are encountering :The request that originated the response that yielded the  Value that should be used as "now" .Whether or not this request is coming from an "http"/ source (not javascript or anything like that) The optional output cookie "LMNOPQRSTUVWXYZ[\]^_`abLM NOPQRSTUVWXYZ[\]^_`abNonecRedirect loop c3 _function which performs a request and returns a response, and possibly another request if there's a redirect.  BCDcCDBccNoned&A single part of a multipart message. fName of the corresponding <input> g)A file name, if this is an attached file h Content type i#Action in m which returns the body  of a message. Kludge to get rid of  constraint lMake a d= from a file, the entire file will reside in memory at once. ' If you want constant memory usage use m mStream d from a file. nn) will read a file and send it in chunks. 1Note that not all servers support this. Only use n  if you know the server you'0re sending to supports chunked request bodies. o Construct a d from form name, filepath and a   ` partFileRequestBody "who_calls" "caller.json" $ RequestBodyBS "{\"caller\":\"Jason J Jason\"}"  -- empty upload form * partFileRequestBody "file" mempty mempty p Construct a d from action returning the  = partFileRequestBodyM "cat_photo" "haskell-the-cat.jpg" $ do U size <- fromInteger <$> withBinaryFile "haskell-the-cat.jpg" ReadMode hFileSize d return $ RequestBodySource size $ CB.sourceFile "haskell-the-cat.jpg" $= CL.map fromByteString r Combine the ds to form multipart/form-data body sJGenerate a boundary simillar to those generated by WebKit-based browsers. uAdd form data to the $. This sets a new -E, adds a content-type request header and changes the method to POST. vJAdd form data to request without doing any IO. Your form data should only  contain pure parts (j, k, o). You'll have ; to supply your own boundary (for example one generated by s) w%Add form data with supplied boundary defghijklmnopqrstuvwdefghijklmnopqrstuvwdefghijklmnopuvwstrqdefghijklmnopqrstuvwNonex<The most low-level function for initiating an HTTP request. ?The first argument to this function gives a full specification = on the request: the host to connect to, whether to use SSL,  headers, etc. Please see $ for full details. The ! second argument specifies which 7 should be used. This function then returns a  with a  . The  contains the status code 0 and headers that were sent back to us, and the  ) contains the body of the request. Note  that this  allows you to have fully = interleaved IO actions during your HTTP download, making it ? possible to download very large responses in constant memory. , You may also directly connect the returned   into a $, perhaps a file or another socket. LAn important note: the response body returned by this function represents a M live HTTP connection. As such, if you do not use the response body, an open . socket will be retained until the containing  ResourceT block exits. If you K do not need the response body, it is recommended that you explicitly shut 5 down the connection immediately, using the pattern:  ! responseBody res $$+- return () HAs a more thorough example, consider the following program. Without the N explicit response body closing, the program will run out of file descriptors G around the 1000th request (depending on the operating system limits).  - import Control.Monad (replicateM_) ( import Control.Monad.IO.Class (liftIO) ( import Data.Conduit (($$+-)) / import Network (withSocketsDo)  import Network.HTTP.Conduit  5 main = withSocketsDo $ withManager $ \manager -> do ) req <- parseUrl "http://localhost/" * mapM_ (worker manager req) [1..5000]   worker manager req i = do  res <- http req manager ; responseBody res $$+- return () -- The important line , liftIO $ print (i, responseStatus res) INote: Unlike previous versions, this function will perform redirects, as  specified by the 3 setting. Get a ! without any redirect following. yDownload the specified $, returning the results as a .  This is a simplified version of x& for the common case where you simply N want the response data as a simple datatype. If you want more power, such as > interleaved actions on the response body during download, you'll need to use  x( directly. This function is defined as:   httpLbs = K <=< xEven though the " contains a lazy bytestring, this  function does not utilize lazy I/O, and therefore the entire @ response body will live in memory. If you want constant memory  usage, you'll need to use conduit packages's   returned by x. INote: Unlike previous versions, this function will perform redirects, as  specified by the 3 setting. z9Download the specified URL, following any redirects, and  return the response body. This function will  an   for any ? response with a non-2xx status code (besides 3xx redirects up & to a limit of 10 redirects). It uses A to parse the ( input. This function essentially wraps y. >Note: Even though this function returns a lazy bytestring, it  does not utilize lazy I/%O, and therefore the entire response > body will live in memory. If you want constant memory usage,  you'll need to use the conduit package and x directly. "Note: This function creates a new 7. It should be avoided  in production code. xyz_  !"#$%&'()*+,-./0123456789:;<=>?@AEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abxyztzyx#"!  $%&'()*+,-./0123456%&'()*+,-./01234567=@>?89:;9:;<MNOPQRSTUVWXYLZ[_`ba]^\AGHKJEFI  xyz  !"#$%&'(()*+,-./0123456789:;<=>?@ABC D E F G H I J K L M N O P Q R S T U V W X Y Z Z [ \ ] ^ _ ` a b c d e f g h i j k l m noppqrstuvwxyz{|}~1         D  E                 http-conduit-1.8.9Network.HTTP.ConduitNetwork.HTTP.Conduit.Internal&Network.HTTP.Conduit.MultipartFormDataNetwork.HTTP.Conduit.ChunkNetwork.HTTP.Conduit.UtilNetwork.HTTP.Conduit.ParserNetwork.HTTP.Conduit.ConnInfoNetwork.HTTP.Conduit.TypesNetwork.HTTP.Conduit.ManagerNetwork.HTTP.Conduit.RequestNetwork.HTTP.Conduit.ResponseNetwork.HTTP.Conduit.Cookiesdata-default-class-0.0.1Data.Default.Classdefnewline sinkHeadersparserHeadersFromByteStringparseChunkHeaderResponseresponseStatusresponseVersionresponseHeaders responseBody HttpExceptionInternalIOException InvalidHeaderInvalidStatusLineExpectedBlankAfter100ContinueFailedConnectionExceptionResponseTimeoutOverlongHeadersHandshakeFailedHttpParserExceptionTooManyRetriesUnparseableRedirectTooManyRedirectsInvalidUrlExceptionStatusCodeExceptionProxy proxyHost proxyPort RequestBodyRequestBodySourceChunkedRequestBodySourceRequestBodyBuilder RequestBodyBSRequestBodyLBSRequestmethodsecureclientCertificateshostportpath queryStringrequestHeaders requestBodyproxy socksProxy hostAddressrawBody decompress redirectCount checkStatusresponseTimeoutgetConnectionWrapperManagerManagerSettingsmanagerConnCountmanagerCheckCertsmanagerCertStoredefaultCheckCerts newManager withManagerwithManagerSettings closeManagerparseUrlsetUriRelativegetUrisetUrialwaysDecompressbrowserDecompressapplyBasicAuthaddProxyurlEncodedBodygetRedirectedRequest lbsResponse CookieJarCookie cookie_name cookie_valuecookie_expiry_time cookie_domain cookie_pathcookie_creation_timecookie_last_access_timecookie_persistentcookie_host_onlycookie_secure_onlycookie_http_onlycreateCookieJardestroyCookieJarevictExpiredCookiesinsertCookiesIntoRequestcomputeCookieStringupdateCookieJarreceiveSetCookieinsertCheckedCookiegenerateCookie httpRedirectPartpartName partFilenamepartContentType partGetBodypartBSpartLBSpartFilepartFileSourcepartFileSourceChunkedpartFileRequestBodypartFileRequestBodyM renderPart renderPartswebkitBoundarywebkitBoundaryPure formDataBodyformDataBodyPureformDataBodyWithBoundaryhttphttpLbs simpleHttpchunkedConduitchunkIt<>readDec hasNoBodybytestring-0.10.0.2Data.ByteString.Lazy fromStrictData.ByteStringhGetSomeStatusHeader parseHeadernotNewlineColonisSpaceisNumber notNewline parseHeaders parseStatusattribshexshexConnInfoconnRead connWrite connCloseconnSink connSource socketConn sslClientConn getSocketfirstSuccessful tls-1.1.5Network.TLS.ContextCertificateRejectExpiredCertificateRejectRevokedCertificateRejectUnknownCACertificateRejectOtherCertificateRejectReasonCertificateUsageAcceptCertificateUsageRejectCertificateUsage$fMonoidRequestBody$fShowRequestBody$fFunctorResponse SimplifiedSChunkedSSourceSBuilder ManagedConnReusedFresh ConnRelease ConnReuse DontReuseReuse ContentTypesimplify toChunked$fExceptionHttpExceptionConnKeyConnHostmConns mMaxConns mCheckCerts mCertCache addToListreapgetManagedConnfailedConnectionException HostAddressHostName NonEmptyListConsOne X509Encoded takeSocket putSocketneToList neFromList safeConnClose nonEmptyMapM_ getSocketConn socketDesc getSslConngetSslProxyConn getConnDestgetConn checkCerts connectionTo$fDefaultManagerSettingsfailure-0.2.0.1Control.FailureFailureghc-prim GHC.TypesIObase Data.MaybeMaybenetwork-2.4.1.2 Network.URIURI needsGunziprequestBuilder$fDefaultRequest $fShowRequestNothing conduit-0.5.6Data.Conduit.InternalSourceData.ByteString.Lazy.Internal ByteStringcheckHeaderLength sinkHeaders' getResponse domainMatches defaultPath pathMatchesrejectPublicSuffixes$fDefaultCookieJarCJexposeslash isIpAddressinsertIntoCookieJar!removeExistingCookieFromCookieJarisPublicSuffixcookie-0.4.0.1 Web.Cookie SetCookie$fShowCookieJar $fEqCookieJar $fOrdCookie $fEqCookieresourcet-0.4.8%Control.Monad.Trans.Resource.Internal liftResourceT_mmapGHC.BaseFunctorcp $fShowPartSinkhttpRawlifted-base-0.2.1.0Control.Exception.LiftedthrowIOwrapIOException