cecobask/imdb-trakt-sync

TRAKT_ACCESS_TOKEN retrieval

Closed this issue ยท 7 comments

Could you verify the steps provided in the README?

I was unable to locate the correct value to use as the TRAKT_ACCESS_TOKEN environment variable through their site. I had to resort to this random website to pull the token for me.

Hey @Valkryst, the TRAKT_ACCESS_TOKEN value cannot be retrieved from the Trakt website. It can only be retrieved through Trakt's API which generates the token for you.

To get a token you'll need to use the RequestBin that I provided, which has the request body (Content tab) formatted for you. You just have to replace the values with your own code, client_id and client_secret, send the the request and get the token from the response, called access_token. Alternatively, you can create your own HTTP request using an app like Postman.

The code value is the PIN you get after clicking on the Authorize button for your API app on the Trakt website. The client_id and client_secret values are available from the same page.

I hope I was helpful ๐Ÿซก

Hey I am getting an error - error scraping imdb profile: user id not found
exit status 1
Error: Process completed with exit code 1.

What am I doing wrong?

Hey @jatin6715, the problem is certainly in the environment variables that you have to set manually.
Depending on how you're trying to run the application, the solution is the following:

  1. If running with GitHub Actions - go to the repository secrets of your fork and make sure each secret (aka environment variable) is defined individually and set to a valid value. You should see something similar to this:
    image
  2. If running locally on your machine - make sure that you have created a file called .env, populate all environment variables with valid values, and finally run the application again. Ensure you don't commit this file to GitHub as it contains your personal tokens.

Thank you so much. This is my first time using Github. I had pasted all the variables in a single secret. I created different variables and it worked. Much respect! Thank you again, you are a life saver.

I'm having fail syncs due to the TRAKT_ACCESS_TOKEN. I also noticed that this repo is also having failed syncs.

Hi @rafae667, looks like your fork was a few commits behind which you've successfully updated now.
Tip: Make sure to have all the currently documented repository secrets in place. When you initially forked the repository, the repository secrets might have been slightly different.

On a side note: Part of the Trakt API is currently down or unavailable, so that's why there are failed sync on the parent repository as well.

Thank you. That's why it won't work, I didn't notice the Trakt website was down.
I guess everything is ok, the problem is just the website being down.
Thank you so much for the work ๐Ÿ‘