Skip to content

Table: teams

This table references:

  • assets(id) via column hero_asset_id

Referenced by:

ColumnTypeNullableNotes
iduuidnoDefault gen_random_uuid()
slugtextno-
nametextno-
descriptiontextnoDefault ''::text
origin_server_iduuidyes-
created_attimestampnoDefault now()
updated_attimestampnoDefault now()
deleted_attimestampyes-
hero_asset_iduuidyesReferences assets(id). The team’s chosen hero picture; NULL means the initials tile. Only an asset that is public and belongs to this team qualifies, checked when it’s chosen and again whenever the team rail renders, so an asset made restricted later drops out. The viewer’s mature-content setting also applies. If the asset is deleted, the team reverts to its initials. Local to this instance.

This is the table’s CREATE TABLE statement. Constraints added with separate ALTER TABLE statements, including foreign-key ON DELETE rules, and indexes are defined elsewhere in the dump; see the complete app/schema.sql.

CREATE TABLE public.teams (
id uuid DEFAULT gen_random_uuid() NOT NULL,
slug text NOT NULL,
name text NOT NULL,
description text DEFAULT ''::text NOT NULL,
origin_server_id uuid,
created_at timestamp with time zone DEFAULT now() NOT NULL,
updated_at timestamp with time zone DEFAULT now() NOT NULL,
deleted_at timestamp with time zone,
hero_asset_id uuid
);

See the schema overview for context.