hScraper-0.1.0.0: A Haskell library to scrape and crawl web-pages

Safe HaskellNone
LanguageHaskell2010

HScraper.Network

Description

Module for fetching different requests over network(Wrapper around http-conduit).

Synopsis

Documentation

fetchResponse :: String -> IO Text Source

A Simple wrapper around simpleHttp so that it goes along with with other functions.

parseParams :: [(String, String)] -> String Source

Parses a list of (key,value) pairs to pass with GET and POST requests.

fetchRequestWith :: Request -> Manager -> IO Text Source

takes a Request and a Manager and returns the response. Useful when querying with a modified request.

defaultGETRequest :: String -> [(String, String)] -> IO Request Source

Minimal GET request, modify it to add proxy,cookies,user-agent etc. Then fetch using @fetchRequestWith.

fetchGETRequest :: String -> [(String, String)] -> IO Text Source

Fetches request using @defaultGETRequest.

defaultPOSTRequest :: String -> [(String, String)] -> IO Request Source

Minimal POST request, modify it to add proxy,cookies,user-agent etc. Then fetch using @fetchRequestWith.

fetchPOSTRequest :: String -> [(String, String)] -> IO Text Source

Fetches request using @defaultPOSTRequest.