bookmark_tweet
Save tweets to your bookmarks for easy access. Organize them in folders to streamline your X (Twitter) experience.
Instructions
Adds the tweet to bookmarks
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| folder_id | No | ||
| tweet_id | Yes |
Implementation Reference
- src/x_twitter_mcp/server.py:301-301 (registration)Registration of the "bookmark_tweet" tool using the @server.tool decorator from FastMCP.@server.tool(name="bookmark_tweet", description="Adds the tweet to bookmarks")
- src/x_twitter_mcp/server.py:302-313 (handler)The main handler function for the "bookmark_tweet" tool. It performs rate limit check, initializes Twitter clients, calls the bookmark API, and returns success status.async def bookmark_tweet(tweet_id: str, folder_id: Optional[str] = None) -> Dict: """Bookmarks a tweet. Args: tweet_id (str): The ID of the tweet to bookmark. folder_id (Optional[str]): The ID of the bookmark folder to add the tweet to. (Currently not supported by Tweepy v2 client, will be ignored). """ if not check_rate_limit("tweet_actions"): raise Exception("Tweet action rate limit exceeded") client, _ = initialize_twitter_clients() result = client.bookmark(tweet_id=tweet_id) return {"tweet_id": tweet_id, "bookmarked": result.data["bookmarked"]}