Automate Twitter/X Posts and Searches
Skill for Twitter/X automation via Composio's Rube MCP: posts, search, user lookup, bookmarks, lists, and likes.
Why it matters
Streamline your Twitter/X presence by automating post creation, media uploads, and targeted searches. This asset leverages Rube MCP to manage your social media interactions efficiently.
Outcomes
What it gets done
Create, delete, and look up posts with optional media attachments.
Search for recent or archived posts using advanced query operators.
Manage user profiles, bookmarks, and Twitter lists.
Automate liking and unliking posts.
Install
Add it to your toolbox
Run in your project directory:
curl -fsSL https://spark.entire.vc/get/ag-twitter-automation | bash Overview
Twitter/X Automation via Rube MCP
A skill for automating Twitter/X operations - posts, search, user lookup, bookmarks, lists, and likes - via Composio's Rube MCP. Use for Twitter/X automation via an MCP-connected agent with an active OAuth connection; watch for non-idempotent post creation.
What it does
Twitter/X Automation via Rube MCP automates Twitter/X operations through Composio's Twitter toolkit. It requires Rube MCP connected (https://rube.app/mcp, no API keys needed) with an active Twitter connection via RUBE_MANAGE_CONNECTIONS (OAuth), and RUBE_SEARCH_TOOLS must be called first for current tool schemas.
When to use - and when NOT to
Use it across six workflows: creating/deleting/looking up posts (TWITTER_CREATION_OF_A_POST, limited to 280 weighted characters where some Unicode counts as more than one and URLs count as a fixed 23 characters), searching posts (TWITTER_RECENT_SEARCH for the last 7 days only, TWITTER_FULL_ARCHIVE_SEARCH requiring Academic Research or Enterprise access for older tweets, and TWITTER_RECENT_SEARCH_COUNTS to get a match count without fetching the tweets themselves - empty results return meta.result_count: 0 with no data field rather than an error), looking up users by username/ID/batch, managing bookmarks (private, requiring the authenticated user's numeric ID), managing lists (owned/membership/pinned/followed, also keyed by numeric user ID), and liking/unliking posts. Media attachment follows a fixed sequence:
1. Upload media with TWITTER_UPLOAD_MEDIA (images) or TWITTER_UPLOAD_LARGE_MEDIA (video/GIF)
2. Get media_id from response
3. Pass media_id as string in media__media_ids array to TWITTER_CREATION_OF_A_POST
Inputs and outputs
Search queries use Twitter's own operator syntax: from:username, to:username, @username mentions, #hashtag, quoted exact phrases, has:media/has:links, is:retweet/-is:retweet, is:reply/-is:reply, and lang:en, combined with space for AND, OR for either, - prefix for NOT, and parentheses for grouping. Nearly every workflow starts with TWITTER_USER_LOOKUP_ME to get the authenticated user's numeric ID, since most endpoints require it rather than a username - usernames themselves must be passed without the @ prefix and are case-insensitive. User and media IDs are numeric strings, not integers, throughout the API.
Integrations
The most critical gotcha: post creation is not idempotent - retrying on a timeout creates duplicate posts, so automated posting needs its own deduplication logic. Rate limits vary significantly by access tier (Free tier allows as few as 1,500 posts/month), checkable via the x-rate-limit-remaining response header. Batch user lookup (TWITTER_USER_LOOKUP_BY_IDS) accepts a maximum of 100 IDs per request, and suspended or deleted accounts return errors rather than empty results. Bookmark pagination uses pagination_token while search pagination uses next_token - a naming inconsistency worth tracking when building generic pagination handling across endpoints.
Who it's for
Teams automating Twitter/X posting, search, and engagement through an MCP-connected agent who need the character-limit, idempotency, and ID-format gotchas already documented to avoid duplicate posts or silent lookup failures. A full quick-reference table maps every task directly to its tool slug and required parameter - e.g. TWITTER_POST_DELETE_BY_POST_ID takes id, TWITTER_ADD_POST_TO_BOOKMARKS takes tweet_id, TWITTER_LIST_LOOKUP_BY_LIST_ID takes list_id - so the right call can be made without re-deriving the correct workflow sequence each time.
FAQ
Common questions
Discussion
Questions & comments · 0
Sign In Sign in to leave a comment.