简体   繁体   中英

how to get all the photos uploaded in instagram for a specific location

I went through the API documentation for /media/recent, but it does not specify what is the duration for which we receive the media files for a specific location.

They have mentioned that we could pass the below parameters to the API.

  1. MIN_TIMESTAMP
  2. MAX_TIMESTAMP

Can anyone give me an example on how to pass this value to the API?

Also is there any API exposed to get the total number of photos for a specific location in instagram?

you can use the medis.search endpoint:

http://instagram.com/developer/endpoints/media/#get_media_search

you have to pass lat and lng for location, max_timestamp and min_timestamp are option and can be specified in epoch time.

here is example:

https://api.instagram.com/v1/media/search?max_timestamp=1410332400&distance=1000&lat=37.8062&lng=-122.4738&access_token=XXX

Here is an implementation using this API, you can search by location and filter by date: http://www.gramfeed.com/instagram/map

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM