instagram-java-scraper icon indicating copy to clipboard operation
instagram-java-scraper copied to clipboard

getMedias(long userId, int pageCount, PageInfo pageCursor) returns 302 response

Open nbraun1 opened this issue 4 years ago • 0 comments

Hi,

If I want to get the next page of medias for an specified user, I'll run into an 302 response. I'm not really sure, where I can find the maxId to request the next page, so I took the id of the first media object and passed it to the request. Here is an small code sample:

instagram.getMedias(account.getId(), 1, new PageInfo(true, String.valueOf(medias.getNodes().get(0).getId())));

Note, that I sent this request without an login! The problem is, if I tried to send a login request, I got a 400 response. However, my credentials are correct! Apart from that, I saw that there is an similar issue (see https://github.com/postaddictme/instagram-java-scraper/issues/145).

Now, my question to you, is the 302 response for a paginated media request caused in my code or in your API?

Thank you in advance for your help. Best regards.

nbraun1 avatar Jun 03 '20 08:06 nbraun1