Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Twitter Api - how to verify if someone follow me

I'm so noob in Twitter Api and I need help! So what I have now? I've created a form where members of my website can follow somebody by clicking on follow buttons from twitter. Okay the part with following is done but how can I check in that form if the member following me or not when he's clicking on 'Claim Free Copy' button to get a error if he's not following? ..I think this is so hard to make but I hope you can help me because there on stackoverflow are the best developers. So the form looks like this

like image 805
J. Doe Avatar asked Feb 06 '23 08:02

J. Doe


1 Answers

Please check this article!

You can invoke the API like the example below -

https://api.twitter.com/1.1/friendships/show.json?source_screen_name=bert&target_screen_name=ernie

You can then parse the JSON response to fulfill your requirement.

enter image description here

like image 117
CodeWalker Avatar answered Feb 09 '23 22:02

CodeWalker