Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
Some tips to build a simple script to check instagram followers/following
-
@mikael okay I think this api will not take me anywhere, but for my exercise I'm trying to versioning the spotify client but maybe I will need ur support if u want, I cannot get the code in the uri when redirected in https://localhost:8090/oauth2callback
-
@MrKingDice, so, you should have registered your app and should have entered the
https://localhost:8090/oauth2callback
in the right place. You should have gotten a client_id and entered that and the scope (e.g. ”user_profile,user_media”) in the right places in the code.Running it you should have had to enter your username and password. Have you put in a debug print to see that the
oauth2callback
endpoint is called? If you run it again, you probably should not be asked for the username and password again – if you are, it might mean they were not right. -
@mikael I already do it, I launch my script open the access_code url and I press authrize, then redirect me to the right https://localhost:8090/oauth2callback plus the code in the URL, but this is the trace
127.0.0.1 - - [05/May/2020 18:55:17] code 400, message Bad request version ('\x15:}\x824\x8cL\xb33\x96Q\x11\x86\xcflG5\xf9\xbc\x00\xdaR') 127.0.0.1 - - [05/May/2020 18:55:18] code 400, message Bad request syntax ('\x16\x03\x01\x02\x00\x01\x00\x01\xfc\x03\x03/\xe4tH\xed`\xf7\xeds3N\x82\x0b\xef\x14\xc7/\x12\xb41\x8c\xfc\xfc?\xca0\xce\x1a\xb3\x95\xf2\xc0 (\x9e\x1c\xceI\xccmW\xd1M\xae\xa2+\xf5O\xef_+\xa3K\xd6\xd3\xa0\xefy\x04\x8f7\xc8\x9e\xbb\xb9\x00"ZZ\x13\x01\x13\x02\x13\x03\xc0+\xc0/\xc0,\xc00\xcc\xa9\xcc\xa8\xc0\x13\xc0\x14\x00\x9c\x00\x9d\x00/\x005\x00')``` I think is because I must use httpS and not http (instagram rules), I tried a very basic script with flask and https enable and return me sort of code
EDIT:
After some digging I try a very basic script using flask and I get sort of code:import os from flask import Flask, request app = Flask(__name__) @app.route('/oauth2callback') def show_info(): code=request.args.get('code') return code if __name__ == "__main__": port = int(os.environ.get("PORT", 8090)) app.run(host='localhost', port=port,ssl_context='adhoc') print(show_info())
And the trace
* Serving Flask app "server" (lazy loading) * Environment: production WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead. * Debug mode: off * Running on https://localhost:8090/ (Press CTRL+C to quit) 127.0.0.1 - - [05/May/2020 19:40:42] "GET /oauth2callback?code=//code HTTP/1.1" 200 -
-
@MrKingDice, you should not be using
https
, there is no certificate. You need to fix in Instagram settings as well. -
@mikael I know but I cant they accept only https redirects urls
-
Building a script to check Instagram followers and following can be a great way to keep track of your account's growth. You can use Instagram API and Python or other programming languages that you feel comfortable with.
-
This post is deleted! -
@GlenOmes Hi, you're right.
-
This post is deleted! -
Building a python script to check who you are following on Instagram that's not following you back can be a fun project. It's great that you're already exploring the Instagram API on Github. In fact, I recently came across a resource that can help you with your Online growth, check out www.namecheap.com/relate/reviews/ for reviews of various online tools that can help you manage your social media accounts and grow your audience. However, since the API is being deprecated soon, it's a good idea to switch to the Instagram Basic Display API on the Facebook for Developer page.
-
This post is deleted!