mirror of
https://github.com/EZ-Api/ez-api.git
synced 2026-01-13 17:47:51 +00:00
feat(api): add admin traffic chart statistics endpoint
Add new endpoint GET /admin/logs/stats/traffic-chart to provide aggregated traffic metrics grouped by time and model. Features include: - Time granularity selection (hour/minute) - Top-N model breakdown with "other" aggregation - Metrics for request counts and token usage Includes generated Swagger documentation.
This commit is contained in:
@@ -368,6 +368,7 @@ func main() {
|
||||
adminGroup.GET("/logs", handler.ListLogs)
|
||||
adminGroup.DELETE("/logs", handler.DeleteLogs)
|
||||
adminGroup.GET("/logs/stats", handler.LogStats)
|
||||
adminGroup.GET("/logs/stats/traffic-chart", handler.GetTrafficChart)
|
||||
adminGroup.GET("/logs/webhook", handler.GetLogWebhookConfig)
|
||||
adminGroup.PUT("/logs/webhook", handler.UpdateLogWebhookConfig)
|
||||
adminGroup.GET("/stats", adminHandler.GetAdminStats)
|
||||
|
||||
Reference in New Issue
Block a user