search_recent_posts
Search recent X (Twitter) posts from the last 7 days using operators like from:, #hashtag, or exact phrases. Retrieve up to 100 results with pagination and sorting.
Instructions
Search recent posts (last 7 days) on X (Twitter).
Supports search operators such as:
from:username (posts by user)
@username (mentions of user)
#hashtag (posts containing hashtag)
"exact phrase" (exact phrase match)
url:domain.com (links to domain)
lang:en (language filter)
-is:retweet (exclude retweets)
-is:reply (exclude replies)
has:images / has:media (media filters)
Args: query: The search query string with optional operators. max_results: Number of posts to retrieve (10 to 100, default 10). next_token: Optional pagination token from a previous search. sort_order: 'recency' or 'relevancy' (default 'recency').
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| next_token | No | ||
| sort_order | No | recency | |
| max_results | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |