@refine/api@0.2.0
·
16 commits
to main
since this release
Minor Changes
- 69347d2: Add a usage overview to the admin dashboard: total refines and tokens, refines-per-day, and breakdowns by model, tone, and device over a selectable time range. Backed by a new
GET /admin/usageendpoint that aggregates history (excluding private entries). Cost estimates are shown when an operator-provided per-model price map is configured. - 897739c: Record token usage on each refine and honor per-request
save/privateflags:save: falseskips history persistence entirely, andprivate: truestores the entry but hides it from the admin history view. Addsis_privateand token columns to the history table. - cb9754b: Add
POST /admin/history/pruneso retention can be driven by an external scheduler (e.g. cron-job.org) instead of only the built-in interval. UsesHISTORY_RETENTION_DAYSby default, or an optional?days=Noverride, and returns the number of rows deleted. - 4e41f50: Add an optional history retention policy. Set
HISTORY_RETENTION_DAYSto auto-delete history older than N days; a cleanup job runs at startup and every 12 hours. Unset or0keeps history forever.