Write Actions

Create Draft Tweet

Save a draft tweet on the account behind your registered session. A draft is private to that account and is never published: it appears in X's own composer under Drafts until you post or delete it. Accepts text, up to 4 media_ids, a reply_to and a quote, exactly like tweet/create. Billed at $0.0016 per call. Cost: $0.0016 per call.

post/draft/create

Request

  • Base URL: https://api.twitterapis.com/twitter
  • URL: https://api.twitterapis.com/twitter/draft/create
  • Auth: HTTP bearer

Request body

textstring required

The draft body. A draft with no text is refused with 400.

media_idsstring

Up to 4 media IDs from media/upload, as a comma-separated string or a JSON array. Omit for a text-only draft.

reply_tostring

ID of the tweet this draft replies to (send it as a string; X IDs are 19 digits).

quotestring

ID of the tweet this draft quotes (send it as a string; X IDs are 19 digits).

Example request

{
  "text": "Draft: our Q1 changelog is nearly done.",
  "media_ids": "1899999999999999999",
  "reply_to": "2080297101888733302",
  "quote": "1900000000000000000"
}

Response

Save a private draft on your own account. Nothing is posted.

okboolean

True when X returned an id for the new draft.

draft_tweet_idstring nullable

Numeric ID of the saved draft, or null when X refused the create. A null here answers 422 and is not billed.

Changes

No recorded changes to this operation across all 1 revision of this API.