Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pool #96

Closed
Epikcoder opened this issue May 12, 2024 · 1 comment
Closed

pool #96

Epikcoder opened this issue May 12, 2024 · 1 comment

Comments

@Epikcoder
Copy link

hi is it possible to use a pool/mutiple accounts at the same time?

@MiddleRed
Copy link
Contributor

If you wish, you can actually use twscrape’s account pool feature and twikit’s api client at the same time, although you need to connect and handle account state manually. But currently, twikit does not have a native account pool support.
Here is an example, I only list out the essential functions.

from twscrape import API, Account
from twikit.twikit_async import Client as twikit_Clienttws_api = API()
accounts = await tws_api.pool.get_all()
…
cookies = await tws_api.pool.get_account(username)
cli = twikit_Client(language = 'en-US')
cli.set_cookies(cookies)
raw_result = await cli.search_tweet("elon musk", product = "Latest")

@d60 d60 closed this as completed May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants