Related queries and mutations in Agent traces and evaluations. Each has its own section.
Queries
getAgentMetadataV2 (query)
getAgentMetadataV2 is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get metadata about AI agents including both trace table and platform agents
Arguments
Returns
[AgentMetadataV2]
Example
query GetAgentMetadataV2 {
getAgentMetadataV2 {
accountUuid
agentName
displayName
traceTableMcon
agentMcon
sourceType
agentReference
lastSeenAt
splitBy
}
}Types used only by getAgentMetadataV2
getAgentMetadataV2AgentMetadataV2
AgentMetadataV2Object type. Metadata about AI agents for agent observability (v2 — includes platform agents).
| Field | Type | Description |
|---|---|---|
accountUuid | UUID! | Account UUID |
agentName | String! | Name of the agent |
displayName | String! | Human-friendly name to show for the agent — the Databricks Agent Bricks tile name for Knowledge-Assistant agents. Falls back to agentName when no friendly name is stored (SDK / Snowflake agents and user-managed trace tables), so it is always safe to display directly. |
traceTableMcon | String! | MCON of the trace table or platform agent |
agentMcon | String | MCON that identifies this agent itself, distinct from every other agent sharing its trace table. Assign it to a domain to scope the domain to this agent. Keep using traceTableMcon to query the agent's traces. Null while the agent's identity is not yet available. |
sourceType | AgentSourceType! | Source type: TRACE_TABLE for user-managed trace tables, PLATFORM_AGENT for platform agents |
agentReference | String | The value to pass as the agent field of the createOrUpdateAgent*MonitorFromDefinition mutations. For a PLATFORM_AGENT this is the portable {database}:{schema}.{name} reference; for a TRACE_TABLE (OTel) agent it is the service_name, which equals agentName. |
warehouse | Warehouse | Warehouse (resource) that owns this agent's trace table or platform-agent registration. Pass its uuid (or name) as the required warehouse argument of the createOrUpdateAgent*MonitorFromDefinition mutations — no separate warehouse lookup or trace-table MCON parsing needed. Null when the agent's warehouse association cannot be resolved (e.g. the warehouse was deleted). |
classification | AgentClassificationOutput | AI-590/AI-598 classification of this agent — same builder and identical lowercase wire values as the incident-keyed TSA REST agent object and getAgentClassification, so consumers share one parser across surfaces (AO-891). Note the intentional casing split with this node's legacy sourceType enum (uppercase member names). |
lastSeenAt | DateTime | When this agent last produced a trace; a row whose observation carried no timestamp carries its record time instead (or the registration's created time for agents recorded from the registration index). An agent stays listed after it goes quiet, reporting zero traces, so this is how long it has been silent. |
workflowAgents | [WorkflowAgent!]! | The agent's workflow agents, most recently seen first. Empty unless the agent is split by workflow. Lists only workflows seen in the last 30 days, and only since startTime when it is later. Lists at most 200 of them. |
splitBy | ObservedAgentSplitBy | How the agent splits into workflow agents. Null: not split. Read from the agent registry, so a split agent with no recent workflow still reports it. |
WorkflowAgent
WorkflowAgentObject type. One workflow of an agent split by workflow, listed as its own agent.
| Field | Type | Description |
|---|---|---|
workflow | String! | The workflow value. |
lastSeenAt | DateTime! | When the newest trace whose first workflow is this value reached this agent: the earliest start time of the agent's own spans in that trace. |
Related types
AgentClassificationOutput, AgentSourceType, DateTime, ObservedAgentSplitBy, UUID, Warehouse
getAgentObservabilityBillingInfo (query)
getAgentObservabilityBillingInfo is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get agent observability billing breakdown: active agents, monitors targeting those agents, and the resulting tier
Returns
AgentObservabilityBillingInfo
Example
query GetAgentObservabilityBillingInfo {
getAgentObservabilityBillingInfo {
numAgents
numMonitors
sizeTier
totalScale
dailyCredits
}
}Types used only by getAgentObservabilityBillingInfo
getAgentObservabilityBillingInfoAgentObservabilityBillingAgent
AgentObservabilityBillingAgentObject type. An active agent counted for billing purposes.
| Field | Type | Description |
|---|---|---|
agentName | String! | Name of the agent |
traceTableMcon | String! | MCON of the trace table or platform agent |
sourceType | AgentSourceType! | TRACE_TABLE or PLATFORM_AGENT |
AgentObservabilityBillingInfo
AgentObservabilityBillingInfoObject type. Billing breakdown for agent observability — active agents, monitors, and tier.
| Field | Type | Description |
|---|---|---|
numAgents | Int! | Number of active agents |
numMonitors | Int! | Number of monitors for active agents |
sizeTier | String! | Billing size tier |
totalScale | Int! | Scale factor for the tier |
dailyCredits | Int! | Daily credits for the tier |
agents | [AgentObservabilityBillingAgent!]! | List of active agents counted for billing |
Related types
getAgentObservabilitySummary (query)
getAgentObservabilitySummary is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Summarize observed agents and known data dependencies for a time window. Unavailable metrics are null.
Arguments
Returns
AgentObservabilitySummary
Example
query GetAgentObservabilitySummary($startTime: DateTime!, $endTime: DateTime!) {
getAgentObservabilitySummary(startTime: $startTime, endTime: $endTime) {
startTime
endTime
generatedTime
instrumentedAgentCount
hasConfiguredAgentSource
agentsWithOpenIssuesCount
agentsOnAlertedDataCount
agentReadTableCount
unmonitoredAgentReadTableCount
recentAlertsOnAgentReadTablesCount
agentsWithRecentAlertsOnReadTablesCount
totalRuns
runSuccessRate
p95LatencySeconds
averageLatencySeconds
totalTraces
errorCount
evalScore
unavailableFields
}
}Types used only by getAgentObservabilitySummary
getAgentObservabilitySummaryAgentObservabilitySummary
AgentObservabilitySummaryObject type. Observed agents and current known dependencies for an alert window.
Selected metrics that are null are unavailable; unavailableFields lists the
selected fields that are null.
totalRuns, run success rate, p95 latency, historical comparisons, and evals are not
yet available.
| Field | Type | Description |
|---|---|---|
startTime | DateTime! | |
endTime | DateTime! | |
generatedTime | DateTime! | |
instrumentedAgentCount | Int | Distinct accessible agents, not lifetime installations. |
hasConfiguredAgentSource | Boolean | Whether an accessible agent trace source is registered. |
agentsWithOpenIssuesCount | Int | Agents with active, non-ignored reinforcement-loop issues seen in the past 48 hours, among the agents the user can check: those in domains where the user has alerts access. Issues served at HIDDEN priority are left out, as on the agent's issues page. Null when the user has no alerts access, when agents were observed but none is in a domain where the user has alerts access, or when the read fails. |
agentOpenIssueCounts | [AgentOpenIssueCount!] | Every agent instrumentedAgentCount counts, with its count of open issues. A number means the agent was checked: 0 means it has none. A null count means the user lacks alerts access in the agent's domain. An agent missing from the list is not in instrumentedAgentCount. Ordered by count, highest first, with null counts last, then by agent name, then by traceTableMcon. Null when the user has no alerts access or the read fails. |
agentsOnAlertedDataCount | Int | Agents reading known tables with currently unresolved alerts created during the window. |
agentReadTableCount | Int | Distinct accessible tables with known direct agent dependencies. Lineage has no read-time filter. |
unmonitoredAgentReadTableCount | Int | Known agent-read tables without monitoring. |
recentAlertsOnAgentReadTablesCount | Int | Distinct alerts created during the window on known agent-read tables, across all statuses and without declared severity. |
agentsWithRecentAlertsOnReadTablesCount | Int | Distinct agents associated with recent alerts on known tables, across all alert statuses. |
totalRuns | BigInt | |
runSuccessRate | Float | Successful run fraction from zero to one, when available. |
p95LatencySeconds | Float | |
averageLatencySeconds | Float | Run-weighted mean recorded trace duration in seconds, using the agent overview latency definition within [startTime, endTime). Includes successful and failed traces with finite, nonnegative durations. Null when no traces qualify or any source is unavailable. |
totalTraces | BigInt | Traces starting in [startTime, endTime), using the agent overview totalTraces definition. Null when any source is unavailable or startTime is before retained span history. |
errorCount | BigInt | Traces counted in totalTraces whose root span errored, using the agent overview errorCount definition. Null when totalTraces is null. |
evalScore | Float | |
spend | Float | Always null. Deprecated: Read getAgentSpend, which the client can poll.. |
spendUnit | String | Always null. Deprecated: Read getAgentSpend, which the client can poll.. |
unavailableFields | [String!]! |
AgentOpenIssueCount
AgentOpenIssueCountObject type. One observed agent and how many open reinforcement-loop issues it has.
| Field | Type | Description |
|---|---|---|
traceTableMcon | String! | The agent's trace table mcon, as getAgentMetadataV2 reports it. |
agentName | String! | |
openIssueCount | Int | Distinct open issues counted for this agent, by the rule agentsWithOpenIssuesCount uses. Null when the user lacks alerts access in the agent's domain, so its issues were not checked. |
Related types
getAgentReadableIdentity (query)
getAgentReadableIdentity is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
The agent's identity, when the caller may open its pages. Null otherwise. Unlike the agents listing, this covers every agent.
Arguments
| Argument | Type | Description |
|---|---|---|
mcon | String! | Trace-table or agent MCON |
agentName | String | The agent on that trace table. Optional with an agent MCON, which names one agent; when given, it must match that agent. |
Returns
ReadableAgentIdentity
Example
query GetAgentReadableIdentity($mcon: String!) {
getAgentReadableIdentity(mcon: $mcon) {
agentMcon
agentName
displayName
storageMcon
sourceType
}
}Types used only by getAgentReadableIdentity
getAgentReadableIdentityReadableAgentIdentity
ReadableAgentIdentityObject type. An agent the caller may open, with the MCONs its pages and monitors need.
| Field | Type | Description |
|---|---|---|
agentMcon | String! | MCON that identifies the agent |
agentName | String! | Name of the agent |
displayName | String! | Name to show for the agent |
storageMcon | String! | MCON of the trace table the agent records spans in |
sourceType | AgentSourceType! | Source type |
Related types
getAgentReadAccess (query)
getAgentReadAccess is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Whether the caller may open this agent's pages. Without agentName, whether the caller reaches the trace table or any agent on it. Unlike the agents listing, this covers every agent.
Arguments
| Argument | Type | Description |
|---|---|---|
mcon | String! | Trace-table or agent MCON |
agentName | String | The agent on that trace table |
Returns
Boolean!
Example
query GetAgentReadAccess($mcon: String!) {
getAgentReadAccess(mcon: $mcon)
}getAgentSegments (query)
getAgentSegments is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get distinct segment values for the given field across all traces. Used to populate the segments dropdown in the Filter Widget.
Arguments
| Argument | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent (aiagent object type) to query |
segmentField | TraceSegmentField! | Field to get distinct segment values for (WORKFLOW, TASK, MODEL) |
Returns
AgentSegmentsResult
Example
query GetAgentSegments($agentName: String!, $traceTableMcon: String!, $segmentField: TraceSegmentField!) {
getAgentSegments(agentName: $agentName, traceTableMcon: $traceTableMcon, segmentField: $segmentField) {
segments
}
}Types used only by getAgentSegments
getAgentSegmentsAgentSegmentsResult
AgentSegmentsResultObject type. Result of getAgentSegments query.
| Field | Type | Description |
|---|---|---|
segments | [String!]! | Distinct segment values for the requested field |
Related types
getAgentSpend (query)
getAgentSpend is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
What the visible agents' model calls cost in a half-open time window, in the customer's currency. Read separately from getAgentObservabilitySummary because it crosses to the customer's warehouse, so the other cards render first. A past window counts agents seen since its start, including agents first seen after it ended. Three error shapes are expected traffic rather than failures: a request carrying an idempotency id whose scan is still running answers REQUEST_IN_PROGRESS, which the client re-sends under the same id until the spend comes back; a request that ran out of time before the scan started answers REQUEST_TIMEOUT, which the client re-sends under the same id; and a request under an id whose earlier attempt failed answers a validation error carrying the IDEMPOTENT_REQUEST_FAILED code, on which the client must mint a fresh id for the same variables.
Arguments
Returns
AgentSpend
Example
query GetAgentSpend($startTime: DateTime!, $endTime: DateTime!) {
getAgentSpend(startTime: $startTime, endTime: $endTime) {
spend
spendUnit
}
}Types used only by getAgentSpend
getAgentSpendAgentSpend
AgentSpendObject type.
| Field | Type | Description |
|---|---|---|
spend | Float | What the cohort's Cortex model calls cost over the window, in spendUnit. It excludes the warehouse cost of the agents' SQL. Null when the user lacks the graphql/query permission, the account lacks an agent or a compute cost rate, a priced agent's cost is in credits or another currency, no agent priced a model call, or the cohort has more Cortex agents than one batched cost read takes. |
spendUnit | String | The lowercase ISO 4217 currency code spend is in, such as usd. |
Related types
getAgentsTraceOverview (query)
getAgentsTraceOverview is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get trace totals (count, average latency, tokens, errors) for several agents or workflow agents of one ClickHouse trace table in one read, for the agents list. A whole-agent entry is unfiltered, and a workflow-agent entry covers the traces that workflow agent owns. Returns one entry per distinct requested entry, in request order. A refused entry list is a VALIDATION_ERROR whose extensions._structured[0].code names the reason. TRACE_OVERVIEW_STATEMENT_TOO_LARGE means the names are too long for one request: send fewer entries.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetAgentsTraceOverviewInput! |
Returns
[AgentTraceOverview!]!
Example
query GetAgentsTraceOverview($input: GetAgentsTraceOverviewInput!) {
getAgentsTraceOverview(input: $input) {
agentName
workflowAgent
}
}Types used only by getAgentsTraceOverview
getAgentsTraceOverviewAgentListMetrics
AgentListMetricsObject type.
| Field | Type | Description |
|---|---|---|
totalTraces | Int! | |
avgLatency | Float | |
totalTokens | BigInt | |
errorCount | Int! |
AgentListMetricsWithComparison
AgentListMetricsWithComparisonObject type.
| Field | Type | Description |
|---|---|---|
totalTraces | Int! | |
avgLatency | Float | |
totalTokens | BigInt | |
errorCount | Int! | |
prevPeriod | AgentListMetrics |
AgentTraceOverview
AgentTraceOverviewObject type.
| Field | Type | Description |
|---|---|---|
agentName | String! | |
metrics | AgentListMetricsWithComparison | Null when the caller cannot access this agent. |
workflowAgent | String | The workflow agent this entry counts. Null for the whole agent. |
AgentTraceOverviewEntryInput
AgentTraceOverviewEntryInputInput object type. One entry of a batched trace overview.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name |
workflowAgent | String | Count only this workflow agent's traces, as the workflowAgent trace filter does. Null counts the whole agent. Must not be blank, and at most 256 characters. |
GetAgentsTraceOverviewInput
GetAgentsTraceOverviewInputInput object type. Input parameters for GetAgentsTraceOverview query.
| Field | Type | Description |
|---|---|---|
traceTableMcon | String! | MCON of the ClickHouse trace table every agent is stored in |
agentNames | [String!] | Whole agents to read, at most 25, each at most 256 characters. Send exactly one of agentNames and agents. |
agents | [AgentTraceOverviewEntryInput!] | Agents or workflow agents to read: at most 25 distinct agent names, at most 201 distinct entries, and names whose query is at most 229376 bytes. One agent and 200 of its workflow agents fit at any length. Each agentName is at most 256 characters. A request over a limit is refused, not truncated. Send exactly one of agentNames and agents. |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (inclusive) |
includePreviousPeriodComparison | Boolean | Include the previous period of equal length (default: true) Default: true. |
Related types
getAgentTraceTables (query)
getAgentTraceTables is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get all agent trace tables
Returns
[AgentTraceTable!]!
Example
query GetAgentTraceTables {
getAgentTraceTables {
createdTime
updatedTime
id
uuid
spanFormat
recommendationsGeneratedAt
supportsConversationEval
supportsConversationClustering
supportsTokenMetrics
}
}Related types
getAvailablePlatformAgents (query)
getAvailablePlatformAgents is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get available agents in a warehouse by querying the platform directly
Arguments
| Argument | Type | Description |
|---|---|---|
connectionUuid | UUID | Source connection to discover agents on. |
connectionDataspace | String | Salesforce Data Cloud dataspace API name. |
platformAgentType | PlatformAgentType | Subtype to filter agents by. Omit to return every agent discoverable on the warehouse: the connection type fixes the platform family, so omitting the subtype lists all Databricks agents (both SDK and KA, tagged per-agent) for a Databricks warehouse — or all Snowflake agents for a Snowflake warehouse — in one call, never crossing platforms. |
warehouseUuid | UUID! | Warehouse UUID to filter agents by |
Returns
[AvailablePlatformAgentData!]!
Example
query GetAvailablePlatformAgents($warehouseUuid: UUID!) {
getAvailablePlatformAgents(warehouseUuid: $warehouseUuid) {
name
databaseName
schemaName
platformAgentType
displayName
tablePrefix
requiresManualTraceStorageSetup
traceTableIngested
}
}Types used only by getAvailablePlatformAgents
getAvailablePlatformAgentsAvailablePlatformAgentData
AvailablePlatformAgentDataObject type.
| Field | Type | Description |
|---|---|---|
name | String! | |
databaseName | String! | |
schemaName | String! | |
platformAgentType | PlatformAgentType! | |
displayName | String! | Human-friendly label for the agent — the Databricks Agent Bricks tile name for Knowledge-Assistant agents, falling back to name for SDK and Snowflake agents (which have no tile). Always populated; never null, so clients can render it directly without a null check. |
tablePrefix | String | |
requiresManualTraceStorageSetup | Boolean! | |
traceTableIngested | Boolean! | Whether the agent's real trace table has been catalogued by metadata collection yet. A surfaced status only — registration is NOT blocked when False; the real-table anchor links on catalog ingest. Always true for Snowflake agents, which have no separate trace table. |
Related types
getConversationClustering (query)
getConversationClustering is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Conversation-clustering panel for one (agent, scope) over the requested [startTime, endTime] window: enablement state, the space, per-cluster stats, eligible/classified coverage, and the requested aggregate metrics. Returns a result even before opt-in (state OPT_IN).
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetConversationsFiltersDataInput! | |
scopeWorkflow | String | Null = agent-wide taxonomy; a workflow selects that scope's taxonomy. |
facet | ClusteringFacet | Which facet's panel to read; defaults to INTENT. Alias the field twice to read both facets in one query. |
metrics | [ClusterMetricInput!] | Aggregates to compute per cluster, plus a baseline over the whole window. Omit it (or pass an empty list) to compute nothing — there is no default set, and metrics/baselineMetrics then come back empty. Duplicate pairs are collapsed. |
Returns
ConversationClusteringResult
Example
query GetConversationClustering($input: GetConversationsFiltersDataInput!) {
getConversationClustering(input: $input) {
state
eligibleConversationCount
classifiedConversationCount
}
}Types used only by getConversationClustering
getConversationClusteringClusterMetricInput
ClusterMetricInputInput object type. One aggregate to compute: a field paired with how to aggregate it. Any combination is accepted.
| Field | Type | Description |
|---|---|---|
field | ConversationMetricField! | The field to aggregate. |
aggregation | ConversationMetricAggregation! | How to aggregate it. |
ClusterShareDenominator
ClusterShareDenominatorEnum type. The conversations a cluster's sharePct is a percentage of. ELIGIBLE_CONVERSATIONS counts every conversation in the window; Issue cards use it. CLASSIFIED_CONVERSATIONS counts conversations with a cluster assignment; Intent cards and Uncategorized use it. RATED_CONVERSATIONS counts conversations an end user rated; the Negative feedback card uses it, because it can never exceed feedback coverage.
| Value | Description |
|---|---|
ELIGIBLE_CONVERSATIONS | |
CLASSIFIED_CONVERSATIONS | |
RATED_CONVERSATIONS |
ConversationClusterMetric
ConversationClusterMetricObject type. One computed aggregate. Echoes the requested (field, aggregation) pair so a caller can match a cluster's entry against the matching baseline entry.
| Field | Type | Description |
|---|---|---|
field | ConversationMetricField! | |
aggregation | ConversationMetricAggregation! | |
value | Float! | The raw aggregate value — deltas against the baseline are the caller's to compute. Seconds for the duration fields, a 0–1 fraction for AVG of HAS_ERRORS. |
ConversationClusterStat
ConversationClusterStatObject type. A cluster's windowed share of conversations (panel card).
| Field | Type | Description |
|---|---|---|
clusterKey | String! | Stable cluster slug. |
name | String! | Human-readable cluster name. |
description | String! | One-line summary of what belongs in this cluster. |
ordinal | Int! | Position within the cluster's source group — custom (USER) and discovered (AUTO) clusters carry independent sequences, so values repeat across groups. The list order (custom first, then discovered, Uncategorized last) is authoritative; don't re-sort by this field alone. |
source | ClusterSource! | Where this cluster came from. USER marks a custom (user-defined) cluster — pinned before discovered clusters and stable across taxonomy refreshes. |
conversationCount | Int! | Conversations assigned to this cluster in the window. |
sharePct | Float! | Percent of the shareDenominator conversations carrying this cluster's assignment. A conversation can carry more than one assignment, so cards can overlap and shares are not guaranteed to sum to 100. |
shareDenominator | ClusterShareDenominator! | Which conversations sharePct is a percentage of. |
shareDenominatorCount | Int! | The number of conversations sharePct divides by. |
condition | FilterGroup | The cluster's criteria as a filter tree — the payload the ops-agent hand-off carries. For an eval-monitor- or percentile-derived cluster this may hold a marker-bearing FilterSql or literal rather than an executable predicate. Null on LLM-derived clusters. |
rule | String | The cluster's membership criteria rendered for display, e.g. "duration_seconds greater than 42.0" for a plain-threshold rule cluster. An eval-monitor-derived cluster renders the literal "[custom SQL condition]" instead of a readable rule, and a percentile-derived cluster renders its still-unresolved marker rather than the resolved threshold. Null on LLM-derived clusters. |
metrics | [ConversationClusterMetric!]! | The requested aggregates for this cluster's conversations in the window. Empty when no metrics were requested, and when the cluster has no conversations in the window. |
ConversationClusteringResult
ConversationClusteringResultObject type. Conversation-clustering panel for one (agent, scope, window): enablement state, the space, per-cluster stats, and coverage.
| Field | Type | Description |
|---|---|---|
state | ConversationClusteringState! | Computed enablement state for the (agent, scope). |
space | ConversationClusteringSpaceType | The clustering space; null before opt-in (state OPT_IN). |
clusters | [ConversationClusterStat!]! | Per-cluster windowed stats incl. the synthetic Uncategorized bucket; empty until a taxonomy exists. |
eligibleConversationCount | Int! | Conversations in the window eligible for classification. On an issue space, this is the M in "N of M conversations carry at least one issue." |
classifiedConversationCount | Int! | Conversations in the window carrying a current-taxonomy cluster assignment. Classification runs on a schedule, so the most recently completed conversations are normally not classified yet and this trails eligibleConversationCount. On an issue space, rule evaluation writes no Uncategorized sentinel — a conversation matching no rule simply gets no assignment row — so this is exactly the N in "N of M conversations carry at least one issue." |
baselineMetrics | [ConversationClusterMetric!]! | The same requested aggregates over every eligible conversation in the window, assigned or not — the comparison point for each cluster's metrics. Empty when no metrics were requested, before a taxonomy exists, or when the window held no conversations. |
ConversationMetricAggregation
ConversationMetricAggregationEnum type. How a field is aggregated over a cluster's conversations. MEDIAN and P95 are approximate on ClickHouse-backed spaces — quantile samples past ~8k conversations per group, so values can shift slightly between identical reads.
| Value | Description |
|---|---|
MEDIAN | |
P95 | |
AVG |
ConversationMetricField
ConversationMetricFieldEnum type. A conversation-grain field a cluster aggregate is computed over. ACTIVE_DURATION_SECONDS is execution duration (per-turn processing time summed); DURATION_SECONDS is elapsed wall-clock duration; TOTAL_TOKENS is the platform-native token cost — not comparable across platforms, and 0 on platforms that report no token counts (check the agent's supportsTokenMetrics); TURN_COUNT is the conversation's turns; HAS_ERRORS is 1 when the conversation had errors and 0 otherwise, so its AVG is the error rate.
| Value | Description |
|---|---|
ACTIVE_DURATION_SECONDS | |
DURATION_SECONDS | |
TOTAL_TOKENS | |
TURN_COUNT | |
HAS_ERRORS |
Related types
ClusterSource, ClusteringFacet, ConversationClusteringSpaceType, ConversationClusteringState, FilterGroup, GetConversationsFiltersDataInput
getConversationClusteringSettings (query)
getConversationClusteringSettings is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Account-level conversation clustering settings.
Returns
ConversationClusteringSettings!
Example
query GetConversationClusteringSettings {
getConversationClusteringSettings {
snowflakeModelId
}
}Related types
ConversationClusteringSettings
getConversationClusteringSpaces (query)
getConversationClusteringSpaces is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
List conversation-clustering spaces for one facet of an agent + trace table, each with its current-version taxonomy clusters.
Arguments
| Argument | Type | Description |
|---|---|---|
agentName | String! | |
traceTableMcon | String! | |
facet | ClusteringFacet | Which facet's spaces to list; defaults to INTENT. Alias the field twice to read both facets in one query. |
before | String | |
after | String | |
first | Int | |
last | Int |
Returns
ConversationClusteringSpaceConnection
Example
query GetConversationClusteringSpaces($agentName: String!, $traceTableMcon: String!) {
getConversationClusteringSpaces(agentName: $agentName, traceTableMcon: $traceTableMcon) {
totalCount
}
}Types used only by getConversationClusteringSpaces
getConversationClusteringSpacesConversationClusteringSpaceConnection
ConversationClusteringSpaceConnectionObject type.
| Field | Type | Description |
|---|---|---|
pageInfo | PageInfo! | Pagination data for this connection. |
edges | [ConversationClusteringSpaceEdge]! | Contains the nodes in this connection. |
totalCount | Int! | Total spaces for the (agent, table). |
ConversationClusteringSpaceEdge
ConversationClusteringSpaceEdgeObject type. A Relay edge containing a ConversationClusteringSpace and its cursor.
| Field | Type | Description |
|---|---|---|
node | ConversationClusteringSpaceType | The item at the end of the edge |
cursor | String! | A cursor for use in pagination |
Related types
ClusteringFacet, ConversationClusteringSpaceType, PageInfo
getConversationEval (query)
getConversationEval is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Score a conversation across one or more rating dimensions (task completion, answer relevance, helpfulness, clarity, prompt adherence, language match, or a caller-supplied custom dimension). Each dimension returns an integer 1-5 score plus a short reasoning string. Results are ephemeral — every call regenerates.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetConversationEvalInput! |
Returns
ConversationEvalResult
Example
query GetConversationEval($input: GetConversationEvalInput!) {
getConversationEval(input: $input) {
conversationId
modelId
}
}Types used only by getConversationEval
getConversationEvalConversationEvalCustomDimensionInput
ConversationEvalCustomDimensionInputInput object type. Caller-supplied custom rubric for an inline eval dimension.
| Field | Type | Description |
|---|---|---|
name | String! | Display label for the custom dimension; echoed back on the result. |
criteria | String! | Free-text rubric the judge will score on. Interpolated into a fixed 1-5 scoring scaffold; the underlying prompt is not exposed in the response. |
ConversationEvalDimension
ConversationEvalDimensionObject type. One dimension's outcome. Either (score + reasoning) or error is set.
| Field | Type | Description |
|---|---|---|
templateName | String | Name of the built-in dimension scored, or null when the dimension is custom. |
customName | String | Caller-supplied display label, or null when the dimension is built-in. |
score | Int | Integer score 1-5; null when error is set. |
reasoning | String | Short explanation for the score; null when error is set. |
error | ConversationEvalDimensionError | Failure detail for this dimension; null on success. |
ConversationEvalDimensionError
ConversationEvalDimensionErrorObject type.
| Field | Type | Description |
|---|---|---|
kind | String! | Failure category for this dimension. |
message | String! | Human-readable failure detail. |
ConversationEvalDimensionInput
ConversationEvalDimensionInputInput object type. One requested dimension on getConversationEval.
Exactly one of templateName or custom must be set. Caller-input
mistakes (unknown template, both/neither set, oversize custom criteria)
abort the entire request via a top-level GraphQL error. Per-dimension
error fields in the result are reserved for execution failures
(warehouse evaluation timeout, malformed model response).
| Field | Type | Description |
|---|---|---|
templateName | String | Name of a built-in conversation-eval dimension to score against (e.g. task_completion_conversation, helpfulness_conversation). |
custom | ConversationEvalCustomDimensionInput | Inline custom criteria. Mutually exclusive with templateName. |
ConversationEvalResult
ConversationEvalResultObject type. Result of getConversationEval: one row per requested dimension.
| Field | Type | Description |
|---|---|---|
conversationId | String! | Conversation id evaluated |
modelId | String! | Model id used for the evaluations |
evalDimensions | [ConversationEvalDimension!]! | One entry per requested eval dimension, in request order. |
GetConversationEvalInput
GetConversationEvalInputInput object type. Input for getConversationEval query.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name |
traceTableMcon | String! | MCON of the trace table or platform agent |
conversationId | String! | Conversation id to score |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (inclusive) |
evalDimensions | [ConversationEvalDimensionInput!]! | One to 7 eval dimensions to apply. Results are returned in the same order as the requested dimensions. |
Related types
getConversationExplanation (query)
getConversationExplanation is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Generate an AI explanation of a full conversation across all its turns. Each call regenerates — explanations are not persisted.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetConversationExplanationInput! |
Returns
ConversationExplanationResult
Example
query GetConversationExplanation($input: GetConversationExplanationInput!) {
getConversationExplanation(input: $input) {
conversationId
summary
modelId
}
}Types used only by getConversationExplanation
getConversationExplanationConversationExplanationResult
ConversationExplanationResultObject type. Result of getConversationExplanation: an AI-authored summary of one conversation.
| Field | Type | Description |
|---|---|---|
conversationId | String! | Conversation id |
summary | String! | Explanation of the conversation — a single comprehensive markdown paragraph covering what the user was trying to accomplish, the steps the agent took across turns, errors encountered, slow calls, and the outcome. Identifiers are wrapped in inline code; the paragraph does not use headings, fenced code blocks, or lists. |
modelId | String! | Identifier of the LLM that produced this explanation |
GetConversationExplanationInput
GetConversationExplanationInputInput object type. Input for getConversationExplanation query.
Related types
getConversationMessageContentV2 (query)
getConversationMessageContentV2 is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Fetch a single chunk of full message content for a cached conversation-thread V2 snapshot.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetConversationMessageContentV2Input! |
Returns
ConversationMessageContentChunkV2
Example
query GetConversationMessageContentV2($input: GetConversationMessageContentV2Input!) {
getConversationMessageContentV2(input: $input) {
messageId
chunkIndex
chunkCount
content
hasMore
}
}Types used only by getConversationMessageContentV2
getConversationMessageContentV2ConversationMessageContentChunkV2
ConversationMessageContentChunkV2Object type. A chunk of full message content from a cached conversation snapshot.
| Field | Type | Description |
|---|---|---|
messageId | String! | Opaque message ID |
chunkIndex | Int! | Zero-based chunk index |
chunkCount | Int! | Total number of chunks |
content | String! | Chunk content |
hasMore | Boolean! | Whether another chunk is available |
GetConversationMessageContentV2Input
GetConversationMessageContentV2InputInput object type. Input for getConversationMessageContentV2 query.
| Field | Type | Description |
|---|---|---|
snapshotId | String! | Snapshot ID from getConversationThreadV2 |
messageId | String! | Opaque message ID from the thread summary |
chunkIndex | Int! | Zero-based chunk index to fetch |
getConversationOverview (query)
getConversationOverview is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Conversation counts, durations, root errors, and turn tokens over matching traces in a window with an exclusive end. Conversations need at least one trace with messages or tool calls. totalConversations equals getTraceOverview.totalConversations for the same input. Filters select turns before conversation grouping. Comparison includes the preceding window of equal length.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetConversationOverviewInput! | Conversation window and filters |
Returns
ConversationOverviewMetricsWithComparison!
Example
query GetConversationOverview($input: GetConversationOverviewInput!) {
getConversationOverview(input: $input) {
totalConversations
erroredConversations
errorRate
avgDurationSeconds
p95DurationSeconds
totalTokens
avgTokensPerConversation
}
}Types used only by getConversationOverview
getConversationOverviewConversationOverviewMetrics
ConversationOverviewMetricsObject type.
| Field | Type | Description |
|---|---|---|
totalConversations | Int! | Conversations with messages or tool calls from traces matching the filters and time range. The end time is excluded. Equals getTraceOverview.totalConversations for the same input. |
erroredConversations | Int! | Conversations with an errored root span in at least one matching turn in the window. Child-span errors alone do not count. |
errorRate | Float | Errored conversations as a percentage (0-100) of all conversations. Null when there are no conversations. |
avgDurationSeconds | Float | Mean wall-clock duration in seconds, from the first turn start to the last turn end within the window. Idle time between turns counts. |
p95DurationSeconds | Float | 95th percentile of seconds from first turn start to last turn end within the window, including idle time between turns. |
totalTokens | BigInt | Sum of turn token counts. Null on platforms without token counts and when no conversation has token data. Zero means zero tokens. |
avgTokensPerConversation | Float | Mean summed turn tokens per conversation with token data. Null on platforms without token counts and when no conversation has token data. Zero means zero tokens. |
ConversationOverviewMetricsWithComparison
ConversationOverviewMetricsWithComparisonObject type.
| Field | Type | Description |
|---|---|---|
totalConversations | Int! | Conversations with messages or tool calls from traces matching the filters and time range. The end time is excluded. Equals getTraceOverview.totalConversations for the same input. |
erroredConversations | Int! | Conversations with an errored root span in at least one matching turn in the window. Child-span errors alone do not count. |
errorRate | Float | Errored conversations as a percentage (0-100) of all conversations. Null when there are no conversations. |
avgDurationSeconds | Float | Mean wall-clock duration in seconds, from the first turn start to the last turn end within the window. Idle time between turns counts. |
p95DurationSeconds | Float | 95th percentile of seconds from first turn start to last turn end within the window, including idle time between turns. |
totalTokens | BigInt | Sum of turn token counts. Null on platforms without token counts and when no conversation has token data. Zero means zero tokens. |
avgTokensPerConversation | Float | Mean summed turn tokens per conversation with token data. Null on platforms without token counts and when no conversation has token data. Zero means zero tokens. |
prevPeriod | ConversationOverviewMetrics | The same metrics for the preceding period of equal length. Null when comparison is disabled; never null when it is enabled. |
GetConversationOverviewInput
GetConversationOverviewInputInput object type. Conversation metrics over traces selected before grouping into conversations.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent to query |
startTime | DateTime! | Start of the window, inclusive |
endTime | DateTime! | End of the window, exclusive |
includePreviousPeriodComparison | Boolean | True, null, or omitted includes the preceding window of equal length. prevPeriod is always present when comparison is on. False disables comparison. Default: true. |
filters | TraceFiltersInput | Select traces before grouping into conversations. Metrics use only matching turns. |
segmentFilter | TraceSegmentFilterInput | Restrict traces by MODEL, WORKFLOW, or TASK before grouping into conversations. Metrics use only matching turns. Omitted or null selects all traces. |
Related types
BigInt, DateTime, TraceFiltersInput, TraceSegmentFilterInput
Source: The GraphQL API reference
This page is generated from the GraphQL schema on each release. Changes made in ReadMe are overwritten.
