Usage

List inference calls

Changed on

Paginated, filterable list of inference calls (detect, locate, element_locate, and agent_chat for an agent run's model steps) the caller's user was billed for over a required time window (created_after/created_before). Filters: endpoint, model, session, free-text search. Order with order_by ('<field> <asc|desc>').

get/usage/inferences

Request

Query parameters

created_afterstring date-time required

Only inferences created at or after this time (RFC 3339).

created_beforestring date-time required

Only inferences created before this time (RFC 3339).

limitinteger

Number of inferences per page (1-100).

offsetinteger

Pagination offset.

endpointstring[] nullable

Only inferences of one of these operations; repeatable. agent_chat is an agent run's model step.

modelstring

Restrict results to a single model name.

searchstring

Filter by inference (event) id substring.

session_idstring

Restrict results to inferences that ran under one phone session.

order_bystring

Sort expression '<field> [asc|desc]', direction defaulting to desc; field is created_at, cost_microdollars, latency_ms, endpoint, model or inference_id. Defaults to created_at desc.

Response

OK

limitinteger required

Page size used for this response.

offsetinteger required

Pagination offset used for this response.

totalinteger required

Total number of inference calls matching the query.

Changes

    • warning

      added the new agent_chat enum value to the // response property for the response status

    • info

      added the enum value agent_chat to the property items/ of the query request parameter endpoint

    • breaking

      added the new required query request parameter created_after

    • breaking

      added the new required query request parameter created_before

    • breaking

      added the pattern ^(created_at|cost_microdollars|latency_ms|endpoint|model|inference_id)( (asc|desc))?$ to the query request parameter order_by

    • warning

      deleted the query request parameter end_date

    • warning

      deleted the query request parameter endpoint_filter

    • warning

      deleted the query request parameter start_date

    • info

      added the new optional query request parameter endpoint

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status