Giter Site home page Giter Site logo

imdb-trakt-sync's Introduction

sync

imdb-trakt-sync

GoLang app that can sync IMDb and Trakt user data - watchlist, lists, ratings and history.
To achieve its goals the application is using the Trakt API and web scraping the IMDb website.

Usage

The application can be setup to run automatically, based on a custom schedule (default: once every 3 hours) using GitHub Actions or locally on your machine.
Follow the relevant section below, based on how you want to use the application.

Run the application using GitHub Actions

  1. Fork this repository to your account
  2. Configure your GitHub repository secrets using the .env.example file as reference:
    1. Retrieve the at-main and ubid-main cookies by logging into your IMDb account and inspecting the cookies using your favourite web browser
    2. Create Trakt API app
    3. Retrieve a Trakt access token:
      1. Get a Trakt code by opening the Trakt API app that you created in the previous step and click the Authorize button
      2. Using the code from the previous step along with your Trakt app's client id & client secret, replace the contents in the request body and retrieve your access token from the response
    4. Create repository secrets: Settings > Secrets > Actions > New repository secret
  3. Enable GitHub Actions for the fork repository
  4. Enable the sync workflow, as scheduled workflows are disabled by default in fork repositories
  5. The sync workflow can be triggered manually right away to test if it works. Alternatively, wait for GitHub actions to automatically trigger it every 3 hours

Run the application locally

  1. Clone this repository to your machine
  2. Make a copy of the .env.example file and name it .env
  3. Populate all the environment variables in that file using the existing values as reference:
    1. Retrieve the at-main and ubid-main cookies by logging into your IMDb account and inspecting the cookies using your favourite web browser
    2. Create Trakt API app
    3. Retrieve a Trakt access token:
      1. Get a Trakt code by opening the Trakt API app that you created in the previous step and click the Authorize button
      2. Using the code from the previous step along with your Trakt app's client id & client secret, replace the contents in the request body and retrieve your access token from the response
  4. Make sure you have GoLang installed on your machine
  5. Open a terminal window in the repository folder and run the application using the command go run .

imdb-trakt-sync's People

Contributors

cecobask avatar geekfried avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.