v1Resources/Posts/deleteUnpublish and delete a post
Unpublish and delete a post
Unpublishes the post from every platform it went live on, then archives it: the record is kept but no longer listed. A post that never went live (draft, scheduled, error) has nothing to unpublish and is archived straight away, which also cancels its schedule. If any platform fails to unpublish, the post is not archived and the response reports the failures with ok: false; platforms already unpublished stay unpublished, so retry to finish the rest.
delete
posts:write/api/v1/posts/{id}Query parameters
idstringrequired
The post to delete.
Response
dataobjectoptional
idstringoptional
Unique identifier for the post.
okbooleanoptional
Whether every platform submission was successfully unpublished.
deletednumberoptional
Number of platform submissions successfully unpublished.
failedarray of objectoptional
Platform submissions that failed to unpublish, if any.
connectionIdstringoptional
ID of the connection whose unpublish failed.
platformstringoptional
The platform this row is for.
errorstringoptional
Error message describing why the unpublish failed.
Errors
401Missing, invalid, expired, or revoked API key.
403The key lacks the required scope, or isn't authorized for this client/location.
404The resource wasn't found, or doesn't belong to your agency.
429Too many requests. Retry after the number of seconds in the Retry-After header.
delete/api/v1/posts/{id}
Your API key
id *
{
"data": {
"id": "cm_post_abc123",
"ok": true,
"deleted": 2,
"failed": []
}
}