API · v1 · stabil
CODEMETA OSDeveloper Center
Konsole öffnen
Entity · entity_watchers

Entity Watcher Schema

Schema-ID
entity_watcher
Collection
entity_watchers
Permissions
  • Lesenentity_watcher_view
  • Anlegenentity_watcher_manage
  • Ändernentity_watcher_manage
  • Löschenentity_watcher_manage

Felder

Entity Watcher Schema

entity_watchers4 Permissions

Schema for validating entity watcher subscriptions (Beobachter)

entityTypestringerforderlich

Target COLLECTION name (plural, e.g. "tickets" / "hr_tickets") — not the singular schema id. Matches the `entityType` convention of the notifications collection.

max 64 Zeichenread-only
entityIduuiderforderlich

UUIDv7 of the watched record.

read-only
userIduuiderforderlich

INTERNAL user id (`users._id`, UUIDv7) — never the better-auth session id. Everything downstream (notifications, data scopes) speaks internal ids.

read-only
userNamestringoptional

Denormalized display name for the watcher chips, so the list does not need an N+1 join. Display-only; `userId` is authoritative.

max 200 Zeichennullable
originstringoptional

How the subscription came to be. MANUAL = clicked "Beobachten". The AUTO_* origins come from ADR 0515 §4 (commented / was mentioned / handed the ticket over) and are what the per-user auto-watch toggle switches off. Kept for the UI hint and for measuring whether auto-watch pulls its weight.

MANUALAUTO_COMMENTAUTO_MENTIONAUTO_HANDOVER
Default: "MANUAL"read-only
mutedUntildatetimeoptional

Silence deliveries until this instant WITHOUT losing the subscription. Null = active.

nullable

Standard-Endpoints

Diese Resource folgt dem generischen CRUD-Vertrag der Plattform. Lesen Sie die Konventionen für Pagination, Idempotenz, Optimistic Locking und Audit. Die wichtigsten Endpoints:

  • GET /api/v1/entity_watchers — Liste, paginiert + filterbar
  • GET /api/v1/entity_watchers/<id> — Einzelne Entity
  • POST /api/v1/entity_watchers — Anlegen
  • PATCH /api/v1/entity_watchers/<id> — Teil-Update
  • DELETE /api/v1/entity_watchers/<id> — Soft-Delete
  • GET /api/v1/entity_watchers/<id>/timeline — Audit + Aktivitäten

Suche