Class FollowApi

    • Constructor Detail

      • FollowApi

        public FollowApi()
    • Method Detail

      • checkCurrentUserFollows

        public CheckCurrentUserFollowsRequest checkCurrentUserFollows​(String type,
                                                                      String ids)

        Get Following State for Artists/Users

        Check to see if the current user is following one or more artists or other Spotify users.

        Parameters:
        type -

        The ID type: either artist or user.

        ids -

        A comma-separated list of the artist or the user Spotify IDs to check. For example: ids=74ASZWbe4lXaubB36ztrGX,08td7MxkoHQkXnWAYD8d6Q. A maximum of 50 IDs can be sent in one request.

        Returns:
        a CheckCurrentUserFollowsRequest object to build and execute the request
      • checkIfUserFollowsPlaylist

        public CheckIfUserFollowsPlaylistRequest checkIfUserFollowsPlaylist​(String playlistId,
                                                                            String ids)

        Check if Users Follow a Playlist

        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 Spotify User IDs ; the ids of the users that you want to check to see if they follow the playlist. Maximum: 5 ids.

        Returns:
        a CheckIfUserFollowsPlaylistRequest object to build and execute the request
      • followArtistsUsers

        public FollowArtistsUsersRequest followArtistsUsers​(String type,
                                                            List<String> ids)

        Follow Artists or Users

        Add the current user as a follower of one or more artists or other Spotify users.

        Parameters:
        type -

        The ID type.

        ids -

        A JSON array of the artist or user Spotify IDs. For example: {ids:["74ASZWbe4lXaubB36ztrGX", "08td7MxkoHQkXnWAYD8d6Q"]}. A maximum of 50 IDs can be sent in one request. Note: if the ids parameter is present in the query string, any IDs listed here in the body will be ignored.

        Returns:
        a FollowArtistsUsersRequest object to build and execute the request
      • getFollowed

        public GetFollowedRequest getFollowed​(String type)

        Get User's Followed Artists

        Get the current user's followed artists.

        Parameters:
        type -

        The ID type: currently only artist is supported.

        Returns:
        a GetFollowedRequest object to build and execute the request
      • unfollowArtistsUsers

        public UnfollowArtistsUsersRequest unfollowArtistsUsers​(String type,
                                                                List<String> ids)

        Unfollow Artists or Users

        Remove the current user as a follower of one or more artists or other Spotify users.

        Parameters:
        type -

        The ID type: either artist or user.

        ids -

        A JSON array of the artist or user Spotify IDs. For example: {ids:["74ASZWbe4lXaubB36ztrGX", "08td7MxkoHQkXnWAYD8d6Q"]}. A maximum of 50 IDs can be sent in one request. Note: if the ids parameter is present in the query string, any IDs listed here in the body will be ignored.

        Returns:
        a UnfollowArtistsUsersRequest object to build and execute the request
      • unfollowPlaylist

        public UnfollowPlaylistRequest unfollowPlaylist​(String playlistId)

        Unfollow Playlist

        Remove the current user as a follower of a playlist.

        Parameters:
        playlistId -

        The Spotify ID of the playlist that is to be no longer followed.

        Returns:
        a UnfollowPlaylistRequest object to build and execute the request