Twitter Scraper avatar
Twitter Scraper
Try for free

Pay $1.50 for 1,000 tweets

View all Actors
Twitter Scraper

Twitter Scraper

microworlds/twitter-scraper
Try for free

Pay $1.50 for 1,000 tweets

Twitter Scraper searches and extracts data from Twitter (with historic data from 2006) - parses and converts the data to structured formats: HTML table, JSON, CSV, Excel and XML.

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 more

1# Set API token
2API_TOKEN=<YOUR_API_TOKEN>
3
4# Prepare Actor input
5cat > input.json <<'EOF'
6{
7  "searchTerms": [
8    "apify"
9  ],
10  "searchMode": "live",
11  "maxTweets": 1000,
12  "maxTweetsPerQuery": 1000,
13  "maxRequestRetries": 6,
14  "handle": [
15    "@cnn"
16  ],
17  "urls": [
18    "https://twitter.com/search?q=gpt&src=typed_query&f=live"
19  ]
20}
21EOF
22
23# Run the Actor using an HTTP API
24# See the full API reference at https://docs.apify.com/api/v2
25curl "https://api.apify.com/v2/acts/microworlds~twitter-scraper/runs?token=$API_TOKEN" \
26  -X POST \
27  -d @input.json \
28  -H 'Content-Type: application/json'
Developer
Maintained by Community
Actor metrics
  • 795 monthly users
  • 39 stars
  • 99.1% runs succeeded
  • 1.4 days response time
  • Created in Jul 2023
  • Modified 2 days ago
Categories