v1
protected
triggers
Get Execution Metrics
Get execution metrics for a trigger.
Returns aggregated counts, success rate, execution time and spend. Spend is the cost of the tasks those runs created, joined at read time — a run is recorded when its task starts, the bill accrues afterwards.
Args: trigger_id: The unique identifier of the trigger hours: Time period in hours to analyze; omitted means the whole history user_context: Authentication context trigger_service: Injected trigger service db_session: Session used for the spend join
Returns: Execution metrics for the trigger
Raises: HTTPException: If trigger not found
get/v1/triggers/{trigger_id}/metrics
Path parameters
trigger_idstring uuid required
Query parameters
hoursinteger nullable
Time period in hours (max 1 year). Omit for the trigger's whole history.
Time period in hours (max 1 year). Omit for the trigger's whole history.
Response
Successful Response