Twitter Scraper APIsAdvanced Tweet Search API
Twitter Advanced Tweet Search API

Twitter (X) Advanced Tweet Search API for Precise Keyword, User, and Date-Based Search

Search public Twitter posts using keywords, hashtags, usernames, languages, date ranges, engagement thresholds, and other advanced operators. Retrieve Top, Latest, or Media results as detailed structured JSON.

1 focused search endpoint
Up to 100 tweets per page
Cursor-based pagination
1 base credit + 1 credit per tweet
1,000 free credits
No credit card required
Endpoints

The Advanced Tweet Search API Endpoint

Pick an endpoint to see what it does, which parameters it accepts, and the JSON your application receives. Authenticate with your API key in the x-api-key header.

GET/v1/twitter/tweets/advanced_search

Advanced Search

Search tweets using powerful query operators: keywords, hashtags, mentions, date ranges, language, and more. Get Top, Latest, or Media results programmatically.

Parameters
queryrequiredSearch query with optional operators (from:, to:, since:, until:, lang:, etc.)
query_typeoptionalResult type: "Top", "Latest", or "Media" (default: "Top")
countoptionalNumber of results per page (default: 20)
cursoroptionalPagination cursor for next page
Sample response
{
  "data": [
    {
      "id": "888",
      "text": "Just tried this web scraping API and it's incredible...",
      "author": { "username": "dev_user", "followers_count": 4500 },
      "favorite_count": 67,
      "created_at": "2025-01-20T09:15:00Z"
    }
  ],
  "next_cursor": "search_cursor_abc"
}
View Advanced Search documentation

What Can You Build With the Twitter Advanced Tweet Search API

Brand and reputation monitoring

Search for brand names, product names, campaign hashtags, executive mentions, and customer conversations. Use Latest results to follow new posts and engagement fields to prioritize important discussions.

Market and competitor intelligence

Track competitor announcements, product launches, feature discussions, and customer complaints. Combine account filters, exact phrases, dates, languages, and engagement thresholds to reduce irrelevant results.

News and event monitoring

Retrieve recent posts about breaking news, conferences, sporting events, entertainment releases, or public incidents. Use Latest for chronological monitoring and Top to identify the most prominent posts.

Content and media discovery

Search for popular or recent posts about a topic and switch to Media results when you specifically need images or videos. Use returned media, URL, hashtag, author, and engagement metadata in curation workflows.

Research and dataset collection

Build structured tweet datasets for social research, journalism, NLP, trend analysis, or public-conversation studies. Use cursor pagination to collect multiple pages while retaining timestamps, authors, engagement, entities, media, and location data.

Influencer and author discovery

Filter by minimum likes or retweets to surface posts from influential accounts on a topic. Use the returned author identifiers to feed further profile lookups or build curated source lists.

More Twitter Data APIs

Why Choose ScrapeBadger?

Build Faster

Sub-100ms response times. Most of that is your network latency, not our infrastructure. Deploy, test, iterate the same day instead of week-long proofs-of-concept.

Scale Confidently

99.9% uptime SLA. Your data pipeline doesn't stop because X changed a selector. Monitoring, patching, and infrastructure are all us. You focus on what you built.

All X Data on One Platform

Tweets, profiles, followers, communities, trends, geo, real-time Streams — 40+ endpoints. Whatever you need from X, it's here. No fragmented tooling, no API gaps forcing you to bolt on a second service.

Integrate Anywhere

RESTful API, SDK support (Python, Node, Go, PHP), MCP, CLI, and no code. Use it in an existing system or a new greenfield; the response shape never surprises you.

Integrate With Your Stack

Use ScrapeBadger through an official SDK, a standard API request, a real-time connection, or the tools already in your workflow.

Python SDK

Build asynchronous data pipelines with typed responses, automatic pagination, retry handling, and access to the complete Twitter API.

Node.js SDK

Add Twitter data to Node.js and TypeScript applications with type definitions, async pagination, and support for both ESM and CommonJS.

REST API

Connect from any backend or programming language using standard HTTP requests. Responses arrive as structured JSON that can be stored, transformed, or passed into another service.

WebSockets and Webhooks

Receive new tweets through a persistent WebSocket connection or deliver them directly to your application through signed webhooks. Available with Twitter Streams for account and query monitoring.

MCP for AI Tools

Give compatible AI agents access to Twitter profiles, tweets, search, trends, communities, lists, and monitoring tools through ScrapeBadger's MCP server.

