1

I am trying to create an Application to upload a picture using intents into Instagram.My problem is once uploaded i want to sign out from that account so some other user can sign in later. Is there a way?

Found this link

Instagram Api User Logout

Unable to understand the answer.

Community
  • 1
  • 1
navjosh
  • 187
  • 2
  • 2
  • 13

1 Answers1

0

Unfortunately Instagram API doesn't give endpoint, which allows to log user out. Answer, which you reference to, recommends to use intercept url with html page - it'll load logout url in iframe and redirect to auth website. So you won't really log out user - he'll be logged out just before auth process.

Html for loading page can be as follows:

<html>
  <body>
    <script type="text/javascript">
      function load() {
        window.location.href = "https://YOURS_AUTH_INSTAGRAM_URL";
      }
    </script>

    <iframe src="https://instagram.com/accounts/logout/"" 
    onload="load()"
    width="0" height="0">
    </iframe>
  </body>
</html>
Krzysztof Skrzynecki
  • 2,345
  • 27
  • 39