# Delete a Contributor Network comment

```http
DELETE /api/public/v1/contributor-network/items/{itemId}/comments/{commentId}
```

**Scope**: `contributor-network.write`.

Removes one comment from public view and leaves a fully redacted thread-position tombstone. A comment author may delete their own comment; the item author may moderate comments on their item.

Competition enrollment is not required, but the API key owner must have completed account setup.

## Path parameters

| Parameter | Requirement |
| :--- | :--- |
| `itemId` | **Required string.** Opaque Contributor Network item ID. |
| `commentId` | **Required string.** Opaque comment ID belonging to that item. |

## Request

The request has no body or query parameters. Do not send an `idempotencyKey`; deleting a comment is naturally idempotent.

```bash
export SAIR_API_BASE="https://api.sair.foundation/api/public/v1"
export SAIR_ITEMS_URL="$SAIR_API_BASE/contributor-network/items"

curl -X DELETE \
  "$SAIR_ITEMS_URL/$ITEM_ID/comments/$COMMENT_ID" \
  -H "Authorization: Bearer $SAIR_API_KEY"
```

## Authorization and unavailable items

For a visible comment on an active public item, the caller must be either the immutable comment author or the immutable item author. Another caller receives `403 COMMENT_NOT_AUTHOR`.

The same two authors remain authorized to remove the comment after the item or its owning Competition is withdrawn, hidden, deleted, or otherwise unavailable. This cleanup path does not make the parent item or comment readable again. A caller that cannot establish one of those immutable author relationships receives `404 NOT_FOUND` for an unavailable parent or tombstone.

## Response

Returns:

```http
HTTP/1.1 204 No Content
Cache-Control: private, no-store
```

The response has no body and no `Content-Type` header. The thread keeps the same comment ID, `createdAt`, and sort position, but exposes `author: null`, `body: null`, `isDeleted: true`, and `viewerCanDelete: false` as documented by [List comments](./list-comments.md).

The visible `commentCount` decreases exactly once. The `idempotencyKey` originally used to create the comment remains bound and can never create a replacement comment.

## Idempotency

The comment author and item author both receive `204` when concurrently deleting the same visible comment. Repeating the request later as either originally authorized author also returns `204`; it does not decrement the count again or rewrite the tombstone.

## Errors

| HTTP | Code | When |
| :---: | :--- | :--- |
| `400` | `MALFORMED_BODY` | The request contains a body, a query parameter, or another unsupported top-level request field. |
| `403` | `ACCOUNT_INITIALIZATION_REQUIRED` | The API key owner has not completed account setup. |
| `403` | `COMMENT_NOT_AUTHOR` | The matching visible comment and active public item exist, but the caller is neither author. |
| `404` | `NOT_FOUND` | The item or comment does not exist, the comment belongs to another item, or the caller has no cleanup authorization for an unavailable item or tombstone. |

See [Errors](../../errors.md) for shared errors.
