Delete a post
Delete a post with DELETE /posts/{id}. Deleted posts can't be restored.
Deletes a post. Deleted posts can't be restored. To take a post off your blog but keep it, use Unpublish a post.
Request
| Item | Value |
|---|---|
| Method · path | DELETE /posts/{id} |
| Permission | Drafts: Write only (write) or higher. Published or scheduled posts: Full access (publish) |
Example
curl -X DELETE https://api-open.weekerp.com/blog/v1/posts/0193a1f2-7c4e-7b8a-9d10-3f2c1b0a9e87 \
-H "Authorization: Bearer wk_live_xxxxxxxx"
Response
You get 204 with no body.
Common errors
| HTTP | code | Fix |
|---|---|---|
| 404 | post_not_found |
Check the post ID. Posts on other blogs can't be found |
| 403 | api_key_scope_insufficient |
Use a full-access key to delete published posts |
| 401 | api_key_invalid |
The key is missing, wrong, or revoked. Check your key |
For the full list of errors, see Error format in Publish posts with the blog API.