Retry failed post
Immediately retries publishing a failed post. Returns the updated post with its new status.
API key authentication - use your Zernio API key as a Bearer token
In: header
Path Parameters
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.posts.retryPost({ path: { postId: 'post_abc123', },});console.log(data);{
"message": "Post published successfully",
"post": {
"_id": "65f1c0a9e2b5af0012ab34cd",
"content": "Check out our new product!",
"status": "published",
"publishedAt": "2024-11-01T10:00:05Z",
"platforms": [
{
"platform": "twitter",
"accountId": {
"_id": "64e1f0...",
"platform": "twitter",
"username": "@acme",
"displayName": "Acme Corp",
"isActive": true
},
"status": "published",
"platformPostId": "1234567890",
"platformPostUrl": "https://twitter.com/acme/status/1234567890"
}
]
}
}{
"error": "string",
"type": "invalid_request_error",
"code": "string",
"param": "string",
"platform": "string",
"platformError": {},
"details": {}
}{
"error": "Unauthorized"
}{
"error": "string"
}{
"error": "string",
"type": "invalid_request_error",
"code": "string",
"param": "string",
"platform": "string",
"platformError": {},
"details": {}
}{
"error": "Not found"
}{
"error": "string",
"type": "invalid_request_error",
"code": "string",
"param": "string",
"platform": "string",
"platformError": {},
"details": {}
}{
"error": "string",
"details": {}
}Bulk upload from CSV POST
Create multiple posts by uploading a CSV file. Use dryRun=true to validate without creating posts.
Edit published post POST
Edit the text of an already-published post. Supported on X (Twitter), Discord, Facebook, and Reddit. Each platform enforces its own rules: **X (Twitter)** - Connected X account must have an active X Premium subscription - Must be within 1 hour of original publish time - Maximum 5 edits per tweet (enforced by X) - Threads cannot be edited, only single tweets - X assigns a NEW post ID on edit, returned as `id` **Discord** - No time limit and no premium requirement - The message ID is unchanged after the edit **Facebook** - Graph only permits editing a post that the same app created, so this works on posts published through Zernio and is rejected for posts created in Meta Business Suite / Composer or by another tool - Media cannot be swapped, only the message text - Reactions, comments, and shares are preserved. The post ID is unchanged **Reddit** - Self-posts only. A link post has no editable body and is rejected before the write - Body only. Reddit exposes no API to edit a post title, ever - The post ID is unchanged Media edits are not supported on any platform. The post record in Zernio is updated with the new content and an edit-history entry.