0

I'm updating code from v1 to v2 of twitter's API (since most of V1 can't be used anymore) I'm trying the following method as per the new Twitter API V2 Tweepy documentation (https://docs.tweepy.org/en/stable/client.html):

try:
    followers = client.get_users_followers(id=2341381484)
    print(str(followers))
except Exception as e:
    print(str(e))

I am already paying for the Basic tier which is said to include this feature. Other requests like .get_user, .get_retweeters, .follow_user,.unfollow_user or .get_users_tweets work perfectly fine.

Twitter's documentation (now Elon Musk's "X") is incomplete, missing or badly written, the only documentation I can rely on is Tweepy's, not twitter's. I kinda feel scammed so far since I haven't found a workaround to this and to a few other things, I paid 100 a month to not have access to certain features that they say V2 Basic API has.

Additionally, I'd like to ask two things that I'll turn into posts here.

  1. See if anyone knows if there's any way of getting a following status like in V1's method .show_friendship(source_id,target_id), that is, to check if an account is or not following another account. I can't find any way to do this on V2 without having to check from a list of all the account's followers (which could be thousands).
  2. One example of the chaos in twitter's API documentation, now a paid API (although there are much worse examples, some methods are not even documented), is https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users-id#tab3. I'm following the documentation to retrieve some user fields such as public_metrics to get the followers count of an account, but the response I get is plain as if I was sending no parameters. V1 didn't need parameters, they sent you all the information whether you needed it or not.

I hope someone finds I'm doing something wrong 'cause this all seems a mess I can't work around.

E C
  • 11
  • 4

0 Answers0