POST

Publish Draft Post


Publishes a specified draft post by ID. This creates a new post entity with the data from the draft post. If the specified draft post was already published, the published post will be updated with the latest values from the draft post entity.

Authentication

You can only call this method when authenticated as a Wix app or Wix user identity.

Permissions
Manage Blog
Learn more about app permissions.
Endpoint
POST
https://www.wixapis.com/blog/v3/draft-posts/{draftPostId}/publish

Path Params
draftPostIdstringRequired

Draft post ID.

Response Object
postIdstringformat GUID

Published post ID.

Publish Draft Post Example 1
Request
cURL
curl -X POST \ 'https://www.wixapis.com/blog/v3/draft-posts/894a58a2-dc75-422d-9ca6-00a489750dfd/publish' \ -H 'Content-Type: application/json' \ -H 'Authorization: <AUTH>'
Response
JSON
{ "postId": "894a58a2-dc75-422d-9ca6-00a489750dfd" }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Event TriggersThis method triggers the following events:
Did this help?