Open beaulebens opened 6 years ago
Instagram have updated their API responses to include data about "carousel" posts (where you post multiple images/media items in a single post). Update the importer to handle these changes and download/embed everything from the original.
There's some example response data in https://www.instagram.com/developer/endpoints/media/
Here's what one of my own posts looks like (series of photos, no videos):
stdClass Object ( [id] => 1737952825260742638_285663 [user] => stdClass Object ( [id] => 285663 [full_name] => Beau Lebens [profile_picture] => https://scontent.cdninstagram.com/vp/a156149c00825dfb66e05d6151024bb0/5B4567CC/t51.2885-19/s150x150/13414371_486301391575531_820857067_a.jpg [username] => beaulebens ) [images] => stdClass Object ( [thumbnail] => stdClass Object ( [width] => 150 [height] => 150 [url] => https://scontent.cdninstagram.com/vp/c36e9cfdb98d9d3677e8208c9e6d0fcd/5B3AA489/t51.2885-15/s150x150/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) [low_resolution] => stdClass Object ( [width] => 320 [height] => 320 [url] => https://scontent.cdninstagram.com/vp/475b9293b5191ce6de98a78c3b057425/5B390DB9/t51.2885-15/s320x320/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) [standard_resolution] => stdClass Object ( [width] => 640 [height] => 640 [url] => https://scontent.cdninstagram.com/vp/c1054a93ba95b3cb74353349fff02fe7/5B2CF6F4/t51.2885-15/s640x640/sh0.08/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) ) [created_time] => 1521400143 [caption] => stdClass Object ( [id] => 17931286021042565 [text] => Arc’teryx Brize 25 vs Patagonia Nine Trails 28 [created_time] => 1521400143 [from] => stdClass Object ( [id] => 285663 [full_name] => Beau Lebens [profile_picture] => https://scontent.cdninstagram.com/vp/a156149c00825dfb66e05d6151024bb0/5B4567CC/t51.2885-19/s150x150/13414371_486301391575531_820857067_a.jpg [username] => beaulebens ) ) [user_has_liked] => [likes] => stdClass Object ( [count] => 0 ) [tags] => Array ( ) [filter] => Normal [comments] => stdClass Object ( [count] => 0 ) [type] => carousel [link] => https://www.instagram.com/p/BgecuLyDZfu/ [location] => [attribution] => [users_in_photo] => Array ( [0] => stdClass Object ( [user] => stdClass Object ( [id] => 22592480 [full_name] => Arc'teryx [profile_picture] => https://scontent.cdninstagram.com/vp/3ac4f80e8ca1ccfdd4b6190c95bce991/5B38FAFA/t51.2885-19/11356945_521047711377460_3545960_a.jpg [username] => arcteryx ) [position] => stdClass Object ( [x] => 0.7857777507 [y] => 0.5855394747 ) ) [1] => stdClass Object ( [user] => stdClass Object ( [id] => 143939018 [full_name] => Patagonia [profile_picture] => https://scontent.cdninstagram.com/vp/d076cf1acec3604cb045281232ef9389/5B2BC258/t51.2885-19/11820461_878388088917822_530389951_a.jpg [username] => patagonia ) [position] => stdClass Object ( [x] => 0.235555542 [y] => 0.5766407119 ) ) ) [carousel_media] => Array ( [0] => stdClass Object ( [images] => stdClass Object ( [thumbnail] => stdClass Object ( [width] => 150 [height] => 150 [url] => https://scontent.cdninstagram.com/vp/c36e9cfdb98d9d3677e8208c9e6d0fcd/5B3AA489/t51.2885-15/s150x150/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) [low_resolution] => stdClass Object ( [width] => 320 [height] => 320 [url] => https://scontent.cdninstagram.com/vp/475b9293b5191ce6de98a78c3b057425/5B390DB9/t51.2885-15/s320x320/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) [standard_resolution] => stdClass Object ( [width] => 640 [height] => 640 [url] => https://scontent.cdninstagram.com/vp/c1054a93ba95b3cb74353349fff02fe7/5B2CF6F4/t51.2885-15/s640x640/sh0.08/e35/28763915_1742157569161436_4735371782242959360_n.jpg ) ) [users_in_photo] => Array ( [0] => stdClass Object ( [user] => stdClass Object ( [id] => 22592480 [full_name] => Arc'teryx [profile_picture] => https://scontent.cdninstagram.com/vp/3ac4f80e8ca1ccfdd4b6190c95bce991/5B38FAFA/t51.2885-19/11356945_521047711377460_3545960_a.jpg [username] => arcteryx ) [position] => stdClass Object ( [x] => 0.7857777507 [y] => 0.5855394747 ) ) [1] => stdClass Object ( [user] => stdClass Object ( [id] => 143939018 [full_name] => Patagonia [profile_picture] => https://scontent.cdninstagram.com/vp/d076cf1acec3604cb045281232ef9389/5B2BC258/t51.2885-19/11820461_878388088917822_530389951_a.jpg [username] => patagonia ) [position] => stdClass Object ( [x] => 0.235555542 [y] => 0.5766407119 ) ) ) [type] => image ) [1] => stdClass Object ( [images] => stdClass Object ( [thumbnail] => stdClass Object ( [width] => 150 [height] => 150 [url] => https://scontent.cdninstagram.com/vp/38515d0259753b236400ebff4550512d/5B280B23/t51.2885-15/s150x150/e35/c0.0.1079.1079/29096457_171997266786965_8970175403993858048_n.jpg ) [low_resolution] => stdClass Object ( [width] => 320 [height] => 319 [url] => https://scontent.cdninstagram.com/vp/c0d09c37c0158937af87ed7ae08830f0/5B4B0A8A/t51.2885-15/s320x320/e35/29096457_171997266786965_8970175403993858048_n.jpg ) [standard_resolution] => stdClass Object ( [width] => 640 [height] => 639 [url] => https://scontent.cdninstagram.com/vp/c4a389ee044b0b349e5f97e79206b7f1/5B3C23C9/t51.2885-15/s640x640/sh0.08/e35/29096457_171997266786965_8970175403993858048_n.jpg ) ) [users_in_photo] => Array ( ) [type] => image ) [2] => stdClass Object ( [images] => stdClass Object ( [thumbnail] => stdClass Object ( [width] => 150 [height] => 150 [url] => https://scontent.cdninstagram.com/vp/717567afa9950f38fedc90ed0733ceb5/5B41C216/t51.2885-15/s150x150/e35/28754394_151921658809455_6055238588335915008_n.jpg ) [low_resolution] => stdClass Object ( [width] => 320 [height] => 320 [url] => https://scontent.cdninstagram.com/vp/c1d313cd49dd9a323ee3d899621c217a/5B42A951/t51.2885-15/s320x320/e35/28754394_151921658809455_6055238588335915008_n.jpg ) [standard_resolution] => stdClass Object ( [width] => 640 [height] => 640 [url] => https://scontent.cdninstagram.com/vp/4153a6494ca79ed0b38319ece5648783/5B2BEA12/t51.2885-15/s640x640/sh0.08/e35/28754394_151921658809455_6055238588335915008_n.jpg ) ) [users_in_photo] => Array ( ) [type] => image ) [3] => stdClass Object ( [images] => stdClass Object ( [thumbnail] => stdClass Object ( [width] => 150 [height] => 150 [url] => https://scontent.cdninstagram.com/vp/676ddce54edf168b28b235d163b4fc90/5B395CEE/t51.2885-15/s150x150/e35/28764555_1602521753179681_4382156145721081856_n.jpg ) [low_resolution] => stdClass Object ( [width] => 320 [height] => 320 [url] => https://scontent.cdninstagram.com/vp/ba1227ba3b07e75b699fd0325b92d2a5/5B4E6ADE/t51.2885-15/s320x320/e35/28764555_1602521753179681_4382156145721081856_n.jpg ) [standard_resolution] => stdClass Object ( [width] => 640 [height] => 640 [url] => https://scontent.cdninstagram.com/vp/35eda795a2292518dcecb4e9348cbc53/5B322993/t51.2885-15/s640x640/sh0.08/e35/28764555_1602521753179681_4382156145721081856_n.jpg ) ) [users_in_photo] => Array ( ) [type] => image ) ) )
Basic support added in 726aa94e753f736631e303d7d8563d2eab10195d
Instagram have updated their API responses to include data about "carousel" posts (where you post multiple images/media items in a single post). Update the importer to handle these changes and download/embed everything from the original.
There's some example response data in https://www.instagram.com/developer/endpoints/media/
Here's what one of my own posts looks like (series of photos, no videos):