Interface FollowSpotifyService


  • public interface FollowSpotifyService
    • Method Detail

      • isFollowingUsers

        @GET("me/following/contains?type=user")
        retrofit2.Call<Boolean[]> isFollowingUsers​(@Query("ids")
                                                   String ids)
        Check to see if the current user is following one or more other Spotify users.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the users
        Returns:
        An array with boolean values indicating whether the users are followed
        See Also:
        Check if Current User Follows Artists or Users
      • isFollowingArtists

        @GET("me/following/contains?type=artist")
        retrofit2.Call<Boolean[]> isFollowingArtists​(@Query("ids")
                                                     String ids)
        Check to see if the current user is following one or more other Spotify artists.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the artists
        Returns:
        An array with boolean values indicating whether the artists are followed
        See Also:
        Check if Current User Follows Artists or Users
      • areFollowingPlaylist

        @GET("playlists/{playlist_id}/followers/contains")
        retrofit2.Call<Boolean[]> areFollowingPlaylist​(@Path("playlist_id")
                                                       String playlistId,
                                                       @Query("ids")
                                                       String ids)
        Check to see if one or more Spotify users are following a specified playlist.
        Parameters:
        playlistId - The Spotify ID of the playlist.
        ids - A comma-separated list of the Spotify IDs for the users
        Returns:
        An array with boolean values indicating whether the playlist is followed by the users
        See Also:
        Check if Users Follow a Playlist
      • followUsers

        @PUT("me/following?type=user")
        retrofit2.Call<Result> followUsers​(@Query("ids")
                                           String ids)
        Add the current user as a follower of one or more Spotify users.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the users
        Returns:
        An empty result
        See Also:
        Follow Artists or Users
      • followArtists

        @PUT("me/following?type=artist")
        retrofit2.Call<Result> followArtists​(@Query("ids")
                                             String ids)
        Add the current user as a follower of one or more Spotify artists.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the artists
        Returns:
        An empty result
        See Also:
        Follow Artists or Users
      • followPlaylist

        @PUT("playlists/{playlist_id}/followers")
        retrofit2.Call<Result> followPlaylist​(@Path("playlist_id")
                                              String playlistId)
        Add the current user as a follower of a playlist.
        Parameters:
        playlistId - The Spotify ID of the playlist
        Returns:
        An empty result
        See Also:
        Follow a Playlist
      • followPlaylist

        @PUT("playlists/{playlist_id}/followers")
        retrofit2.Call<Result> followPlaylist​(@Path("playlist_id")
                                              String playlistId,
                                              @Body
                                              PlaylistFollowPrivacy playlistFollowPrivacy)
        Add the current user as a follower of a playlist.
        Parameters:
        playlistId - The Spotify ID of the playlist
        playlistFollowPrivacy - The privacy state of the playlist
        Returns:
        An empty result
        See Also:
        Follow a Playlist
      • getFollowedArtists

        @GET("me/following?type=artist")
        retrofit2.Call<ArtistsCursorPager> getFollowedArtists()
        Get the current user's followed artists.
        Returns:
        Object containing a list of artists that user follows wrapped in a cursor object.
        See Also:
        Get User's Followed Artists
      • getFollowedArtists

        @GET("me/following?type=artist")
        retrofit2.Call<ArtistsCursorPager> getFollowedArtists​(@QueryMap
                                                              Map<String,​Object> options)
        Get the current user's followed artists.
        Parameters:
        options - Optional parameters. For list of supported parameters see endpoint documentation
        Returns:
        Object containing a list of artists that user follows wrapped in a cursor object.
        See Also:
        Get User's Followed Artists
      • unfollowUsers

        @DELETE("me/following?type=user")
        retrofit2.Call<Result> unfollowUsers​(@Query("ids")
                                             String ids)
        Remove the current user as a follower of one or more Spotify users.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the users
        Returns:
        An empty result
        See Also:
        Unfollow Artists or Users
      • unfollowArtists

        @DELETE("me/following?type=artist")
        retrofit2.Call<Result> unfollowArtists​(@Query("ids")
                                               String ids)
        Remove the current user as a follower of one or more Spotify artists.
        Parameters:
        ids - A comma-separated list of the Spotify IDs for the artists
        Returns:
        An empty result
        See Also:
        Unfollow Artists or Users
      • unfollowPlaylist

        @DELETE("playlists/{playlist_id}/followers")
        retrofit2.Call<Result> unfollowPlaylist​(@Path("playlist_id")
                                                String playlistId)
        Unfollow a Playlist
        Parameters:
        playlistId - The Spotify ID of the playlist
        Returns:
        An empty result
        See Also:
        Unfollow a Playlist