@@ -1049,14 +1049,17 @@ def markUnplayed(self, item):
10491049 self .query (key , params = params )
10501050 return self
10511051
1052- def searchDiscover (self , query , limit = 30 , libtype = None ):
1052+ def searchDiscover (self , query , limit = 30 , libtype = None , providers = 'discover' ):
10531053 """ Search for movies and TV shows in Discover.
10541054 Returns a list of :class:`~plexapi.video.Movie` and :class:`~plexapi.video.Show` objects.
10551055
10561056 Parameters:
10571057 query (str): Search query.
10581058 limit (int, optional): Limit to the specified number of results. Default 30.
10591059 libtype (str, optional): 'movie' or 'show' to only return movies or shows, otherwise return all items.
1060+ providers (str, optional): 'discover' for default behavior
1061+ or 'discover,PLEXAVOD' to also include the Plex ad-suported video service
1062+ or 'discover,PLEXAVOD,PLEXTVOD' to also include the Plex video rental service
10601063 """
10611064 libtypes = {'movie' : 'movies' , 'show' : 'tv' }
10621065 libtype = libtypes .get (libtype , 'movies,tv' )
@@ -1068,6 +1071,7 @@ def searchDiscover(self, query, limit=30, libtype=None):
10681071 'query' : query ,
10691072 'limit' : limit ,
10701073 'searchTypes' : libtype ,
1074+ 'searchProviders' : providers ,
10711075 'includeMetadata' : 1
10721076 }
10731077
0 commit comments