Spotify: Implemented API request and tests for user tracks

This commit is contained in:
Philipp Wolfer 2023-11-22 10:24:33 +01:00
parent d0739aad0f
commit ed9debc127
No known key found for this signature in database
GPG key ID: 8FDF744D4919943B
4 changed files with 623 additions and 9 deletions

View file

@ -23,12 +23,18 @@ THE SOFTWARE.
package spotify
type TracksResult struct {
Href string `json:"href"`
Limit int `json:"limit"`
Next string `json:"next"`
Previous string `json:"previous"`
Offset int `json:"offset"`
Total int `json:"total"`
Href string `json:"href"`
Limit int `json:"limit"`
Next string `json:"next"`
Previous string `json:"previous"`
Offset int `json:"offset"`
Total int `json:"total"`
Items []SavedTrack `json:"items"`
}
type SavedTrack struct {
AddedAt string `json:"added_at"`
Track Track `json:"track"`
}
type RecentlyPlayedResult struct {
@ -45,8 +51,8 @@ type Cursors struct {
}
type Listen struct {
Track Track `json:"track"`
PlayedAt string `json:"played_at"`
Track Track `json:"track"`
}
type Track struct {