@mawdbotsonsolana/twitter
v0.1.0
Published
MawdBot — Autonomous Twitter/X agent powered by OpenClaw, Grok, and 20+ services
Maintainers
Readme
Twitter/X Extension for Clawdbot
Enable @mawdbot to tweet, search, and interact with Twitter/X autonomously.
🚀 Features
- Post Tweets - Create new tweets with text and media
- Reply & Quote - Respond to or quote other tweets
- Search - Find tweets by keywords
- Timeline - View your timeline or any user's timeline
- User Lookup - Get profile information
- Engagement - Like, retweet, follow/unfollow
- Mentions - Check who's talking about you
🚀 Migration & Bootstrap
To deploy the autonomous agent on a new server or environment:
Clone the repository and navigate to this folder.
Run the bootstrap script:
chmod +x bootstrap.sh ./bootstrap.shThis will:
- Check for Node.js
- Create
.envfrom.env.example(if missing) - Install dependencies
- Build the project
Configure Environment: Edit
.envand fill in your API keys (Twitter, Gemini, Birdeye, etc.).Start the Agent:
npx pm2 start mawdbot-autonomous.ts --name mawdbot-autonomous
🔐 Environment Variables
Copy .env.example to .env and configure:
# Twitter (OAuth 1.0a - "Read and Write" permissions required)
TWITTER_CONSUMER_KEY=...
TWITTER_CONSUMER_KEY_SECRET=...
TWITTER_ACCESS_TOKEN=...
TWITTER_ACCESS_TOKEN_SECRET=...
# Google Gemini (Image Generation)
GOOGLE_API_KEY=...
# Solana Data
HELIUS_RPC_URL=...
BIRDEYE_API_KEY=...🤖 Autonomous Mode
The mawdbot-autonomous.ts script runs the agent 24/7 with the following schedule:
- Images: Every 60 mins (Gemini Nano Banana Pro)
- Market Updates: Every 17 mins (Birdeye liquidity)
- Hourly Trending: Top 5 tokens every hour
- Engagement: Monitors @0rdlibrary and mentions every 1-2 mins
🎯 AI Agent Tools
The extension registers these tools for natural language interaction:
| Tool | Description |
|------|-------------|
| twitter_tweet | Post a new tweet |
| twitter_tweet_with_media | Post tweet with images |
| twitter_reply | Reply to a tweet |
| twitter_quote | Quote tweet |
| twitter_delete | Delete a tweet |
| twitter_search | Search for tweets |
| twitter_get_tweet | Get tweet details by ID |
| twitter_get_user | Get user profile |
| twitter_get_timeline | Get user's timeline |
| twitter_get_my_timeline | Get your own timeline |
| twitter_like | Like a tweet |
| twitter_unlike | Unlike a tweet |
| twitter_retweet | Retweet |
| twitter_unretweet | Undo retweet |
| twitter_follow | Follow a user |
| twitter_unfollow | Unfollow a user |
| twitter_get_mentions | Get mentions |
| twitter_get_profile | Get your profile |
💬 Usage Examples
Talk to the bot naturally via Telegram:
"Tweet: Hello World! 👋"
"Reply to tweet 123456 saying thanks!"
"Search for tweets about Solana"
"What's @elonmusk latest tweet?"
"Like the tweet 789012"
"Who mentioned me recently?"🏗️ Build
cd extensions/twitter
pnpm install
pnpm build📁 Structure
extensions/twitter/
├── src/
│ ├── services/
│ │ └── twitter-service.ts # Twitter API wrapper
│ ├── tools/
│ │ └── twitter-tools.ts # AI agent tools
│ ├── plugin.ts # Plugin registration
│ └── index.ts # Main export
├── package.json
├── tsconfig.json
└── README.md🔗 Links
- Twitter Account: @mawdbot
- Twitter API: Developer Portal
- twitter-api-v2: npm package
📄 License
MIT
