Awesome
<p align="center"> <img src="media/ipp.png" width="340"> <br> <a href="https://travis-ci.org/CodeDotJS/instagram-profile-picture"> <img src="https://travis-ci.org/CodeDotJS/instagram-profile-picture.svg?branch=master"> </a> </p>Get url to the profile picture of any instagram user in different resolutions
Install
npm install --save instagram-profile-picture
Usage
Full size
:
1080x1080 px
const ipp = require('instagram-profile-picture');
ipp('9gag').then(user => {
console.log(user);
// => https://scontent-sit4-1.cdninstagram.com/7...jpg
});
Regular size
:
640x640 px
ipp.regular('instagram').then(user => {
console.log(user);
// => https://scontent-sit4-1.cdninstagram.com/7...jpg
});
Medium size
:
320x320 px
ipp.medium('9gag').then(user => {
console.log(user);
// => https://scontent-sit4-1.cdninstagram.com/7...jpg
});
Small size
:
150x150 px
ipp.small('9gag').then(user => {
console.log(user);
// => https://scontent-sit4-1.cdninstagram.com/7...jpg
});
Extra
Additionally, you can get downloadable link to the publically shared media (images/videos)
Images
ipp.image('https://www.instagram.com/p/BRfTRCQBeHw/').then(img => {
console.log(img);
// => "https://instagram.fpat1-1.fna....9017349928908750848_n.jpg"
});
Videos
ipp.video('https://www.instagram.com/p/BTTuhDsgtCs/').then(vid => {
console.log(vid);
// => "https://instagram.fpat1-1.fn....9178079197241802752_n.mp4"
})
Related
Instavim
: Download instagram media directly from command line.
License
MIT © Rishi Giri;