Safe Haskell | None |
---|---|
Language | Haskell2010 |
Request construction
- data Request f a
- data R f
- data Ready
- data Sign
- data Format
- api :: Text -> Request f a
- post :: Request f a
- get :: Request f a
- json :: Request JSON a
- xml :: Request XML a
- data APIKey
- apiKey :: Text -> Request f APIKey
- data SessionKey
- sessionKey :: Text -> Request f SessionKey
- data Token
- token :: Text -> Request f Token
- data Callback
- callback :: Text -> Request f Callback
- data Artist
- artist :: Text -> Request f Artist
- artists :: [Text] -> Request f [Artist]
- data Album
- album :: Text -> Request f Album
- data MBID
- mbid :: Text -> Request f MBID
- data Country
- country :: Text -> Request f Country
- data Autocorrect
- autocorrect :: Bool -> Request f Autocorrect
- data Event
- event :: Int64 -> Request f Event
- data Status
- status :: Status -> Request f Status
- data From
- from :: Int64 -> Request f From
- data To
- to :: Int64 -> Request f To
- data Group
- group :: Text -> Request f Group
- data Language
- language :: Text -> Request f Language
- data Distance
- distance :: Int64 -> Request f Distance
- data Longitude
- longitude :: Text -> Request f Longitude
- data Latitude
- latitude :: Text -> Request f Latitude
- data Location
- location :: Text -> Request f Location
- data Start
- start :: Int64 -> Request f Start
- data End
- end :: Int64 -> Request f End
- data Festivals
- festivalsonly :: Bool -> Request f Festivals
- data StartTimestamp
- startTimestamp :: Int64 -> Request f StartTimestamp
- data EndTimestamp
- endTimestamp :: Int64 -> Request f EndTimestamp
- data Metro
- metro :: Text -> Request f Metro
- data Tag
- tags :: [Text] -> Request f [Tag]
- tag :: Text -> Request f Tag
- data Track
- track :: Text -> Request f Track
- data Timestamp
- timestamp :: Int64 -> Request f Timestamp
- data Fingerprint
- fingerprint :: Int64 -> Request f Fingerprint
- data AlbumArtist
- albumArtist :: Text -> Request f AlbumArtist
- data Duration
- duration :: Int64 -> Request f Duration
- data TrackNumber
- trackNumber :: Int64 -> Request f TrackNumber
- data Playlist
- playlist :: Int64 -> Request f Playlist
- data Title
- title :: Text -> Request f Title
- data Description
- description :: Text -> Request f Description
- data ChosenByUser
- chosenByUser :: Bool -> Request f ChosenByUser
- data Context
- context :: Text -> Request f Context
- data StreamId
- streamId :: Int64 -> Request f StreamId
- data RecentTracks
- recentTracks :: Bool -> Request f RecentTracks
- data Recipient
- recipient :: Text -> Request f Recipient
- data Username
- username :: Text -> Request f Username
- data User
- user :: Text -> Request f User
- data Password
- password :: Text -> Request f Password
- data Public
- public :: Bool -> Request f Public
- data Message
- message :: Text -> Request f Message
- data Page
- page :: Int64 -> Request f Page
- data Limit
- limit :: Int64 -> Request f Limit
- data TaggingType
- taggingType :: Text -> Request f TaggingType
- data UseRecs
- useRecs :: Bool -> Request f UseRecs
- data Venue
- venue :: Int64 -> Request f Venue
- data VenueName
- venueName :: Text -> Request f VenueName
- data Discovery
- discovery :: Bool -> Request f Discovery
- data RTP
- rtp :: Bool -> Request f RTP
- data BuyLinks
- buyLinks :: Bool -> Request f BuyLinks
- data Multiplier
- multiplier :: Multiplier -> Request f Multiplier
- data Bitrate
- bitrate :: Bitrate -> Request f Bitrate
- data Name
- name :: Text -> Request f Name
- data Station
- station :: Text -> Request f Station
- class Targeted a
- comparison :: Targeted a => Int64 -> Request f a -> Request f a
- data Scrobble
- data LibraryAlbum
- data LibraryArtist
Request
Lastfm API request data type
low-level representation
Request that is ready to be sent
Response format: either JSON or XML
Request major parameters
api :: Text -> Request f a Source
Change request API method
Primarily used in API call wrappers, not intended for usage by library user
Change html _method to POST
Primarily used in API call wrappers, not intended for usage by library user
Change html _method to GET
Primarily used in API call wrappers, not intended for usage by library user
Change API response format to JSON
This is a little helper. It's actually enough to specialize Format manually
Change API response format to XML
This is a little helper. It's actually enough to specialize Format manually
ArtistAlbumOrMBID r (Artist -> Album -> APIKey -> r) | |
ArtistAlbumOrMBID r (MBID -> APIKey -> r) | |
ArtistTrackOrMBID (MBID -> APIKey -> Ready) | |
ArtistTrackOrMBID (Artist -> Track -> APIKey -> Ready) |
data SessionKey Source
sessionKey :: Text -> Request f SessionKey Source
Change request session key
Request minor parameters
ArtistOrMBID r Artist | |
ArtistAlbumOrMBID r (Artist -> Album -> APIKey -> r) | |
Targeted [Artist] | |
ArtistTrackOrMBID (Artist -> Track -> APIKey -> Ready) |
ArtistOrMBID r MBID | |
ArtistAlbumOrMBID r (MBID -> APIKey -> r) | |
ArtistTrackOrMBID (MBID -> APIKey -> Ready) |
data Autocorrect Source
autocorrect :: Bool -> Request f Autocorrect Source
Add autocorrect parameter
festivalsonly :: Bool -> Request f Festivals Source
Add festivalsonly parameter
data StartTimestamp Source
startTimestamp :: Int64 -> Request f StartTimestamp Source
Add startTimestamp parameter
data EndTimestamp Source
endTimestamp :: Int64 -> Request f EndTimestamp Source
Add endTimestamp parameter
data Fingerprint Source
fingerprint :: Int64 -> Request f Fingerprint Source
Add fingerprint parameter
data AlbumArtist Source
albumArtist :: Text -> Request f AlbumArtist Source
Add albumArtist parameter
data TrackNumber Source
trackNumber :: Int64 -> Request f TrackNumber Source
Add trackNumber parameter
data Description Source
description :: Text -> Request f Description Source
Add description parameter
data ChosenByUser Source
chosenByUser :: Bool -> Request f ChosenByUser Source
Add chosenByUser parameter
data RecentTracks Source
recentTracks :: Bool -> Request f RecentTracks Source
Add recentTracks parameter
data TaggingType Source
taggingType :: Text -> Request f TaggingType Source
Add taggingType parameter
data Multiplier Source
multiplier :: Multiplier -> Request f Multiplier Source
Add multiplier parameter
data LibraryAlbum Source
data LibraryArtist Source