# public.chat_hub_tools ## Columns | Name | Type | Default | Nullable | Children | Parents | Comment | | ---- | ---- | ------- | -------- | -------- | ------- | ------- | | createdAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | | | | | definition | json | | false | | | | | enabled | boolean | true | false | | | | | id | uuid | | false | [public.chat_hub_agent_tools](public.chat_hub_agent_tools.md) [public.chat_hub_session_tools](public.chat_hub_session_tools.md) | | | | name | varchar(255) | | false | | | | | ownerId | uuid | | false | | [public.user](public.user.md) | | | type | varchar(255) | | false | | | | | typeVersion | double precision | | false | | | | | updatedAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | | | | ## Constraints | Name | Type | Definition | | ---- | ---- | ---------- | | FK_b8030b47af9213f1fd15450fb7f | FOREIGN KEY | FOREIGN KEY ("ownerId") REFERENCES "user"(id) ON DELETE CASCADE | | PK_696d26426c704fba79b2c195ef5 | PRIMARY KEY | PRIMARY KEY (id) | | chat_hub_tools_createdAt_not_null | n | NOT NULL "createdAt" | | chat_hub_tools_definition_not_null | n | NOT NULL definition | | chat_hub_tools_enabled_not_null | n | NOT NULL enabled | | chat_hub_tools_id_not_null | n | NOT NULL id | | chat_hub_tools_name_not_null | n | NOT NULL name | | chat_hub_tools_ownerId_not_null | n | NOT NULL "ownerId" | | chat_hub_tools_typeVersion_not_null | n | NOT NULL "typeVersion" | | chat_hub_tools_type_not_null | n | NOT NULL type | | chat_hub_tools_updatedAt_not_null | n | NOT NULL "updatedAt" | ## Indexes | Name | Definition | | ---- | ---------- | | IDX_4c72ebdb265d1775bf61147af0 | CREATE UNIQUE INDEX "IDX_4c72ebdb265d1775bf61147af0" ON public.chat_hub_tools USING btree ("ownerId", name) | | PK_696d26426c704fba79b2c195ef5 | CREATE UNIQUE INDEX "PK_696d26426c704fba79b2c195ef5" ON public.chat_hub_tools USING btree (id) | ## Relations ```mermaid erDiagram "public.chat_hub_agent_tools" }o--|| "public.chat_hub_tools" : "FOREIGN KEY (#quot;toolId#quot;) REFERENCES chat_hub_tools(id) ON DELETE CASCADE" "public.chat_hub_session_tools" }o--|| "public.chat_hub_tools" : "FOREIGN KEY (#quot;toolId#quot;) REFERENCES chat_hub_tools(id) ON DELETE CASCADE" "public.chat_hub_tools" }o--|| "public.user" : "FOREIGN KEY (#quot;ownerId#quot;) REFERENCES #quot;user#quot;(id) ON DELETE CASCADE" "public.chat_hub_tools" { timestamp_3__with_time_zone createdAt json definition boolean enabled uuid id varchar_255_ name uuid ownerId FK varchar_255_ type double_precision typeVersion timestamp_3__with_time_zone updatedAt } "public.chat_hub_agent_tools" { uuid agentId FK uuid toolId FK } "public.chat_hub_session_tools" { uuid sessionId FK uuid toolId FK } "public.user" { timestamp_3__with_time_zone createdAt boolean disabled varchar_255_ email varchar_32_ firstName uuid id date lastActiveAt varchar_32_ lastName boolean mfaEnabled text mfaRecoveryCodes text mfaSecret varchar_255_ password json personalizationAnswers varchar_128_ roleSlug FK json settings timestamp_3__with_time_zone updatedAt } ``` --- > Generated by [tbls](https://github.com/k1LoW/tbls)