Providers
src/providers
Under the provider's folder, the developers will find the different implementations for retrieving data from the internet. All the API implementation for our fetching data libraries will be placed here. Implementations for the APIs of Content Management System(s) (CMS) implementations, Online Video Platform (OVP), and any other 3rd party library our application needs.
Elevate needs a CMS and an OVP implementation. Is mandatory for the application to run to have these two implementations available. Each one should expose different methods to the application, and these methods will be tested. If implementing the different CMS or OVP API does not pass the test, the application will not work.
Minimum available methods for providers
-
Configuration
- getConfiguration
-
CMS
- getMenu
- getPageLayout
- getDefaultTheme
-
OVP
- getChannelData
- getEpisodeById
- getMovieById
- getMovieCategories
- getMovieData
- getMovieDataById
- getMovies
- getMoviesByCategory
- getTvListings
- getTvShows
- getTvSeasonEpisodesById
- getTvShowData
- getTvShowById
- getTvShowEpisodesById
- getTvShowSeasonsById
- searchMovies
- searchShows
- signIn
- signOut
- validateToken
-
i18n
- getDefaultLocaleCode
- getLocales
- getLocale
-
Entitlement
- checkEntitlement
-
idP
- login
- validateUser
- logout
- getPairingCode
- pair
- forgotPassword
- getUser
-
Profile
- TBD
- TBD
The providers API implementation does not have to care about treating data. The parsing and model of the data will be done in the different models defined for data.
If you need to implement your own CMS or OVP, please hava a look into the How to... section
Example for Control CMS implementation
import control from './control/control';
const cmsInstance = control();
export default cmsInstance;