Swiftpack.co - Package - alfianlosari/TMDbMovieKit


A TMDb Swift 5.1 API Wrapper for the REST API.


  • Add the dependency to your target/project using Swift Package Manager
  • Import framework in your source
  • Initialize by passing the API Key from the TMDb website

How to use

  1. Initialize by passing the API Key
impot TMDbMovieKit

let tmdbStore = MovieStore(apiKey: "Insert API Key in here")
  1. Fetch Movies based on endpoint
tmdbStore.fetchMovies(from: endpoint, successHandler: {[weak self] (response) in
  let movies = response.results
  // Movies Fetched from endpoint
  }) {[weak self] (error) in
  // Error occured
  1. Fetch Movies based on id
tmdbStore.fetchMovie(id: id, successHandler: { [weak self](https://raw.github.com/alfianlosari/TMDbMovieKit/blob/master/movie) in
       // Movie fetched with id
   }) {[weak self] (error) in
       // Error Occured


Stars: 0


Used By

Total: 0