π
Emulate any client
Choose which Twitter client to impersonate β Web, Android, iPhone, TweetDeck, or more β each with correct bearer tokens and HTTP fingerprints.
Log in and interact with the unofficial X API using any client identity β web, Android, iOS, or TweetDeck
π
Choose which Twitter client to impersonate β Web, Android, iPhone, TweetDeck, or more β each with correct bearer tokens and HTTP fingerprints.
β‘
Access almost every feature on the platform β tweets, DMs, communities, spaces, bookmarks, lists, and more β through a clean JavaScript interface.
π
Log in with an auth token or username/password, with built-in support for 2FA, email verification, and elevated access.
π
Route all traffic through HTTP or SOCKS5 proxies for IP rotation, rate limit management, or restricted network access.
π§©
Drop down to raw GraphQL, v1.1, or v2 API calls for undocumented endpoints or full control over requests and responses.
π¦
Ships with ESM support, and sensible defaults. Install, import, and start building in seconds.
Install the package and start interacting with Twitter in just a few lines:
js
import Emusks from "emusks";
const client = new Emusks();
await client.login("your_auth_token");
const tweet = await client.tweets.create("Hello from emusks! π");
console.log(`i tweeted to https://x.com/i/status/${tweet.id}`);
// like the tweet
await client.tweets.like(tweet.id);
// get a user
const user = await client.users.getByUsername("elonmusk");
console.log(`${user.name} has ${user.stats.followers.count} followers`);
// follow them
await client.users.follow(user.id);
// search for tweets
const results = await client.search.tweets("javascript");
// get your home timeline
const home = await client.timelines.home();client.tweetsCreate, delete, like, retweet, pin, and schedule tweetsclient.timelinesHome feed, user tweets, media, likes, and highlightsclient.usersGet profiles, follow, block, mute, and manage relationshipsclient.dmsInbox, conversations, search, and message managementclient.searchSearch tweets, users, media, lists, and communitiesclient.bookmarksBookmark tweets, manage folders, and search saved contentclient.listsCreate, manage, and subscribe to curated listsclient.communitiesJoin, create, moderate, and explore communitiesclient.spacesGet details, search, and subscribe to live audio roomsclient.trendsExplore trending topics, locations, and AI summariesclient.topicsFollow, unfollow, and discover topics of interestclient.accountSettings, security, sessions, 2FA, and preferencesclient.notificationsNotification timeline, badges, and push settingsclient.mediaMedia metadata, alt text, and subtitle management