4 Commits

Author SHA1 Message Date
zenfun
e7db9f319f fix: delete keys and seed only active ones
Ensure admin key deletion removes the DB record and returns a
"deleted" status. Update seeder idempotency to count only active keys
when deciding whether to skip or create new keys.
2026-01-10 01:18:04 +08:00
zenfun
6af938448e fix(seeder): improve key idempotency and log names
Trim whitespace in provider model lists, format provider names as `group#keyID`
to match DP logs, and skip existing API keys during seeding (deleting on reset)
to keep runs idempotent and summaries accurate
2026-01-10 00:58:02 +08:00
zenfun
5431e24923 fix(seeder): correct log generation fields
- Parse provider group models from API response string and expose as slice
- Send `model` field (not `model_name`) when creating logs
- Use API key ID as `provider_id` instead of provider group ID
- Restrict reset behavior to resources matching seeder tag/prefix
- Refactor usage sample generation to accept a context struct
2026-01-10 00:46:03 +08:00
zenfun
18b9846f83 feat(seeder): add control plane data seeder
Introduce a `cmd/seeder` CLI to generate deterministic demo datasets and
seed them into the Control Plane via admin endpoints, supporting reset,
dry-run, profiles, and usage sample generation.

Add Cobra/Viper dependencies to support the new command.
2026-01-10 00:26:48 +08:00