API /Series/lookup monitor status question

I am using the /api/series/lookup?term= search to pull a series and determine if it is being monitored. From what I am seeing all of my result data coming across always says the series in not monitored, it also shows 0 for the episode and episodeFileCount values.

When I use the web interface to perform an Add Series search for the same episode the Network data appears to display the same results that I am getting from a direct API call but the web UI is obviously parsing something from this data allowing it to know that the series “Already Exists”.

I then was able to locate /src/UI/AddSeries/SearchResultView.js which seems to be doing a local JS lookup using backbonejs on line 79.

Am I correct in that this is what is occurring? If I want to truly know if a series is monitored or not, do I need to compare the results of the /api/series/lookup to /api/series? Is there a reason this isn’t done automatically and when a /api/series/lookup is called?

Thank you guys for your support, love the product. Working on a unified search for NZBDrone + CouchPotato.

Correct the check if its already part of the collection is done on the client side (it will also prevent it from being added a second time if you try to attempt to add it again).

Yes, you will need to compare the two to see if its already been added. As for the decision, it was made a long time ago, but thinking about it now, it keeps the search results clean of any contamination (by separating the search from your own DB).

1 Like

markus,

Thank you for the clarification, I did see the argument both ways, and I have no issue with the client side comparison.