feat: 下游 API 密钥管理 (#103)

* feat: downstream API key usage + proxy log attribution

* chore(schema): regenerate generated artifacts

* test: keep migration replay + platform detection tests stable

* feat: complete downstream api key management validation

* refactor: move downstream keys into console nav

* feat: upgrade downstream keys management console

* feat: harden downstream key management flows

* test: cover downstream key policy guards

* feat: add downstream key grouping and tags

* feat: polish downstream key search and log metadata

* test: fix sqlite migration bootstrap coverage

* perf: isolate vchart bundle loading

* fix: align downstream key drawer metrics

---------

Co-authored-by: DeliciousBuding <DeliciousBuding@users.noreply.github.com>
This commit is contained in:
Delicious
2026-03-15 22:00:02 +08:00
committed by GitHub
parent 251348f784
commit a64a51aa0c
44 changed files with 4162 additions and 183 deletions
@@ -0,0 +1,3 @@
ALTER TABLE `proxy_logs` ADD `downstream_api_key_id` integer;
--> statement-breakpoint
CREATE INDEX IF NOT EXISTS `proxy_logs_downstream_api_key_created_at_idx` ON `proxy_logs` (`downstream_api_key_id`, `created_at`);
@@ -0,0 +1,3 @@
ALTER TABLE `downstream_api_keys` ADD `group_name` text;
--> statement-breakpoint
ALTER TABLE `downstream_api_keys` ADD `tags` text;
+15 -1
View File
@@ -64,6 +64,20 @@
"when": 1773528832339,
"tag": "0009_model_availability_is_manual",
"breakpoints": true
},
{
"idx": 9,
"version": "6",
"when": 1773553945763,
"tag": "0010_proxy_logs_downstream_api_key",
"breakpoints": true
},
{
"idx": 10,
"version": "6",
"when": 1773605400000,
"tag": "0011_downstream_api_key_metadata",
"breakpoints": true
}
]
}
}