> This page is for Agent Handler.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.merge.dev/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.merge.dev/_mcp/server.

# X

**Authentication:** OAuth or bearer token. See [Magic Link](/merge-agent-handler/features/magic-link) for the runtime auth flow, or [Application credentials](/merge-agent-handler/admin-setup/add-oauth-credentials) to bring your own OAuth app.

## Sample use cases

* Pull the engagement on our last 10 tweets and rank by impressions.
* Search for mentions of our brand in the last 24 hours not yet replied to.
* Post the launch announcement and pin it to the company profile.

## Available Tools

#### like\_post

Like a post/tweet by its ID. Requires like.write scope.

#### unlike\_post

Unlike a post/tweet by its ID. Removes your like from the post.

#### retweet

Retweet a post by its ID. Shares the post with your followers.

#### unretweet

Undo a retweet by its original tweet ID. Removes the retweet from your profile.

#### add\_bookmark

Bookmark a post/tweet for later. Private bookmarks are only visible to you.

#### remove\_bookmark

Remove a post from your bookmarks by its tweet ID.

#### get\_bookmarks

Get your bookmarked posts. Returns up to 100 posts per page with pagination.

#### get\_liking\_users

Get users who liked a tweet. Returns up to 100 users with pagination.

#### get\_liked\_tweets

Get tweets a user has liked. Use get\_me first to get your own user ID.

#### get\_retweeters

Get users who retweeted a post. Returns up to 100 users.

#### get\_quote\_tweets

Get quote tweets of a post. Returns tweets that quote the specified tweet.

#### create\_post

Create a new post/tweet. Max 280 chars. Supports replies (reply\_to\_tweet\_id), quotes (quote\_tweet\_id), and polls (2-4 options).

#### delete\_post

Delete a post/tweet by its ID. You can only delete your own posts.

#### get\_post

Get a single post/tweet by its ID. Returns text, author, metrics, and referenced tweets.

#### search\_recent\_posts

Search posts from the last 7 days. Supports operators: from:user, to:user, -is:retweet, has:media, lang:en. Max 100 results per page.

#### follow\_user

Follow a user by their user ID. Use get\_user\_by\_username first if you only have the @handle.

#### unfollow\_user

Unfollow a user by their user ID. Also cancels pending follow requests.

#### mute\_user

Mute a user by their user ID. Their posts won't appear in your timeline but they can still follow you.

#### unmute\_user

Unmute a user by their user ID. Their posts will appear in your timeline again.

#### get\_muted\_users

Get your list of muted users. Muted users' posts don't appear in your timeline.

#### get\_user\_tweets

Get a user's recent tweets by user ID. Can exclude retweets/replies. Use get\_me first to get your own user ID.

#### get\_user\_mentions

Get tweets that mention a user by their user ID. Use get\_me first to get mentions of yourself.

#### get\_me

Get the authenticated user's profile including ID, username, name, bio, and metrics. Use this first to get your user ID for other operations.

#### get\_user\_by\_id

Get a user's profile by their unique ID. Returns username, name, bio, follower counts, and verification status.

#### get\_user\_by\_username

Get a user's profile by @username (without the @ symbol). Returns ID, name, bio, metrics, and verification status.

#### get\_followers

Get a list of users who follow the specified user. Returns up to 1000 followers per request with pagination.

#### get\_following

Get a list of users that the specified user follows. Returns up to 1000 accounts per request with pagination.