model-hub

GET /model-hub/eval-templates/<id>/usage/

Returns usage stats, chart data, and the paginated usage table. Query params: page (0-based), page_size, period (30m|6h|1d|7d|30d|90d|180d|365d), optional start_date/end_date pair (overrides period — sent by the FE for Today / Yesterday / Custom).

The response is rendered through EvalUsageStatsResponseResultSerializer(instance=...).data at the boundary so shape drift surfaces here instead of shipping silently.

Counts and lists only successful runs from the usage ledger (APICallLog rows with status success), from every source: tasks, playground, composites, datasets and experiments. Errored and skipped runs are not usage but stay in the eval logs (task logs, template eval logs); an in-flight run counts once it succeeds. error_count is therefore 0 and pass_rate 100 whenever there are runs; both remain for compatibility.

get/model-hub/eval-templates/{template_id}/usage/

Request

  • Base URL: http://localhost:8000
  • URL: http://localhost:8000/model-hub/eval-templates/{template_id}/usage/
  • Auth: one of:
    • API key in header X-Api-Key
    • API key in header X-Secret-Key

Query parameters

pageinteger
page_sizeinteger
period'30m' | '6h' | '1d' | '7d' | '30d' | '90d' | '180d' | '365d'
start_datestring date-time
end_datestring date-time
refreshboolean

Response

OK

statusboolean required

Changes

No recorded changes to this operation across all 1 revision of this API.