Closed royjor2016 closed 3 years ago
Running test pipeline:
Dec 8, 2020, 3:59:38 PM Info Dec 08, 2020 Dec 8, 2020, 3:59:39 PM Info {"data":{"reels_media":[]},"status":"ok"} Dec 8, 2020, 3:59:39 PM Info Number of URL(s) from @16278726: 0 Dec 8, 2020, 3:59:39 PM Info {"data":{"reels_media":[]},"status":"ok"} Dec 8, 2020, 3:59:39 PM Info Number of URL(s) from @528817151: 0 Dec 8, 2020, 3:59:39 PM Info {"data":{"reels_media":[]},"status":"ok"} Dec 8, 2020, 3:59:39 PM Info Number of URL(s) from @1112881921: 0 Dec 8, 2020, 3:59:40 PM Info Failed to fetch data from the test accounts!!!
The Endpoint has changed to https://i.instagram.com/api/v1/feed/reels_media/?reel_ids=xxxxxxxxx
But I have no ideas about what the parameter reel_ids
stands for.
OK. reel_ids
is the Instagram User ID that can be looked up from https://codeofaninja.com/tools/find-instagram-user-id/
But it returns {"message": "useragent mismatch", "status": "fail"}
when using a web browser to request the API directly.
There are two new variables, namely, x-ig-app-id
and x-ig-www-claim
in the header if I view the stories from www.instagram.com. I have to explore whether they are related to the useragent
.
@royjor2016
I've updated the code. Could you please test the branch NewEndpoint#11 and see if it works? Thanks!
@chriskyfung TypeError: Cannot read property 'reels_media' of undefined (line 67, file "code")
my line 67
var items = data.reels_media[0].items;
i think it's because JSON changed.
older json data started like this
{"data":{"reels_media":[{"__typename":"GraphReel","id":"xxxxxxx","latest_reel_media":xxxxxxxxxxxx,"can_reply":true,"owner":
now it starts like this
{"reels": {"xxxxxxx": {"id": xxxxxxxxxx, "latest_reel_media":
Please check the following commit.
yes it's working smoothly now. thanks a lot for the quick fixes!
It seems IG has changed their codes such that this script fails to fetch contents.
Looking at my execution logs, I think it started around noon, 7 Dec, UTC.
I thought it was cookie problem but now I cannot even reproduce the steps to get the "query hash" string.