Skip to content

Create Blog Comment​

POST
/api/v1/posts/{id}/comments

Parameters​

Path Parameters

id*
Type
string
Required

Request Body​

application/json
JSON
{
  
"content": "string",
  
"parent_comment_id": "string",
  
"metadata": {
  
  
"additionalProperties": "string"
  
}
}

Responses​

Comment created

Playground​

Server
Variables
Key
Value
Body

Samples​

Powered by VitePress OpenAPI

Create a comment on a blog post.

Auth: conditional.

Parameters ​

NameInTypeRequiredDescription
idpathstringYesPost id

Request Body ​

json
{
	"body": "Nice article"
}

Response 200 ​

json
{
	"data": { "id": "com_2", "body": "Nice article" },
	"user_context": { "authenticated": true },
	"meta": {}
}

Response Errors ​

  • 400 invalid comment payload
  • 403 comments not allowed for caller
  • 404 post not found

Notes ​

  • The caller must be allowed to comment by the post visibility rules.
  • Use this from logged-in or guest flows depending on configuration.