adverse-sapphire•3y ago
I'm very new to Apify and APIs in general, how do I get the latest tweet with a scraper?
I'll be using JS to get all the info.
13 Replies
correct-apricot•3y ago
Hi @Basel_Dev
correct-apricot•3y ago
You can use this Twitter scraper for that purpose - https://apify.com/microworlds/twitter-scraper
Apify
Twitter Scraper · Apify
Twitter Scraper searches and extracts data from Twitter - parses and converts the data to structured formats: HTML table, JSON, CSV, Excel and XML.
correct-apricot•3y ago
You can specify the search mode. To get latest results, set the search mode to
Liveadverse-sapphireOP•3y ago
Ah, I'm looking to do that on a specific profile though
correct-apricot•3y ago

correct-apricot•3y ago
Yes, you can provide a search URL.
E.g., to get the latest tweets from the twitter account
elonmusk, you can pass in the URL:
https://twitter.com/search?q=(from%3Aelonmusk)&src=typed_query&f=liveadverse-sapphireOP•3y ago
Thank you so much!
How do I automate this with Nodejs though?
correct-apricot•3y ago
I am running a sample for you, will soon complete 👍
adverse-sapphireOP•3y ago
Is there any tutorial on how to export these results automatically, so that my code can use them?
correct-apricot•3y ago
correct-apricot•3y ago
I think you can simply use Apify's APIs for this
correct-apricot•3y ago
As per running the scraper and getting the results in Node js, here's the API docs:
https://docs.apify.com/api/v2#/reference/actors/run-actor-synchronously-and-get-dataset-items/run-actor-synchronously-with-input-and-get-dataset-items
adverse-sapphireOP•3y ago
Thank you!