Question

I want to take some metadata using my imdb pro account.

The page that I'm going to look for is this:

https://pro-labs.imdb.com/title/{IMDB ID}

I try to open the link with Jsoup, but it returns the following error:

java.io.IOException: 403 error loading URL http://pro.imdb.com/signup/v4/login?u=https://pro-labs.imdb.com/title/{IMDB ID}.

This is because I am not logged.

This is the login page: https://secure.imdb.com/signup/v4/login.

How can I make a request to include my log in info?

Was it helpful?

Solution

Jsoup is has only a limited support of login / authentication. Better you use another library (recommendation: Apache HttpClient) to do this.

In general you then can do these steps:

  1. Login using eg. HttpClient
  2. Download the websitde into a buffer
  3. Parse this buffer using jsoup
  4. Process the content as required
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top