Skip to main content
POST
Create Posts
Quote-posting (using the quote_tweet_id parameter) requires an Enterprise plan. It is not available on self-serve (pay-per-use) tiers.

Media attachments

Upload media first with the chunked upload endpoints, then pass the returned media_id in media.media_ids. A Post may include up to 4 photos, 1 animated GIF, or 1 video. Duration and file size are checked again at Post create. They follow the posting user’s X Premium / verified status and the media_category used at upload — not your developer API plan. These caps apply to tweet_video and amplify_video. If the video is longer than that user is allowed to post, the response is 403 Forbidden:
A successful upload does not guarantee the media can be attached. See size and duration limits.

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json
card_uri
string

Card URI parameter.

community_id
string

Community to post the tweet to.

Pattern: ^[0-9]{1,19}$

Direct message deep link.

edit_options
object

Edit an existing tweet rather than creating a new one.

for_super_followers_only
boolean

Restrict tweet to super followers.

geo
object

Geo location for the tweet.

made_with_ai
boolean

Disclose that the tweet contains AI-generated media.

media
object

Media attachments.

nullcast
boolean

If true, the tweet is not shown in the public timeline.

paid_partnership
boolean

Disclose that the tweet is a paid partnership.

poll
object

Poll configuration.

quote_tweet_id
string

Tweet ID to quote.

Pattern: ^[0-9]{1,19}$
reply
object

Tweet reply configuration.

reply_settings
enum<string>

Who can reply to this tweet.

Available options:
following,
mentionedUsers,
subscribers,
verified
share_with_followers
boolean

Share an exclusive (super-follower) tweet with all followers.

text
string
default:""

Text of the tweet. Required unless media is provided. Defaulted to an empty string so it is always sent: the backend's tweet_text variable is non-null and rejects an absent value.

Response

The request has succeeded.

data
object
errors
object[]