Follow user on twitter via Rest API

How, using twitter rest api, I can follow the user in this format:

http: // myuser: mypassword@urloftwitterapi / follow? user = useriwannafollow

Is there a very simple method? thanks

+4
source share
2 answers

As Joost already posted, take a look:
https://dev.twitter.com/docs/api/1/post/friendships/create

If you want to use this longer than before the end of June, you need to check OAuth authentication:
https://dev.twitter.com/docs/auth/
https://dev.twitter.com/docs/auth/oauth/single-user-with-examples

Since Twitter will cancel the basic HTTP out by June 30:
http://www.countdowntooauth.com/

This means that you will need some library by then, if you do not want to do something like Python or Ruby, you can check Twurl: http://github.com/marcel/twurl/

+6
source

Source: https://habr.com/ru/post/1307912/


All Articles