feat: initial commit with accounts manager project structure
- TypeScript项目基础架构 - API路由和账户管理服务 - 数据库模式和迁移 - 基础配置文件和文档 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
		
							
								
								
									
										16
									
								
								drizzle/0000_initial_schema.sql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								drizzle/0000_initial_schema.sql
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,16 @@ | ||||
| CREATE TABLE IF NOT EXISTS "accounts" ( | ||||
| 	"id" serial PRIMARY KEY NOT NULL, | ||||
| 	"owner_id" varchar(128) NOT NULL, | ||||
| 	"platform" varchar(100) NOT NULL, | ||||
| 	"custom_id" varchar(255) NOT NULL, | ||||
| 	"data" text NOT NULL, | ||||
| 	"status" varchar(50) NOT NULL, | ||||
| 	"notes" text, | ||||
| 	"locked_at" timestamp, | ||||
| 	"created_at" timestamp DEFAULT now() NOT NULL, | ||||
| 	"updated_at" timestamp DEFAULT now() NOT NULL | ||||
| ); | ||||
|  | ||||
| CREATE UNIQUE INDEX IF NOT EXISTS "platform_custom_id_idx" ON "accounts" ("platform","custom_id"); | ||||
| CREATE INDEX IF NOT EXISTS "owner_id_status_idx" ON "accounts" ("owner_id","status"); | ||||
| CREATE INDEX IF NOT EXISTS "platform_owner_idx" ON "accounts" ("platform","owner_id"); | ||||
		Reference in New Issue
	
	Block a user
	 Your Name
					Your Name