Instagram closed API access that supported advanced searches and API queries required the use of an ID for the user or location. There are still several ways to find these IDs, though the API limits what you can do with it.
Photos/Videos: Add the shortcode URL to the oEmbed API . Or, add /media/ to the user's profile page and scroll to the bottom of the Instagram API output. TIP: oEmbed is one of the only API methods that delivers the media's creation time in a GMT/PST format.
You'll find a JSON formatter like JSONView makes this data easier to review in the browser. Pagination links are also interactive.
Source Code: You can also find IDs in the HTML.
On a shortcode URL, search for user_id. Shortcodes are the web location for individual photos or videos and look like this:
Instagram Locations are similar to Facebook check-ins. Users choose to add these locations to media during the upload by selecting it from a list of nearby places. Once posted, the Location name can be found on the Instagram page hosting the media.
The Lat/Long coordinates of Locations used to be found in some API queries. These coordinates were derived from the LocationID and not the user's mobile phone. Each Locations also has its own Instagram page, which was searchable via the LocationID.
Instagram Locations are often created by Instagram users. Therefore, it's not unusual to find a physical place with more than one Instagram Location or InstagramID.
Each business or attraction within a place can also have an InstagramID. For example, restaurants and retail stores within a business and sightseeing attractions within an amusement park can each have an InstagramID. Therefore, it's a good idea to include these nearby locations in your location search.
This tool originally provided an introduction to conducting API queries with IDs. For more informaton, see the API Search tab.People: UserID