Alexa.Education.Grade.Coursework Interface

Implement the Alexa.Education.Grade.Coursework interface in your Alexa education skill to provide a list of graded coursework for a given student or course. For more information about education skills, see About Alexa Education Skills.

For the list of languages that the Grade.Coursework interface supports, see List of Alexa Interfaces and Supported Languages.

Utterances

When you use the Alexa.Education.Grade.Coursework interface, the voice interaction model is already built for you. The following examples show some user utterances:

Alexa, what did I get on my chemistry assignment?
Alexa, what did Hannah get on her history paper?
Alexa, how did Derrick do on his math test?

Request

The Get request queries a list of graded coursework for a given student or course. The request payload contains the necessary attributes for filtering and pagination. This request has query parameters to filter for studentId (required), courseworkType (optional), and courseId (optional). The results must be sorted based on recency of the grades.

If there's more than one student associated with the account and the user doesn't specify the student, Alexa asks the user for clarification, and then includes the appropriate studentId in the request to your skill. In other words, your skill doesn't need to discern whether there's more than one student associated with the account, it just needs to return the results for the specified studentId.

The payload of the Get request contains the following fields.

Field Description Type

paginationContext

Pagination information

PaginationContext object for requests

query

Match-all query parameters to filter for studentId (required), courseworkType (optional) and courseId (optional).

Object

locale

Locale that identifies the user's language

string enum

The following is an example of a Get request.

{
  "request": {
    "header": {
      "namespace": "Alexa.Education.Grade.Coursework",
      "name": "Get",
      "messageId": "ExampleMessageID",
      "interfaceVersion": "1.0"
    },
    "authorization": {
      "type": "BearerToken",
      "token": "ExampleBearerToken"
    },
    "payload": {
      "paginationContext": {
        "maxResults": 5,
        "nextToken": "ExampleNextToken"
      },
      "query": {
        "matchAll": {
          "studentId": "1184",
          "courseId": "course_001",
          "courseworkType": "ASSIGNMENT"
        }
      },
      "locale": "en-US"
    }
  }
}

Response

If you handle a Get request successfully, respond with a GetResponse object.

The payload of a GetResponse object contains the following fields.

Field Description Type Required

paginationContext

Pagination information

PaginationContext object for responses

No

courseworkGrades

The results of the query

Array of CourseworkGrade objects

Yes

The following is an example of GetResponse.

Copied to clipboard.

{
  "response": {
    "header": {
      "namespace": "Alexa.Education.Grade.Coursework",
      "name": "GetResponse",
      "messageId": "ExampleMessageID",
      "interfaceVersion": "1.0"
    },
    "payload": {
      "paginationContext": {
        "totalCount": 1
      },
      "courseworkGrades": [
        {
          "courseworkId": "assignment_001",
          "courseId": "course_001",
          "courseName": "English Language Arts Standards",
          "studentId": "student_001",
          "courseworkType": "ASSIGNMENT",
          "courseworkTitle": "Quiz 1",
          "grade": {
            "overallGrade": {
              "gradeScore": {
                "type": "PERCENTAGE",
                "score": 90
              }
            },
            "standardGrades": [
              {
                "name": "Demonstrate understanding of key details in a text.",
                "gradeScore": {
                  "type": "POINTS",
                  "score": 3,
                  "maxPoints": 4
                }
              },
              {
                "name": "Recount stories and determine their central message, lesson, or moral.",
                  "gradeScore": {
                    "type": "POINTS",
                    "score": 4,
                    "maxPoints": 4
                  }
              }
            ]
          },
          "lastGradedTime": "2019-04-12T00:00:00Z"
        },
        {
          "courseworkId": "quiz_001",
          "courseId": "course_001",
          "courseName": "Math 101",
          "studentId": "student_001",
          "courseworkType": "ASSESSMENT",
          "courseworkTitle": "Homework 1",
          "grade": {
            "standardGrades": [
              {
                "name": "Make sense of problems and persevere in solving them",
                "gradeScore": {
                  "type": "RUBRIC",
                  "score": "Advanced"
                }
              },
              {
                "name": "Reason abstractly and quantitatively",
                "gradeScore": {
                  "type": "RUBRIC",
                  "score": "Proficient"
                }
              },
              {
                "name": "Construct viable arguments and critique the reasoning of others",
                "gradeScore": {
                  "type": "RUBRIC",
                  "score": "Advanced"
                }
              }
            ],
            "lastGradedTime": "2019-04-12T00:00:00Z"
          }
         }
      ]
    }
  }
}