CumulusDocs
Open Studio
On this page

Get a version comparison

Read a comparison and its per-case verdicts.

Operation ID: comparisons.get.

Request

GET /api/v1/comparisons/{comparison_id}

  • TypeScript SDK: client.comparisons.get (path arguments use path).
  • MCP tool: sdk_client_call with operationId: "comparisons.get" (path arguments use input.path). Legacy alias: comparisons_get. Connect to your authenticated /mcp endpoint with an API key for the same environment.
  • Minimum API key role: viewer.
  • Idempotency: No idempotency header required.

Read resource IDs from earlier responses and use a key for the same environment.

Request example

Set each path variable to an ID returned by an earlier API request.

Set CUMULUS_BASE_URL to your workspace API URL and CUMULUS_API_KEY to a key for that environment. Example values are synthetic.

cURL

curl
curl --fail-with-body -sS "${CUMULUS_BASE_URL%/}/api/v1/comparisons/${COMPARISON_ID}" \
  -H "Authorization: Bearer $CUMULUS_API_KEY"

TypeScript

typescript
import { Cumulus } from "@cumulus/sdk";

const baseUrl = process.env.CUMULUS_BASE_URL;
const apiKey = process.env.CUMULUS_API_KEY;
if (!baseUrl || !apiKey) throw new Error("Set CUMULUS_BASE_URL and CUMULUS_API_KEY");
const client = new Cumulus({ baseUrl, apiKey });

const response = await client.comparisons.get({
  "path": {
    "comparison_id": "<comparison_id>"
  }
});

Input schema

Path, query and header parameters

comparison_id

path parameter · Required.

Type: string (uuid). pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.

JSON request body

This operation has no JSON request body.

Complete OpenAPI schema
OpenAPI JSON
{
  "parameters": [
    {
      "name": "comparison_id",
      "in": "path",
      "required": true,
      "schema": {
        "type": "string",
        "format": "uuid",
        "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
      }
    }
  ],
  "requestBody": null
}

Responses

HTTP 200

Get one comparison with its per-case verdicts

application/json

FieldType or valuesRequiredDescription and limits
comparisonobjectRequired—
comparison.owner_idstringRequiredminLength: 1.
comparison.environmentstringRequiredminLength: 1.
comparison.tenant_idstring (uuid)Requiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
comparison.comparison_idstring (uuid)Requiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
comparison.agent_idstringRequiredAgent identifier in the environment selected by your API key. minLength: 1. maxLength: 256. pattern: ^[A-Za-z0-9][A-Za-z0-9_.:-]*$.
comparison.baselineobjectRequired—
comparison.baseline.agent_idstringRequiredAgent identifier in the environment selected by your API key. minLength: 1. maxLength: 256. pattern: ^[A-Za-z0-9][A-Za-z0-9_.:-]*$.
comparison.baseline.versionintegerRequiredAt least 0. At most 2147483647.
comparison.baseline.digeststringRequiredpattern: ^sha256:[a-f0-9]{64}$.
comparison.candidateobjectRequired—
comparison.candidate.agent_idstringRequiredAgent identifier in the environment selected by your API key. minLength: 1. maxLength: 256. pattern: ^[A-Za-z0-9][A-Za-z0-9_.:-]*$.
comparison.candidate.versionintegerRequiredAt least 0. At most 2147483647.
comparison.candidate.digeststringRequiredpattern: ^sha256:[a-f0-9]{64}$.
comparison.case_run_idsarray of string (uuid)RequiredminItems: 1. maxItems: 200.
comparison.state"queued" · "running" · "completed" · "failed" · "uncertain"Required—
comparison.summaryobject or nullRequired—
comparison.summary.casesintegerRequired in a non-null parentAt least -9007199254740991. At most 9007199254740991.
comparison.summary.candidate_winsintegerRequired in a non-null parentAt least -9007199254740991. At most 9007199254740991.
comparison.summary.baseline_winsintegerRequired in a non-null parentAt least -9007199254740991. At most 9007199254740991.
comparison.summary.tiesintegerRequired in a non-null parentAt least -9007199254740991. At most 9007199254740991.
comparison.summary.unscoredintegerRequired in a non-null parentAt least -9007199254740991. At most 9007199254740991.
comparison.rubricobjectRequired—
comparison.rubric.idstringRequiredminLength: 1. maxLength: 128.
comparison.rubric.versionintegerRequiredGreater than 0. At most 9007199254740991.
comparison.judge_modelobjectRequired—
comparison.judge_model.model_idstringRequiredminLength: 1. pattern: \S.
comparison.judge_model.providerstringRequiredminLength: 1. pattern: \S.
comparison.judge_model.tier"frontier" · "cumulus-served" · "customer-gpu"Required—
comparison.error_codestring or nullRequiredmaxLength: 128.
comparison.finished_atstring (date-time) or nullRequiredpattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:.\d+)?(?:Z))$.
comparison.created_byobjectRequired—
comparison.created_by · variant 1object—Fields for this schema branch.
comparison.created_by.owner_idstringRequiredminLength: 1.
comparison.created_by.environmentstringRequiredminLength: 1.
comparison.created_by.kind"user"Required—
comparison.created_by.idstring (uuid)Requiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
comparison.created_by · variant 2object—Fields for this schema branch.
comparison.created_by.owner_idstringRequiredminLength: 1.
comparison.created_by.environmentstringRequiredminLength: 1.
comparison.created_by.kind"api_key"Required—
comparison.created_by.idstring (uuid)Requiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
comparison.created_by · variant 3object—Fields for this schema branch.
comparison.created_by.owner_idstringRequiredminLength: 1.
comparison.created_by.environmentstringRequiredminLength: 1.
comparison.created_by.kind"system"Required—
comparison.created_by.idstringRequiredminLength: 1. maxLength: 256.
comparison.created_atstring (date-time)Requiredpattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:.\d+)?(?:Z))$.
casesarray of objectRequiredmaxItems: 200.
cases[].ordinalintegerRequiredAt least 0. At most 199.
cases[].source_run_idstring (uuid)Requiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
cases[].baseline_run_idstring (uuid) or nullRequiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
cases[].candidate_run_idstring (uuid) or nullRequiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
cases[].state"pending" · "running" · "judging" · "settled" · "failed" · "uncertain"Required—
cases[].verdict"candidate" · "baseline" · "tie" or nullRequired—
cases[].baseline_scorenumber or nullRequiredAt least 0. At most 1.
cases[].candidate_scorenumber or nullRequiredAt least 0. At most 1.
cases[].judge_measurement_idstring (uuid) or nullRequiredpattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$.
cases[].error_codestring or nullRequiredmaxLength: 128.
cases[].content_state"retained" · "expired"Required—

