Home > Mobile >  How to find several users using users/lookup twitter api?
How to find several users using users/lookup twitter api?

Time:11-24

My goal is to retrieve relevant users based on the search field using twitter api enter image description here

CodePudding user response:

You are using the wrong API for your use case. This API is for converting exact user names into user objects (to fetch id's, profile pictures etc). The requirement is to pass exact usernames, separated by commas, and it will return an object for each.

What you are looking for is search, not lookup:

https://developer.twitter.com/en/docs/twitter-api/v1/accounts-and-users/follow-search-get-users/api-reference/get-users-search

  • Related