/get-grades

Retrieve the graded results for a specific quiz by ID. Filter by student using a primaryKey.

Input Parameters

Parameter
Type
Description

quizId

String

The unique identifier for the quiz.

primaryKey

String

The primary key for the student. Optional: if no PK is passed, we will fetch ALL submissions for this quiz.

Example Request

// Example to get grades
fetch("https://api.arlinear.com/functions/v1/get-grades", {
  method: "POST",
  headers: {
    Authorization: "<Your API Key>",
  },
  body: JSON.stringify({
    quizId: "ba777045-7033-4701-b17b-da9e90dcd41e",
    primaryKey: "emily@school.com", // optional: if no PK is passed, we will fetch ALL submissions for this quiz
  }),
});

Example Return Value

Returns a list of quiz submissions.

  • primaryKey: The primary key for the student.

  • score: Total points scored.

  • scoreOutOf: Maximum possible points.

  • createdAt : Date when the student submitted the quiz.

  • corrections: An array of corrections for each question.

Note: if no primaryKey is passed, we will fetch ALL submissions for this quiz.

[
  {
    "primaryKey": "emily@school.com",
    "score": 8,
    "scoreOutOf": 10,
    "createdAt": "2023-11-17T20:20:29.644882+00:00",
    "corrections": [
      {
    	  "studentInput": "y=6",
    	  "score":  1,
    	  "scoreOutOf":  1,
    	  "feedback":  "Correct answer. Great job!"
      },
      ...
     ]
  }
]

Last updated