X (Twitter) API Guide

How to Schedule X Retweets via API

Retweet any X post on a schedule using the PostFast API. Amplify your own tweets or share community content programmatically.

Last updated: April 2026
Amplify your best X content on autopilotGet API Key

A retweet shares another user's (or your own) tweet on your timeline without modification. Using the PostFast API, you can schedule retweets by passing the original tweet's URL to the xRetweetUrl control.

When xRetweetUrl is set, the content and mediaItems fields on your post are ignored - the API simply shares the original tweet exactly as it appears. This is ideal for amplifying your own best posts across time zones, resharing community content, or scheduling retweets of partner announcements.

Accepted URL formats include x.com, twitter.com, and mobile.twitter.com. Example: https://x.com/username/status/1234567890.

API Parameters

ParameterTypeDescription
xRetweetUrlstringURL of tweet to retweet without changes. Content and media are ignored when this is provided. Accepted formats: x.com, twitter.com, mobile.twitter.com

Code Example

const response = await fetch('https://api.postfa.st/social-posts', {
  method: 'POST',
  headers: {
    'pf-api-key': 'YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
        "posts": [
            {
                "content": "",
                "scheduledAt": "2026-05-01T16:00:00.000Z",
                "socialMediaId": "aa1a3044-98aa-07b2-b493-221232117009"
            }
        ],
        "controls": {
            "xRetweetUrl": "https://x.com/postfast/status/1234567890"
        }
    })
});

const data = await response.json();

Did You Know?

Content and media
Ignored
Any content or mediaItems you provide are discarded - the original tweet is shared as-is.
Accepted URL formats
x.com, twitter.com, mobile.twitter.com
Any of the three work. Example: https://x.com/username/status/1234567890
Counts toward X daily limit
Yes
Retweets count against your plan's per-account X daily limit (6-9 depending on plan) and your organization's shared daily pool. See /fair-usage.
Tweet visibility
Must be publicly accessible
X itself rejects retweets of protected, deleted, or blocked-author tweets at publish time.

Tips

Schedule retweets of your own top-performing tweets ~12-24 hours later to reach different time zones

Retweets still count toward your plan's X daily limit (6-9 per account per day) - budget them alongside original tweets

Use any of the three accepted URL formats - x.com, twitter.com, or mobile.twitter.com

You can leave content as an empty string when xRetweetUrl is set - it has no effect on the published retweet

For adding your own commentary on top of a shared tweet, note that quote tweets are not yet supported via API

Schedule retweets across time zones programmatically

7-day free trial
Try PostFast Free

Common Pitfalls

Providing content expecting it to show

When xRetweetUrl is set, both content and mediaItems are discarded. The retweet shows only the original tweet. Use quote tweets (not yet API-supported) if you want to add commentary.

Invalid URL format

Only x.com, twitter.com, and mobile.twitter.com URLs are documented as accepted. Other formats (share links, shortened URLs) are not guaranteed to work - use one of the three documented domains.

Retweeting deleted or protected tweets

If the original tweet is deleted, made private, or its author blocks your account before the scheduled time, the retweet will fail at publish time.

Frequently Asked Questions

What happens to content and media when xRetweetUrl is set?

They are ignored. PostFast passes the original tweet URL to X and the retweet shares the original tweet exactly as it appears - your own content and mediaItems are discarded.

Which URL formats are accepted?

Three formats work: x.com, twitter.com, and mobile.twitter.com. For example: https://x.com/username/status/1234567890 or https://twitter.com/username/status/1234567890.

Can I retweet my own posts?

Yes. Retweeting your own tweets is a common tactic to reach followers across time zones. The retweet appears on your timeline as a shared copy of the original.

Automate retweets alongside original posts from one API

Start Free Trial
7-day free trialCancel anytime