A
A
Artur Aralin2017-08-10 12:35:11
Node.js
Artur Aralin, 2017-08-10 12:35:11

Instagram api. How to get photos by tag?

Hello!
I need to implement search by tags in instagram. I already started a sandbox for myself, set up authorization, but I can’t get data from Instagram.
Instagram has an endpoint /tags/tag-name/media/recent, but it asks me for `MAX_TAG_ID`, which I don’t understand where to get it from. In turn /locations/search(search by geolocation) returns an empty data object.
I use this library https://www.npmjs.com/package/node-instagram
Please tell me how to work with this beast.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Eremin, 2017-08-10
@EreminD

Here

// Get information about a tag object. 
instagram.get('tags/:tag-name').then((data) => {
  console.log(data);
});

Get tag id and that's it

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question