Error responses

HTTPDescription
4XXTyped error (ApiError)
5XXTyped error (ApiError)

Errors use the shared error envelope. Inspect error.code, retryable, outcome and details before retrying.

Complete OpenAPI schema
OpenAPI JSON
{
  "200": {
    "description": "Get one comparison with its per-case verdicts",
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/ComparisonsGetResponse200"
        }
      }
    }
  },
  "4XX": {
    "description": "Typed error (ApiError)",
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/ApiError"
        }
      }
    }
  },
  "5XX": {
    "description": "Typed error (ApiError)",
    "content": {
      "application/json": {
        "schema": {
          "$ref": "#/components/schemas/ApiError"
        }
      }
    }
  }
}

Referenced schemas

Expand the complete OpenAPI definitions for integrations that generate their own clients.

Complete OpenAPI schema
OpenAPI JSON
{
  "components": {
    "schemas": {
      "ComparisonsGetResponse200": {
        "type": "object",
        "properties": {
          "comparison": {
            "$ref": "#/components/schemas/Comparison"
          },
          "cases": {
            "maxItems": 200,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "ordinal": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 199
                },
                "source_run_id": {
                  "type": "string",
                  "format": "uuid",
                  "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
                },
                "baseline_run_id": {
                  "nullable": true,
                  "type": "string",
                  "format": "uuid",
                  "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
                },
                "candidate_run_id": {
                  "nullable": true,
                  "type": "string",
                  "format": "uuid",
                  "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "running",
                    "judging",
                    "settled",
                    "failed",
                    "uncertain"
                  ]
                },
                "verdict": {
                  "nullable": true,
                  "type": "string",
                  "enum": [
                    "candidate",
                    "baseline",
                    "tie"
                  ]
                },
                "baseline_score": {
                  "nullable": true,
                  "type": "number",
                  "minimum": 0,
                  "maximum": 1
                },
                "candidate_score": {
                  "nullable": true,
                  "type": "number",
                  "minimum": 0,
                  "maximum": 1
                },
                "judge_measurement_id": {
                  "nullable": true,
                  "type": "string",
                  "format": "uuid",
                  "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
                },
                "error_code": {
                  "nullable": true,
                  "type": "string",
                  "maxLength": 128
                },
                "content_state": {
                  "type": "string",
                  "enum": [
                    "retained",
                    "expired"
                  ]
                }
              },
              "required": [
                "ordinal",
                "source_run_id",
                "baseline_run_id",
                "candidate_run_id",
                "state",
                "verdict",
                "baseline_score",
                "candidate_score",
                "judge_measurement_id",
                "error_code",
                "content_state"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": [
          "comparison",
          "cases"
        ],
        "additionalProperties": false
      },
      "Comparison": {
        "type": "object",
        "properties": {
          "owner_id": {
            "type": "string",
            "minLength": 1
          },
          "environment": {
            "type": "string",
            "minLength": 1
          },
          "tenant_id": {
            "type": "string",
            "format": "uuid",
            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
          },
          "comparison_id": {
            "type": "string",
            "format": "uuid",
            "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
          },
          "agent_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256,
            "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]*$"
          },
          "baseline": {
            "$ref": "#/components/schemas/PublicationRef"
          },
          "candidate": {
            "$ref": "#/components/schemas/PublicationRef"
          },
          "case_run_ids": {
            "minItems": 1,
            "maxItems": 200,
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid",
              "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
            }
          },
          "state": {
            "type": "string",
            "enum": [
              "queued",
              "running",
              "completed",
              "failed",
              "uncertain"
            ]
          },
          "summary": {
            "nullable": true,
            "type": "object",
            "properties": {
              "cases": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "candidate_wins": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "baseline_wins": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "ties": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "unscored": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "cases",
              "candidate_wins",
              "baseline_wins",
              "ties",
              "unscored"
            ],
            "additionalProperties": false
          },
          "rubric": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              },
              "version": {
                "type": "integer",
                "minimum": 0,
                "exclusiveMinimum": true,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "id",
              "version"
            ],
            "additionalProperties": false
          },
          "judge_model": {
            "$ref": "#/components/schemas/ModelIdentity"
          },
          "error_code": {
            "nullable": true,
            "type": "string",
            "maxLength": 128
          },
          "finished_at": {
            "nullable": true,
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
          },
          "created_by": {
            "$ref": "#/components/schemas/PrincipalRef"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
          }
        },
        "required": [
          "owner_id",
          "environment",
          "tenant_id",
          "comparison_id",
          "agent_id",
          "baseline",
          "candidate",
          "case_run_ids",
          "state",
          "summary",
          "rubric",
          "judge_model",
          "error_code",
          "finished_at",
          "created_by",
          "created_at"
        ],
        "additionalProperties": false
      },
      "PublicationRef": {
        "type": "object",
        "properties": {
          "agent_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256,
            "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]*$"
          },
          "version": {
            "type": "integer",
            "minimum": 0,
            "maximum": 2147483647
          },
          "digest": {
            "type": "string",
            "pattern": "^sha256:[a-f0-9]{64}$"
          }
        },
        "required": [
          "agent_id",
          "version",
          "digest"
        ],
        "additionalProperties": false
      },
      "ModelIdentity": {
        "type": "object",
        "properties": {
          "model_id": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          },
          "provider": {
            "type": "string",
            "minLength": 1,
            "pattern": "\\S"
          },
          "tier": {
            "type": "string",
            "enum": [
              "frontier",
              "cumulus-served",
              "customer-gpu"
            ]
          }
        },
        "required": [
          "model_id",
          "provider",
          "tier"
        ],
        "additionalProperties": false
      },
      "PrincipalRef": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "owner_id": {
                "type": "string",
                "minLength": 1
              },
              "environment": {
                "type": "string",
                "minLength": 1
              },
              "kind": {
                "type": "string",
                "enum": [
                  "user"
                ]
              },
              "id": {
                "type": "string",
                "format": "uuid",
                "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
              }
            },
            "required": [
              "owner_id",
              "environment",
              "kind",
              "id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "owner_id": {
                "type": "string",
                "minLength": 1
              },
              "environment": {
                "type": "string",
                "minLength": 1
              },
              "kind": {
                "type": "string",
                "enum": [
                  "api_key"
                ]
              },
              "id": {
                "type": "string",
                "format": "uuid",
                "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
              }
            },
            "required": [
              "owner_id",
              "environment",
              "kind",
              "id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "owner_id": {
                "type": "string",
                "minLength": 1
              },
              "environment": {
                "type": "string",
                "minLength": 1
              },
              "kind": {
                "type": "string",
                "enum": [
                  "system"
                ]
              },
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 256
              }
            },
            "required": [
              "owner_id",
              "environment",
              "kind",
              "id"
            ],
            "additionalProperties": false
          }
        ]
      },
      "ApiError": {
        "type": "object",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": [
                  "unauthenticated",
                  "forbidden",
                  "not_found",
                  "conflict",
                  "invalid_request",
                  "idempotency_conflict",
                  "policy_denied",
                  "capability_unavailable",
                  "provider_unavailable",
                  "knowledge_unavailable",
                  "publication_invalid",
                  "run_not_active",
                  "rate_limited",
                  "outcome_unknown",
                  "internal"
                ]
              },
              "message": {
                "type": "string"
              },
              "retryable": {
                "type": "boolean"
              },
              "outcome": {
                "type": "string",
                "enum": [
                  "none",
                  "unknown"
                ]
              },
              "details": {
                "type": "object",
                "additionalProperties": {}
              }
            },
            "required": [
              "code",
              "message",
              "retryable",
              "outcome"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "error"
        ],
        "additionalProperties": false
      }
    }
  }
}

Errors and recovery

See API error handling and Troubleshooting.

Content version 8aa42144Customer SDKMarkdown source
Get a version comparison · Cumulus developer docs