Ir al contenido

Table: comments

Esta página aún no está disponible en tu idioma.

This table references:

Referenced by:

ColumnTypeNullableNotes
iduuidnoDefault gen_random_uuid()
target_kindtextno
target_iduuidno
parent_iduuidyesReferences comments(id)
root_iduuidno
depthintegernoDefault 0
author_user_refbigintyes
bodytextno
body_htmltextnoDefault ''::text
annotation_typetextyes
annotation_datajsonbyes
like_countbigintnoDefault 0
edited_attimestampyes
deleted_attimestampyes
origin_server_iduuidyes
created_attimestampnoDefault now()
updated_attimestampnoDefault now()
peer_iduuidyesReferences federation_peers(id)
actor_uritextyes
activity_uritextyes
  • CONSTRAINT comments_annotation_type_check CHECK ((annotation_type = ANY (ARRAY['point'::text, 'rect'::text, 'timestamp'::text, 'frame'::text, 'whiteboard'::text, 'text-range'::text])))
  • CONSTRAINT comments_origin_check CHECK ((((author_user_ref IS NOT NULL) AND (peer_id IS NULL) AND (actor_uri IS NULL)) OR ((author_user_ref IS NULL) AND (peer_id IS NOT NULL) AND (actor_uri IS NOT NULL))))
  • CONSTRAINT comments_target_kind_check CHECK ((target_kind = ANY (ARRAY['post'::text, 'asset'::text, 'collection'::text])))
CREATE TABLE public.comments (
id uuid DEFAULT gen_random_uuid() NOT NULL,
target_kind text NOT NULL,
target_id uuid NOT NULL,
parent_id uuid,
root_id uuid NOT NULL,
depth integer DEFAULT 0 NOT NULL,
author_user_ref bigint,
body text NOT NULL,
body_html text DEFAULT ''::text NOT NULL,
annotation_type text,
annotation_data jsonb,
like_count bigint DEFAULT 0 NOT NULL,
edited_at timestamp with time zone,
deleted_at timestamp with time zone,
origin_server_id uuid,
created_at timestamp with time zone DEFAULT now() NOT NULL,
updated_at timestamp with time zone DEFAULT now() NOT NULL,
peer_id uuid,
actor_uri text,
activity_uri text,
CONSTRAINT comments_annotation_type_check CHECK ((annotation_type = ANY (ARRAY['point'::text, 'rect'::text, 'timestamp'::text, 'frame'::text, 'whiteboard'::text, 'text-range'::text]))),
CONSTRAINT comments_origin_check CHECK ((((author_user_ref IS NOT NULL) AND (peer_id IS NULL) AND (actor_uri IS NULL)) OR ((author_user_ref IS NULL) AND (peer_id IS NOT NULL) AND (actor_uri IS NOT NULL)))),
CONSTRAINT comments_target_kind_check CHECK ((target_kind = ANY (ARRAY['post'::text, 'asset'::text, 'collection'::text])))
);

Please see the schema overview for context. This document was last regenerated on 2026-07-26T08:25:29.520Z.