Module track

back

Procs

proc trackCorrection(fm: LastFM; track, artist: string): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getCorrection. Returns the JsonNode of the contents of the response.
proc trackInfo(fm: LastFM; track, artist: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getInfo. Returns the JsonNode of the contents of the response.
proc trackInfo(fm: LastFM; mbid: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getInfo. Returns the JsonNode of the contents of the response.
proc searchTracks(fm: LastFM; track, artist: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getInfo. Returns the JsonNode of the contents of the response.
proc searchTracks(fm: LastFM; track: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getInfo. Returns the JsonNode of the contents of the response.
proc scrobble(fm: LastFMSession; track, artist: string; timestamp = getTime().toUnix()): Future[  
JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.scrobble. Currently, multiple fields are missing from this API, including album name, sub-client name, streamid, chosenByUser, duration, and MusicBrainz ID. However, the basic functionality (scrobbling a track from its name and artist) is fully functional. Returns the JsonNode of the contents of the response.
proc loveTrack(fm: LastFMSession; track, artist: string): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.love. Returns the JsonNode of the contents of the response.
proc unloveTrack(fm: LastFMSession; track, artist: string): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.unlove. Returns the JsonNode of the contents of the response.
proc setNowPlaying(fm: LastFMSession; track, artist: string): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.updateNowPlaying. Currently missing optional fields. However, core functionality is working. Returns the JsonNode of the contents of the response.
proc similarTracks(fm: LastFM; track, artist: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.unlove. Currently missing optional fields. However, core functionality is working. Returns the JsonNode of the contents of the response.
proc trackAddTags(fm: LastFMSession; track, artist: string; tags: AtMost[10, string]): Future[  
JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.addTags. tags is of type AtMost[10, string], which is any array of strings with length <= 10. Returns the JsonNode of the contents of the response.
proc trackRemoveTag(fm: LastFMSession; track, artist: string; tag: string): Future[  
JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.removeTags. Returns the JsonNode of the contents of the response.
proc trackTags(fm: LastFM; track, artist, user: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getTags. This version of the function may be used for both unauthenticated and authenticated sessions, and thus requires that a user parameter be specified. Returns the JsonNode of the contents of the response.
proc trackTags(fm: LastFMSession; track, artist: string; autocorrect = on): Future[  
JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getTags. This version of the function can only be used with an authenticated Last.FM session. Returns the JsonNode of the contents of the response.
proc trackTopTags(fm: LastFM; track, artist: string; autocorrect = on): Future[JsonNode] {.
raises: [FutureError], tags: [ReadIOEffect, WriteIOEffect, TimeEffect, RootEffect]
.}
Breakout of Track.getTopTags. Currently missing the optional mbid field. Returns the JsonNode of the contents of the response.