twscrape

Scrape tweets, profiles, followers, and trends from Twitter/X via GraphQL API.

Updated Feb 23, 2026
One-click install
npx skills add https://github.com/zphwd/bianchengbaodian --skill twscrape-zphwd
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: twscrape
Source: https://github.com/zphwd/bianchengbaodian/tree/main/skills/twscrape
Command: npx skills add https://github.com/zphwd/bianchengbaodian --skill twscrape-zphwd

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses the challenges of extracting data from Twitter/X by providing a robust Python library that bypasses API limitations through account rotation and leverages the GraphQL API for advanced scraping.

Core Features & Use Cases

  • Twitter/X Data Scraping: Extract tweets, user profiles, followers, trends, and more.
  • Account Rotation & Session Management: Uses multiple accounts to avoid rate limits and ensure continuous scraping.
  • Async Operations: Supports asynchronous programming for efficient, large-scale data collection.
  • Use Case: A social media analyst needs to gather all tweets mentioning a specific brand over the past month. This Skill can be used to perform this search efficiently, handling potential rate limits by rotating through multiple accounts.

Quick Start

Use the twscrape skill to search for tweets containing the phrase "AI advancements".

Frequently Asked Questions about twscrape

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I scrape Twitter data without hitting API rate limits?

Scrape Twitter data without hitting API rate limits by using account rotation, which cycles through multiple accounts to ensure continuous data extraction. This approach bypasses standard API limitations by distributing requests across sessions.

What is the best way to extract large-scale Twitter follower lists and user profiles?

Extract large-scale Twitter follower lists and user profiles efficiently by using asynchronous operations. Async programming allows you to handle large-scale data collection concurrently, retrieving user data without blocking sequential requests.

Can I use Python to retrieve tweets mentioning a specific brand over the past month?

You can use Python to retrieve tweets mentioning a specific brand over the past month by leveraging the GraphQL API. This method provides advanced search capabilities to gather targeted tweets efficiently for social media analysis.

Does Twitter scraping with account rotation support retrieving trending topics?

Twitter scraping with account rotation does support retrieving trending topics. The system leverages the GraphQL API to extract trends, user profiles, and tweets while managing session rotations to avoid rate limits.

How does the GraphQL API improve Twitter data extraction compared to standard methods?

The GraphQL API improves Twitter data extraction by allowing precise data queries and advanced scraping capabilities. It bypasses standard API limitations, enabling efficient retrieval of tweets, user profiles, and follower lists.