Skip to main content
POST
/
calls
/
query_stats
Calls Query Stats
curl --request POST \
  --url https://api.example.com/calls/query_stats \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "project_id": "<string>",
  "filter": {
    "op_names": [
      "<string>"
    ],
    "input_refs": [
      "<string>"
    ],
    "output_refs": [
      "<string>"
    ],
    "parent_ids": [
      "<string>"
    ],
    "trace_ids": [
      "<string>"
    ],
    "call_ids": [
      "<string>"
    ],
    "thread_ids": [
      "<string>"
    ],
    "turn_ids": [
      "<string>"
    ],
    "trace_roots_only": true,
    "wb_user_ids": [
      "<string>"
    ],
    "wb_run_ids": [
      "<string>"
    ]
  },
  "query": {
    "$expr": {
      "$and": [
        {
          "$literal": "<string>"
        }
      ]
    }
  },
  "limit": 123,
  "include_total_storage_size": false,
  "expand_columns": [
    "inputs.self.message",
    "inputs.model.prompt"
  ]
}
'
{
  "count": 123,
  "total_storage_size_bytes": 123
}

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Body

application/json
project_id
string
required
filter
CallsFilter · object
query
Query · object
limit
integer | null
include_total_storage_size
boolean | null
default:false
expand_columns
string[] | null

Columns with refs to objects or table rows that require expansion during filtering or ordering.

Example:
[
"inputs.self.message",
"inputs.model.prompt"
]

Response

Successful Response

count
integer
required
total_storage_size_bytes
integer | null