Skip to main content
POST
/
x
/
tweets
Create tweet
curl --request POST \
  --url https://api.example.com/x/tweets \
  --header 'Content-Type: <content-type>' \
  --header 'x-api-key: <x-api-key>' \
  --data '
{
  "account": "<string>",
  "text": "<string>",
  "reply_to_tweet_id": "<string>",
  "attachment_url": "<string>",
  "community_id": "<string>",
  "is_note_tweet": true,
  "media_ids": [
    "<string>"
  ]
}
'
10 credits per call · All plans from $0.00012/credit
curl -X POST https://xquik.com/api/v1/x/tweets \
  -H "x-api-key: xq_YOUR_KEY_HERE" \
  -H "Content-Type: application/json" \
  -d '{
    "account": "elonmusk",
    "text": "Hello from Xquik!"
  }' | jq

Headers

x-api-key
string
required
Your API key. Session cookie authentication is also supported.
Content-Type
string
required
Must be application/json.

Body

account
string
required
X username or account ID identifying which connected X account to post as. The @ prefix is automatically stripped if included.
text
string
required
Tweet text content. Maximum 280 characters for standard tweets, or up to 25,000 characters if is_note_tweet is true.
reply_to_tweet_id
string
Tweet ID to reply to. When set, the new tweet is posted as a reply in that tweet’s thread.
attachment_url
string
URL to attach to the tweet as a card. Must be a valid HTTP or HTTPS URL.
community_id
string
X Community ID to post the tweet into. The connected account must be a member of the community.
is_note_tweet
boolean
Set to true to post a long-form note tweet (up to 25,000 characters). Defaults to false.
media_ids
string[]
Array of media IDs to attach. Upload media first via the Upload Media endpoint, then pass the returned IDs here. Maximum 4 images or 1 video per tweet.

Response

tweetId
string
ID of the newly created tweet.
success
boolean
Always true on success.
{
  "tweetId": "1895432178065391234",
  "success": true
}
Next steps: Delete Tweet to remove a posted tweet, Like or Retweet to engage with tweets.