Endpoint: Fetching Answers of a Test Instance

Endpoint: Fetching Answers of a Test Instance
This endpoint is in beta stage. 
Its implementation is subject to change.
GET /api/integration/rest/v1/tasks/:taskId/test-instances/:id/answers

This endpoint lets you fetch the answers a candidate has given in a test instance.

Query ParametersExpected ValueDefault
mode"basic" | "detailed""basic"

With the "mode" parameter, you can choose to receive a smaller or a bigger object for each task, depending on your needs.

Response

Upon a successful request, the following response will be returned.

{
  answers: (Basic | Detailed)[];
}

If mode is set to "basic", the answer object will be in the following shape:

// "basic" answer object
{
    sectionIndex: number;
    sectionNo: number;
    pageNo: number;
    pageNoInSection: number;
    questionNo: number;
    questionNoInSection: number;
    questionNoInPage: number;
    questionReference: {
      kind: "questionbank";
      organizationId: string;
      questionId: string;
    } | {
      kind: "questionbox";
      questionBoxUUID: string;
    }
    required: boolean;
    effective: boolean;
    question: {
      kind: "multiplechoice";
      text: string;
      answer: {
        valid: boolean;
        score: number; // between -1 and 1
        pointsAchieved: number; // score * (+/- multiplier)
        choices: {
          text: string;
        }[];
      } | null;
    } | {
      kind: "match";
      text: string;
      answer: {
        valid: boolean;
        score: number; // between -1 and 1
        pointsAchieved: number; // score * (+/- multiplier)
        matches: { 
          item: string;
          option: string; 
        }[];
      } | null;
    } | {
      kind: "input";
      text: string;
      type: "field" | "area" | "audio" | "video" | "code" 
        | "rich" | "file" | "photo" | "numeric" | "tabular";
      answer: {
        valid: boolean;
        score: number; // between -1 and 1
        pointsAchieved: number; // score * (+/- multiplier)
        value: string | null;
      } | null;
    };
}

If mode is set to "detailed", the answer object will have some additional properties. It will be in the following shape:

// "detailed" answer object
Basic & {
    sectionUuid: string;
    pageUuid: string;
}
Created on 2026/01/30 Updated on 2026/02/26 Share
Go Back

Talk to a representative

Discover how TestInvite can support your organization’s assessment goals