Posts
Edit a post
Before any network has started sending, replaces targets, sets scheduledAt or moves the post between draft and scheduled. Omitted fields are kept.
PATCH /v1/posts/{id} rewrites the targets, moves scheduledAt or changes status: draft removes the schedule and keeps the content, scheduled reschedules it. Once a network has sent the post, the response is 409 post_not_editable.
curl -X PATCH https://api.sofia-post.com/api/v1/posts/$POST_ID \
-H "Authorization: Bearer $SOFIA_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"status":"scheduled","scheduledAt":"2026-11-20T09:00:00Z"}'Authorizations
AuthorizationstringheaderrequiredYour personal key or OAuth access token, sent as
Bearer <token>.
Path parameters
idstringrequiredIdentifier of the post.
Body
targetsobject[]All the targets, rewritten (text, media, format, account); absent: kept
Show child attributes
platformstringrequiredTargeted network
Allowed values:
instagramfacebookxlinkedintiktoktextstringrequiredCaption published on this network
mediaobject[]Attached media
Show child attributes
idstringIdentifier of a media of the establishment library (otherwise
urlandtype)urlstringPublic address of the media (https in live); without an identifier
typestringKind of the media given by address
Allowed values:
imagevideo
formatstringFormat (
post,reel,story,carousel...); by default, the one the network would serveaccountIdstringLive: the connected account that publishes, when the establishment has several on this network (
GET /v1/establishments/:id/accounts)
scheduledAtstring<date-time>New date, in the future: the post is scheduled at this date
statusstringdraft: back to draft (keeps the content, loses the time);scheduled: schedule atscheduledAt, or at the time it hadAllowed values:
draftscheduled
Response
The post after the edit.
idstringrequiredIdentifier of the post
statusstringrequiredAcross all networks;
partial: published on one, failed on anotherAllowed values:
draftscheduledpublishingpublishedsent_to_inboxfailedpartialestablishmentIdstringrequiredEstablishment of the post
createdAtstring<date-time>requiredWhen the post was created
targetsobject[]requiredOne entry per network and account: two accounts on one network, two entries
Show child attributes
platformstringrequiredNetwork of the target
accountIdstringrequiredThe account that publishes (
GET /v1/establishments/:id/accounts)statestringrequiredState of the target on its network
Allowed values:
draftscheduledpublishingpublishedsent_to_inboxfailedpublishedAtstring<date-time>When the target was published
permalinkstringLink to the published post on the network
errorstringWhy the network refused
scheduledAtstring<date-time>When the post is scheduled to be published