lfm_api

package module
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2022 License: MIT Imports: 8 Imported by: 0

README

lfm-api

Documentation

Index

Constants

View Source
const LastFmUrl = "https://www.last.fm/"

Variables

View Source
var EmptyScrobble = Scrobble{
	Active: false,
}

Functions

This section is empty.

Types

type Scrobble

type Scrobble struct {
	Active        bool      // Whether the user is actively scrobbling
	Name          string    // The name of the track
	Artist        string    // The artist of the track
	Album         string    // The album of the track
	Loved         bool      // Whether the user loves the track
	DataId        string    // A unique ID used to identify the scrobble, generated by Last.FM
	DataTimestamp time.Time // When the user began scrobbling
	DataLink      string    // A link to the track (YouTube, etc.)
	DataLinkTitle string    // A description for the dataLink
	CoverArtUrl   string    // A URL to the album cover art
}

Scrobble represents a scrobble on Last.FM.

func GetActiveScrobble

func GetActiveScrobble(username string) (Scrobble, error)

GetActiveScrobble returns the active scrobble for the given user.

func (Scrobble) String added in v1.0.3

func (s Scrobble) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL