Instagram通过API获取所有媒体 -

Instagram通过API获取所有媒体 -

问题描述:

I am using https://github.com/cosenary/Instagram-PHP-API to integrate Instagram API for my application.

I have a requirement of getting all the media's for the 'self' user and display. I tried with min_id and max_id but it only show recent 20 media I also use max_timestamp and min_timestamp but nothing worked to me.

Is there something I missing or is there any work around to solve this issue.

Thanks FJ

我正在使用 https://github.com/cosenary/Instagram-PHP-API 将Instagram API集成到我的应用程序中。 p>

我有一个要求 获取所有媒体的“自我”用户和显示。 我尝试使用min_id和max_id,但它只显示最近的20个媒体我也使用max_timestamp和min_timestamp但没有任何对我有用。 p>

我有什么遗漏或有任何解决方法可以解决这个问题 问题。 p>

谢谢 FJ p> div>

You need to enable Live mode, with Sandbox mode you only get 20 posts, Test you app with Sandbox mode and request for live mode

https://www.instagram.com/developer/sandbox/

First of all if your Instagram client is in Sandbox mode then you can't get more than 20 posts, more clearly last 20 posts. After client approve you can request more data using

MAX_ID  Return media earlier than this max_id.
MIN_ID  Return media later than this min_id.
COUNT   Count of media to return.

If client is in Sandbox mode then user should be also in Sandbox Users list. This list you can find when you click manage on your Instagram client.

Hope this will help you.

The Sandbox is the problem.

You can test your application by using a "real" token that you can get here :

Pixel Union