0

I want to post an image on Instagram using Instagram-graph-API. The documentation does not especially give any support for Node.js. Also, online resources are very very little regarding this topic. Can some help in implementing this by first making an authentication request using a redirect URL(as mentioned in docs and few online resources) then using the auth code to generate an access token. Once we got the access token finally we post images on Instagram. There are no well-guided articles or docs regarding this. Most of the NPM packages are also not useful. Also, middleware such passport and others are not clear enough.

I need all the implementation using Node.js, Express. Can someone help me?

sakigo
  • 95
  • 8
manikandan
  • 29
  • 1
  • 1
  • 4
  • 1
    Possible duplicate of [How to post pictures to instagram using API](https://stackoverflow.com/questions/18844706/how-to-post-pictures-to-instagram-using-api) – bummi Jan 10 '19 at 22:05

3 Answers3

3

The post API endpoint is private. They only allow a few select third parties post directly to Instagram, if at all these days.

The only thing you can do is open Instagram with the media already selected.

Take a look here

AndyRyan
  • 1,500
  • 12
  • 23
  • Actually there are more options, like use the Instagram Private API to do the job. See my reply to other explanation. – Benedetto Abbenanti Jan 31 '18 at 16:55
  • 1
    There is a reason they call it PRIVATE api. If Instagram detect you are doing this the account WILL get banned. We have seen this first hand – AndyRyan Feb 01 '18 at 17:51
  • I only see "if" statement.. however if you say that there is NO WAY, you're writing definitely the wrong answer. This is called disinformation. – Benedetto Abbenanti Feb 01 '18 at 19:26
  • 1
    And your answer will get peoples instagram accounts banned, and if this user is building a product for use by customers, putting their customers accounts at risk. – AndyRyan Feb 05 '18 at 18:25
  • Instagram is constantly changing his own platform: some days ago they released a new "Graph API" (intended to replace the old API) and there is a feature for his customers (with business pages) called "Content Publishing BETA". I don't think that they want to continue ban accounts and this new feature is the proof. – Benedetto Abbenanti Feb 09 '18 at 14:10
  • @AndyRyan Thanks, your point is valid. Going to the link given by you, I see they recommend using Intents. But they don't mention how to wrap the image so that Instagram app takes it from the intent. Would appreciate any hint – rommex Dec 31 '18 at 17:17
0

You could build a simple server Rest API on Heroku that do the job. If you know Python or Javascript or PHP is simple; use some framework like Node.js + Express or Flask or Bottle or Laravel or anything you want.

Then when you hit your API it do the job of upload the media to Instagram, using the Private API (used within the app to upload a media!).

So how use this Instagram Private API? There are only a few active project that integrate with Instagram Private API. Go look yourself.

PHP mgp25/Instagram-API

Python b3nab/instapy-cli

UPDATES On 30th January 2018 Instagram announces that his old API is going to be replaced by a new Instagram Graph API, that will give you (with a business page) the possibility to publish contents and (consequently) schedule them.

To see other infos on new Graph API go here > https://developers.facebook.com/blog/post/2018/01/30/instagram-graph-api-updates/

0

The Instagram API is very limited, for now there's no way to post from the instagram API.

publishing API is closed

You can read more about it here.

Content Publishing - Instagram Platform

Quethzel Diaz
  • 621
  • 1
  • 11
  • 26