1

I have designed a website which asks the user to enter his Instagram username, then it must extract the Instagram user ID from it and do the rest of work. my question is how to get the user ID from the username without the need to login in Instagram?

the (id to username) conversion has already been answered here, but I'm looking for (username to id) conversion. any help will be greatly appreciated.

9
  • 1
    Maybe ? stackoverflow.com/questions/37593025/…
    – InUser
    Nov 3, 2020 at 10:01
  • the solution mentioned there used to work, but now Instagram does not provide those information unless you log in-which is what I want to get rid of
    – Soheil
    Nov 3, 2020 at 10:04
  • seems that I can use instagram.com/web/search/topsearch/?query=username without being logged in, and the response contains the pk
    – InUser
    Nov 3, 2020 at 10:14
  • maybe you are already logged_in in the browser and so your cookies are being included in the request. have you checked?
    – Soheil
    Nov 3, 2020 at 10:17
  • Yes, I have two different responses if I'm logged in/incognito but both of them has the PK
    – InUser
    Nov 3, 2020 at 10:20

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.