Skip to content

Post Lifecycle

When you create a post through Postproxy, it moves through a predictable lifecycle. This guide explains each state, what to expect, and how to handle different scenarios.

Draft
publish / schedule
Pendingmedia processing
media ok
Scheduled
at scheduled time
Processing< 1 sec
jobs initiated
Processed
media failed
Media Processing Failed

Every post has three independent status layers. Understanding these is essential for building reliable integrations.

Post status

Overall state of the post: draft, pending, scheduled, processing, processed, or media_processing_failed

Platform status

Individual status for each social platform: pending, processing, published, failed, or failed_waiting_for_retry

Media status

Processing state of each attachment: pending, processed, or failed


Your post is saved but not scheduled for publication. It’s a work in progress.

{
"status": "draft",
"draft": true,
"scheduled_at": null
}

Next step: Call POST /api/posts/:id/publish to publish immediately, or update the post with scheduled_at to schedule it.

Can edit/delete: Yes


Your post has been created and media is being processed. The post is not yet ready for publication.

{
"status": "pending",
"draft": false,
"media": [
{ "status": "pending", "content_type": "image/jpeg" }
]
}

What happens:

  1. Media files are downloaded from URLs or processed from uploads
  2. Files are validated and prepared for each platform
  3. Media status transitions: pendingprocessed or failed

Next step:

  • All media processed successfully → status becomes scheduled
  • Any media failed → status becomes media_processing_failed

Typical duration: Images 1–15 seconds. Videos 10–120 seconds depending on size.

Can edit/delete: Cannot edit. Can delete.


Your post is ready and queued for publication at the specified time. All media has been successfully processed.

{
"status": "scheduled",
"draft": false,
"scheduled_at": "2024-01-15T10:00:00Z",
"media": [
{ "status": "processed", "url": "https://cdn.postproxy.dev/..." }
]
}

Next step: At the scheduled time, the system changes status to processing, initiates publishing jobs, and immediately transitions to processed.

Can edit/delete: Cannot edit. Can delete.


A brief intermediate state while platform publishing jobs are being enqueued.

{
"status": "processing",
"draft": false
}

Duration: Usually less than 1 second.

Can edit/delete: No


Platform publishing jobs have been initiated. The post is now in the hands of each platform’s publishing system.

{
"status": "processed",
"draft": false
}

At the platform level, you may see various states:

{
"platforms": [
{ "network": "twitter", "status": "published" },
{ "network": "instagram", "status": "processing" },
{ "network": "youtube", "status": "failed" }
]
}

Can edit/delete: Cannot edit. Can delete from Postproxy (does not remove from social platforms).


Media Processing Failed Media Processing Failed

Section titled “ Media Processing Failed”

One or more media attachments failed to download or process. This is the only failure state at the post level.

{
"status": "media_processing_failed",
"media": [
{
"id": "abc123",
"status": "failed",
"error_message": "Media file not found (404)",
"source_url": "https://example.com/missing.jpg"
}
]
}

Recovery: Create a new post with correct media URLs and delete the failed post.


Even if a post has status: "processed", individual platforms can succeed or fail independently.

pendingprocessingpublished
failedfailed_waiting_for_retryprocessing(retry)
StatusMeaning
pendingWaiting to be processed
processingCurrently publishing — active API call in progress
publishedSuccessfully live on the social network
failedPermanent failure — check error_message
failed_waiting_for_retryTemporary failure, retry scheduled — see retry_after

Post to 3 platforms where 2 succeed and 1 fails:

{
"status": "processed",
"platforms": [
{ "network": "twitter", "status": "published" },
{ "network": "linkedin", "status": "published" },
{
"network": "instagram",
"status": "failed",
"error_message": "Instagram account disconnected"
}
]
}

Postproxy automatically retries transient failures so you don’t have to.

Retried automatically

Network timeouts, temporary rate limits, platform API temporarily unavailable, quota errors

Not retried

Invalid credentials, account disconnected, content policy violations, invalid media format

Retries use exponential backoff:

AttemptDelay
1st retry1 minute
2nd retry5 minutes
3rd retry15 minutes
4th retry30 minutes
5th retry60 minutes

Maximum: 5 retry attempts

{
"network": "twitter",
"status": "failed_waiting_for_retry",
"error_message": "Rate limit exceeded",
"retry_attempts": 2,
"retry_after": "2024-01-15T10:20:00Z"
}

When you include media in a post, it must be processed before publishing can begin.

StatusMeaningDuration
pendingDownloading/processing1–30 seconds
processedReady for publication
failedCould not processCheck error_message
Media typeTypical duration
Small image (< 1 MB)1–5 seconds
Large image (1–10 MB)5–15 seconds
Short video (< 100 MB)10–30 seconds
Large video (> 100 MB)30–120 seconds
ErrorCause
Media file not found (404)URL doesn’t exist
Access denied to media file (403)URL requires authentication
Connection timed outServer too slow or unreachable
Unsupported formatFile type not supported by platform

Subscribe to webhooks to receive real-time updates about your posts. See Webhooks for setup.

