Skip to content

Moderate Blog Comment​

POST
/api/v1/posts/comments/{commentId}/moderate

Authorizations​

SessionAuth

Session ID for authenticated requests

Type
API Key (header: X-Session-ID)

Parameters​

Path Parameters

commentId*
Type
string
Required

Request Body​

application/json
JSON
{
  
"status": "string",
  
"reason": "string"
}

Responses​

Moderation applied

Playground​

Server
Authorization
Variables
Key
Value
Body

Samples​

Powered by VitePress OpenAPI

Moderate a blog comment.

Auth: session + moderator/admin.

Parameters ​

NameInTypeRequiredDescription
commentIdpathstringYesComment id

Request Body ​

json
{
	"action": "approve"
}

Response 200 ​

json
{
	"data": { "id": "com_2", "status": "approved" },
	"user_context": { "authenticated": true, "user_type": "moderator" },
	"meta": {}
}

Response Errors ​

  • 400 invalid moderation action
  • 401 missing session
  • 403 missing moderator/admin role
  • 404 comment not found

Notes ​

  • Use this to approve, reject, or review comments depending on moderation policy.