Update thread visibility (private/public/unlisted)
:guid (Line 339)"private": Owner-only access"public": Public access when public_sharing feature enabled"unlisted": Accessible via direct link when public_sharing feature enabledthreads SET visibility = {request.Visibility}, updated_at = NOW() WHERE thread_id = {threadId}"private": Thread becomes owner-only"public": Thread becomes publicly accessible (if public_sharing feature enabled)"unlisted": Thread accessible via direct link (if public_sharing feature enabled)privatepublicpublic_sharing = true, owner only if falseunlistedpublic_sharing = true, owner only if false"Public", "PUBLIC"): Accepted, lowercased (Line 392)| Code | HTTP | Cause | Controller Line |
|---|---|---|---|
| N/A | 401 | JWT missing or invalid | Middleware |
| N/A | 401 | User ID claim missing | 352-355 |
INVALID_REQUEST | 400 | Visibility null/empty | 381-389 |
INVALID_REQUEST | 400 | Invalid visibility value | 391-400 |
NOT_FOUND | 404 | Thread doesn’t exist | 359-367 |
FORBIDDEN | 403 | Not thread owner | 369-378 |
VISIBILITY_UPDATE_ERROR | 500 | Service exception | 411-419 |
updated_at timestamp changes on every callpublic_sharing feature flag
Behavior Matrix:
| Flag | Visibility | Effect on Access |
|---|---|---|
| ON | private | Owner only |
| ON | public | Public access |
| ON | unlisted | Link-based access |
| OFF | private | Owner only |
| OFF | public | Owner only (flag overrides visibility) |
| OFF | unlisted | Owner only (flag overrides visibility) |
public_sharing = false
visibility field echoing normalized value (lowercased)"PUBLIC" → Response "public"