15 May, 2021, at 10:03 PM WIB (0 comments)
I came across this interesting piece of command-line tool, called InstaLooter.
The usage itself is very easy, as described here.
All I have to do is to first install PyPI.
I installed pip3
, and then I proceeded with git
.
Following the instruction, I did:
$ git clone https://github.com/althonos/InstaLooter $ cd InstaLooter # pip3 install .
Then, we can use the following command:
$ instaLooter user <username> [<directory>] [options]
I used the -v
option to download videos as well, and afterwards, in the same target directory, we can download only the newest entries with -N
option.
For downloading individual posts, we can use the following command:
$ instaLooter post <post_token> <directory> [options]
To login into your account, do the following:
$ instalooter login
Afterwards, you'd be prompted to include your credentials. The credentials would be stored in a cache file, and it would use that to interact with target profiles.
It is very handy.
So what I did was to make a bash script with the following content:
#!/bin/bash instalooter user $1 "./$1" -v -N
Suppose the script name is igpost
, then it would take the following terms:
$ ./igpost <target>
Where <target>
is the target profile name.
Then it would create a folder named <target>
where all of the posts of that profile would be downloaded.
Unfortunately, it couldn't take instagram stories, highlights, and tagged posts.
For that, we would need instaloader.