-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | A library and a command line tool to access bit.ly URL shortener. -- -- This package allows to use bit.ly and j.mp URL shortening service from -- Haskell. Currently it supports shorten and expand requests. -- -- API key is required. Please find yours at -- http://bit.ly/account/. -- -- Configuration file (`~/.bitly`) format: -- --
--   login = your_bit.ly_login
--   apikey = your_API_key
--   
-- -- Examples (command line utility): -- --
--   $ echo "Text with an URL: http://example.com/" | bitly
--   Text with an URL: http://bit.ly/2eSq1z
--   $ bitly shorten http://example.com
--   http://bit.ly/2eSq1z
--   $ bitly expand http://bit.ly/2eSq1z
--   http://example.com/
--   
@package Bitly @version 0.0.3 -- | This package allows to use bit.ly and j.mp URL -- shortening service from Haskell programs. See also -- Network.TinyURL module. module Network.Bitly -- | Service credentials. data Account Account :: String -> String -> String -> Account -- | bit.ly login name login :: Account -> String -- | API key as found at http://bit.ly/account/ apikey :: Account -> String -- | Server to use, e.g. http://api.j.mp server :: Account -> String -- | Account to use with bit.ly bitlyAccount :: Account -- | Account to use with j.mp jmpAccount :: Account -- | Given a long URL, shorten encodes it as a shorter one. shorten :: Account -> String -> IO Result -- | Given a short bit.ly URL, expand decodes it back into a long -- source URL. expand :: Account -> String -> IO Result -- | Either an error message or a modified URL type Result = Either String String instance Read Account instance Show Account