EventWhen it fires
post.processedPost finished processing, jobs initiated
platform_post.publishedIndividual platform published successfully
platform_post.failedIndividual platform failed
platform_post.failed_waiting_for_retryRetry scheduled for a platform
media.failedMedia processing error
platform_post.insightsNew analytics available
{
"event_type": "post.processed",
"data": {
"id": "abc123",
"body": "Hello world!",
"status": "processed",
"platforms": [
{ "platform": "twitter", "status": "published" },
{ "platform": "instagram", "status": "published" }
]
}
}
{
"event_type": "platform_post.failed",
"data": {
"id": "pp_456",
"post_id": "abc123",
"platform": "instagram",
"status": "failed",
"error": "Invalid credentials"
}
}

Terminal window
POST /api/posts
{
"post": {
"body": "Big announcement tomorrow!",
"scheduled_at": "2024-01-16T09:00:00Z"
},
"profiles": ["twitter", "linkedin"]
}
  1. Immediate response: status: "scheduled" (no media to process)
  2. At scheduled time: processingprocessed (jobs enqueued, < 1 second)
  3. Platform jobs run asynchronously — Twitter and LinkedIn publish independently

Terminal window
POST /api/posts
{
"post": {
"body": "Big announcement tomorrow!",
"scheduled_at": "2024-01-16T09:00:00Z"
},
"profiles": ["instagram", "facebook"],
"media": ["https://example.com/photo.jpg"]
}
  1. Immediate response: status: "pending", media status: "pending"
  2. Media processing: 5–15 seconds
  3. Media processed → post becomes scheduled
  4. At scheduled time: processingprocessed (jobs initiated)
  5. Platform jobs run asynchronously

Terminal window
POST /api/posts
{
"post": { "body": "Live now!" },
"profiles": ["twitter"]
}
  1. System sets scheduled_at to current time
  2. Status: scheduledprocessingprocessed (< 1 second)
  3. Twitter platform job runs (1–5 seconds)

Total time: 2–10 seconds


Terminal window
# Step 1: Create draft
POST /api/posts
{
"post": { "body": "Work in progress", "draft": true },
"profiles": ["twitter"]
}
# Response: status: "draft"
Terminal window
# Step 2: Publish when ready (hours or days later)
POST /api/posts/abc123/publish
# Response: status: "processing"

The draft stays in draft status with no automatic publishing until you explicitly call /publish.


  1. Post status: processingprocessed (< 1 second)
  2. Platform jobs run independently:
    • Twitter: published (2 sec)
    • LinkedIn: published (3 sec)
    • Instagram: failed — account disconnected (4 sec)
  3. Post remains processed — platform statuses show mixed results

After platforms finish:

{
"status": "processed",
"platforms": [
{ "network": "twitter", "status": "published" },
{ "network": "linkedin", "status": "published" },
{
"network": "instagram",
"status": "failed",
"error_message": "Instagram account disconnected"
}
]
}

Recovery: Fix Instagram connection in your dashboard, then create a new post for Instagram if needed.


  1. Post status: processingprocessed (job initiated)
  2. Twitter API returns rate limit error
  3. Platform status: failed_waiting_for_retry
  4. System waits 1 minute, retries automatically
  5. Twitter publishes successfully

During retry:

{
"status": "processed",
"platforms": [{
"network": "twitter",
"status": "failed_waiting_for_retry",
"retry_after": "2024-01-15T10:01:00Z"
}]
}

PhaseDurationNotes
Post creation< 1 secPost created with initial status
Media processing (images)1–15 secPost in pending status
Media processing (video)10–120 secDepends on file size
SchedulingInstantPost → scheduled after media ready
Job initiation< 1 secprocessingprocessed
Platform publishing (text)1–5 secPer platform
Platform publishing (images)5–15 secPer platform
Platform publishing (video)10–60 secPer platform
Retries1–60 minExponential backoff, max 5 attempts
First insights1+ hourAfter platform reports published
Insight updates2–12 hoursVaries by platform
  • TikTok — May take 1–5 minutes for video processing on their end
  • YouTube — Large videos may take longer to upload
  • Instagram / Twitter / Facebook / LinkedIn — Usually fastest (1–10 seconds)

Use the status query parameter to filter posts:

Terminal window
GET /api/posts?status=draft
GET /api/posts?status=scheduled
GET /api/posts?status=published
GET /api/posts?status=failed
FilterWhat you get
draftAll draft posts
scheduledPosts scheduled for the future
publishedSuccessfully published posts (status: "processed")
failedPosts with at least one failed platform

Check platform statuses

processed means jobs started, not completed. Always check individual platform statuses for actual publishing state.

Handle retries gracefully

Don’t alert users on first failure. Check for failed_waiting_for_retry and wait for automatic retries before reporting permanent failures.

Use webhooks

Instead of polling the API, subscribe to webhook events for instant notifications and fewer API calls.

Plan for partial failures

Posts can partially succeed — some platforms publish while others fail. Handle this in your UI and allow users to retry failed platforms.