0

After a short timeframe, Instagram updates the image URL and the one they give you becomes expired. It isn't a scheduled thing so it isn't something you can refetch on a schedule to fix. The URL you have may break at any time. Has anyone found a solution to easily retrieve an Instagram video URL perhaps similar to the way that the linked solution fetches a current version of static images?

Here is an example of an expired URL that comes from the Instagram API: https://video-iad3-1.cdninstagram.com/v/t50.33967-16/311796704_656982995824312_2200462786629368413_n.mp4?_nc_cat=100&vs=415717487387323_1550039796&_nc_vs=HBksFQAYJEdPQ2psUks0N2hiR2hWVUNBRjE2Z3ZJX25Za2VicV9FQUFBRhUAAsgBABUAGCRHRGw4alJKMmxkNUFBTU1CQU0wMG1qVU5adW9XYnFfRUFBQUYVAgLIAQAoABgAGwGIB3VzZV9vaWwBMRUAACb8mv6DgfHqQBUCKAJDMywXQBIFHrhR64UYEmRhc2hfYmFzZWxpbmVfMV92MREAdQAA&ccb=1-7&_nc_sid=59939d&efg=eyJ2ZW5jb2RlX3RhZyI6InZ0c192b2RfdXJsZ2VuLjcyMC5jbGlwcyJ9&_nc_ohc=nav3pTRz9T0AX-csieO&_nc_ht=video-iad3-1.cdninstagram.com&edm=AL-3X8kEAAAA&oh=00_AT9Wj2ue0CNOvRywTzAh2gvCxJl9Bhr1me4nIveXwZ2KNg&oe=634A481F&_nc_rid=6e1aabaa0c

This problem is specifically for Instagram Videos. The same thing happens to images and we are using the solution from this post: Instagram/feed API media URL shows 'URL signature expired' to fix static images and video poster images. But this doesn't work for video.

We've also tried the suggestions of using parameters ?__a=1 but it comes up as a broken page and does not return json as some have suggested.

Currently we are falling back to the poster image, but having the video would obviously be ideal.

innerurge1
  • 718
  • 3
  • 17

0 Answers0