Adding support for Podcasts#436
Conversation
Mostly small changes except for one major (Item in PlaybackContext). Since Item can be either FullTrack or FullEpisode, I had to use an interface that decodes this on the fly.
|
I just noticed that there have also been changes to other endpoints. Namely /playlists/{playlist_id}/tracks. I implemented those as well and added a couple of bug fixes. |
| { | ||
| [JsonProperty("album")] | ||
| public SimpleAlbum Album { get; set; } | ||
|
|
There was a problem hiding this comment.
Small rant: Their docs are so inconsistent, it's really annoying at this point.
On this page: https://developer.spotify.com/documentation/web-api/reference/playlists/get-playlists-tracks/
It says 3 different things:
On success, the response body contains an array of track objects and episode objects
Where the link goes to track-object-simplified, containing NO album property
track object (full)
This is documented on the page although it's theoretically never used in the call?
playlist track object
Contains a link to track-object-full.
|
I added some changes but I was unable to update your fork, let's continue in #437 |
Adding new models that represent Show and Episodes.
Modified several functions to support returning both tracks and episodes. The major change is in PlaybackContext Item field that is now an interface. This solves the issue that the same returned json field (item) can be either a track or an episode.