From 6e7d91005b2d52be9522ca149e45fc0378bd7f29 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 16:24:04 +0900 Subject: [PATCH 01/13] add updatedAt column --- drizzle/schema.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drizzle/schema.ts b/drizzle/schema.ts index 08ed7355..b445e21c 100644 --- a/drizzle/schema.ts +++ b/drizzle/schema.ts @@ -47,6 +47,7 @@ export const organizations = pgTable("organizations", { dbId: serial("db_id").primaryKey(), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const subscriptions = pgTable("subscriptions", { @@ -75,6 +76,7 @@ export const teams = pgTable("teams", { .references(() => organizations.dbId), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export type UserId = `usr_${string}`; @@ -138,6 +140,7 @@ export const agents = pgTable("agents", { }), graphHash: text("graph_hash").unique(), createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const builds = pgTable("builds", { @@ -239,6 +242,7 @@ export const requests = pgTable("requests", { .references(() => builds.dbId), status: text("status").$type().notNull().default("queued"), createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), startedAt: timestamp("started_at"), finishedAt: timestamp("finished_at"), }); @@ -375,6 +379,7 @@ export const files = pgTable("files", { fileSize: integer("file_size").notNull(), blobUrl: text("blob_url").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const fileOpenaiFileRepresentations = pgTable( "file_openai_file_representations", From 09429520f97824ea8246ebf87ef516044f4bb9c1 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 16:24:48 +0900 Subject: [PATCH 02/13] add migration --- migrations/0005_overrated_scarlet_spider.sql | 5 + migrations/meta/0005_snapshot.json | 1865 ++++++++++++++++++ migrations/meta/_journal.json | 87 +- 3 files changed, 1917 insertions(+), 40 deletions(-) create mode 100644 migrations/0005_overrated_scarlet_spider.sql create mode 100644 migrations/meta/0005_snapshot.json diff --git a/migrations/0005_overrated_scarlet_spider.sql b/migrations/0005_overrated_scarlet_spider.sql new file mode 100644 index 00000000..c097f456 --- /dev/null +++ b/migrations/0005_overrated_scarlet_spider.sql @@ -0,0 +1,5 @@ +ALTER TABLE "agents" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "files" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "organizations" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "requests" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; \ No newline at end of file diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json new file mode 100644 index 00000000..ce198e62 --- /dev/null +++ b/migrations/meta/0005_snapshot.json @@ -0,0 +1,1865 @@ +{ + "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", + "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.agents": { + "name": "agents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "graphv2": { + "name": "graphv2", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true, + "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "agents_team_db_id_teams_db_id_fk": { + "name": "agents_team_db_id_teams_db_id_fk", + "tableFrom": "agents", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "agents_id_unique": { + "name": "agents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "agents_graph_hash_unique": { + "name": "agents_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.builds": { + "name": "builds", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "before_id": { + "name": "before_id", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "after_id": { + "name": "after_id", + "type": "integer", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "builds_agent_db_id_agents_db_id_fk": { + "name": "builds_agent_db_id_agents_db_id_fk", + "tableFrom": "builds", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "builds_id_unique": { + "name": "builds_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "builds_graph_hash_unique": { + "name": "builds_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.edges": { + "name": "edges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "target_port_db_id": { + "name": "target_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "source_port_db_id": { + "name": "source_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "edges_build_db_id_builds_db_id_fk": { + "name": "edges_build_db_id_builds_db_id_fk", + "tableFrom": "edges", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_target_port_db_id_ports_db_id_fk": { + "name": "edges_target_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "target_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_source_port_db_id_ports_db_id_fk": { + "name": "edges_source_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "source_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "edges_target_port_db_id_source_port_db_id_unique": { + "name": "edges_target_port_db_id_source_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "target_port_db_id", + "source_port_db_id" + ] + }, + "edges_id_build_db_id_unique": { + "name": "edges_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.file_openai_file_representations": { + "name": "file_openai_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_file_id": { + "name": "openai_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "file_openai_file_representations_file_db_id_files_db_id_fk": { + "name": "file_openai_file_representations_file_db_id_files_db_id_fk", + "tableFrom": "file_openai_file_representations", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "file_openai_file_representations_openai_file_id_unique": { + "name": "file_openai_file_representations_openai_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_file_id" + ] + } + } + }, + "public.files": { + "name": "files", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_name": { + "name": "file_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_type": { + "name": "file_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_size": { + "name": "file_size", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "blob_url": { + "name": "blob_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "files_id_unique": { + "name": "files_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.knowledge_content_openai_vector_store_file_representations": { + "name": "knowledge_content_openai_vector_store_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_content_db_id": { + "name": "knowledge_content_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_file_id": { + "name": "openai_vector_store_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_status": { + "name": "openai_vector_store_status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { + "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", + "tableFrom": "knowledge_content_openai_vector_store_file_representations", + "tableTo": "knowledge_contents", + "columnsFrom": [ + "knowledge_content_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "kcovsfr_knowledge_content_db_id_unique": { + "name": "kcovsfr_knowledge_content_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "knowledge_content_db_id" + ] + }, + "kcovsfr_openai_vector_store_file_id_unique": { + "name": "kcovsfr_openai_vector_store_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_file_id" + ] + } + } + }, + "public.knowledge_contents": { + "name": "knowledge_contents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_content_type": { + "name": "knowledge_content_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "knowledge_contents_file_db_id_files_db_id_fk": { + "name": "knowledge_contents_file_db_id_files_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_contents_id_unique": { + "name": "knowledge_contents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "knowledge_contents_file_db_id_knowledge_db_id_unique": { + "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "file_db_id", + "knowledge_db_id" + ] + } + } + }, + "public.knowledge_openai_vector_store_representations": { + "name": "knowledge_openai_vector_store_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_id": { + "name": "openai_vector_store_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_openai_vector_store_representations", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { + "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_id" + ] + } + } + }, + "public.knowledges": { + "name": "knowledges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledges_agent_db_id_agents_db_id_fk": { + "name": "knowledges_agent_db_id_agents_db_id_fk", + "tableFrom": "knowledges", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledges_id_unique": { + "name": "knowledges_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.nodes": { + "name": "nodes", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "class_name": { + "name": "class_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "nodes_build_db_id_builds_db_id_fk": { + "name": "nodes_build_db_id_builds_db_id_fk", + "tableFrom": "nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "nodes_id_build_db_id_unique": { + "name": "nodes_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.oauth_credentials": { + "name": "oauth_credentials", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "provider_account_id": { + "name": "provider_account_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "access_token": { + "name": "access_token", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "refresh_token": { + "name": "refresh_token", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "expires_at": { + "name": "expires_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "token_type": { + "name": "token_type", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "scope": { + "name": "scope", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "oauth_credentials_user_id_users_db_id_fk": { + "name": "oauth_credentials_user_id_users_db_id_fk", + "tableFrom": "oauth_credentials", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "oauth_credentials_user_id_provider_provider_account_id_unique": { + "name": "oauth_credentials_user_id_provider_provider_account_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_id", + "provider", + "provider_account_id" + ] + } + } + }, + "public.organizations": { + "name": "organizations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.ports": { + "name": "ports", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "direction": { + "name": "direction", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "type": { + "name": "type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "ports_node_db_id_nodes_db_id_fk": { + "name": "ports_node_db_id_nodes_db_id_fk", + "tableFrom": "ports", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "ports_id_node_db_id_unique": { + "name": "ports_id_node_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "node_db_id" + ] + } + } + }, + "public.request_port_messages": { + "name": "request_port_messages", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "port_db_id": { + "name": "port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "message": { + "name": "message", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_port_messages_request_db_id_requests_db_id_fk": { + "name": "request_port_messages_request_db_id_requests_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_port_messages_port_db_id_ports_db_id_fk": { + "name": "request_port_messages_port_db_id_ports_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "ports", + "columnsFrom": [ + "port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_port_messages_request_db_id_port_db_id_unique": { + "name": "request_port_messages_request_db_id_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id", + "port_db_id" + ] + } + } + }, + "public.request_results": { + "name": "request_results", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "text": { + "name": "text", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_results_request_db_id_requests_db_id_fk": { + "name": "request_results_request_db_id_requests_db_id_fk", + "tableFrom": "request_results", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_results_request_db_id_unique": { + "name": "request_results_request_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id" + ] + } + } + }, + "public.request_runners": { + "name": "request_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_runners_request_db_id_requests_db_id_fk": { + "name": "request_runners_request_db_id_requests_db_id_fk", + "tableFrom": "request_runners", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_runners_runner_id_unique": { + "name": "request_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stack_runners": { + "name": "request_stack_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_stack_runners", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stack_runners_runner_id_unique": { + "name": "request_stack_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stacks": { + "name": "request_stacks", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "start_node_db_id": { + "name": "start_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "end_node_db_id": { + "name": "end_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stacks_request_db_id_requests_db_id_fk": { + "name": "request_stacks_request_db_id_requests_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_start_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_start_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "start_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_end_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_end_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "end_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stacks_id_unique": { + "name": "request_stacks_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.request_steps": { + "name": "request_steps", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'in_progress'" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "request_steps_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_steps_node_db_id_nodes_db_id_fk": { + "name": "request_steps_node_db_id_nodes_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_steps_id_unique": { + "name": "request_steps_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.requests": { + "name": "requests", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'queued'" + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "requests_build_db_id_builds_db_id_fk": { + "name": "requests_build_db_id_builds_db_id_fk", + "tableFrom": "requests", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "requests_id_unique": { + "name": "requests_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.stripe_user_mappings": { + "name": "stripe_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "stripe_customer_id": { + "name": "stripe_customer_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "stripe_user_mappings_user_db_id_users_db_id_fk": { + "name": "stripe_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "stripe_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "stripe_user_mappings_user_db_id_unique": { + "name": "stripe_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "stripe_user_mappings_stripe_customer_id_unique": { + "name": "stripe_user_mappings_stripe_customer_id_unique", + "nullsNotDistinct": false, + "columns": [ + "stripe_customer_id" + ] + } + } + }, + "public.subscriptions": { + "name": "subscriptions", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "cancel_at_period_end": { + "name": "cancel_at_period_end", + "type": "boolean", + "primaryKey": false, + "notNull": true + }, + "cancel_at": { + "name": "cancel_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "canceled_at": { + "name": "canceled_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "current_period_start": { + "name": "current_period_start", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "current_period_end": { + "name": "current_period_end", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "created": { + "name": "created", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "ended_at": { + "name": "ended_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_start": { + "name": "trial_start", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_end": { + "name": "trial_end", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "subscriptions_organization_db_id_organizations_db_id_fk": { + "name": "subscriptions_organization_db_id_organizations_db_id_fk", + "tableFrom": "subscriptions", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "subscriptions_id_unique": { + "name": "subscriptions_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.supabase_user_mappings": { + "name": "supabase_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "supabase_user_id": { + "name": "supabase_user_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "supabase_user_mappings_user_db_id_users_db_id_fk": { + "name": "supabase_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "supabase_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "supabase_user_mappings_user_db_id_unique": { + "name": "supabase_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "supabase_user_mappings_supabase_user_id_unique": { + "name": "supabase_user_mappings_supabase_user_id_unique", + "nullsNotDistinct": false, + "columns": [ + "supabase_user_id" + ] + } + } + }, + "public.team_memberships": { + "name": "team_memberships", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "role": { + "name": "role", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "team_memberships_user_db_id_users_db_id_fk": { + "name": "team_memberships_user_db_id_users_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "team_memberships_team_db_id_teams_db_id_fk": { + "name": "team_memberships_team_db_id_teams_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "team_memberships_user_db_id_team_db_id_unique": { + "name": "team_memberships_user_db_id_team_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id", + "team_db_id" + ] + } + } + }, + "public.teams": { + "name": "teams", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "teams_organization_db_id_organizations_db_id_fk": { + "name": "teams_organization_db_id_organizations_db_id_fk", + "tableFrom": "teams", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.trigger_nodes": { + "name": "trigger_nodes", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "trigger_nodes_build_db_id_builds_db_id_fk": { + "name": "trigger_nodes_build_db_id_builds_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "trigger_nodes_node_db_id_nodes_db_id_fk": { + "name": "trigger_nodes_node_db_id_nodes_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "trigger_nodes_build_db_id_unique": { + "name": "trigger_nodes_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "build_db_id" + ] + } + } + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_id_unique": { + "name": "users_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} \ No newline at end of file diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index e99fe607..5d9cab12 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,41 +1,48 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - } - ] -} + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + }, + { + "idx": 5, + "version": "7", + "when": 1730358603269, + "tag": "0005_overrated_scarlet_spider", + "breakpoints": true + } + ] +} \ No newline at end of file From 5e4b8b0979062cd2746dde3b96b8cee057dd518e Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 16:25:15 +0900 Subject: [PATCH 03/13] update bun.lockb --- bun.lockb | Bin 436708 -> 436708 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/bun.lockb b/bun.lockb index b362bf8ff5b4634af60986e11d5879d4cf88f2fa..9c1319e719ff9f9d23af836d401dbfecb64e4493 100755 GIT binary patch delta 1129 zcmaEIS?bAUsR?=tVQuf%f9&6MX4$gd==B@7Uia?|b#&M|Zw*%~7k{7V#_7#fo&II*<1crk8o@nZV9(&5@p z**AG#e)W4zwEU^DvpKP1p;XH)h2*_9O}sZJR0qs)U7KU_K+WB@qsPrmC&T(`_zwT8 z*LYp_1TkE?#S*x3(e%Avm?Y}=uiMFWKa5l2SoZlPetVhDaD`lcdVQ;e!E7V>tLj}I z3HraYWtc*Dsml2qL|KVjtx8|Vzj%L)#)DJ!^#_;|nN~0|FaQyU00RSqBnyy$0+t4k zq<+C*vuQeBDRB+WD>us+*+-AeGH(I%f{l}?! z<#U@YE20~3f1PZcaP9ub%S=+KvYxA-CR9wk93qt{S5pjj9t%SQ&{@*R&f6CDP|tr_ z?92s+nz#-Wu?vWW9F|=Ac8h0|ulTLQpG;*heJ_`FTQ^;DSAe7|Q|X&9Hfhu4)$R}0 z7I-a-d-~wKwcK>sZ$RhOOcJ~N=*BMd&?I1v8+9@r}3o2ZH84} z%Q%WOnoc%+Z}691ag)(xhn)V#{VhvaM1-~nSNwy99>`^~$j+O`#@POUw&3%uiR$ZZ zBfRZfBJ%zwwo`gY~pYV(^H5;pI8_^r%LlA%pRe?fviuV-j!jZ~D^%>56|v^$P| zzMnSzEXa8u`wEOiJ#3fGdu3xL|7fXDo`L=M--5Y+uDf~9u*??l*{Ss*C;uXo;P3qt zjy69&r_}q!=2wx@C61n^_X$@W^mZUct~|2yrV4cK|C)3+vS8-+D(zPS7gl)795C8& zUp20w<868Sbg@}|zE-<8?vo5U7-a41%XBU&>1o%@u;f|Fo7J5=XJqpnn%v-|-M->G z)AkkLnak1`O}5L&v0Q&6Z2}C3>~KZ~F$RW)HMhh}4}SBz$iir-XQ^j0UC^6VlF?+k zHjo0V+W=H20aSOf(V4OhE=c1S*gQD%dqERlZ`SQ=z1fN*feun!$|l1&{n0j7#p&;tv++!iU(Uuhy*|Nh!aZ@$cA+XFvLwKAG+IjSH>4URp6t{14CHb$=WEw)!!0 zc}$LYZ!o>XgHZs?I00jDctS-yV2lnJ;{=Ss;RRCzVQ5UA;Kb72;>EbV#f$0ZN(Y-4 z2kdPbY&fUiFYR*(oUoqh{j_)2bmN#rCabc?&VD&%!SAeHwcUFs&f(^GV0ZlN=h*N3 zYsK6{qk0!X!~2BJ-(r)vDFZ-*Y%s*mi`jo~v}%%fy z6#rRa2 z+<4Jk<9Q{h z3Yg{n{`91(0Ct8yyJtJDvpJe8{#E10qxIjnZnwYrE^^xPMzHf(7#e`il16skH2zO% z+Ges>*fy(+>?xgeu0O@<=dq^W*@+Sw96tQ)JPi8he-&+BDS7|-k9U_pD1SO}^;&kT z#-lf%b0ikF=kqkQPnZ1$bl#qs3|$G|ejUy4xN>4zg@zu;WwOZ5+pDlbLCEETaJgr~ z(H(5|TgBEd_4Zw~Vot?8|Fym!d4F>ko2&P-%#E>^b|pUkJabOT=4sU$o*!my-T7#{xOU|xj%ydP z{eupq)pY;Y(dT9V5_|p4I_;yuZo%gdKSYXLd1U7u&)pKmDb6Far@pkz*mg{e%je+5i9nQ!g#=y|9=9ZZ0!Eb&SSr`rVEcJ}13wpCk zG8#|U22x;k8-VI0fa)%qZFbs!?o%90T|7{MDafFQKn2o31-oXYO1MwSIt*0+l=%ac zkp;?x_B%AK^LnHVm1$q=&ANT9H(PNe&_Rkz*<=`}JBF|+Ontb68t=1$O#*0j>I$}cMgR({!Eyiq From 8d2b5864c205e5e5c8962d67856d227a06971ae5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 31 Oct 2024 08:07:19 +0000 Subject: [PATCH 04/13] Update docs/packages-license.md --- docs/packages-license.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/packages-license.md b/docs/packages-license.md index 12fbbb21..cde96984 100644 --- a/docs/packages-license.md +++ b/docs/packages-license.md @@ -1,6 +1,6 @@ # giselle -As of October 29, 2024 10:23am. 926 total +As of October 31, 2024 8:07am. 926 total ## Summary * 667 MIT From 1a5c2b7ccc1ad5a8239db2809eb1c2b1e32fec58 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 17:09:24 +0900 Subject: [PATCH 05/13] format --- drizzle/schema.ts | 25 +- migrations/meta/0005_snapshot.json | 3523 +++++++++++++--------------- migrations/meta/_journal.json | 94 +- 3 files changed, 1726 insertions(+), 1916 deletions(-) diff --git a/drizzle/schema.ts b/drizzle/schema.ts index b445e21c..d771d3e0 100644 --- a/drizzle/schema.ts +++ b/drizzle/schema.ts @@ -47,7 +47,10 @@ export const organizations = pgTable("organizations", { dbId: serial("db_id").primaryKey(), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export const subscriptions = pgTable("subscriptions", { @@ -76,7 +79,10 @@ export const teams = pgTable("teams", { .references(() => organizations.dbId), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export type UserId = `usr_${string}`; @@ -140,7 +146,10 @@ export const agents = pgTable("agents", { }), graphHash: text("graph_hash").unique(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export const builds = pgTable("builds", { @@ -242,7 +251,10 @@ export const requests = pgTable("requests", { .references(() => builds.dbId), status: text("status").$type().notNull().default("queued"), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), startedAt: timestamp("started_at"), finishedAt: timestamp("finished_at"), }); @@ -379,7 +391,10 @@ export const files = pgTable("files", { fileSize: integer("file_size").notNull(), blobUrl: text("blob_url").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export const fileOpenaiFileRepresentations = pgTable( "file_openai_file_representations", diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json index ce198e62..b08a030b 100644 --- a/migrations/meta/0005_snapshot.json +++ b/migrations/meta/0005_snapshot.json @@ -1,1865 +1,1660 @@ { - "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", - "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.agents": { - "name": "agents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "graphv2": { - "name": "graphv2", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true, - "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "agents_team_db_id_teams_db_id_fk": { - "name": "agents_team_db_id_teams_db_id_fk", - "tableFrom": "agents", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "agents_id_unique": { - "name": "agents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "agents_graph_hash_unique": { - "name": "agents_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.builds": { - "name": "builds", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "before_id": { - "name": "before_id", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "after_id": { - "name": "after_id", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "builds_agent_db_id_agents_db_id_fk": { - "name": "builds_agent_db_id_agents_db_id_fk", - "tableFrom": "builds", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "builds_id_unique": { - "name": "builds_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "builds_graph_hash_unique": { - "name": "builds_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.edges": { - "name": "edges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "target_port_db_id": { - "name": "target_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "source_port_db_id": { - "name": "source_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "edges_build_db_id_builds_db_id_fk": { - "name": "edges_build_db_id_builds_db_id_fk", - "tableFrom": "edges", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_target_port_db_id_ports_db_id_fk": { - "name": "edges_target_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "target_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_source_port_db_id_ports_db_id_fk": { - "name": "edges_source_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "source_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "edges_target_port_db_id_source_port_db_id_unique": { - "name": "edges_target_port_db_id_source_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "target_port_db_id", - "source_port_db_id" - ] - }, - "edges_id_build_db_id_unique": { - "name": "edges_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.file_openai_file_representations": { - "name": "file_openai_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_file_id": { - "name": "openai_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "file_openai_file_representations_file_db_id_files_db_id_fk": { - "name": "file_openai_file_representations_file_db_id_files_db_id_fk", - "tableFrom": "file_openai_file_representations", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "file_openai_file_representations_openai_file_id_unique": { - "name": "file_openai_file_representations_openai_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_file_id" - ] - } - } - }, - "public.files": { - "name": "files", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_name": { - "name": "file_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_type": { - "name": "file_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_size": { - "name": "file_size", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "blob_url": { - "name": "blob_url", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "files_id_unique": { - "name": "files_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.knowledge_content_openai_vector_store_file_representations": { - "name": "knowledge_content_openai_vector_store_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_content_db_id": { - "name": "knowledge_content_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_file_id": { - "name": "openai_vector_store_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_status": { - "name": "openai_vector_store_status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { - "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", - "tableFrom": "knowledge_content_openai_vector_store_file_representations", - "tableTo": "knowledge_contents", - "columnsFrom": [ - "knowledge_content_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "kcovsfr_knowledge_content_db_id_unique": { - "name": "kcovsfr_knowledge_content_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "knowledge_content_db_id" - ] - }, - "kcovsfr_openai_vector_store_file_id_unique": { - "name": "kcovsfr_openai_vector_store_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_file_id" - ] - } - } - }, - "public.knowledge_contents": { - "name": "knowledge_contents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_content_type": { - "name": "knowledge_content_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "knowledge_contents_file_db_id_files_db_id_fk": { - "name": "knowledge_contents_file_db_id_files_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_contents_id_unique": { - "name": "knowledge_contents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "knowledge_contents_file_db_id_knowledge_db_id_unique": { - "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_db_id", - "knowledge_db_id" - ] - } - } - }, - "public.knowledge_openai_vector_store_representations": { - "name": "knowledge_openai_vector_store_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_id": { - "name": "openai_vector_store_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_openai_vector_store_representations", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { - "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_id" - ] - } - } - }, - "public.knowledges": { - "name": "knowledges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledges_agent_db_id_agents_db_id_fk": { - "name": "knowledges_agent_db_id_agents_db_id_fk", - "tableFrom": "knowledges", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledges_id_unique": { - "name": "knowledges_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.nodes": { - "name": "nodes", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "class_name": { - "name": "class_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "data": { - "name": "data", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "nodes_build_db_id_builds_db_id_fk": { - "name": "nodes_build_db_id_builds_db_id_fk", - "tableFrom": "nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "nodes_id_build_db_id_unique": { - "name": "nodes_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.oauth_credentials": { - "name": "oauth_credentials", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "provider_account_id": { - "name": "provider_account_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "expires_at": { - "name": "expires_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "token_type": { - "name": "token_type", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scope": { - "name": "scope", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "oauth_credentials_user_id_users_db_id_fk": { - "name": "oauth_credentials_user_id_users_db_id_fk", - "tableFrom": "oauth_credentials", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "oauth_credentials_user_id_provider_provider_account_id_unique": { - "name": "oauth_credentials_user_id_provider_provider_account_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_id", - "provider", - "provider_account_id" - ] - } - } - }, - "public.organizations": { - "name": "organizations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.ports": { - "name": "ports", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "direction": { - "name": "direction", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "type": { - "name": "type", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "ports_node_db_id_nodes_db_id_fk": { - "name": "ports_node_db_id_nodes_db_id_fk", - "tableFrom": "ports", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "ports_id_node_db_id_unique": { - "name": "ports_id_node_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "node_db_id" - ] - } - } - }, - "public.request_port_messages": { - "name": "request_port_messages", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "port_db_id": { - "name": "port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "message": { - "name": "message", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_port_messages_request_db_id_requests_db_id_fk": { - "name": "request_port_messages_request_db_id_requests_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_port_messages_port_db_id_ports_db_id_fk": { - "name": "request_port_messages_port_db_id_ports_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "ports", - "columnsFrom": [ - "port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_port_messages_request_db_id_port_db_id_unique": { - "name": "request_port_messages_request_db_id_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id", - "port_db_id" - ] - } - } - }, - "public.request_results": { - "name": "request_results", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "text": { - "name": "text", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_results_request_db_id_requests_db_id_fk": { - "name": "request_results_request_db_id_requests_db_id_fk", - "tableFrom": "request_results", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_results_request_db_id_unique": { - "name": "request_results_request_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id" - ] - } - } - }, - "public.request_runners": { - "name": "request_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_runners_request_db_id_requests_db_id_fk": { - "name": "request_runners_request_db_id_requests_db_id_fk", - "tableFrom": "request_runners", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_runners_runner_id_unique": { - "name": "request_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stack_runners": { - "name": "request_stack_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_stack_runners", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stack_runners_runner_id_unique": { - "name": "request_stack_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stacks": { - "name": "request_stacks", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "start_node_db_id": { - "name": "start_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "end_node_db_id": { - "name": "end_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stacks_request_db_id_requests_db_id_fk": { - "name": "request_stacks_request_db_id_requests_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_start_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_start_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "start_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_end_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_end_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "end_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stacks_id_unique": { - "name": "request_stacks_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.request_steps": { - "name": "request_steps", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'in_progress'" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "request_steps_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_steps_node_db_id_nodes_db_id_fk": { - "name": "request_steps_node_db_id_nodes_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_steps_id_unique": { - "name": "request_steps_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.requests": { - "name": "requests", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'queued'" - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "requests_build_db_id_builds_db_id_fk": { - "name": "requests_build_db_id_builds_db_id_fk", - "tableFrom": "requests", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "requests_id_unique": { - "name": "requests_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.stripe_user_mappings": { - "name": "stripe_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "stripe_customer_id": { - "name": "stripe_customer_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "stripe_user_mappings_user_db_id_users_db_id_fk": { - "name": "stripe_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "stripe_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "stripe_user_mappings_user_db_id_unique": { - "name": "stripe_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "stripe_user_mappings_stripe_customer_id_unique": { - "name": "stripe_user_mappings_stripe_customer_id_unique", - "nullsNotDistinct": false, - "columns": [ - "stripe_customer_id" - ] - } - } - }, - "public.subscriptions": { - "name": "subscriptions", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "cancel_at_period_end": { - "name": "cancel_at_period_end", - "type": "boolean", - "primaryKey": false, - "notNull": true - }, - "cancel_at": { - "name": "cancel_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "canceled_at": { - "name": "canceled_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "current_period_start": { - "name": "current_period_start", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "current_period_end": { - "name": "current_period_end", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "created": { - "name": "created", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "ended_at": { - "name": "ended_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_start": { - "name": "trial_start", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_end": { - "name": "trial_end", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "subscriptions_organization_db_id_organizations_db_id_fk": { - "name": "subscriptions_organization_db_id_organizations_db_id_fk", - "tableFrom": "subscriptions", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "subscriptions_id_unique": { - "name": "subscriptions_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.supabase_user_mappings": { - "name": "supabase_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "supabase_user_id": { - "name": "supabase_user_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "supabase_user_mappings_user_db_id_users_db_id_fk": { - "name": "supabase_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "supabase_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "supabase_user_mappings_user_db_id_unique": { - "name": "supabase_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "supabase_user_mappings_supabase_user_id_unique": { - "name": "supabase_user_mappings_supabase_user_id_unique", - "nullsNotDistinct": false, - "columns": [ - "supabase_user_id" - ] - } - } - }, - "public.team_memberships": { - "name": "team_memberships", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "role": { - "name": "role", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "team_memberships_user_db_id_users_db_id_fk": { - "name": "team_memberships_user_db_id_users_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "team_memberships_team_db_id_teams_db_id_fk": { - "name": "team_memberships_team_db_id_teams_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "team_memberships_user_db_id_team_db_id_unique": { - "name": "team_memberships_user_db_id_team_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id", - "team_db_id" - ] - } - } - }, - "public.teams": { - "name": "teams", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "teams_organization_db_id_organizations_db_id_fk": { - "name": "teams_organization_db_id_organizations_db_id_fk", - "tableFrom": "teams", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.trigger_nodes": { - "name": "trigger_nodes", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "trigger_nodes_build_db_id_builds_db_id_fk": { - "name": "trigger_nodes_build_db_id_builds_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "trigger_nodes_node_db_id_nodes_db_id_fk": { - "name": "trigger_nodes_node_db_id_nodes_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "trigger_nodes_build_db_id_unique": { - "name": "trigger_nodes_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "build_db_id" - ] - } - } - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_id_unique": { - "name": "users_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file + "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", + "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.agents": { + "name": "agents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "graphv2": { + "name": "graphv2", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true, + "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "agents_team_db_id_teams_db_id_fk": { + "name": "agents_team_db_id_teams_db_id_fk", + "tableFrom": "agents", + "tableTo": "teams", + "columnsFrom": ["team_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "agents_id_unique": { + "name": "agents_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "agents_graph_hash_unique": { + "name": "agents_graph_hash_unique", + "nullsNotDistinct": false, + "columns": ["graph_hash"] + } + } + }, + "public.builds": { + "name": "builds", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "before_id": { + "name": "before_id", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "after_id": { + "name": "after_id", + "type": "integer", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "builds_agent_db_id_agents_db_id_fk": { + "name": "builds_agent_db_id_agents_db_id_fk", + "tableFrom": "builds", + "tableTo": "agents", + "columnsFrom": ["agent_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "builds_id_unique": { + "name": "builds_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "builds_graph_hash_unique": { + "name": "builds_graph_hash_unique", + "nullsNotDistinct": false, + "columns": ["graph_hash"] + } + } + }, + "public.edges": { + "name": "edges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "target_port_db_id": { + "name": "target_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "source_port_db_id": { + "name": "source_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "edges_build_db_id_builds_db_id_fk": { + "name": "edges_build_db_id_builds_db_id_fk", + "tableFrom": "edges", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_target_port_db_id_ports_db_id_fk": { + "name": "edges_target_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": ["target_port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_source_port_db_id_ports_db_id_fk": { + "name": "edges_source_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": ["source_port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "edges_target_port_db_id_source_port_db_id_unique": { + "name": "edges_target_port_db_id_source_port_db_id_unique", + "nullsNotDistinct": false, + "columns": ["target_port_db_id", "source_port_db_id"] + }, + "edges_id_build_db_id_unique": { + "name": "edges_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "build_db_id"] + } + } + }, + "public.file_openai_file_representations": { + "name": "file_openai_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_file_id": { + "name": "openai_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "file_openai_file_representations_file_db_id_files_db_id_fk": { + "name": "file_openai_file_representations_file_db_id_files_db_id_fk", + "tableFrom": "file_openai_file_representations", + "tableTo": "files", + "columnsFrom": ["file_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "file_openai_file_representations_openai_file_id_unique": { + "name": "file_openai_file_representations_openai_file_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_file_id"] + } + } + }, + "public.files": { + "name": "files", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_name": { + "name": "file_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_type": { + "name": "file_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_size": { + "name": "file_size", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "blob_url": { + "name": "blob_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "files_id_unique": { + "name": "files_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.knowledge_content_openai_vector_store_file_representations": { + "name": "knowledge_content_openai_vector_store_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_content_db_id": { + "name": "knowledge_content_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_file_id": { + "name": "openai_vector_store_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_status": { + "name": "openai_vector_store_status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { + "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", + "tableFrom": "knowledge_content_openai_vector_store_file_representations", + "tableTo": "knowledge_contents", + "columnsFrom": ["knowledge_content_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "kcovsfr_knowledge_content_db_id_unique": { + "name": "kcovsfr_knowledge_content_db_id_unique", + "nullsNotDistinct": false, + "columns": ["knowledge_content_db_id"] + }, + "kcovsfr_openai_vector_store_file_id_unique": { + "name": "kcovsfr_openai_vector_store_file_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_vector_store_file_id"] + } + } + }, + "public.knowledge_contents": { + "name": "knowledge_contents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_content_type": { + "name": "knowledge_content_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "knowledges", + "columnsFrom": ["knowledge_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "knowledge_contents_file_db_id_files_db_id_fk": { + "name": "knowledge_contents_file_db_id_files_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "files", + "columnsFrom": ["file_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_contents_id_unique": { + "name": "knowledge_contents_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "knowledge_contents_file_db_id_knowledge_db_id_unique": { + "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", + "nullsNotDistinct": false, + "columns": ["file_db_id", "knowledge_db_id"] + } + } + }, + "public.knowledge_openai_vector_store_representations": { + "name": "knowledge_openai_vector_store_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_id": { + "name": "openai_vector_store_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_openai_vector_store_representations", + "tableTo": "knowledges", + "columnsFrom": ["knowledge_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { + "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_vector_store_id"] + } + } + }, + "public.knowledges": { + "name": "knowledges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledges_agent_db_id_agents_db_id_fk": { + "name": "knowledges_agent_db_id_agents_db_id_fk", + "tableFrom": "knowledges", + "tableTo": "agents", + "columnsFrom": ["agent_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledges_id_unique": { + "name": "knowledges_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.nodes": { + "name": "nodes", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "class_name": { + "name": "class_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "nodes_build_db_id_builds_db_id_fk": { + "name": "nodes_build_db_id_builds_db_id_fk", + "tableFrom": "nodes", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "nodes_id_build_db_id_unique": { + "name": "nodes_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "build_db_id"] + } + } + }, + "public.oauth_credentials": { + "name": "oauth_credentials", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "provider_account_id": { + "name": "provider_account_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "access_token": { + "name": "access_token", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "refresh_token": { + "name": "refresh_token", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "expires_at": { + "name": "expires_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "token_type": { + "name": "token_type", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "scope": { + "name": "scope", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "oauth_credentials_user_id_users_db_id_fk": { + "name": "oauth_credentials_user_id_users_db_id_fk", + "tableFrom": "oauth_credentials", + "tableTo": "users", + "columnsFrom": ["user_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "oauth_credentials_user_id_provider_provider_account_id_unique": { + "name": "oauth_credentials_user_id_provider_provider_account_id_unique", + "nullsNotDistinct": false, + "columns": ["user_id", "provider", "provider_account_id"] + } + } + }, + "public.organizations": { + "name": "organizations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.ports": { + "name": "ports", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "direction": { + "name": "direction", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "type": { + "name": "type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "ports_node_db_id_nodes_db_id_fk": { + "name": "ports_node_db_id_nodes_db_id_fk", + "tableFrom": "ports", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "ports_id_node_db_id_unique": { + "name": "ports_id_node_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "node_db_id"] + } + } + }, + "public.request_port_messages": { + "name": "request_port_messages", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "port_db_id": { + "name": "port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "message": { + "name": "message", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_port_messages_request_db_id_requests_db_id_fk": { + "name": "request_port_messages_request_db_id_requests_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_port_messages_port_db_id_ports_db_id_fk": { + "name": "request_port_messages_port_db_id_ports_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "ports", + "columnsFrom": ["port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_port_messages_request_db_id_port_db_id_unique": { + "name": "request_port_messages_request_db_id_port_db_id_unique", + "nullsNotDistinct": false, + "columns": ["request_db_id", "port_db_id"] + } + } + }, + "public.request_results": { + "name": "request_results", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "text": { + "name": "text", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_results_request_db_id_requests_db_id_fk": { + "name": "request_results_request_db_id_requests_db_id_fk", + "tableFrom": "request_results", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_results_request_db_id_unique": { + "name": "request_results_request_db_id_unique", + "nullsNotDistinct": false, + "columns": ["request_db_id"] + } + } + }, + "public.request_runners": { + "name": "request_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_runners_request_db_id_requests_db_id_fk": { + "name": "request_runners_request_db_id_requests_db_id_fk", + "tableFrom": "request_runners", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_runners_runner_id_unique": { + "name": "request_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": ["runner_id"] + } + } + }, + "public.request_stack_runners": { + "name": "request_stack_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_stack_runners", + "tableTo": "request_stacks", + "columnsFrom": ["request_stack_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stack_runners_runner_id_unique": { + "name": "request_stack_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": ["runner_id"] + } + } + }, + "public.request_stacks": { + "name": "request_stacks", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "start_node_db_id": { + "name": "start_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "end_node_db_id": { + "name": "end_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stacks_request_db_id_requests_db_id_fk": { + "name": "request_stacks_request_db_id_requests_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_start_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_start_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": ["start_node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_end_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_end_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": ["end_node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stacks_id_unique": { + "name": "request_stacks_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.request_steps": { + "name": "request_steps", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'in_progress'" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "request_steps_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "request_stacks", + "columnsFrom": ["request_stack_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_steps_node_db_id_nodes_db_id_fk": { + "name": "request_steps_node_db_id_nodes_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_steps_id_unique": { + "name": "request_steps_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.requests": { + "name": "requests", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'queued'" + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "requests_build_db_id_builds_db_id_fk": { + "name": "requests_build_db_id_builds_db_id_fk", + "tableFrom": "requests", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "requests_id_unique": { + "name": "requests_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.stripe_user_mappings": { + "name": "stripe_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "stripe_customer_id": { + "name": "stripe_customer_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "stripe_user_mappings_user_db_id_users_db_id_fk": { + "name": "stripe_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "stripe_user_mappings", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "stripe_user_mappings_user_db_id_unique": { + "name": "stripe_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id"] + }, + "stripe_user_mappings_stripe_customer_id_unique": { + "name": "stripe_user_mappings_stripe_customer_id_unique", + "nullsNotDistinct": false, + "columns": ["stripe_customer_id"] + } + } + }, + "public.subscriptions": { + "name": "subscriptions", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "cancel_at_period_end": { + "name": "cancel_at_period_end", + "type": "boolean", + "primaryKey": false, + "notNull": true + }, + "cancel_at": { + "name": "cancel_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "canceled_at": { + "name": "canceled_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "current_period_start": { + "name": "current_period_start", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "current_period_end": { + "name": "current_period_end", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "created": { + "name": "created", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "ended_at": { + "name": "ended_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_start": { + "name": "trial_start", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_end": { + "name": "trial_end", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "subscriptions_organization_db_id_organizations_db_id_fk": { + "name": "subscriptions_organization_db_id_organizations_db_id_fk", + "tableFrom": "subscriptions", + "tableTo": "organizations", + "columnsFrom": ["organization_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "subscriptions_id_unique": { + "name": "subscriptions_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.supabase_user_mappings": { + "name": "supabase_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "supabase_user_id": { + "name": "supabase_user_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "supabase_user_mappings_user_db_id_users_db_id_fk": { + "name": "supabase_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "supabase_user_mappings", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "supabase_user_mappings_user_db_id_unique": { + "name": "supabase_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id"] + }, + "supabase_user_mappings_supabase_user_id_unique": { + "name": "supabase_user_mappings_supabase_user_id_unique", + "nullsNotDistinct": false, + "columns": ["supabase_user_id"] + } + } + }, + "public.team_memberships": { + "name": "team_memberships", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "role": { + "name": "role", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "team_memberships_user_db_id_users_db_id_fk": { + "name": "team_memberships_user_db_id_users_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "team_memberships_team_db_id_teams_db_id_fk": { + "name": "team_memberships_team_db_id_teams_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "teams", + "columnsFrom": ["team_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "team_memberships_user_db_id_team_db_id_unique": { + "name": "team_memberships_user_db_id_team_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id", "team_db_id"] + } + } + }, + "public.teams": { + "name": "teams", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "teams_organization_db_id_organizations_db_id_fk": { + "name": "teams_organization_db_id_organizations_db_id_fk", + "tableFrom": "teams", + "tableTo": "organizations", + "columnsFrom": ["organization_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.trigger_nodes": { + "name": "trigger_nodes", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "trigger_nodes_build_db_id_builds_db_id_fk": { + "name": "trigger_nodes_build_db_id_builds_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "trigger_nodes_node_db_id_nodes_db_id_fk": { + "name": "trigger_nodes_node_db_id_nodes_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "trigger_nodes_build_db_id_unique": { + "name": "trigger_nodes_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["build_db_id"] + } + } + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_id_unique": { + "name": "users_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index 5d9cab12..416a2022 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,48 +1,48 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - }, - { - "idx": 5, - "version": "7", - "when": 1730358603269, - "tag": "0005_overrated_scarlet_spider", - "breakpoints": true - } - ] -} \ No newline at end of file + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + }, + { + "idx": 5, + "version": "7", + "when": 1730358603269, + "tag": "0005_overrated_scarlet_spider", + "breakpoints": true + } + ] +} From 10a62d3c0794c7ce6d46ed543f1b302f6594b0ee Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 18:31:03 +0900 Subject: [PATCH 06/13] new line --- migrations/0005_overrated_scarlet_spider.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migrations/0005_overrated_scarlet_spider.sql b/migrations/0005_overrated_scarlet_spider.sql index c097f456..85c436b2 100644 --- a/migrations/0005_overrated_scarlet_spider.sql +++ b/migrations/0005_overrated_scarlet_spider.sql @@ -2,4 +2,4 @@ ALTER TABLE "agents" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;-- ALTER TABLE "files" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint ALTER TABLE "organizations" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint ALTER TABLE "requests" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; \ No newline at end of file +ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; From 546088f85611acef9c6bf91198522456516a298e Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 18:58:45 +0900 Subject: [PATCH 07/13] Revert "new line" This reverts commit 10a62d3c0794c7ce6d46ed543f1b302f6594b0ee. --- migrations/0005_overrated_scarlet_spider.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migrations/0005_overrated_scarlet_spider.sql b/migrations/0005_overrated_scarlet_spider.sql index 85c436b2..c097f456 100644 --- a/migrations/0005_overrated_scarlet_spider.sql +++ b/migrations/0005_overrated_scarlet_spider.sql @@ -2,4 +2,4 @@ ALTER TABLE "agents" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;-- ALTER TABLE "files" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint ALTER TABLE "organizations" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint ALTER TABLE "requests" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; +ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; \ No newline at end of file From 70198f3f4e059e5d1b0d426718bcae05bff01682 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 18:59:03 +0900 Subject: [PATCH 08/13] Revert "format" This reverts commit 1a5c2b7ccc1ad5a8239db2809eb1c2b1e32fec58. --- drizzle/schema.ts | 25 +- migrations/meta/0005_snapshot.json | 3523 +++++++++++++++------------- migrations/meta/_journal.json | 94 +- 3 files changed, 1916 insertions(+), 1726 deletions(-) diff --git a/drizzle/schema.ts b/drizzle/schema.ts index d771d3e0..b445e21c 100644 --- a/drizzle/schema.ts +++ b/drizzle/schema.ts @@ -47,10 +47,7 @@ export const organizations = pgTable("organizations", { dbId: serial("db_id").primaryKey(), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at") - .defaultNow() - .notNull() - .$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const subscriptions = pgTable("subscriptions", { @@ -79,10 +76,7 @@ export const teams = pgTable("teams", { .references(() => organizations.dbId), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at") - .defaultNow() - .notNull() - .$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export type UserId = `usr_${string}`; @@ -146,10 +140,7 @@ export const agents = pgTable("agents", { }), graphHash: text("graph_hash").unique(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at") - .defaultNow() - .notNull() - .$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const builds = pgTable("builds", { @@ -251,10 +242,7 @@ export const requests = pgTable("requests", { .references(() => builds.dbId), status: text("status").$type().notNull().default("queued"), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at") - .defaultNow() - .notNull() - .$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), startedAt: timestamp("started_at"), finishedAt: timestamp("finished_at"), }); @@ -391,10 +379,7 @@ export const files = pgTable("files", { fileSize: integer("file_size").notNull(), blobUrl: text("blob_url").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at") - .defaultNow() - .notNull() - .$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const fileOpenaiFileRepresentations = pgTable( "file_openai_file_representations", diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json index b08a030b..ce198e62 100644 --- a/migrations/meta/0005_snapshot.json +++ b/migrations/meta/0005_snapshot.json @@ -1,1660 +1,1865 @@ { - "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", - "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.agents": { - "name": "agents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "graphv2": { - "name": "graphv2", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true, - "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "agents_team_db_id_teams_db_id_fk": { - "name": "agents_team_db_id_teams_db_id_fk", - "tableFrom": "agents", - "tableTo": "teams", - "columnsFrom": ["team_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "agents_id_unique": { - "name": "agents_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - }, - "agents_graph_hash_unique": { - "name": "agents_graph_hash_unique", - "nullsNotDistinct": false, - "columns": ["graph_hash"] - } - } - }, - "public.builds": { - "name": "builds", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "before_id": { - "name": "before_id", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "after_id": { - "name": "after_id", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "builds_agent_db_id_agents_db_id_fk": { - "name": "builds_agent_db_id_agents_db_id_fk", - "tableFrom": "builds", - "tableTo": "agents", - "columnsFrom": ["agent_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "builds_id_unique": { - "name": "builds_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - }, - "builds_graph_hash_unique": { - "name": "builds_graph_hash_unique", - "nullsNotDistinct": false, - "columns": ["graph_hash"] - } - } - }, - "public.edges": { - "name": "edges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "target_port_db_id": { - "name": "target_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "source_port_db_id": { - "name": "source_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "edges_build_db_id_builds_db_id_fk": { - "name": "edges_build_db_id_builds_db_id_fk", - "tableFrom": "edges", - "tableTo": "builds", - "columnsFrom": ["build_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_target_port_db_id_ports_db_id_fk": { - "name": "edges_target_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": ["target_port_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_source_port_db_id_ports_db_id_fk": { - "name": "edges_source_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": ["source_port_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "edges_target_port_db_id_source_port_db_id_unique": { - "name": "edges_target_port_db_id_source_port_db_id_unique", - "nullsNotDistinct": false, - "columns": ["target_port_db_id", "source_port_db_id"] - }, - "edges_id_build_db_id_unique": { - "name": "edges_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": ["id", "build_db_id"] - } - } - }, - "public.file_openai_file_representations": { - "name": "file_openai_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_file_id": { - "name": "openai_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "file_openai_file_representations_file_db_id_files_db_id_fk": { - "name": "file_openai_file_representations_file_db_id_files_db_id_fk", - "tableFrom": "file_openai_file_representations", - "tableTo": "files", - "columnsFrom": ["file_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "file_openai_file_representations_openai_file_id_unique": { - "name": "file_openai_file_representations_openai_file_id_unique", - "nullsNotDistinct": false, - "columns": ["openai_file_id"] - } - } - }, - "public.files": { - "name": "files", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_name": { - "name": "file_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_type": { - "name": "file_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_size": { - "name": "file_size", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "blob_url": { - "name": "blob_url", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "files_id_unique": { - "name": "files_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.knowledge_content_openai_vector_store_file_representations": { - "name": "knowledge_content_openai_vector_store_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_content_db_id": { - "name": "knowledge_content_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_file_id": { - "name": "openai_vector_store_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_status": { - "name": "openai_vector_store_status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { - "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", - "tableFrom": "knowledge_content_openai_vector_store_file_representations", - "tableTo": "knowledge_contents", - "columnsFrom": ["knowledge_content_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "kcovsfr_knowledge_content_db_id_unique": { - "name": "kcovsfr_knowledge_content_db_id_unique", - "nullsNotDistinct": false, - "columns": ["knowledge_content_db_id"] - }, - "kcovsfr_openai_vector_store_file_id_unique": { - "name": "kcovsfr_openai_vector_store_file_id_unique", - "nullsNotDistinct": false, - "columns": ["openai_vector_store_file_id"] - } - } - }, - "public.knowledge_contents": { - "name": "knowledge_contents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_content_type": { - "name": "knowledge_content_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "knowledges", - "columnsFrom": ["knowledge_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "knowledge_contents_file_db_id_files_db_id_fk": { - "name": "knowledge_contents_file_db_id_files_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "files", - "columnsFrom": ["file_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_contents_id_unique": { - "name": "knowledge_contents_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - }, - "knowledge_contents_file_db_id_knowledge_db_id_unique": { - "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", - "nullsNotDistinct": false, - "columns": ["file_db_id", "knowledge_db_id"] - } - } - }, - "public.knowledge_openai_vector_store_representations": { - "name": "knowledge_openai_vector_store_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_id": { - "name": "openai_vector_store_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_openai_vector_store_representations", - "tableTo": "knowledges", - "columnsFrom": ["knowledge_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { - "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", - "nullsNotDistinct": false, - "columns": ["openai_vector_store_id"] - } - } - }, - "public.knowledges": { - "name": "knowledges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledges_agent_db_id_agents_db_id_fk": { - "name": "knowledges_agent_db_id_agents_db_id_fk", - "tableFrom": "knowledges", - "tableTo": "agents", - "columnsFrom": ["agent_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledges_id_unique": { - "name": "knowledges_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.nodes": { - "name": "nodes", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "class_name": { - "name": "class_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "data": { - "name": "data", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "nodes_build_db_id_builds_db_id_fk": { - "name": "nodes_build_db_id_builds_db_id_fk", - "tableFrom": "nodes", - "tableTo": "builds", - "columnsFrom": ["build_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "nodes_id_build_db_id_unique": { - "name": "nodes_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": ["id", "build_db_id"] - } - } - }, - "public.oauth_credentials": { - "name": "oauth_credentials", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "provider_account_id": { - "name": "provider_account_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "expires_at": { - "name": "expires_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "token_type": { - "name": "token_type", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scope": { - "name": "scope", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "oauth_credentials_user_id_users_db_id_fk": { - "name": "oauth_credentials_user_id_users_db_id_fk", - "tableFrom": "oauth_credentials", - "tableTo": "users", - "columnsFrom": ["user_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "oauth_credentials_user_id_provider_provider_account_id_unique": { - "name": "oauth_credentials_user_id_provider_provider_account_id_unique", - "nullsNotDistinct": false, - "columns": ["user_id", "provider", "provider_account_id"] - } - } - }, - "public.organizations": { - "name": "organizations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.ports": { - "name": "ports", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "direction": { - "name": "direction", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "type": { - "name": "type", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "ports_node_db_id_nodes_db_id_fk": { - "name": "ports_node_db_id_nodes_db_id_fk", - "tableFrom": "ports", - "tableTo": "nodes", - "columnsFrom": ["node_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "ports_id_node_db_id_unique": { - "name": "ports_id_node_db_id_unique", - "nullsNotDistinct": false, - "columns": ["id", "node_db_id"] - } - } - }, - "public.request_port_messages": { - "name": "request_port_messages", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "port_db_id": { - "name": "port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "message": { - "name": "message", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_port_messages_request_db_id_requests_db_id_fk": { - "name": "request_port_messages_request_db_id_requests_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "requests", - "columnsFrom": ["request_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_port_messages_port_db_id_ports_db_id_fk": { - "name": "request_port_messages_port_db_id_ports_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "ports", - "columnsFrom": ["port_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_port_messages_request_db_id_port_db_id_unique": { - "name": "request_port_messages_request_db_id_port_db_id_unique", - "nullsNotDistinct": false, - "columns": ["request_db_id", "port_db_id"] - } - } - }, - "public.request_results": { - "name": "request_results", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "text": { - "name": "text", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_results_request_db_id_requests_db_id_fk": { - "name": "request_results_request_db_id_requests_db_id_fk", - "tableFrom": "request_results", - "tableTo": "requests", - "columnsFrom": ["request_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_results_request_db_id_unique": { - "name": "request_results_request_db_id_unique", - "nullsNotDistinct": false, - "columns": ["request_db_id"] - } - } - }, - "public.request_runners": { - "name": "request_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_runners_request_db_id_requests_db_id_fk": { - "name": "request_runners_request_db_id_requests_db_id_fk", - "tableFrom": "request_runners", - "tableTo": "requests", - "columnsFrom": ["request_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_runners_runner_id_unique": { - "name": "request_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": ["runner_id"] - } - } - }, - "public.request_stack_runners": { - "name": "request_stack_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_stack_runners", - "tableTo": "request_stacks", - "columnsFrom": ["request_stack_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stack_runners_runner_id_unique": { - "name": "request_stack_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": ["runner_id"] - } - } - }, - "public.request_stacks": { - "name": "request_stacks", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "start_node_db_id": { - "name": "start_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "end_node_db_id": { - "name": "end_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stacks_request_db_id_requests_db_id_fk": { - "name": "request_stacks_request_db_id_requests_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "requests", - "columnsFrom": ["request_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_start_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_start_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": ["start_node_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_end_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_end_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": ["end_node_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stacks_id_unique": { - "name": "request_stacks_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.request_steps": { - "name": "request_steps", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'in_progress'" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "request_steps_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "request_stacks", - "columnsFrom": ["request_stack_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_steps_node_db_id_nodes_db_id_fk": { - "name": "request_steps_node_db_id_nodes_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "nodes", - "columnsFrom": ["node_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_steps_id_unique": { - "name": "request_steps_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.requests": { - "name": "requests", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'queued'" - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "requests_build_db_id_builds_db_id_fk": { - "name": "requests_build_db_id_builds_db_id_fk", - "tableFrom": "requests", - "tableTo": "builds", - "columnsFrom": ["build_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "requests_id_unique": { - "name": "requests_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.stripe_user_mappings": { - "name": "stripe_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "stripe_customer_id": { - "name": "stripe_customer_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "stripe_user_mappings_user_db_id_users_db_id_fk": { - "name": "stripe_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "stripe_user_mappings", - "tableTo": "users", - "columnsFrom": ["user_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "stripe_user_mappings_user_db_id_unique": { - "name": "stripe_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": ["user_db_id"] - }, - "stripe_user_mappings_stripe_customer_id_unique": { - "name": "stripe_user_mappings_stripe_customer_id_unique", - "nullsNotDistinct": false, - "columns": ["stripe_customer_id"] - } - } - }, - "public.subscriptions": { - "name": "subscriptions", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "cancel_at_period_end": { - "name": "cancel_at_period_end", - "type": "boolean", - "primaryKey": false, - "notNull": true - }, - "cancel_at": { - "name": "cancel_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "canceled_at": { - "name": "canceled_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "current_period_start": { - "name": "current_period_start", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "current_period_end": { - "name": "current_period_end", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "created": { - "name": "created", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "ended_at": { - "name": "ended_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_start": { - "name": "trial_start", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_end": { - "name": "trial_end", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "subscriptions_organization_db_id_organizations_db_id_fk": { - "name": "subscriptions_organization_db_id_organizations_db_id_fk", - "tableFrom": "subscriptions", - "tableTo": "organizations", - "columnsFrom": ["organization_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "subscriptions_id_unique": { - "name": "subscriptions_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - }, - "public.supabase_user_mappings": { - "name": "supabase_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "supabase_user_id": { - "name": "supabase_user_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "supabase_user_mappings_user_db_id_users_db_id_fk": { - "name": "supabase_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "supabase_user_mappings", - "tableTo": "users", - "columnsFrom": ["user_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "supabase_user_mappings_user_db_id_unique": { - "name": "supabase_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": ["user_db_id"] - }, - "supabase_user_mappings_supabase_user_id_unique": { - "name": "supabase_user_mappings_supabase_user_id_unique", - "nullsNotDistinct": false, - "columns": ["supabase_user_id"] - } - } - }, - "public.team_memberships": { - "name": "team_memberships", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "role": { - "name": "role", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "team_memberships_user_db_id_users_db_id_fk": { - "name": "team_memberships_user_db_id_users_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "users", - "columnsFrom": ["user_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - }, - "team_memberships_team_db_id_teams_db_id_fk": { - "name": "team_memberships_team_db_id_teams_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "teams", - "columnsFrom": ["team_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "team_memberships_user_db_id_team_db_id_unique": { - "name": "team_memberships_user_db_id_team_db_id_unique", - "nullsNotDistinct": false, - "columns": ["user_db_id", "team_db_id"] - } - } - }, - "public.teams": { - "name": "teams", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "teams_organization_db_id_organizations_db_id_fk": { - "name": "teams_organization_db_id_organizations_db_id_fk", - "tableFrom": "teams", - "tableTo": "organizations", - "columnsFrom": ["organization_db_id"], - "columnsTo": ["db_id"], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.trigger_nodes": { - "name": "trigger_nodes", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "trigger_nodes_build_db_id_builds_db_id_fk": { - "name": "trigger_nodes_build_db_id_builds_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "builds", - "columnsFrom": ["build_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "trigger_nodes_node_db_id_nodes_db_id_fk": { - "name": "trigger_nodes_node_db_id_nodes_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "nodes", - "columnsFrom": ["node_db_id"], - "columnsTo": ["db_id"], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "trigger_nodes_build_db_id_unique": { - "name": "trigger_nodes_build_db_id_unique", - "nullsNotDistinct": false, - "columns": ["build_db_id"] - } - } - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_id_unique": { - "name": "users_id_unique", - "nullsNotDistinct": false, - "columns": ["id"] - } - } - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} + "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", + "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.agents": { + "name": "agents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "graphv2": { + "name": "graphv2", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true, + "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "agents_team_db_id_teams_db_id_fk": { + "name": "agents_team_db_id_teams_db_id_fk", + "tableFrom": "agents", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "agents_id_unique": { + "name": "agents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "agents_graph_hash_unique": { + "name": "agents_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.builds": { + "name": "builds", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "before_id": { + "name": "before_id", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "after_id": { + "name": "after_id", + "type": "integer", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "builds_agent_db_id_agents_db_id_fk": { + "name": "builds_agent_db_id_agents_db_id_fk", + "tableFrom": "builds", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "builds_id_unique": { + "name": "builds_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "builds_graph_hash_unique": { + "name": "builds_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.edges": { + "name": "edges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "target_port_db_id": { + "name": "target_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "source_port_db_id": { + "name": "source_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "edges_build_db_id_builds_db_id_fk": { + "name": "edges_build_db_id_builds_db_id_fk", + "tableFrom": "edges", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_target_port_db_id_ports_db_id_fk": { + "name": "edges_target_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "target_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_source_port_db_id_ports_db_id_fk": { + "name": "edges_source_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "source_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "edges_target_port_db_id_source_port_db_id_unique": { + "name": "edges_target_port_db_id_source_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "target_port_db_id", + "source_port_db_id" + ] + }, + "edges_id_build_db_id_unique": { + "name": "edges_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.file_openai_file_representations": { + "name": "file_openai_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_file_id": { + "name": "openai_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "file_openai_file_representations_file_db_id_files_db_id_fk": { + "name": "file_openai_file_representations_file_db_id_files_db_id_fk", + "tableFrom": "file_openai_file_representations", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "file_openai_file_representations_openai_file_id_unique": { + "name": "file_openai_file_representations_openai_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_file_id" + ] + } + } + }, + "public.files": { + "name": "files", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_name": { + "name": "file_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_type": { + "name": "file_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_size": { + "name": "file_size", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "blob_url": { + "name": "blob_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "files_id_unique": { + "name": "files_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.knowledge_content_openai_vector_store_file_representations": { + "name": "knowledge_content_openai_vector_store_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_content_db_id": { + "name": "knowledge_content_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_file_id": { + "name": "openai_vector_store_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_status": { + "name": "openai_vector_store_status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { + "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", + "tableFrom": "knowledge_content_openai_vector_store_file_representations", + "tableTo": "knowledge_contents", + "columnsFrom": [ + "knowledge_content_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "kcovsfr_knowledge_content_db_id_unique": { + "name": "kcovsfr_knowledge_content_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "knowledge_content_db_id" + ] + }, + "kcovsfr_openai_vector_store_file_id_unique": { + "name": "kcovsfr_openai_vector_store_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_file_id" + ] + } + } + }, + "public.knowledge_contents": { + "name": "knowledge_contents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_content_type": { + "name": "knowledge_content_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "knowledge_contents_file_db_id_files_db_id_fk": { + "name": "knowledge_contents_file_db_id_files_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_contents_id_unique": { + "name": "knowledge_contents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "knowledge_contents_file_db_id_knowledge_db_id_unique": { + "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "file_db_id", + "knowledge_db_id" + ] + } + } + }, + "public.knowledge_openai_vector_store_representations": { + "name": "knowledge_openai_vector_store_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_id": { + "name": "openai_vector_store_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_openai_vector_store_representations", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { + "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_id" + ] + } + } + }, + "public.knowledges": { + "name": "knowledges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledges_agent_db_id_agents_db_id_fk": { + "name": "knowledges_agent_db_id_agents_db_id_fk", + "tableFrom": "knowledges", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledges_id_unique": { + "name": "knowledges_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.nodes": { + "name": "nodes", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "class_name": { + "name": "class_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "nodes_build_db_id_builds_db_id_fk": { + "name": "nodes_build_db_id_builds_db_id_fk", + "tableFrom": "nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "nodes_id_build_db_id_unique": { + "name": "nodes_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.oauth_credentials": { + "name": "oauth_credentials", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "provider_account_id": { + "name": "provider_account_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "access_token": { + "name": "access_token", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "refresh_token": { + "name": "refresh_token", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "expires_at": { + "name": "expires_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "token_type": { + "name": "token_type", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "scope": { + "name": "scope", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "oauth_credentials_user_id_users_db_id_fk": { + "name": "oauth_credentials_user_id_users_db_id_fk", + "tableFrom": "oauth_credentials", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "oauth_credentials_user_id_provider_provider_account_id_unique": { + "name": "oauth_credentials_user_id_provider_provider_account_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_id", + "provider", + "provider_account_id" + ] + } + } + }, + "public.organizations": { + "name": "organizations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.ports": { + "name": "ports", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "direction": { + "name": "direction", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "type": { + "name": "type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "ports_node_db_id_nodes_db_id_fk": { + "name": "ports_node_db_id_nodes_db_id_fk", + "tableFrom": "ports", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "ports_id_node_db_id_unique": { + "name": "ports_id_node_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "node_db_id" + ] + } + } + }, + "public.request_port_messages": { + "name": "request_port_messages", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "port_db_id": { + "name": "port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "message": { + "name": "message", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_port_messages_request_db_id_requests_db_id_fk": { + "name": "request_port_messages_request_db_id_requests_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_port_messages_port_db_id_ports_db_id_fk": { + "name": "request_port_messages_port_db_id_ports_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "ports", + "columnsFrom": [ + "port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_port_messages_request_db_id_port_db_id_unique": { + "name": "request_port_messages_request_db_id_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id", + "port_db_id" + ] + } + } + }, + "public.request_results": { + "name": "request_results", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "text": { + "name": "text", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_results_request_db_id_requests_db_id_fk": { + "name": "request_results_request_db_id_requests_db_id_fk", + "tableFrom": "request_results", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_results_request_db_id_unique": { + "name": "request_results_request_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id" + ] + } + } + }, + "public.request_runners": { + "name": "request_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_runners_request_db_id_requests_db_id_fk": { + "name": "request_runners_request_db_id_requests_db_id_fk", + "tableFrom": "request_runners", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_runners_runner_id_unique": { + "name": "request_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stack_runners": { + "name": "request_stack_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_stack_runners", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stack_runners_runner_id_unique": { + "name": "request_stack_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stacks": { + "name": "request_stacks", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "start_node_db_id": { + "name": "start_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "end_node_db_id": { + "name": "end_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stacks_request_db_id_requests_db_id_fk": { + "name": "request_stacks_request_db_id_requests_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_start_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_start_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "start_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_end_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_end_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "end_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stacks_id_unique": { + "name": "request_stacks_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.request_steps": { + "name": "request_steps", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'in_progress'" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "request_steps_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_steps_node_db_id_nodes_db_id_fk": { + "name": "request_steps_node_db_id_nodes_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_steps_id_unique": { + "name": "request_steps_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.requests": { + "name": "requests", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'queued'" + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "requests_build_db_id_builds_db_id_fk": { + "name": "requests_build_db_id_builds_db_id_fk", + "tableFrom": "requests", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "requests_id_unique": { + "name": "requests_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.stripe_user_mappings": { + "name": "stripe_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "stripe_customer_id": { + "name": "stripe_customer_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "stripe_user_mappings_user_db_id_users_db_id_fk": { + "name": "stripe_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "stripe_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "stripe_user_mappings_user_db_id_unique": { + "name": "stripe_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "stripe_user_mappings_stripe_customer_id_unique": { + "name": "stripe_user_mappings_stripe_customer_id_unique", + "nullsNotDistinct": false, + "columns": [ + "stripe_customer_id" + ] + } + } + }, + "public.subscriptions": { + "name": "subscriptions", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "cancel_at_period_end": { + "name": "cancel_at_period_end", + "type": "boolean", + "primaryKey": false, + "notNull": true + }, + "cancel_at": { + "name": "cancel_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "canceled_at": { + "name": "canceled_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "current_period_start": { + "name": "current_period_start", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "current_period_end": { + "name": "current_period_end", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "created": { + "name": "created", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "ended_at": { + "name": "ended_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_start": { + "name": "trial_start", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_end": { + "name": "trial_end", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "subscriptions_organization_db_id_organizations_db_id_fk": { + "name": "subscriptions_organization_db_id_organizations_db_id_fk", + "tableFrom": "subscriptions", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "subscriptions_id_unique": { + "name": "subscriptions_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.supabase_user_mappings": { + "name": "supabase_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "supabase_user_id": { + "name": "supabase_user_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "supabase_user_mappings_user_db_id_users_db_id_fk": { + "name": "supabase_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "supabase_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "supabase_user_mappings_user_db_id_unique": { + "name": "supabase_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "supabase_user_mappings_supabase_user_id_unique": { + "name": "supabase_user_mappings_supabase_user_id_unique", + "nullsNotDistinct": false, + "columns": [ + "supabase_user_id" + ] + } + } + }, + "public.team_memberships": { + "name": "team_memberships", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "role": { + "name": "role", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "team_memberships_user_db_id_users_db_id_fk": { + "name": "team_memberships_user_db_id_users_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "team_memberships_team_db_id_teams_db_id_fk": { + "name": "team_memberships_team_db_id_teams_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "team_memberships_user_db_id_team_db_id_unique": { + "name": "team_memberships_user_db_id_team_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id", + "team_db_id" + ] + } + } + }, + "public.teams": { + "name": "teams", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "teams_organization_db_id_organizations_db_id_fk": { + "name": "teams_organization_db_id_organizations_db_id_fk", + "tableFrom": "teams", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.trigger_nodes": { + "name": "trigger_nodes", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "trigger_nodes_build_db_id_builds_db_id_fk": { + "name": "trigger_nodes_build_db_id_builds_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "trigger_nodes_node_db_id_nodes_db_id_fk": { + "name": "trigger_nodes_node_db_id_nodes_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "trigger_nodes_build_db_id_unique": { + "name": "trigger_nodes_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "build_db_id" + ] + } + } + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_id_unique": { + "name": "users_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} \ No newline at end of file diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index 416a2022..5d9cab12 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,48 +1,48 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - }, - { - "idx": 5, - "version": "7", - "when": 1730358603269, - "tag": "0005_overrated_scarlet_spider", - "breakpoints": true - } - ] -} + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + }, + { + "idx": 5, + "version": "7", + "when": 1730358603269, + "tag": "0005_overrated_scarlet_spider", + "breakpoints": true + } + ] +} \ No newline at end of file From d52b20d0a41d3d0ed90b0b990defe401b3f6ebde Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 18:59:20 +0900 Subject: [PATCH 09/13] Revert "add migration" This reverts commit 09429520f97824ea8246ebf87ef516044f4bb9c1. --- migrations/0005_overrated_scarlet_spider.sql | 5 - migrations/meta/0005_snapshot.json | 1865 ------------------ migrations/meta/_journal.json | 87 +- 3 files changed, 40 insertions(+), 1917 deletions(-) delete mode 100644 migrations/0005_overrated_scarlet_spider.sql delete mode 100644 migrations/meta/0005_snapshot.json diff --git a/migrations/0005_overrated_scarlet_spider.sql b/migrations/0005_overrated_scarlet_spider.sql deleted file mode 100644 index c097f456..00000000 --- a/migrations/0005_overrated_scarlet_spider.sql +++ /dev/null @@ -1,5 +0,0 @@ -ALTER TABLE "agents" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "files" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "organizations" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "requests" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint -ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; \ No newline at end of file diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json deleted file mode 100644 index ce198e62..00000000 --- a/migrations/meta/0005_snapshot.json +++ /dev/null @@ -1,1865 +0,0 @@ -{ - "id": "572ab090-7dde-4aa2-a53c-5f1359bd8ea2", - "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.agents": { - "name": "agents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "graphv2": { - "name": "graphv2", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true, - "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "agents_team_db_id_teams_db_id_fk": { - "name": "agents_team_db_id_teams_db_id_fk", - "tableFrom": "agents", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "agents_id_unique": { - "name": "agents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "agents_graph_hash_unique": { - "name": "agents_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.builds": { - "name": "builds", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "before_id": { - "name": "before_id", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "after_id": { - "name": "after_id", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "builds_agent_db_id_agents_db_id_fk": { - "name": "builds_agent_db_id_agents_db_id_fk", - "tableFrom": "builds", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "builds_id_unique": { - "name": "builds_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "builds_graph_hash_unique": { - "name": "builds_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.edges": { - "name": "edges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "target_port_db_id": { - "name": "target_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "source_port_db_id": { - "name": "source_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "edges_build_db_id_builds_db_id_fk": { - "name": "edges_build_db_id_builds_db_id_fk", - "tableFrom": "edges", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_target_port_db_id_ports_db_id_fk": { - "name": "edges_target_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "target_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_source_port_db_id_ports_db_id_fk": { - "name": "edges_source_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "source_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "edges_target_port_db_id_source_port_db_id_unique": { - "name": "edges_target_port_db_id_source_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "target_port_db_id", - "source_port_db_id" - ] - }, - "edges_id_build_db_id_unique": { - "name": "edges_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.file_openai_file_representations": { - "name": "file_openai_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_file_id": { - "name": "openai_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "file_openai_file_representations_file_db_id_files_db_id_fk": { - "name": "file_openai_file_representations_file_db_id_files_db_id_fk", - "tableFrom": "file_openai_file_representations", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "file_openai_file_representations_openai_file_id_unique": { - "name": "file_openai_file_representations_openai_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_file_id" - ] - } - } - }, - "public.files": { - "name": "files", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_name": { - "name": "file_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_type": { - "name": "file_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_size": { - "name": "file_size", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "blob_url": { - "name": "blob_url", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "files_id_unique": { - "name": "files_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.knowledge_content_openai_vector_store_file_representations": { - "name": "knowledge_content_openai_vector_store_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_content_db_id": { - "name": "knowledge_content_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_file_id": { - "name": "openai_vector_store_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_status": { - "name": "openai_vector_store_status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { - "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", - "tableFrom": "knowledge_content_openai_vector_store_file_representations", - "tableTo": "knowledge_contents", - "columnsFrom": [ - "knowledge_content_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "kcovsfr_knowledge_content_db_id_unique": { - "name": "kcovsfr_knowledge_content_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "knowledge_content_db_id" - ] - }, - "kcovsfr_openai_vector_store_file_id_unique": { - "name": "kcovsfr_openai_vector_store_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_file_id" - ] - } - } - }, - "public.knowledge_contents": { - "name": "knowledge_contents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_content_type": { - "name": "knowledge_content_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "knowledge_contents_file_db_id_files_db_id_fk": { - "name": "knowledge_contents_file_db_id_files_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_contents_id_unique": { - "name": "knowledge_contents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "knowledge_contents_file_db_id_knowledge_db_id_unique": { - "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_db_id", - "knowledge_db_id" - ] - } - } - }, - "public.knowledge_openai_vector_store_representations": { - "name": "knowledge_openai_vector_store_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_id": { - "name": "openai_vector_store_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_openai_vector_store_representations", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { - "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_id" - ] - } - } - }, - "public.knowledges": { - "name": "knowledges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledges_agent_db_id_agents_db_id_fk": { - "name": "knowledges_agent_db_id_agents_db_id_fk", - "tableFrom": "knowledges", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledges_id_unique": { - "name": "knowledges_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.nodes": { - "name": "nodes", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "class_name": { - "name": "class_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "data": { - "name": "data", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "nodes_build_db_id_builds_db_id_fk": { - "name": "nodes_build_db_id_builds_db_id_fk", - "tableFrom": "nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "nodes_id_build_db_id_unique": { - "name": "nodes_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.oauth_credentials": { - "name": "oauth_credentials", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "provider_account_id": { - "name": "provider_account_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "expires_at": { - "name": "expires_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "token_type": { - "name": "token_type", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scope": { - "name": "scope", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "oauth_credentials_user_id_users_db_id_fk": { - "name": "oauth_credentials_user_id_users_db_id_fk", - "tableFrom": "oauth_credentials", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "oauth_credentials_user_id_provider_provider_account_id_unique": { - "name": "oauth_credentials_user_id_provider_provider_account_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_id", - "provider", - "provider_account_id" - ] - } - } - }, - "public.organizations": { - "name": "organizations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.ports": { - "name": "ports", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "direction": { - "name": "direction", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "type": { - "name": "type", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "ports_node_db_id_nodes_db_id_fk": { - "name": "ports_node_db_id_nodes_db_id_fk", - "tableFrom": "ports", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "ports_id_node_db_id_unique": { - "name": "ports_id_node_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "node_db_id" - ] - } - } - }, - "public.request_port_messages": { - "name": "request_port_messages", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "port_db_id": { - "name": "port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "message": { - "name": "message", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_port_messages_request_db_id_requests_db_id_fk": { - "name": "request_port_messages_request_db_id_requests_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_port_messages_port_db_id_ports_db_id_fk": { - "name": "request_port_messages_port_db_id_ports_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "ports", - "columnsFrom": [ - "port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_port_messages_request_db_id_port_db_id_unique": { - "name": "request_port_messages_request_db_id_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id", - "port_db_id" - ] - } - } - }, - "public.request_results": { - "name": "request_results", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "text": { - "name": "text", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_results_request_db_id_requests_db_id_fk": { - "name": "request_results_request_db_id_requests_db_id_fk", - "tableFrom": "request_results", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_results_request_db_id_unique": { - "name": "request_results_request_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id" - ] - } - } - }, - "public.request_runners": { - "name": "request_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_runners_request_db_id_requests_db_id_fk": { - "name": "request_runners_request_db_id_requests_db_id_fk", - "tableFrom": "request_runners", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_runners_runner_id_unique": { - "name": "request_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stack_runners": { - "name": "request_stack_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_stack_runners", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stack_runners_runner_id_unique": { - "name": "request_stack_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stacks": { - "name": "request_stacks", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "start_node_db_id": { - "name": "start_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "end_node_db_id": { - "name": "end_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stacks_request_db_id_requests_db_id_fk": { - "name": "request_stacks_request_db_id_requests_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_start_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_start_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "start_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_end_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_end_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "end_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stacks_id_unique": { - "name": "request_stacks_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.request_steps": { - "name": "request_steps", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'in_progress'" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "request_steps_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_steps_node_db_id_nodes_db_id_fk": { - "name": "request_steps_node_db_id_nodes_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_steps_id_unique": { - "name": "request_steps_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.requests": { - "name": "requests", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'queued'" - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "requests_build_db_id_builds_db_id_fk": { - "name": "requests_build_db_id_builds_db_id_fk", - "tableFrom": "requests", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "requests_id_unique": { - "name": "requests_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.stripe_user_mappings": { - "name": "stripe_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "stripe_customer_id": { - "name": "stripe_customer_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "stripe_user_mappings_user_db_id_users_db_id_fk": { - "name": "stripe_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "stripe_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "stripe_user_mappings_user_db_id_unique": { - "name": "stripe_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "stripe_user_mappings_stripe_customer_id_unique": { - "name": "stripe_user_mappings_stripe_customer_id_unique", - "nullsNotDistinct": false, - "columns": [ - "stripe_customer_id" - ] - } - } - }, - "public.subscriptions": { - "name": "subscriptions", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "cancel_at_period_end": { - "name": "cancel_at_period_end", - "type": "boolean", - "primaryKey": false, - "notNull": true - }, - "cancel_at": { - "name": "cancel_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "canceled_at": { - "name": "canceled_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "current_period_start": { - "name": "current_period_start", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "current_period_end": { - "name": "current_period_end", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "created": { - "name": "created", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "ended_at": { - "name": "ended_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_start": { - "name": "trial_start", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_end": { - "name": "trial_end", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "subscriptions_organization_db_id_organizations_db_id_fk": { - "name": "subscriptions_organization_db_id_organizations_db_id_fk", - "tableFrom": "subscriptions", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "subscriptions_id_unique": { - "name": "subscriptions_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.supabase_user_mappings": { - "name": "supabase_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "supabase_user_id": { - "name": "supabase_user_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "supabase_user_mappings_user_db_id_users_db_id_fk": { - "name": "supabase_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "supabase_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "supabase_user_mappings_user_db_id_unique": { - "name": "supabase_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "supabase_user_mappings_supabase_user_id_unique": { - "name": "supabase_user_mappings_supabase_user_id_unique", - "nullsNotDistinct": false, - "columns": [ - "supabase_user_id" - ] - } - } - }, - "public.team_memberships": { - "name": "team_memberships", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "role": { - "name": "role", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "team_memberships_user_db_id_users_db_id_fk": { - "name": "team_memberships_user_db_id_users_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "team_memberships_team_db_id_teams_db_id_fk": { - "name": "team_memberships_team_db_id_teams_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "team_memberships_user_db_id_team_db_id_unique": { - "name": "team_memberships_user_db_id_team_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id", - "team_db_id" - ] - } - } - }, - "public.teams": { - "name": "teams", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "teams_organization_db_id_organizations_db_id_fk": { - "name": "teams_organization_db_id_organizations_db_id_fk", - "tableFrom": "teams", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.trigger_nodes": { - "name": "trigger_nodes", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "trigger_nodes_build_db_id_builds_db_id_fk": { - "name": "trigger_nodes_build_db_id_builds_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "trigger_nodes_node_db_id_nodes_db_id_fk": { - "name": "trigger_nodes_node_db_id_nodes_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "trigger_nodes_build_db_id_unique": { - "name": "trigger_nodes_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "build_db_id" - ] - } - } - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_id_unique": { - "name": "users_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index 5d9cab12..e99fe607 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,48 +1,41 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - }, - { - "idx": 5, - "version": "7", - "when": 1730358603269, - "tag": "0005_overrated_scarlet_spider", - "breakpoints": true - } - ] -} \ No newline at end of file + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + } + ] +} From 3be9565feb19d3ef1a1843cf263a19f009c272c3 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 19:00:55 +0900 Subject: [PATCH 10/13] remove files and requests --- drizzle/schema.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/drizzle/schema.ts b/drizzle/schema.ts index b445e21c..9332811b 100644 --- a/drizzle/schema.ts +++ b/drizzle/schema.ts @@ -242,7 +242,6 @@ export const requests = pgTable("requests", { .references(() => builds.dbId), status: text("status").$type().notNull().default("queued"), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), startedAt: timestamp("started_at"), finishedAt: timestamp("finished_at"), }); @@ -379,7 +378,6 @@ export const files = pgTable("files", { fileSize: integer("file_size").notNull(), blobUrl: text("blob_url").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), }); export const fileOpenaiFileRepresentations = pgTable( "file_openai_file_representations", From 2c0705f1a70aee2a911b7fce1a321d9effd5dc7b Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 19:02:29 +0900 Subject: [PATCH 11/13] re-generate migration --- migrations/0005_smart_vapor.sql | 3 + migrations/meta/0005_snapshot.json | 1851 ++++++++++++++++++++++++++++ migrations/meta/_journal.json | 87 +- 3 files changed, 1901 insertions(+), 40 deletions(-) create mode 100644 migrations/0005_smart_vapor.sql create mode 100644 migrations/meta/0005_snapshot.json diff --git a/migrations/0005_smart_vapor.sql b/migrations/0005_smart_vapor.sql new file mode 100644 index 00000000..fb6c3834 --- /dev/null +++ b/migrations/0005_smart_vapor.sql @@ -0,0 +1,3 @@ +ALTER TABLE "agents" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "organizations" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL;--> statement-breakpoint +ALTER TABLE "teams" ADD COLUMN "updated_at" timestamp DEFAULT now() NOT NULL; \ No newline at end of file diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json new file mode 100644 index 00000000..0487cc13 --- /dev/null +++ b/migrations/meta/0005_snapshot.json @@ -0,0 +1,1851 @@ +{ + "id": "4726f4d8-0183-445f-bb90-3c6d6a117716", + "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.agents": { + "name": "agents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "graphv2": { + "name": "graphv2", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true, + "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "agents_team_db_id_teams_db_id_fk": { + "name": "agents_team_db_id_teams_db_id_fk", + "tableFrom": "agents", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "agents_id_unique": { + "name": "agents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "agents_graph_hash_unique": { + "name": "agents_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.builds": { + "name": "builds", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "before_id": { + "name": "before_id", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "after_id": { + "name": "after_id", + "type": "integer", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "builds_agent_db_id_agents_db_id_fk": { + "name": "builds_agent_db_id_agents_db_id_fk", + "tableFrom": "builds", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "builds_id_unique": { + "name": "builds_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "builds_graph_hash_unique": { + "name": "builds_graph_hash_unique", + "nullsNotDistinct": false, + "columns": [ + "graph_hash" + ] + } + } + }, + "public.edges": { + "name": "edges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "target_port_db_id": { + "name": "target_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "source_port_db_id": { + "name": "source_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "edges_build_db_id_builds_db_id_fk": { + "name": "edges_build_db_id_builds_db_id_fk", + "tableFrom": "edges", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_target_port_db_id_ports_db_id_fk": { + "name": "edges_target_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "target_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_source_port_db_id_ports_db_id_fk": { + "name": "edges_source_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": [ + "source_port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "edges_target_port_db_id_source_port_db_id_unique": { + "name": "edges_target_port_db_id_source_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "target_port_db_id", + "source_port_db_id" + ] + }, + "edges_id_build_db_id_unique": { + "name": "edges_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.file_openai_file_representations": { + "name": "file_openai_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_file_id": { + "name": "openai_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "file_openai_file_representations_file_db_id_files_db_id_fk": { + "name": "file_openai_file_representations_file_db_id_files_db_id_fk", + "tableFrom": "file_openai_file_representations", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "file_openai_file_representations_openai_file_id_unique": { + "name": "file_openai_file_representations_openai_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_file_id" + ] + } + } + }, + "public.files": { + "name": "files", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_name": { + "name": "file_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_type": { + "name": "file_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_size": { + "name": "file_size", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "blob_url": { + "name": "blob_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "files_id_unique": { + "name": "files_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.knowledge_content_openai_vector_store_file_representations": { + "name": "knowledge_content_openai_vector_store_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_content_db_id": { + "name": "knowledge_content_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_file_id": { + "name": "openai_vector_store_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_status": { + "name": "openai_vector_store_status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { + "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", + "tableFrom": "knowledge_content_openai_vector_store_file_representations", + "tableTo": "knowledge_contents", + "columnsFrom": [ + "knowledge_content_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "kcovsfr_knowledge_content_db_id_unique": { + "name": "kcovsfr_knowledge_content_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "knowledge_content_db_id" + ] + }, + "kcovsfr_openai_vector_store_file_id_unique": { + "name": "kcovsfr_openai_vector_store_file_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_file_id" + ] + } + } + }, + "public.knowledge_contents": { + "name": "knowledge_contents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_content_type": { + "name": "knowledge_content_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "knowledge_contents_file_db_id_files_db_id_fk": { + "name": "knowledge_contents_file_db_id_files_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "files", + "columnsFrom": [ + "file_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_contents_id_unique": { + "name": "knowledge_contents_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + }, + "knowledge_contents_file_db_id_knowledge_db_id_unique": { + "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "file_db_id", + "knowledge_db_id" + ] + } + } + }, + "public.knowledge_openai_vector_store_representations": { + "name": "knowledge_openai_vector_store_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_id": { + "name": "openai_vector_store_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_openai_vector_store_representations", + "tableTo": "knowledges", + "columnsFrom": [ + "knowledge_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { + "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", + "nullsNotDistinct": false, + "columns": [ + "openai_vector_store_id" + ] + } + } + }, + "public.knowledges": { + "name": "knowledges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledges_agent_db_id_agents_db_id_fk": { + "name": "knowledges_agent_db_id_agents_db_id_fk", + "tableFrom": "knowledges", + "tableTo": "agents", + "columnsFrom": [ + "agent_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledges_id_unique": { + "name": "knowledges_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.nodes": { + "name": "nodes", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "class_name": { + "name": "class_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "nodes_build_db_id_builds_db_id_fk": { + "name": "nodes_build_db_id_builds_db_id_fk", + "tableFrom": "nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "nodes_id_build_db_id_unique": { + "name": "nodes_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "build_db_id" + ] + } + } + }, + "public.oauth_credentials": { + "name": "oauth_credentials", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "provider_account_id": { + "name": "provider_account_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "access_token": { + "name": "access_token", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "refresh_token": { + "name": "refresh_token", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "expires_at": { + "name": "expires_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "token_type": { + "name": "token_type", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "scope": { + "name": "scope", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "oauth_credentials_user_id_users_db_id_fk": { + "name": "oauth_credentials_user_id_users_db_id_fk", + "tableFrom": "oauth_credentials", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "oauth_credentials_user_id_provider_provider_account_id_unique": { + "name": "oauth_credentials_user_id_provider_provider_account_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_id", + "provider", + "provider_account_id" + ] + } + } + }, + "public.organizations": { + "name": "organizations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.ports": { + "name": "ports", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "direction": { + "name": "direction", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "type": { + "name": "type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "ports_node_db_id_nodes_db_id_fk": { + "name": "ports_node_db_id_nodes_db_id_fk", + "tableFrom": "ports", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "ports_id_node_db_id_unique": { + "name": "ports_id_node_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id", + "node_db_id" + ] + } + } + }, + "public.request_port_messages": { + "name": "request_port_messages", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "port_db_id": { + "name": "port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "message": { + "name": "message", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_port_messages_request_db_id_requests_db_id_fk": { + "name": "request_port_messages_request_db_id_requests_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_port_messages_port_db_id_ports_db_id_fk": { + "name": "request_port_messages_port_db_id_ports_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "ports", + "columnsFrom": [ + "port_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_port_messages_request_db_id_port_db_id_unique": { + "name": "request_port_messages_request_db_id_port_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id", + "port_db_id" + ] + } + } + }, + "public.request_results": { + "name": "request_results", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "text": { + "name": "text", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_results_request_db_id_requests_db_id_fk": { + "name": "request_results_request_db_id_requests_db_id_fk", + "tableFrom": "request_results", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_results_request_db_id_unique": { + "name": "request_results_request_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "request_db_id" + ] + } + } + }, + "public.request_runners": { + "name": "request_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_runners_request_db_id_requests_db_id_fk": { + "name": "request_runners_request_db_id_requests_db_id_fk", + "tableFrom": "request_runners", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_runners_runner_id_unique": { + "name": "request_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stack_runners": { + "name": "request_stack_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_stack_runners", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stack_runners_runner_id_unique": { + "name": "request_stack_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": [ + "runner_id" + ] + } + } + }, + "public.request_stacks": { + "name": "request_stacks", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "start_node_db_id": { + "name": "start_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "end_node_db_id": { + "name": "end_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stacks_request_db_id_requests_db_id_fk": { + "name": "request_stacks_request_db_id_requests_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "requests", + "columnsFrom": [ + "request_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_start_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_start_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "start_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_end_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_end_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": [ + "end_node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stacks_id_unique": { + "name": "request_stacks_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.request_steps": { + "name": "request_steps", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'in_progress'" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "request_steps_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "request_stacks", + "columnsFrom": [ + "request_stack_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_steps_node_db_id_nodes_db_id_fk": { + "name": "request_steps_node_db_id_nodes_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_steps_id_unique": { + "name": "request_steps_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.requests": { + "name": "requests", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'queued'" + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "requests_build_db_id_builds_db_id_fk": { + "name": "requests_build_db_id_builds_db_id_fk", + "tableFrom": "requests", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "requests_id_unique": { + "name": "requests_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.stripe_user_mappings": { + "name": "stripe_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "stripe_customer_id": { + "name": "stripe_customer_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "stripe_user_mappings_user_db_id_users_db_id_fk": { + "name": "stripe_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "stripe_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "stripe_user_mappings_user_db_id_unique": { + "name": "stripe_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "stripe_user_mappings_stripe_customer_id_unique": { + "name": "stripe_user_mappings_stripe_customer_id_unique", + "nullsNotDistinct": false, + "columns": [ + "stripe_customer_id" + ] + } + } + }, + "public.subscriptions": { + "name": "subscriptions", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "cancel_at_period_end": { + "name": "cancel_at_period_end", + "type": "boolean", + "primaryKey": false, + "notNull": true + }, + "cancel_at": { + "name": "cancel_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "canceled_at": { + "name": "canceled_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "current_period_start": { + "name": "current_period_start", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "current_period_end": { + "name": "current_period_end", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "created": { + "name": "created", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "ended_at": { + "name": "ended_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_start": { + "name": "trial_start", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_end": { + "name": "trial_end", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "subscriptions_organization_db_id_organizations_db_id_fk": { + "name": "subscriptions_organization_db_id_organizations_db_id_fk", + "tableFrom": "subscriptions", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "subscriptions_id_unique": { + "name": "subscriptions_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + }, + "public.supabase_user_mappings": { + "name": "supabase_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "supabase_user_id": { + "name": "supabase_user_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "supabase_user_mappings_user_db_id_users_db_id_fk": { + "name": "supabase_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "supabase_user_mappings", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "supabase_user_mappings_user_db_id_unique": { + "name": "supabase_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id" + ] + }, + "supabase_user_mappings_supabase_user_id_unique": { + "name": "supabase_user_mappings_supabase_user_id_unique", + "nullsNotDistinct": false, + "columns": [ + "supabase_user_id" + ] + } + } + }, + "public.team_memberships": { + "name": "team_memberships", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "role": { + "name": "role", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "team_memberships_user_db_id_users_db_id_fk": { + "name": "team_memberships_user_db_id_users_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "users", + "columnsFrom": [ + "user_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + }, + "team_memberships_team_db_id_teams_db_id_fk": { + "name": "team_memberships_team_db_id_teams_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "teams", + "columnsFrom": [ + "team_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "team_memberships_user_db_id_team_db_id_unique": { + "name": "team_memberships_user_db_id_team_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "user_db_id", + "team_db_id" + ] + } + } + }, + "public.teams": { + "name": "teams", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "teams_organization_db_id_organizations_db_id_fk": { + "name": "teams_organization_db_id_organizations_db_id_fk", + "tableFrom": "teams", + "tableTo": "organizations", + "columnsFrom": [ + "organization_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.trigger_nodes": { + "name": "trigger_nodes", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "trigger_nodes_build_db_id_builds_db_id_fk": { + "name": "trigger_nodes_build_db_id_builds_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "builds", + "columnsFrom": [ + "build_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "trigger_nodes_node_db_id_nodes_db_id_fk": { + "name": "trigger_nodes_node_db_id_nodes_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "nodes", + "columnsFrom": [ + "node_db_id" + ], + "columnsTo": [ + "db_id" + ], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "trigger_nodes_build_db_id_unique": { + "name": "trigger_nodes_build_db_id_unique", + "nullsNotDistinct": false, + "columns": [ + "build_db_id" + ] + } + } + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_id_unique": { + "name": "users_id_unique", + "nullsNotDistinct": false, + "columns": [ + "id" + ] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} \ No newline at end of file diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index e99fe607..69b24366 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,41 +1,48 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - } - ] -} + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + }, + { + "idx": 5, + "version": "7", + "when": 1730368916214, + "tag": "0005_smart_vapor", + "breakpoints": true + } + ] +} \ No newline at end of file From 4959682d4f87f02052049eb77ae9ae46bfc8fb64 Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Thu, 31 Oct 2024 19:05:50 +0900 Subject: [PATCH 12/13] re-format --- drizzle/schema.ts | 15 +- migrations/meta/0005_snapshot.json | 3495 +++++++++++++--------------- migrations/meta/_journal.json | 94 +- 3 files changed, 1704 insertions(+), 1900 deletions(-) diff --git a/drizzle/schema.ts b/drizzle/schema.ts index 9332811b..a54f90b0 100644 --- a/drizzle/schema.ts +++ b/drizzle/schema.ts @@ -47,7 +47,10 @@ export const organizations = pgTable("organizations", { dbId: serial("db_id").primaryKey(), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export const subscriptions = pgTable("subscriptions", { @@ -76,7 +79,10 @@ export const teams = pgTable("teams", { .references(() => organizations.dbId), name: text("name").notNull(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export type UserId = `usr_${string}`; @@ -140,7 +146,10 @@ export const agents = pgTable("agents", { }), graphHash: text("graph_hash").unique(), createdAt: timestamp("created_at").defaultNow().notNull(), - updatedAt: timestamp("updated_at").defaultNow().notNull().$onUpdate(() => new Date()), + updatedAt: timestamp("updated_at") + .defaultNow() + .notNull() + .$onUpdate(() => new Date()), }); export const builds = pgTable("builds", { diff --git a/migrations/meta/0005_snapshot.json b/migrations/meta/0005_snapshot.json index 0487cc13..225eaaf9 100644 --- a/migrations/meta/0005_snapshot.json +++ b/migrations/meta/0005_snapshot.json @@ -1,1851 +1,1646 @@ { - "id": "4726f4d8-0183-445f-bb90-3c6d6a117716", - "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.agents": { - "name": "agents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "graphv2": { - "name": "graphv2", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true, - "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "agents_team_db_id_teams_db_id_fk": { - "name": "agents_team_db_id_teams_db_id_fk", - "tableFrom": "agents", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "agents_id_unique": { - "name": "agents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "agents_graph_hash_unique": { - "name": "agents_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.builds": { - "name": "builds", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph_hash": { - "name": "graph_hash", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "before_id": { - "name": "before_id", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "after_id": { - "name": "after_id", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "builds_agent_db_id_agents_db_id_fk": { - "name": "builds_agent_db_id_agents_db_id_fk", - "tableFrom": "builds", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "builds_id_unique": { - "name": "builds_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "builds_graph_hash_unique": { - "name": "builds_graph_hash_unique", - "nullsNotDistinct": false, - "columns": [ - "graph_hash" - ] - } - } - }, - "public.edges": { - "name": "edges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "target_port_db_id": { - "name": "target_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "source_port_db_id": { - "name": "source_port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "edges_build_db_id_builds_db_id_fk": { - "name": "edges_build_db_id_builds_db_id_fk", - "tableFrom": "edges", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_target_port_db_id_ports_db_id_fk": { - "name": "edges_target_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "target_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "edges_source_port_db_id_ports_db_id_fk": { - "name": "edges_source_port_db_id_ports_db_id_fk", - "tableFrom": "edges", - "tableTo": "ports", - "columnsFrom": [ - "source_port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "edges_target_port_db_id_source_port_db_id_unique": { - "name": "edges_target_port_db_id_source_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "target_port_db_id", - "source_port_db_id" - ] - }, - "edges_id_build_db_id_unique": { - "name": "edges_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.file_openai_file_representations": { - "name": "file_openai_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_file_id": { - "name": "openai_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "file_openai_file_representations_file_db_id_files_db_id_fk": { - "name": "file_openai_file_representations_file_db_id_files_db_id_fk", - "tableFrom": "file_openai_file_representations", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "file_openai_file_representations_openai_file_id_unique": { - "name": "file_openai_file_representations_openai_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_file_id" - ] - } - } - }, - "public.files": { - "name": "files", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "file_name": { - "name": "file_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_type": { - "name": "file_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_size": { - "name": "file_size", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "blob_url": { - "name": "blob_url", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "files_id_unique": { - "name": "files_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.knowledge_content_openai_vector_store_file_representations": { - "name": "knowledge_content_openai_vector_store_file_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_content_db_id": { - "name": "knowledge_content_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_file_id": { - "name": "openai_vector_store_file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_status": { - "name": "openai_vector_store_status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { - "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", - "tableFrom": "knowledge_content_openai_vector_store_file_representations", - "tableTo": "knowledge_contents", - "columnsFrom": [ - "knowledge_content_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "kcovsfr_knowledge_content_db_id_unique": { - "name": "kcovsfr_knowledge_content_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "knowledge_content_db_id" - ] - }, - "kcovsfr_openai_vector_store_file_id_unique": { - "name": "kcovsfr_openai_vector_store_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_file_id" - ] - } - } - }, - "public.knowledge_contents": { - "name": "knowledge_contents", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_content_type": { - "name": "knowledge_content_type", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_db_id": { - "name": "file_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "knowledge_contents_file_db_id_files_db_id_fk": { - "name": "knowledge_contents_file_db_id_files_db_id_fk", - "tableFrom": "knowledge_contents", - "tableTo": "files", - "columnsFrom": [ - "file_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_contents_id_unique": { - "name": "knowledge_contents_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - }, - "knowledge_contents_file_db_id_knowledge_db_id_unique": { - "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_db_id", - "knowledge_db_id" - ] - } - } - }, - "public.knowledge_openai_vector_store_representations": { - "name": "knowledge_openai_vector_store_representations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "knowledge_db_id": { - "name": "knowledge_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "openai_vector_store_id": { - "name": "openai_vector_store_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { - "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", - "tableFrom": "knowledge_openai_vector_store_representations", - "tableTo": "knowledges", - "columnsFrom": [ - "knowledge_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { - "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", - "nullsNotDistinct": false, - "columns": [ - "openai_vector_store_id" - ] - } - } - }, - "public.knowledges": { - "name": "knowledges", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "agent_db_id": { - "name": "agent_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "knowledges_agent_db_id_agents_db_id_fk": { - "name": "knowledges_agent_db_id_agents_db_id_fk", - "tableFrom": "knowledges", - "tableTo": "agents", - "columnsFrom": [ - "agent_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "knowledges_id_unique": { - "name": "knowledges_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.nodes": { - "name": "nodes", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "class_name": { - "name": "class_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "data": { - "name": "data", - "type": "jsonb", - "primaryKey": false, - "notNull": true - }, - "graph": { - "name": "graph", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "nodes_build_db_id_builds_db_id_fk": { - "name": "nodes_build_db_id_builds_db_id_fk", - "tableFrom": "nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "nodes_id_build_db_id_unique": { - "name": "nodes_id_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "build_db_id" - ] - } - } - }, - "public.oauth_credentials": { - "name": "oauth_credentials", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "provider_account_id": { - "name": "provider_account_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "expires_at": { - "name": "expires_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "token_type": { - "name": "token_type", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scope": { - "name": "scope", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "oauth_credentials_user_id_users_db_id_fk": { - "name": "oauth_credentials_user_id_users_db_id_fk", - "tableFrom": "oauth_credentials", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "oauth_credentials_user_id_provider_provider_account_id_unique": { - "name": "oauth_credentials_user_id_provider_provider_account_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_id", - "provider", - "provider_account_id" - ] - } - } - }, - "public.organizations": { - "name": "organizations", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.ports": { - "name": "ports", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "direction": { - "name": "direction", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "type": { - "name": "type", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "ports_node_db_id_nodes_db_id_fk": { - "name": "ports_node_db_id_nodes_db_id_fk", - "tableFrom": "ports", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "ports_id_node_db_id_unique": { - "name": "ports_id_node_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id", - "node_db_id" - ] - } - } - }, - "public.request_port_messages": { - "name": "request_port_messages", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "port_db_id": { - "name": "port_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "message": { - "name": "message", - "type": "jsonb", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_port_messages_request_db_id_requests_db_id_fk": { - "name": "request_port_messages_request_db_id_requests_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_port_messages_port_db_id_ports_db_id_fk": { - "name": "request_port_messages_port_db_id_ports_db_id_fk", - "tableFrom": "request_port_messages", - "tableTo": "ports", - "columnsFrom": [ - "port_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_port_messages_request_db_id_port_db_id_unique": { - "name": "request_port_messages_request_db_id_port_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id", - "port_db_id" - ] - } - } - }, - "public.request_results": { - "name": "request_results", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "text": { - "name": "text", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_results_request_db_id_requests_db_id_fk": { - "name": "request_results_request_db_id_requests_db_id_fk", - "tableFrom": "request_results", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_results_request_db_id_unique": { - "name": "request_results_request_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "request_db_id" - ] - } - } - }, - "public.request_runners": { - "name": "request_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "provider": { - "name": "provider", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_runners_request_db_id_requests_db_id_fk": { - "name": "request_runners_request_db_id_requests_db_id_fk", - "tableFrom": "request_runners", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_runners_runner_id_unique": { - "name": "request_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stack_runners": { - "name": "request_stack_runners", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "runner_id": { - "name": "runner_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_stack_runners", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stack_runners_runner_id_unique": { - "name": "request_stack_runners_runner_id_unique", - "nullsNotDistinct": false, - "columns": [ - "runner_id" - ] - } - } - }, - "public.request_stacks": { - "name": "request_stacks", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_db_id": { - "name": "request_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "start_node_db_id": { - "name": "start_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "end_node_db_id": { - "name": "end_node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "request_stacks_request_db_id_requests_db_id_fk": { - "name": "request_stacks_request_db_id_requests_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "requests", - "columnsFrom": [ - "request_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_start_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_start_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "start_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_stacks_end_node_db_id_nodes_db_id_fk": { - "name": "request_stacks_end_node_db_id_nodes_db_id_fk", - "tableFrom": "request_stacks", - "tableTo": "nodes", - "columnsFrom": [ - "end_node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_stacks_id_unique": { - "name": "request_stacks_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.request_steps": { - "name": "request_steps", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "request_stack_db_id": { - "name": "request_stack_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'in_progress'" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "request_steps_request_stack_db_id_request_stacks_db_id_fk": { - "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "request_stacks", - "columnsFrom": [ - "request_stack_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "request_steps_node_db_id_nodes_db_id_fk": { - "name": "request_steps_node_db_id_nodes_db_id_fk", - "tableFrom": "request_steps", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "request_steps_id_unique": { - "name": "request_steps_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.requests": { - "name": "requests", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true, - "default": "'queued'" - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "started_at": { - "name": "started_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "finished_at": { - "name": "finished_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "requests_build_db_id_builds_db_id_fk": { - "name": "requests_build_db_id_builds_db_id_fk", - "tableFrom": "requests", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "requests_id_unique": { - "name": "requests_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.stripe_user_mappings": { - "name": "stripe_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "stripe_customer_id": { - "name": "stripe_customer_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "stripe_user_mappings_user_db_id_users_db_id_fk": { - "name": "stripe_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "stripe_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "stripe_user_mappings_user_db_id_unique": { - "name": "stripe_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "stripe_user_mappings_stripe_customer_id_unique": { - "name": "stripe_user_mappings_stripe_customer_id_unique", - "nullsNotDistinct": false, - "columns": [ - "stripe_customer_id" - ] - } - } - }, - "public.subscriptions": { - "name": "subscriptions", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "status": { - "name": "status", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "cancel_at_period_end": { - "name": "cancel_at_period_end", - "type": "boolean", - "primaryKey": false, - "notNull": true - }, - "cancel_at": { - "name": "cancel_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "canceled_at": { - "name": "canceled_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "current_period_start": { - "name": "current_period_start", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "current_period_end": { - "name": "current_period_end", - "type": "timestamp", - "primaryKey": false, - "notNull": true - }, - "created": { - "name": "created", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "ended_at": { - "name": "ended_at", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_start": { - "name": "trial_start", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "trial_end": { - "name": "trial_end", - "type": "timestamp", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "subscriptions_organization_db_id_organizations_db_id_fk": { - "name": "subscriptions_organization_db_id_organizations_db_id_fk", - "tableFrom": "subscriptions", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "subscriptions_id_unique": { - "name": "subscriptions_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - }, - "public.supabase_user_mappings": { - "name": "supabase_user_mappings", - "schema": "", - "columns": { - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "supabase_user_id": { - "name": "supabase_user_id", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "supabase_user_mappings_user_db_id_users_db_id_fk": { - "name": "supabase_user_mappings_user_db_id_users_db_id_fk", - "tableFrom": "supabase_user_mappings", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "supabase_user_mappings_user_db_id_unique": { - "name": "supabase_user_mappings_user_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id" - ] - }, - "supabase_user_mappings_supabase_user_id_unique": { - "name": "supabase_user_mappings_supabase_user_id_unique", - "nullsNotDistinct": false, - "columns": [ - "supabase_user_id" - ] - } - } - }, - "public.team_memberships": { - "name": "team_memberships", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "user_db_id": { - "name": "user_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "team_db_id": { - "name": "team_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "role": { - "name": "role", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "team_memberships_user_db_id_users_db_id_fk": { - "name": "team_memberships_user_db_id_users_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "users", - "columnsFrom": [ - "user_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "team_memberships_team_db_id_teams_db_id_fk": { - "name": "team_memberships_team_db_id_teams_db_id_fk", - "tableFrom": "team_memberships", - "tableTo": "teams", - "columnsFrom": [ - "team_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "team_memberships_user_db_id_team_db_id_unique": { - "name": "team_memberships_user_db_id_team_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "user_db_id", - "team_db_id" - ] - } - } - }, - "public.teams": { - "name": "teams", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "organization_db_id": { - "name": "organization_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "created_at": { - "name": "created_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "updated_at": { - "name": "updated_at", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "teams_organization_db_id_organizations_db_id_fk": { - "name": "teams_organization_db_id_organizations_db_id_fk", - "tableFrom": "teams", - "tableTo": "organizations", - "columnsFrom": [ - "organization_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {} - }, - "public.trigger_nodes": { - "name": "trigger_nodes", - "schema": "", - "columns": { - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - }, - "build_db_id": { - "name": "build_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "node_db_id": { - "name": "node_db_id", - "type": "integer", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "trigger_nodes_build_db_id_builds_db_id_fk": { - "name": "trigger_nodes_build_db_id_builds_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "builds", - "columnsFrom": [ - "build_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - }, - "trigger_nodes_node_db_id_nodes_db_id_fk": { - "name": "trigger_nodes_node_db_id_nodes_db_id_fk", - "tableFrom": "trigger_nodes", - "tableTo": "nodes", - "columnsFrom": [ - "node_db_id" - ], - "columnsTo": [ - "db_id" - ], - "onDelete": "cascade", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "trigger_nodes_build_db_id_unique": { - "name": "trigger_nodes_build_db_id_unique", - "nullsNotDistinct": false, - "columns": [ - "build_db_id" - ] - } - } - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "id": { - "name": "id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "db_id": { - "name": "db_id", - "type": "serial", - "primaryKey": true, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_id_unique": { - "name": "users_id_unique", - "nullsNotDistinct": false, - "columns": [ - "id" - ] - } - } - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file + "id": "4726f4d8-0183-445f-bb90-3c6d6a117716", + "prevId": "d687c106-1d4b-4bc2-bf92-b396c8040ec4", + "version": "7", + "dialect": "postgresql", + "tables": { + "public.agents": { + "name": "agents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "graphv2": { + "name": "graphv2", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true, + "default": "'{\"nodes\":[],\"edges\":[],\"viewport\":{\"x\":0,\"y\":0,\"zoom\":1}}'::jsonb" + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "agents_team_db_id_teams_db_id_fk": { + "name": "agents_team_db_id_teams_db_id_fk", + "tableFrom": "agents", + "tableTo": "teams", + "columnsFrom": ["team_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "agents_id_unique": { + "name": "agents_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "agents_graph_hash_unique": { + "name": "agents_graph_hash_unique", + "nullsNotDistinct": false, + "columns": ["graph_hash"] + } + } + }, + "public.builds": { + "name": "builds", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph_hash": { + "name": "graph_hash", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "before_id": { + "name": "before_id", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "after_id": { + "name": "after_id", + "type": "integer", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "builds_agent_db_id_agents_db_id_fk": { + "name": "builds_agent_db_id_agents_db_id_fk", + "tableFrom": "builds", + "tableTo": "agents", + "columnsFrom": ["agent_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "builds_id_unique": { + "name": "builds_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "builds_graph_hash_unique": { + "name": "builds_graph_hash_unique", + "nullsNotDistinct": false, + "columns": ["graph_hash"] + } + } + }, + "public.edges": { + "name": "edges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "target_port_db_id": { + "name": "target_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "source_port_db_id": { + "name": "source_port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "edges_build_db_id_builds_db_id_fk": { + "name": "edges_build_db_id_builds_db_id_fk", + "tableFrom": "edges", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_target_port_db_id_ports_db_id_fk": { + "name": "edges_target_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": ["target_port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "edges_source_port_db_id_ports_db_id_fk": { + "name": "edges_source_port_db_id_ports_db_id_fk", + "tableFrom": "edges", + "tableTo": "ports", + "columnsFrom": ["source_port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "edges_target_port_db_id_source_port_db_id_unique": { + "name": "edges_target_port_db_id_source_port_db_id_unique", + "nullsNotDistinct": false, + "columns": ["target_port_db_id", "source_port_db_id"] + }, + "edges_id_build_db_id_unique": { + "name": "edges_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "build_db_id"] + } + } + }, + "public.file_openai_file_representations": { + "name": "file_openai_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_file_id": { + "name": "openai_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "file_openai_file_representations_file_db_id_files_db_id_fk": { + "name": "file_openai_file_representations_file_db_id_files_db_id_fk", + "tableFrom": "file_openai_file_representations", + "tableTo": "files", + "columnsFrom": ["file_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "file_openai_file_representations_openai_file_id_unique": { + "name": "file_openai_file_representations_openai_file_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_file_id"] + } + } + }, + "public.files": { + "name": "files", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "file_name": { + "name": "file_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_type": { + "name": "file_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "file_size": { + "name": "file_size", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "blob_url": { + "name": "blob_url", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "files_id_unique": { + "name": "files_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.knowledge_content_openai_vector_store_file_representations": { + "name": "knowledge_content_openai_vector_store_file_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_content_db_id": { + "name": "knowledge_content_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_file_id": { + "name": "openai_vector_store_file_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_status": { + "name": "openai_vector_store_status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk": { + "name": "knowledge_content_openai_vector_store_file_representations_knowledge_content_db_id_knowledge_contents_db_id_fk", + "tableFrom": "knowledge_content_openai_vector_store_file_representations", + "tableTo": "knowledge_contents", + "columnsFrom": ["knowledge_content_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "kcovsfr_knowledge_content_db_id_unique": { + "name": "kcovsfr_knowledge_content_db_id_unique", + "nullsNotDistinct": false, + "columns": ["knowledge_content_db_id"] + }, + "kcovsfr_openai_vector_store_file_id_unique": { + "name": "kcovsfr_openai_vector_store_file_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_vector_store_file_id"] + } + } + }, + "public.knowledge_contents": { + "name": "knowledge_contents", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_content_type": { + "name": "knowledge_content_type", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "file_db_id": { + "name": "file_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_contents_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_contents_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "knowledges", + "columnsFrom": ["knowledge_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "knowledge_contents_file_db_id_files_db_id_fk": { + "name": "knowledge_contents_file_db_id_files_db_id_fk", + "tableFrom": "knowledge_contents", + "tableTo": "files", + "columnsFrom": ["file_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_contents_id_unique": { + "name": "knowledge_contents_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + }, + "knowledge_contents_file_db_id_knowledge_db_id_unique": { + "name": "knowledge_contents_file_db_id_knowledge_db_id_unique", + "nullsNotDistinct": false, + "columns": ["file_db_id", "knowledge_db_id"] + } + } + }, + "public.knowledge_openai_vector_store_representations": { + "name": "knowledge_openai_vector_store_representations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "knowledge_db_id": { + "name": "knowledge_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "openai_vector_store_id": { + "name": "openai_vector_store_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk": { + "name": "knowledge_openai_vector_store_representations_knowledge_db_id_knowledges_db_id_fk", + "tableFrom": "knowledge_openai_vector_store_representations", + "tableTo": "knowledges", + "columnsFrom": ["knowledge_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledge_openai_vector_store_representations_openai_vector_store_id_unique": { + "name": "knowledge_openai_vector_store_representations_openai_vector_store_id_unique", + "nullsNotDistinct": false, + "columns": ["openai_vector_store_id"] + } + } + }, + "public.knowledges": { + "name": "knowledges", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "agent_db_id": { + "name": "agent_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "knowledges_agent_db_id_agents_db_id_fk": { + "name": "knowledges_agent_db_id_agents_db_id_fk", + "tableFrom": "knowledges", + "tableTo": "agents", + "columnsFrom": ["agent_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "knowledges_id_unique": { + "name": "knowledges_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.nodes": { + "name": "nodes", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "class_name": { + "name": "class_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "data": { + "name": "data", + "type": "jsonb", + "primaryKey": false, + "notNull": true + }, + "graph": { + "name": "graph", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "nodes_build_db_id_builds_db_id_fk": { + "name": "nodes_build_db_id_builds_db_id_fk", + "tableFrom": "nodes", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "nodes_id_build_db_id_unique": { + "name": "nodes_id_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "build_db_id"] + } + } + }, + "public.oauth_credentials": { + "name": "oauth_credentials", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_id": { + "name": "user_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "provider_account_id": { + "name": "provider_account_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "access_token": { + "name": "access_token", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "refresh_token": { + "name": "refresh_token", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "expires_at": { + "name": "expires_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "token_type": { + "name": "token_type", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "scope": { + "name": "scope", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "oauth_credentials_user_id_users_db_id_fk": { + "name": "oauth_credentials_user_id_users_db_id_fk", + "tableFrom": "oauth_credentials", + "tableTo": "users", + "columnsFrom": ["user_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "oauth_credentials_user_id_provider_provider_account_id_unique": { + "name": "oauth_credentials_user_id_provider_provider_account_id_unique", + "nullsNotDistinct": false, + "columns": ["user_id", "provider", "provider_account_id"] + } + } + }, + "public.organizations": { + "name": "organizations", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.ports": { + "name": "ports", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "direction": { + "name": "direction", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "type": { + "name": "type", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "ports_node_db_id_nodes_db_id_fk": { + "name": "ports_node_db_id_nodes_db_id_fk", + "tableFrom": "ports", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "ports_id_node_db_id_unique": { + "name": "ports_id_node_db_id_unique", + "nullsNotDistinct": false, + "columns": ["id", "node_db_id"] + } + } + }, + "public.request_port_messages": { + "name": "request_port_messages", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "port_db_id": { + "name": "port_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "message": { + "name": "message", + "type": "jsonb", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_port_messages_request_db_id_requests_db_id_fk": { + "name": "request_port_messages_request_db_id_requests_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_port_messages_port_db_id_ports_db_id_fk": { + "name": "request_port_messages_port_db_id_ports_db_id_fk", + "tableFrom": "request_port_messages", + "tableTo": "ports", + "columnsFrom": ["port_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_port_messages_request_db_id_port_db_id_unique": { + "name": "request_port_messages_request_db_id_port_db_id_unique", + "nullsNotDistinct": false, + "columns": ["request_db_id", "port_db_id"] + } + } + }, + "public.request_results": { + "name": "request_results", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "text": { + "name": "text", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_results_request_db_id_requests_db_id_fk": { + "name": "request_results_request_db_id_requests_db_id_fk", + "tableFrom": "request_results", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_results_request_db_id_unique": { + "name": "request_results_request_db_id_unique", + "nullsNotDistinct": false, + "columns": ["request_db_id"] + } + } + }, + "public.request_runners": { + "name": "request_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "provider": { + "name": "provider", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_runners_request_db_id_requests_db_id_fk": { + "name": "request_runners_request_db_id_requests_db_id_fk", + "tableFrom": "request_runners", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_runners_runner_id_unique": { + "name": "request_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": ["runner_id"] + } + } + }, + "public.request_stack_runners": { + "name": "request_stack_runners", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "runner_id": { + "name": "runner_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_stack_runners_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_stack_runners", + "tableTo": "request_stacks", + "columnsFrom": ["request_stack_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stack_runners_runner_id_unique": { + "name": "request_stack_runners_runner_id_unique", + "nullsNotDistinct": false, + "columns": ["runner_id"] + } + } + }, + "public.request_stacks": { + "name": "request_stacks", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_db_id": { + "name": "request_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "start_node_db_id": { + "name": "start_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "end_node_db_id": { + "name": "end_node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "request_stacks_request_db_id_requests_db_id_fk": { + "name": "request_stacks_request_db_id_requests_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "requests", + "columnsFrom": ["request_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_start_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_start_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": ["start_node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_stacks_end_node_db_id_nodes_db_id_fk": { + "name": "request_stacks_end_node_db_id_nodes_db_id_fk", + "tableFrom": "request_stacks", + "tableTo": "nodes", + "columnsFrom": ["end_node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_stacks_id_unique": { + "name": "request_stacks_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.request_steps": { + "name": "request_steps", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "request_stack_db_id": { + "name": "request_stack_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'in_progress'" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "request_steps_request_stack_db_id_request_stacks_db_id_fk": { + "name": "request_steps_request_stack_db_id_request_stacks_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "request_stacks", + "columnsFrom": ["request_stack_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "request_steps_node_db_id_nodes_db_id_fk": { + "name": "request_steps_node_db_id_nodes_db_id_fk", + "tableFrom": "request_steps", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "request_steps_id_unique": { + "name": "request_steps_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.requests": { + "name": "requests", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true, + "default": "'queued'" + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "started_at": { + "name": "started_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "finished_at": { + "name": "finished_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "requests_build_db_id_builds_db_id_fk": { + "name": "requests_build_db_id_builds_db_id_fk", + "tableFrom": "requests", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "requests_id_unique": { + "name": "requests_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.stripe_user_mappings": { + "name": "stripe_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "stripe_customer_id": { + "name": "stripe_customer_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "stripe_user_mappings_user_db_id_users_db_id_fk": { + "name": "stripe_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "stripe_user_mappings", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "stripe_user_mappings_user_db_id_unique": { + "name": "stripe_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id"] + }, + "stripe_user_mappings_stripe_customer_id_unique": { + "name": "stripe_user_mappings_stripe_customer_id_unique", + "nullsNotDistinct": false, + "columns": ["stripe_customer_id"] + } + } + }, + "public.subscriptions": { + "name": "subscriptions", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "status": { + "name": "status", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "cancel_at_period_end": { + "name": "cancel_at_period_end", + "type": "boolean", + "primaryKey": false, + "notNull": true + }, + "cancel_at": { + "name": "cancel_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "canceled_at": { + "name": "canceled_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "current_period_start": { + "name": "current_period_start", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "current_period_end": { + "name": "current_period_end", + "type": "timestamp", + "primaryKey": false, + "notNull": true + }, + "created": { + "name": "created", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "ended_at": { + "name": "ended_at", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_start": { + "name": "trial_start", + "type": "timestamp", + "primaryKey": false, + "notNull": false + }, + "trial_end": { + "name": "trial_end", + "type": "timestamp", + "primaryKey": false, + "notNull": false + } + }, + "indexes": {}, + "foreignKeys": { + "subscriptions_organization_db_id_organizations_db_id_fk": { + "name": "subscriptions_organization_db_id_organizations_db_id_fk", + "tableFrom": "subscriptions", + "tableTo": "organizations", + "columnsFrom": ["organization_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "subscriptions_id_unique": { + "name": "subscriptions_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + }, + "public.supabase_user_mappings": { + "name": "supabase_user_mappings", + "schema": "", + "columns": { + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "supabase_user_id": { + "name": "supabase_user_id", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "supabase_user_mappings_user_db_id_users_db_id_fk": { + "name": "supabase_user_mappings_user_db_id_users_db_id_fk", + "tableFrom": "supabase_user_mappings", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "supabase_user_mappings_user_db_id_unique": { + "name": "supabase_user_mappings_user_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id"] + }, + "supabase_user_mappings_supabase_user_id_unique": { + "name": "supabase_user_mappings_supabase_user_id_unique", + "nullsNotDistinct": false, + "columns": ["supabase_user_id"] + } + } + }, + "public.team_memberships": { + "name": "team_memberships", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "user_db_id": { + "name": "user_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "team_db_id": { + "name": "team_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "role": { + "name": "role", + "type": "text", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "team_memberships_user_db_id_users_db_id_fk": { + "name": "team_memberships_user_db_id_users_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "users", + "columnsFrom": ["user_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + }, + "team_memberships_team_db_id_teams_db_id_fk": { + "name": "team_memberships_team_db_id_teams_db_id_fk", + "tableFrom": "team_memberships", + "tableTo": "teams", + "columnsFrom": ["team_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "team_memberships_user_db_id_team_db_id_unique": { + "name": "team_memberships_user_db_id_team_db_id_unique", + "nullsNotDistinct": false, + "columns": ["user_db_id", "team_db_id"] + } + } + }, + "public.teams": { + "name": "teams", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "organization_db_id": { + "name": "organization_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "name": { + "name": "name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "created_at": { + "name": "created_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "updated_at": { + "name": "updated_at", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "teams_organization_db_id_organizations_db_id_fk": { + "name": "teams_organization_db_id_organizations_db_id_fk", + "tableFrom": "teams", + "tableTo": "organizations", + "columnsFrom": ["organization_db_id"], + "columnsTo": ["db_id"], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": {} + }, + "public.trigger_nodes": { + "name": "trigger_nodes", + "schema": "", + "columns": { + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + }, + "build_db_id": { + "name": "build_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + }, + "node_db_id": { + "name": "node_db_id", + "type": "integer", + "primaryKey": false, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": { + "trigger_nodes_build_db_id_builds_db_id_fk": { + "name": "trigger_nodes_build_db_id_builds_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "builds", + "columnsFrom": ["build_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + }, + "trigger_nodes_node_db_id_nodes_db_id_fk": { + "name": "trigger_nodes_node_db_id_nodes_db_id_fk", + "tableFrom": "trigger_nodes", + "tableTo": "nodes", + "columnsFrom": ["node_db_id"], + "columnsTo": ["db_id"], + "onDelete": "cascade", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "trigger_nodes_build_db_id_unique": { + "name": "trigger_nodes_build_db_id_unique", + "nullsNotDistinct": false, + "columns": ["build_db_id"] + } + } + }, + "public.users": { + "name": "users", + "schema": "", + "columns": { + "id": { + "name": "id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "db_id": { + "name": "db_id", + "type": "serial", + "primaryKey": true, + "notNull": true + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "users_id_unique": { + "name": "users_id_unique", + "nullsNotDistinct": false, + "columns": ["id"] + } + } + } + }, + "enums": {}, + "schemas": {}, + "sequences": {}, + "_meta": { + "columns": {}, + "schemas": {}, + "tables": {} + } +} diff --git a/migrations/meta/_journal.json b/migrations/meta/_journal.json index 69b24366..ddc9a1b5 100644 --- a/migrations/meta/_journal.json +++ b/migrations/meta/_journal.json @@ -1,48 +1,48 @@ { - "version": "7", - "dialect": "postgresql", - "entries": [ - { - "idx": 0, - "version": "7", - "when": 1727672114041, - "tag": "0000_aberrant_stardust", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1727751238434, - "tag": "0001_glorious_mathemanic", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1727759326160, - "tag": "0002_mighty_zarek", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1729227804577, - "tag": "0003_messy_fabian_cortez", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1729759218608, - "tag": "0004_handy_kylun", - "breakpoints": true - }, - { - "idx": 5, - "version": "7", - "when": 1730368916214, - "tag": "0005_smart_vapor", - "breakpoints": true - } - ] -} \ No newline at end of file + "version": "7", + "dialect": "postgresql", + "entries": [ + { + "idx": 0, + "version": "7", + "when": 1727672114041, + "tag": "0000_aberrant_stardust", + "breakpoints": true + }, + { + "idx": 1, + "version": "7", + "when": 1727751238434, + "tag": "0001_glorious_mathemanic", + "breakpoints": true + }, + { + "idx": 2, + "version": "7", + "when": 1727759326160, + "tag": "0002_mighty_zarek", + "breakpoints": true + }, + { + "idx": 3, + "version": "7", + "when": 1729227804577, + "tag": "0003_messy_fabian_cortez", + "breakpoints": true + }, + { + "idx": 4, + "version": "7", + "when": 1729759218608, + "tag": "0004_handy_kylun", + "breakpoints": true + }, + { + "idx": 5, + "version": "7", + "when": 1730368916214, + "tag": "0005_smart_vapor", + "breakpoints": true + } + ] +} From cb4dad8493811afeb6a291f94cba1a82bca15dda Mon Sep 17 00:00:00 2001 From: Koji Matsumoto Date: Fri, 1 Nov 2024 11:53:24 +0900 Subject: [PATCH 13/13] Revert "Update docs/packages-license.md" This reverts commit 8d2b5864c205e5e5c8962d67856d227a06971ae5. --- docs/packages-license.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/packages-license.md b/docs/packages-license.md index cde96984..12fbbb21 100644 --- a/docs/packages-license.md +++ b/docs/packages-license.md @@ -1,6 +1,6 @@ # giselle -As of October 31, 2024 8:07am. 926 total +As of October 29, 2024 10:23am. 926 total ## Summary * 667 MIT