馃彲 Tweet Scraper V2 (Pay Per Result) - X / Twitter Scraper avatar
馃彲 Tweet Scraper V2 (Pay Per Result) - X / Twitter Scraper
Try for free

Pay $0.30 for 1,000 tweets

View all Actors
馃彲 Tweet Scraper V2 (Pay Per Result) - X / Twitter Scraper

馃彲 Tweet Scraper V2 (Pay Per Result) - X / Twitter Scraper

apidojo/tweet-scraper
Try for free

Pay $0.30 for 1,000 tweets

鈿★笍 Lightning-fast search, URL, list, and profile scraping, with customizable filters. At $0.30 per 1000 tweets, and 30-80 tweets per second, it is ideal for researchers, entrepreneurs, and businesses! Get comprehensive insights from Twitter (X) now!

The code examples below show how to run the Actor and get its results. To run the code, you need to have an Apify account. Replace <YOUR_API_TOKEN> in the code with your API token, which you can find under Settings > Integrations in Apify Console. Learn mode

Node.js

Python

curl

1import { ApifyClient } from 'apify-client';
2
3// Initialize the ApifyClient with your Apify API token
4const client = new ApifyClient({
5    token: '<YOUR_API_TOKEN>',
6});
7
8// Prepare Actor input
9const input = {
10    "startUrls": [
11        "https://twitter.com/apify/status/1727706472623091883",
12        "https://twitter.com/apify",
13        "https://twitter.com/search?q=apify%20&src=typed_query",
14        "https://twitter.com/i/lists/78783491",
15        "https://twitter.com/elonmusk/likes",
16        "https://twitter.com/elonmusk/with_replies"
17    ],
18    "searchTerms": [
19        "web scraping",
20        "scraping from:apify"
21    ],
22    "twitterHandles": [
23        "elonmusk",
24        "taylorswift13"
25    ],
26    "conversationIds": [
27        "1754067365707563045",
28        "1732037140111102460"
29    ],
30    "maxItems": 1000,
31    "sort": "Top",
32    "tweetLanguage": "en",
33    "author": "apify",
34    "inReplyTo": "webexpo",
35    "mentioning": "elonmusk",
36    "geotaggedNear": "Los Angeles",
37    "withinRadius": "15km",
38    "geocode": "37.7764685,-122.4172004,10km",
39    "placeObjectId": "96683cc9126741d1",
40    "minimumRetweets": 5,
41    "minimumFavorites": 5,
42    "minimumReplies": 5,
43    "start": "2021-07-01",
44    "end": "2021-07-02",
45    "customMapFunction": (object) => { return {...object} }
46};
47
48(async () => {
49    // Run the Actor and wait for it to finish
50    const run = await client.actor("apidojo/tweet-scraper").call(input);
51
52    // Fetch and print Actor results from the run's dataset (if any)
53    console.log('Results from dataset');
54    const { items } = await client.dataset(run.defaultDatasetId).listItems();
55    items.forEach((item) => {
56        console.dir(item);
57    });
58})();
Developer
Maintained by Community
Actor metrics
  • 1.1k monthly users
  • 87.1% runs succeeded
  • 0.3 days response time
  • Created in Nov 2023
  • Modified about 11 hours ago