ScrapeBadger CLI

Search tweets, retrieve profiles, inspect trends, and export results as JSON, CSV, Markdown, or terminal-friendly tables without writing an application.

Trusted by Developers Worldwide

See what our customers say about ScrapeBadger Twitter API.

We switched from the official Twitter API and cut our costs by 95%. The pagination is seamless, and we've never hit a rate limit. Best decision we made this year.

MC
Marcus Chen
Lead Data Engineer at DataFlow Analytics
2 weeks ago

The follower and engagement endpoints are incredibly detailed. We use it for influencer research and competitor analysis. Response times are sub-100ms consistently.

SM
Sarah Mitchell
Marketing Director at SocialPulse Agency
1 month ago

Started with the Apify actor, then moved to the API for more control. The 1,000 free credits were enough to build our MVP. Now processing 2M+ tweets monthly.

JR
James Rodriguez
Founder at TweetMetrics
3 weeks ago

Perfect for academic research. The community and trends endpoints give us data we couldn't get anywhere else. Documentation could use more examples, but support is responsive.

EW
Emily Watson
Research Scientist at Stanford NLP Lab
1 month ago

We monitor 50,000+ accounts for our clients. ScrapeBadger handles it without breaking a sweat. The bulk ID endpoints are a game-changer for large-scale monitoring.

AP
Alex Petrov
CTO at MediaMonitor Pro
2 weeks ago

The geo and trends endpoints power our location-based analytics. Setup took 10 minutes. Their Apify actors are also great for quick one-off scrapes.

LP
Lisa Park
Product Manager at Trendy AI
3 weeks ago
Pricing

Simple, transparent pricing

Start with pay-as-you-go credits (never expire) or save up to 64% with a monthly or annual subscription. Failed requests never consume credits, and the exact charge is returned in the X-Credits-Used response header.

Not Sure Which Plan Fits Your Needs? Calculate Your Cost and Find the Right Plan.

Every endpoint uses the same model: 1 base credit + 1 credit per item returned. Single-item lookups always cost 2 credits. Paginated list endpoints cost 1 + the number of items in the page. Failed requests cost 0 credits.

FAQ

Frequently asked questions

Everything you need to know about the Twitter Advanced Tweet Search API.

What is a Twitter Advanced Tweet Search API?

A Twitter Advanced Tweet Search API lets an application search public Twitter posts using keywords, phrases, hashtags, account names, languages, dates, engagement thresholds, and other advanced operators. ScrapeBadger returns matching posts as structured tweet objects.

Which Twitter advanced search operators are supported?

The documented operators include from:, to:, since:, until:, min_faves:, min_retweets:, and lang:. Queries can also contain ordinary keywords, exact phrases in quotes, hashtags, and combinations of multiple filters in a single query string.

What is the difference between Top, Latest, and Media?

Top returns tweets ranked by popularity and relevance and is the default. Latest returns the most recent matching tweets in reverse-chronological order and may return fewer results than Top. Media returns matching tweets that contain images or videos.

What tweet data is returned?

Responses can include tweet text, author identifiers, timestamps, language, engagement counts, media, URLs, hashtags, mentions, polls, places, reply and quote relationships, edit information, link previews, Community Notes indicators, and the tweet source.

How many tweets can I retrieve per request?

The count parameter accepts values from 1 to 100 and defaults to 20 tweets per page. When another page is available, the response includes a top-level next_cursor that can be passed through the cursor parameter to request the next page.

Can I search the complete historical Twitter archive?

The endpoint searches results currently available through Twitter's search system. The API documentation does not promise access to every historical tweet or guarantee complete archive coverage for all dates and queries. Use since: and until: operators to target a specific date range.

How much does the Twitter Advanced Tweet Search API cost?

Every successful search costs 1 base credit plus 1 credit for each tweet returned. A response containing 20 tweets uses 21 credits; a full 100-tweet page uses 101 credits. Failed 4xx and 5xx requests use 0 credits, and the exact charge is returned in the X-Credits-Used response header.

Start building with the Advanced Tweet Search API

Sign up free and get 1,000 API credits. No credit card required.

Disclaimer: ScrapeBadger is not affiliated with, endorsed by, or in any way officially connected with X Corp. (formerly Twitter, Inc.) or any of its subsidiaries or affiliates. The names Twitter, X, and related trademarks are the property of their respective owners.