Twitter Post Scheduling API - With Image
Media Support Capabilities
Supported Media Types
Media Type | File Formats | Max File Size | Max Count | Twitter Specifications |
---|---|---|---|---|
Images | JPG, PNG, WEBP | 5MB per image | 4 per tweet | Recommended: 1200x675px (16:9) |
GIFs | GIF | 15MB | 4 per tweet | Max dimensions: 1280x1080px |
Videos | MP4, MOV | 512MB | 1 per tweet | Max length: 2 minutes 20 seconds |
Media Combination Rules
- Images: Up to 4 images per tweet
- GIF: Up to 4 GIFs per tweet
- Video: 1 video per tweet
Endpoint Details
POST https://portfolio.tigest.club/api/v1/dashboard/post/webhook
Content-Type: multipart/form-data
Request Parameters
Parameter | Type | Required | Description | Valid Values | Example |
---|---|---|---|---|---|
content | string | Yes | The text content of your tweet | Text up to 280 characters | ”Excited to announce our new feature! 🚀“ |
channel | string | Yes | Target platform (always Twitter) | "Twitter" | ”Twitter” |
post_type | string | Yes | Type of content being posted | "post" | ”post” |
calendar_uuid | string | Yes | Unique identifier for your content calendar | Valid UUID format | ”69a1bf45-c48e-46cf-bd53-f47f3efa9763” |
scheduled_at | string | Yes | Publication date and time in ISO 8601 format | Future datetime in UTC | ”2025-05-30T21:30:00Z” |
status | string | Yes | Post publication status | "draft" , "published" , "scheduled" | ”scheduled” |
images | file[] | No | Image, GIF, or video files to attach | See media specifications above | Multiple files via form data |
Example Requests
Schedule Tweet with Multiple Media
curl --location 'https://portfolio.tigest.club/api/v1/dashboard/post/webhook' \
--header 'X-API-KEY: your_api_key_here' \
--form 'content="🚀 Our product evolution in 4 stunning visuals! From concept to reality. Which stage resonates most with your journey? #ProductDevelopment #Innovation"' \
--form 'channel="Twitter"' \
--form 'post_type="post"' \
--form 'scheduled_at="2025-05-29T15:00:00Z"' \
--form 'status="scheduled"' \
--form 'calendar_uuid="69a1bf45-c48e-46cf-bd53-f47f3efa9763"' \
--form 'images=@"/path/to/concept-design.gif"' \
--form 'images=@"/path/to/wireframe.png"' \
--form 'images=@"/path/to/prototype.jpg"' \
--form 'images=@"/path/to/final-product.mp4"'
Response Format
Successful Response with Media
Status Code: 200 OK
{
"data": {
"id": 1073263,
"uuid": "3b3ffdad-1b5c-46f3-a8cc-3bca5d752987",
"calendar_uuid": "69a1bf45-c48e-46cf-bd53-f47f3efa9763",
"calendar_user_uuid": "cb3c071c-319a-4dfb-ab0c-538339d18325",
"content": "🚀 Our product evolution in 4 stunning visuals! From concept to reality. Which stage resonates most with your journey? #ProductDevelopment #Innovation",
"channel": "Twitter",
"images": [
"https://tigestdashboard.blob.core.windows.net/dashboard/concept-design-uuid.gif",
"https://tigestdashboard.blob.core.windows.net/dashboard/wireframe-uuid.png",
"https://tigestdashboard.blob.core.windows.net/dashboard/prototype-uuid.jpg",
"https://tigestdashboard.blob.core.windows.net/dashboard/final-product-uuid.mp4"
],
"status": "scheduled",
"scheduled_at": "2025-05-29T15:00:00Z",
"created_at": "2025-05-28T12:36:09.922160883Z",
"is_active": true,
"updated_at": "2025-05-28T12:36:09.922160883Z",
"post_type": "post",
"post_content": {},
"metadata": {
"media_count": 4,
"media_types": ["image/jpeg", "image/png", "image/jpeg", "image/jpeg"],
"total_media_size": "2.4MB"
},
"campaign_uuid": null,
"analytics": {}
},
"success": true
}
Response Fields
Field | Type | Description |
---|---|---|
images | array | URLs of uploaded media files (images, GIFs, videos) |
metadata.media_count | integer | Number of media files attached |
metadata.media_types | array | MIME types of uploaded media files |
metadata.total_media_size | string | Combined size of all media files |
Error Handling
Media-Specific Error Codes
File Size Exceeded (Code: 4010)
{
"errors": {
"code": 4010,
"message": "Media file too large. Images must be under 5MB, GIFs under 15MB, and videos under 512MB."
},
"success": false
}
Unsupported Media Type (Code: 4011)
{
"errors": {
"code": 4011,
"message": "Unsupported media format. Please use JPG, PNG, WEBP for images, GIF for animations, or MP4/MOV for videos."
},
"success": false
}
Media Combination Error (Code: 4012)
{
"errors": {
"code": 4012,
"message": "Invalid media combination. You can upload up to 4 images, 1 GIF, or 1 video per tweet, but not mixed types."
},
"success": false
}
Media Upload Failed (Code: 4013)
{
"errors": {
"code": 4013,
"message": "Media upload failed. Please check your file paths and try again."
},
"success": false
}
Last updated: May 28, 2025