Docs home

Get Batch Class Section Details

Returns the exercises and materials in one section of a class, with the learner's attempts, grades and views, plus section progress. Use it to show the items inside a section.

GET/student/sections/{SectionId}/resources
Get Batch Class Section Details
curl --request GET \
  --url 'https://<your-api-host>/nuSource/api/v1/student/sections/{SectionId}/resources?class_id=<ClassId>'
{
  "code": 200,
  "message": "Success",
  "resources": [
    [
      5,
      686,
      18557,
      "! only",
      0,
      0,
      0,
      0,
      1,
      0,
      0,
      1,
      1,
      0,
      0,
      0
    ],
    [
      5,
      694,
      18591,
      "Test later",
      0,
      0,
      0,
      0,
      1,
      0,
      0,
      0,
      1,
      0,
      0,
      0
    ],
    [
      4,
      12089,
      18636,
      "asdfasdfasdf",
      "",
      0,
      0,
      1,
      0,
      0,
      -1,
      1,
      0,
      "html_text",
      0,
      1
    ],
    [
      4,
      12090,
      18638,
      "VImeo Test",
      "video/mp4",
      1,
      0,
      1,
      0,
      0,
      -1,
      1,
      0,
      "file",
      0,
      0
    ],
    [
      4,
      12091,
      18639,
      "VImeo Iskon",
      "video/mp4",
      1,
      0,
      1,
      0,
      0,
      -1,
      1,
      0,
      "file",
      0,
      0
    ],
    [
      5,
      725,
      18668,
      "teadf",
      0,
      0,
      0,
      0,
      1,
      0,
      0,
      1,
      2,
      0,
      0,
      1
    ]
  ],
  "section": {
    "id": 5284,
    "name": "CHINTA",
    "description": "",
    "c_num_users": 7,
    "num_exercises": 3,
    "num_materials": 3,
    "cs_attempts": 0,
    "cs_passed": 0,
    "cs_perfect": 0,
    "cs_mat_views": 0,
    "freepreview": 0,
    "cs_mat_uviews": 0,
    "user_mat_uviews": 0,
    "user_passed": 0,
    "is_prerequisite": 0,
    "progress": 0
  }
}

Access: Learners enrolled in the class.

Path parameters
section_idintegerrequired
The section ID, as the number in the URL.
Query parameters
class_idintegerrequired
The class the section belongs to.
1 returns each item as a JSON object. 2 (default) returns each item as a positional array.
Response200application/json
codeinteger
Example: 200
messagestring
Example: Success
resourcesinteger[][]
Exercises and materials sorted by display position
sectionobject
Show child attributesHide child attributes
section.idinteger
Example: 5284
Example: CHINTA
Learners in the class
Example: 7
Example: 3
Example: 3
Example: 0
Example: 0
Example: 0
Example: 0
Example: 0
Example: 0
Example: 0
Example: 0
Example: 0
Percent
Example: 0

Notes: Errors: "You do not have access to this class"; "Section Not avaliable." or a "Section Available from ... to ..." message when the section is switched off or outside its availability window; and an error if a prerequisite is not finished. Rate limit: 30 requests per 1 minute; going over locks you out for 30 minutes.

Updated yesterday

Ask AI