---
title: "Gets a ranking group's context and the votes each of its datapoints received against every opponent."
method: GET
path: "/job/{jobId}/results/groups/{groupId}/head-to-head"
tags: ["Job"]
---

# Gets a ranking group's context and the votes each of its datapoints received against every opponent.

`GET /job/{jobId}/results/groups/{groupId}/head-to-head`

## Request

- Base URL: `https://api.rapidata.ai`
- URL: `https://api.rapidata.ai/job/{jobId}/results/groups/{groupId}/head-to-head`
- Auth: one of:
  - OpenID Connect (`https://auth.rapidata.ai/.well-known/openid-configuration`, scopes: `job:read`)
  - OpenID Connect (`https://auth.rapidata.ai/.well-known/openid-configuration`, scopes: `api`)
  - none
- TypeScript: <https://skmtc.dev/rapidata/apis/rapidata-api/docs/job/:jobId/results/groups/:groupId/head-to-head/get.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `jobId` string, required
- `groupId` string, required

## Response `200`

OK

- GetJobRankingGroupHeadToHeadEndpointOutput
  - `context` string, nullable: The text context shared by every comparison in the group.
  - `contextAsset` union
    - object
      - `_t` 'FileAsset', required
      - `fileName` string, required
      - `metadata` MetadataModelCollection, required
      - `identifier` string, required
    - object
      - `_t` 'MultiAsset', required
      - `assets` IAsset[], required
      - `metadata` MetadataModelCollection, required
      - `identifier` string, required
    - object
      - `_t` 'NullAsset', required
      - `metadata` MetadataModelCollection, required
      - `identifier` string, required
    - object
      - `_t` 'TextAsset', required
      - `text` string, required
      - `translatedText` object, nullable
        - `wasTranslated` boolean
        - `englishText` string, required
        - `text` string, required
        - `targetLanguage` string, required
      - `metadata` MetadataModelCollection, required
      - `identifier` string, required
  - `headToHead` GetJobRankingGroupHeadToHeadEndpointOutputGrid
    - `datapoints` GetJobRankingGroupHeadToHeadEndpointOutputGridDatapoint[], required
      - `datapointId` string, required
      - `asset` union, required
        - object
          - `_t` 'FileAsset', required
          - `fileName` string, required
          - `metadata` MetadataModelCollection, required
          - `identifier` string, required
        - object
          - `_t` 'MultiAsset', required
          - `assets` IAsset[], required
          - `metadata` MetadataModelCollection, required
          - `identifier` string, required
        - object
          - `_t` 'NullAsset', required
          - `metadata` MetadataModelCollection, required
          - `identifier` string, required
        - object
          - `_t` 'TextAsset', required
          - `text` string, required
          - `translatedText` object, nullable
            - `wasTranslated` boolean
            - `englishText` string, required
            - `text` string, required
            - `targetLanguage` string, required
          - `metadata` MetadataModelCollection, required
          - `identifier` string, required
    - `rows` GetJobRankingGroupHeadToHeadEndpointOutputGridRow[], required
      - `datapointId` string, required
      - `cells` GetJobRankingGroupHeadToHeadEndpointOutputGridRowCell[], required
        - `opponentId` string, required
        - `votesFor` integer, required
        - `votesAgainst` integer, required

## Other responses

- `400`: Bad Request
- `401`: Unauthenticated
- `403`: Forbidden

## Changes

- **2026-11-10** `850bce79ea7f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/rapidata/apis/rapidata-api/changes/job/:jobId/results/groups/:groupId/head-to-head/get.md)

---

[API](https://skmtc.dev/rapidata/apis/rapidata-api.md) - [All operations](https://skmtc.dev/rapidata/apis/rapidata-api/llms.txt) - [OpenAPI document](https://skmtc.dev/rapidata/apis/rapidata-api/revisions/850bce79ea7f?raw)
