Instagram unsupported image size

I have a problem calling an API. I would like to get the latest media for the user. I am making an API call to the following endpoint: https://api.instagram.com/v1/users/1638607411/media/recent?count=100&client_id=MY_CLIENT_ID

Answer:

...

["images":protected]=> array(3) { ["low_resolution"]=> array(3) { ["url"]=> string(114) "https://scontent.cdninstagram.com/hphotos-xfa1/t51.2885-15/s320x320/e35/11264735_1688306834723686_1802219154_n.jpg" ["width"]=> int(320) ["height"]=> int(320) } ["thumbnail"]=> array(3) { ["url"]=> string(114) "https://scontent.cdninstagram.com/hphotos-xfa1/t51.2885-15/s150x150/e35/11264735_1688306834723686_1802219154_n.jpg" ["width"]=> int(150) ["height"]=> int(150) } ["standard_resolution"]=> array(3) { ["url"]=> string(114) "https://scontent.cdninstagram.com/hphotos-xfa1/t51.2885-15/s612x612/e35/11264735_1688306834723686_1802219154_n.jpg" ["width"]=> int(612) ["height"]=> int(612) } } 

...

I want to use the image "standard_resolution", but it does not work. When I want to receive it directly, I received Status Code: 404 Unsupported Size

In addition, when I change "s612x612" in the url to "s640x640" - it works.

Looks like an Instagram API error, I already reported this, but maybe someone is experiencing something similar?

+8
instagram api instagram
source share
2 answers

We noticed this from Friday August 14th with their real-time API. We did some tests, and this seems to be a random error, only a small subset of the answers is incorrect, the interim fix really replaces "s612x612" in the url with "s640x640".

+1
source share

Also ran into this error today, the problem seems to be related to the Instagram API. Your fix is ​​the best workaround, also presented a bug report.

Please note that your fix - changing the URL while waiting for a square of 640 pixels - returns a 450 pixel square in some of my tests.

0
source share

All Articles