Social API reference

Social API · Moderation-Admin

post/v1/workspaces/{workspace_id}/communities/{community_id}/moderation/blocked-termsAuth

Add a hidden word to the community lexicon. A comment whose body contains the term is routed to `action`: `hide` → lands hidden; `pending_approval` → lands in the approve lane. Re-adding a term updates its action. Case-insensitive.

Path parameters

workspace_id*string · uuid

Id of the workspace.

community_id*string · uuid

Id of the community.

Headers

Idempotency-Keystring

Opaque client-generated string (1-256 chars, `[A-Za-z0-9._:-]`) that makes a retry safe: within 24 h a repeat with the same key and body returns the original response with `Idempotent-Replay: true` instead of running again. Same key with a different body is `409 IDEMPOTENCY_KEY_REUSE`.

Request body

term*string

The word/phrase to block (case-insensitive substring). Max 128 chars.

Example: "spoiler"

actionenum (2)

What a match does. Default `hide`.

Example: "hide"

Response · 201 Blocked term added.

id*string · uuid

Blocked term UUID.

Example: "ffffffff-2222-0000-0000-000000000001"

community_id*string · uuid

Owning community UUID.

Example: "cccccccc-cccc-cccc-cccc-cccccccccccc"

term*string

The blocked term (lowercased).

Example: "spoiler"

action*object

What a match does.

Example: "hide"

created_at*string · date-time

ISO timestamp the term was added.

Example: "2026-05-01T12:00:00.000Z"

Example

Request

POST https://social.productcraft.co/v1/workspaces/{workspace_id}/communities/{community_id}/moderation/blocked-terms
Authorization: Bearer YOUR_TOKEN
Content-Type: application/json

{
  "term": "spoiler",
  "action": "hide"
}

Response

{
  "id": "ffffffff-2222-0000-0000-000000000001",
  "community_id": "cccccccc-cccc-cccc-cccc-cccccccccccc",
  "term": "spoiler",
  "action": "hide",
  "created_at": "2026-05-01T12:00:00.000Z"
}