[X] Search Posts
The [X] Search Posts block retrieves recent posts from X (Twitter) that match a specified search query.
Search recent X posts matching a query
The [X] Search Posts block retrieves recent posts from X (Twitter) that match a specified search query. It accepts a query string of up to 512 characters and supports X API v2 search operators, allowing you to filter by user, hashtag, mention, language, media presence, and more using boolean logic. You can also narrow results to a specific time window using ISO 8601 start and end timestamps, and control how many posts are returned with a maxResults value between 1 and 100 (defaulting to 50).
The block returns an array of post objects, each containing the post's ID, author ID, creation date, text content, and engagement stats including retweet count, reply count, and like count. Results can be stored in a workflow variable as a JSON-stringified string using the destinationVar field, making them available for downstream processing.
This block fits into workflows that involve social media monitoring, trend analysis, content aggregation, or sentiment tracking. It can be paired with AI analysis blocks to classify or summarize post content, or used to feed data into reporting and alerting workflows based on what people are saying about a topic, brand, or event.
What you can build
Real-world workflows powered by the [X] Search Posts block.
Brand Mention Monitoring
Search for posts mentioning a brand or product name to track public sentiment and surface notable conversations in near real time.
Hashtag Trend Tracking
Query posts by hashtag to monitor how a topic or campaign is spreading across X over a rolling 7-day window.
Competitor Activity Analysis
Use the from: operator to pull recent posts from specific accounts and feed them into a summarization or comparison workflow.
Event Coverage Aggregation
Collect posts referencing a live event using hashtags and keywords, then compile highlights or summaries for a report.
Influencer Engagement Review
Retrieve posts directed at or mentioning a specific user and analyze reply and like counts to assess engagement levels.
Media-Rich Content Discovery
Filter posts that contain images or videos on a given topic using the has:media operator combined with a keyword or hashtag query.
Ready to add [X] Search Posts to your workflow?
Get Started FreeCommon questions about [X] Search Posts
What are the required parameters for this block?
The only required parameter is query, a string of up to 512 characters that defines what posts to search for. The options fields (startTime, endTime, maxResults) and destinationVar are all optional.
What does the block return for each post?
Each post in the returned array includes an id, authorId, dateCreated, text, and a stats object containing retweets, replies, and likes counts.
How far back does the search go?
The block searches only the past 7 days of posts. You can further narrow the time range using the startTime and endTime options, both of which accept ISO 8601 date strings.
What search operators are supported in the query field?
The query field supports X API v2 operators including from:, to:, @mentions, #hashtags, is:retweet, is:reply, has:media, has:links, lang:, exclusion with -, grouping with parentheses, and boolean logic using AND, OR, and NOT. Note that operators like has:media and is:retweet must be combined with a standalone keyword or operator to be valid.
What kinds of workflows is this block commonly used in?
This block is commonly used in social media monitoring, trend tracking, sentiment analysis, and content aggregation workflows. It pairs well with AI analysis blocks that process or classify the returned post text, and with reporting blocks that surface engagement metrics.
Related capabilities
[LinkedIn] Create post
Create a post on LinkedIn from the connected account.
[X] Create post
Create a post on X (Twitter) from the connected account.
[YouTube] Search Videos
Search for YouTube videos by keyword.
[YouTube] Fetch Video
Retrieve metadata for a YouTube video (title, description, stats, channel info).
[YouTube] Fetch Captions
Retrieve the captions/transcript for a YouTube video.
[YouTube] Fetch Channel
Retrieve metadata and recent videos for a YouTube channel.
Add [X] Search Posts to your workflow
Build powerful AI workflows with drag-and-drop blocks. No coding required.