Skip to content

feat(watchlist): display media from external API as a DiscoverSliderType #4068

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

dohnutt
Copy link

@dohnutt dohnutt commented Mar 9, 2025

Description

Defines a new DiscoverSliderType named ExternalWatchlistSlider, which pulls TMDB IDs from a given external API and displays them in a slider view, very similar to how Overseerr displays your Plex Watchlist.

I'm pretty inexperienced with React so I leaned heavily on existing conventions within the project—namely the PlexWatchlistSlider. This implementation displays the first 20 results from your external API (in my example, a scraped Google Watchlist from a personal project, but ideally it would be able to display the full results of the API in a paginated/infinite scroll view similar to the Plex Watchlist.

The challenges here, as far as I can tell, are:

  • Creating a ListView route per slider—though a way around this is to have one route with parameters passed to it (/discover/external-watchlist?apiUrl=http://example.com/api&pageParam=p)
  • As subtly referenced in the above bullet, you'd need to somehow define how to paginate the API. Is the URL param p=X or page=X, or perhaps something else?
  • How would you map fields from the external API to a WatchlistItem[]?

Perhaps these challenges could be out of scope of this feature request and it could simply be a DiscoverSliderType. This could especially work if it were paired with a linkUrl property so as to link to your external list rather than try to build a frontend into Overseerr—but of course then you lose the request functionality on the rest of your external list.

I am very green to contributing to open source, very green to React, and more generally comfortable with HTML and CSS than with complex JS so please feel free to tear it apart! If you've read this far, thank you for your time ❤️

Screenshot (if UI-related)

localhost_5055_ (3)
External Watchlist slider being added

localhost_5055_ (1)
External Watchlist slider in the discover edit view

localhost_5055_
External Watchlist slider on the discover page

To-Dos

  • Successful build yarn build
  • Translation keys yarn i18n:extract
  • Database migration (if required)

Issues Fixed or Closed

N/A

@dohnutt dohnutt marked this pull request as draft March 9, 2025 02:30
@dohnutt
Copy link
Author

dohnutt commented Mar 9, 2025

I figured out the standalone page fed by the external API. You can see here dohnutt/overseerr@e121845

The page, at /discover/externalwatchlist, accepts a couple URL parameters so that the page can be built on the fly. For example, http://localhost:5055/discover/externalwatchlist?apiUrl=http:example.com/api&title=Google%20Watchlist

could return this page
localhost_5055_discover_externalwatchlist_apiUrl=http%3A%2F%2F192 168 86 226%3A5155%2Fapi%2Fv1%2Fwatchlist title=Google%20Watchlist

@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch 2 times, most recently from 8a9a5af to d336732 Compare March 26, 2025 18:13
@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch 2 times, most recently from 8e1d5bb to ff452ca Compare April 5, 2025 12:40
@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch from ff452ca to 2edbce0 Compare April 16, 2025 17:46
@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch from 2edbce0 to dbe301d Compare April 26, 2025 11:05
@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch 3 times, most recently from 1cf39c7 to e007a0c Compare May 9, 2025 19:11
dohnutt added 4 commits June 19, 2025 10:24
…external API

Create `ExternalWatchlistSlider` to display media from a given external API endpoint.
Fix issue where slider looks different between create and other views
@dohnutt dohnutt force-pushed the discover-slider-external-watchlist branch from e007a0c to 075f777 Compare June 19, 2025 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant