Browse Community Interaction

beta · guide · 0.1.0

Resolve moderation reports

Use moderation:write from a Project Backend after its own reviewer or policy has decided one received report. MiniCenter records either restricted or no_action and atomically sets the Comment to restricted or visible. A restriction uses the report's fixed reason; no separate free-text reason is accepted.

Shell example
: "${MINICENTER_URL:?set the Sandbox URL}"
: "${MINICENTER_PROJECT_CREDENTIAL:?set a Project Credential}"
: "${MINICENTER_COMMENT_ID:?set a Comment ID}"
: "${MINICENTER_REPORT_ID:?set a report ID}"

curl --fail-with-body -X PUT "${MINICENTER_URL}/api/v1/community/comments/${MINICENTER_COMMENT_ID}/reports/${MINICENTER_REPORT_ID}/decision" \
  -H "Authorization: Bearer ${MINICENTER_PROJECT_CREDENTIAL}" \
  -H 'Content-Type: application/json' \
  --data '{"resource_type":"article","resource_id":"article-42","decision":"restricted"}'

The credential, report, Comment, Project Client and exact opaque resource must match. The first decision is permanent: an identical retry safely returns the same decided_at, while a different decision returns 422. Use reports:read to query one report or moderation:read to observe the outcome in the queue.

The first successful decision also publishes one client-scoped community.comment.moderated Domain Event in the same database transaction. Subscribe through the Events & Webhooks capability, verify its signature, and deduplicate at-least-once delivery by the envelope id. An identical decision retry does not publish another logical event.

The response and queue omit reporter identity and Comment body. This operation never deletes or rewrites Comment content, restricts an account, sends a notification, or decides Project-specific consequences. The Project Backend remains responsible for review authority and display policy. If MiniCenter is unavailable or the result is uncertain, retry the identical PUT; never substitute a different decision.