MoviebaseApp / tmdb-kotlin

🎬 Modern powerful TMDB API to fetch movies and TV shows for Kotlin Multiplatform.
https://www.moviebase.app
Apache License 2.0
205 stars 20 forks source link

Feature video url builder #7

Closed JcMinarro closed 2 years ago

JcMinarro commented 2 years ago

Create the class TmdbVideoUrlBuilder to provide a method to generate Video URLs from the TmdbVideo entities received from the API.

The current allowed Videos are from YouTube and Vimeo (From March 23, 2019, as was shown here

The key value returned on the API represents the platform video ID and the site value the platform itself. A new enum has been created to model the site and depending on it we use a different base URL as is detailed here