Twitter / X API Reference
Post tweets with text, images, video, and GIFs via the Schedulala API.
Quick reference
| auth | OAuth 2.0 |
| text Limit | 280 characters |
| max Media | 4 images OR 1 video |
| media Rule | Images and video cannot be mixed |
| max Video Duration | 2 min 20 s |
| entity Selection | None |
| first Comment | Supported — 280 chars (Premium limits apply per account); thread-target comments supported |
Content types
Up to 280 characters
Up to 4 images per post. JPEG, PNG, GIF, WebP.
1 video per post. MP4 or MOV. Max 512 MB.
Counts as video — only 1 per post
Not supported
Media requirements
Constraints enforced by Twitter / X's API. Requests that violate these limits will be rejected.
| Constraint | Value |
|---|---|
| Max image size | 5 MB |
| Max video size | 512 MB |
| Image formats | JPEG, PNG, GIF, WEBP |
| Video formats | MP4, QUICKTIME |
| Max video duration | 2 min 20 s |
| Image aspect ratio | 1:3 to 3:1 |
| Min image dimensions | 4x4 px |
| Max media items | 4 |
| GIF support | Yes |
Platform settings
Pass these fields inside platformSettings.twitter in the request body.
| Name | Type | Required | Description |
|---|---|---|---|
communityId | string | Optional | ID of a Twitter Community to post to. Omit for a regular tweet. |
shareWithFollowers | boolean | Optional | Whether to share a community post with your followers' timelines.Default: true |
communityIdstringOptionalID of a Twitter Community to post to. Omit for a regular tweet.
shareWithFollowersbooleanOptionalWhether to share a community post with your followers' timelines.
Default: true
Code examples
Basic post
curl -X POST https://schedulala.com/api/v1/posts \-H "Authorization: Bearer sk_live_YOUR_KEY" \-H "Content-Type: application/json" \-d '{"content": "Hello from the Schedulala API!","platforms": [{ "platform": "twitter", "accountId": "acc_123" }],"publishNow": true}'
Post with media
curl -X POST https://schedulala.com/api/v1/posts \-H "Authorization: Bearer sk_live_YOUR_KEY" \-H "Content-Type: application/json" \-d '{"content": "Check out these photos!","platforms": [{ "platform": "twitter", "accountId": "acc_123" }],"mediaItems": [{ "type": "image", "url": "https://example.com/photo1.jpg" },{ "type": "image", "url": "https://example.com/photo2.jpg" }],"publishNow": true}'
Quirks & gotchas
4 images OR 1 video per post — you cannot mix images and video.
GIFs count as video, so you can only include 1 GIF and no other media.
Minimum image dimensions: 4x4 px.
Image max: 5 MB. Video max: 512 MB.
WebP images are supported but may be re-encoded.