Observability

Token metrics and tool timelines for sessions

Get Tool Timeline Endpoint

GET
/observability/sessions/{session_id}/tools

Path Parameters

session_id*string

Query Parameters

limit?integer
Default100
include_blocked?boolean
Defaulttrue

Response Body

application/json

application/json

curl -X GET "https://loading/observability/sessions/string/tools"
{
  "session_id": "string",
  "total_executions": 0,
  "executions": [
    {
      "observation_id": "",
      "operation_type": "",
      "tool_name": "string",
      "timestamp": "2019-08-24T14:15:22Z",
      "duration_ms": 0,
      "success": true,
      "error_message": "string"
    }
  ]
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}

Get Token Metrics Endpoint

GET
/observability/sessions/{session_id}/tokens

Path Parameters

session_id*string

Query Parameters

include_records?boolean
Defaulttrue

Response Body

application/json

application/json

curl -X GET "https://loading/observability/sessions/string/tokens"
{
  "session_id": "string",
  "input_tokens": 0,
  "output_tokens": 0,
  "total_tokens": 0,
  "total_cost_usd": "0",
  "cache_creation_tokens": 0,
  "cache_read_tokens": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}

Get Request Latency

GET
/observability/latency

Query Parameters

route?|

One route TEMPLATE, e.g. /evals/{eval_id}. Every route when omitted.

window?string

How far back to look

Default"24h"
Value in"1h" | "24h" | "7d" | "30d"

Response Body

application/json

application/json

curl -X GET "https://loading/observability/latency"
{
  "window": "1h",
  "since": "string",
  "available": true,
  "routes": [
    {
      "method": "string",
      "route": "string",
      "count": 0,
      "p50_ms": 0,
      "p95_ms": 0,
      "p99_ms": 0,
      "max_ms": 0,
      "p99_display": "string"
    }
  ],
  "recorder": {
    "running": true,
    "written": 0,
    "dropped": 0,
    "write_failures": 0,
    "discarded": 0,
    "cleanup_failures": 0,
    "buffered": 0
  }
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}

Get Upstream Retries

GET
/observability/upstream-retries

Query Parameters

window?string

How far back to look

Default"24h"
Value in"1h" | "24h" | "7d" | "30d"

Response Body

application/json

application/json

curl -X GET "https://loading/observability/upstream-retries"
{
  "window": "1h",
  "since": "string",
  "total": 0,
  "counts": [
    {
      "provider": "string",
      "requested_model": "string",
      "upstream_kind": "string",
      "retries": 0
    }
  ]
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string",
      "input": null,
      "ctx": {}
    }
  ]
}

On this page