Twitter Send Tool
Post and interact with tweets on Twitter/X via X API v2.
How It Works
This skill provides instructions for the Twitter Send tool node. Connect the Twitter Send node to an AI Agent's input-tools handle to enable posting and interactions.
Actions use the connected OAuth user context and the plugin's token-refresh/retry path. Provider scopes and account limits still apply.
twitter_send Tool
Send tweets, replies, retweets, likes, and deletions.
Schema Fields
| Field | Type | Required | Description |
|---|---|---|---|
| action | string | Yes | Action type: tweet, reply, quote, retweet, like, unlike, delete |
| text | string | If tweet/reply/quote | Tweet text content (max 280 characters) |
| tweet_id | string | If reply/quote/retweet/like/unlike/delete | Target tweet ID |
Actions
| Action | Required Fields | Description | Rate Limit Notes |
|---|---|---|---|
tweet |
text | Post a new tweet | Provider controlled |
reply |
text, tweet_id | Reply to an existing tweet | Provider controlled |
quote |
text, tweet_id | Quote an existing tweet | Provider controlled |
retweet |
tweet_id | Retweet an existing tweet | Provider controlled |
like |
tweet_id | Like a tweet | Provider controlled |
unlike |
tweet_id | Remove like from a tweet | Provider controlled |
delete |
tweet_id | Delete your own tweet | Provider controlled |
Examples
Post a tweet:
{
"action": "tweet",
"text": "Hello Twitter! This is my first automated tweet."
}
Reply to a tweet:
{
"action": "reply",
"text": "Thanks for sharing this!",
"tweet_id": "1234567890123456789"
}
Create a thread (chain of replies): First post:
{
"action": "tweet",
"text": "Thread: Here are 3 tips for better code (1/3)"
}
Then reply to the returned tweet ID for each subsequent post:
{
"action": "reply",
"text": "Tip 1: Write tests first (2/3)",
"tweet_id": "<id_from_first_tweet>"
}
Retweet:
{
"action": "retweet",
"tweet_id": "1234567890123456789"
}
Like a tweet:
{
"action": "like",
"tweet_id": "1234567890123456789"
}
Unlike a tweet:
{
"action": "unlike",
"tweet_id": "1234567890123456789"
}
Delete a tweet:
{
"action": "delete",
"tweet_id": "1234567890123456789"
}
Response Format
Tweet/Reply:
{
"success": true,
"result": {
"id": "1234567890123456789",
"text": "Hello Twitter!"
},
"execution_time": 0.45
}
Retweet:
{
"success": true,
"result": {
"retweeted": true
},
"execution_time": 0.3
}
Like:
{
"success": true,
"result": {
"liked": true
},
"execution_time": 0.25
}
Delete:
{
"success": true,
"result": {
"deleted": true
},
"execution_time": 0.3
}
Error Response
{
"success": false,
"error": "Tweet text is required",
"execution_time": 0.01
}
Guidelines
- Character limit: This node clips tweet/reply/quote text to the first 280 characters before sending. Compose within that limit to avoid losing content.
- Tweet IDs: Use the numeric ID string (e.g.,
1234567890123456789). Get these from search results or user timelines. - Rate limits: X API has strict rate limits (see table above). Space out rapid actions.
- Content policy: Follow X's content policies and terms of service.
- Threading: Use reply action with
tweet_idset to the previous tweet's ID to create threads. - Token refresh: If a 401/403 error occurs, the system automatically refreshes the OAuth token and retries.
- Retweet vs Quote: Use
retweetwithtweet_idfor a native retweet. Usequotewithtweet_idandtextfor a quote tweet.
Common Use Cases
- Post automated updates and announcements
- Reply to mentions or specific tweets
- Like tweets matching certain criteria (found via twitter_search)
- Create tweet threads by chaining replies using returned IDs
- Engage with followers programmatically
- Delete tweets that match certain conditions
Setup Requirements
- Connect the Twitter Send node to an AI Agent's
input-toolshandle - Ensure Twitter is connected (authenticated via OAuth in Credentials Modal)
- Your X Developer account must have appropriate API access level
- Required OAuth scopes:
tweet.read,tweet.write,like.read,like.write,users.read,offline.access
