NextSchoolNextSchool Data API

SDQ (Care Module)

Strengths and Difficulties Questionnaire — template, student list, and scored results nested on Student

SDQ

The Strengths and Difficulties Questionnaire (SDQ) is a 25-item screening tool scored across five dimensions. Three respondents fill it out per student: TEACHER, PARENT, and STUDENT. All queries require authentication and are scoped to your school.

The SDQ surface is read-only — this API exposes only template, student list, and scored result queries. Answers are captured through the care application.

Respondent Types

RespondentType is a GraphQL enum with three values:

ValueDescription
TEACHERHomeroom or advising teacher
PARENTParent or guardian
STUDENTStudent self-assessment

Scoring Dimensions

#DimensionQuestionsRisk threshold
1EMOTIONAL3, 8, 13, 16, 246
2CONDUCT5, 7, 12, 18, 225
3HYPERACTIVITY2, 10, 15, 21, 256
4PEER6, 11, 14, 19, 234
5PROSOCIAL1, 4, 9, 17, 20strength if > 3

For dimensions 1–4: score > thresholdPROBLEM, score == thresholdRISK, otherwise NORMAL. Each dimension returns NOT_ASSESSED until all five of its questions are answered.

For PROSOCIAL: score > 3STRENGTH, else NO_STRENGTH (Prosocial is inverted — a high score is a strength, not a risk).

Total score = sum of dimensions 1–4 only (Prosocial is excluded from the total).

AnsweredTotal scoreLevel
0NOT_ASSESSED (ยังไม่ประเมิน)
1 – 19PARTIAL (ประเมินยังไม่ครบ)
20 +> 18PROBLEM
20 +17 – 18RISK
20 +< 17NORMAL

Get SDQ Template

Return the template, all 25 questions in order, and the answer choices for each question. Response is cached in-memory for 60 minutes.

query {
  sdqTemplate {
    id
    name
    questions {
      id
      orderNumber
      questionText
      answers {
        id
        answerText
        answerPoint
      }
    }
  }
}

List Students with Completion Status

Return students in your school with per-respondent completion counts. Defaults to the active academic year when no academicYearId or semesterId is provided.

query {
  sdqStudents(classroomId: 42, status: "progress", limit: 50) {
    studentId
    code
    title
    firstname
    lastname
    classroomName
    orderNumber
    teacherDone
    parentDone
    studentDone
    teacherAnswered
    parentAnswered
    studentAnsweredCount
  }
}

Parameters

ParameterTypeDefaultDescription
academicYearIdIntactive yearScope results to a specific academic year
semesterIdIntScope results to a single semester (overrides academicYearId)
classroomIdIntFilter to one classroom
statusStringallcompleted | progress | not_started | all
limitInt50Maximum number of rows
offsetInt0Number of rows to skip

Status Filter Semantics

ValueMatches
completedAll three respondents have answered every question
progressAt least one respondent started but not all three are complete
not_startedNo respondent has answered any question
all (or omitted)Every student in scope

Get Scored Result

SDQ scores are exposed as a nested field on Student. Use the top-level student(id) query (which is school-scoped) and select the sdq field. This returns one entry per respondent (TEACHER, PARENT, STUDENT) in a single call.

# Defaults to the active semester for the caller's school
query {
  student(id: 12345) {
    id
    fullName
    classroomName
    sdq {
      respondent
      totalScore
      totalAnswered
      totalLevel
      totalLevelText    # e.g. "ปกติ"
      dimensions {
        name
        nameText        # e.g. "ด้านอารมณ์"
        score
        answeredCount
        level
        levelText       # e.g. "ปกติ" / "เสี่ยง" / "มีปัญหา" / "มีจุดแข็ง"
      }
    }
  }
}

Pass semesterId explicitly to score a different semester:

query {
  student(id: 12345) {
    sdq(semesterId: 78) {
      respondent
      totalLevel
      totalScore
    }
  }
}

Student.sdq

ArgumentTypeDescription
semesterIdIntOptional. When omitted, the active semester for the caller school is used.

Returns [SdqRespondentResult!]! — always three entries, one for each respondent. Respondents with no answers appear with totalLevel: NOT_ASSESSED; respondents who answered some but fewer than 20 questions appear with totalLevel: PARTIAL.

Example: Combined list + nested SDQ

Because sdq is a field on Student, you can fetch scores for many students in one round-trip by nesting it under students():

query {
  students(limit: 5, search: "ณัฏฐรินทร์") {
    id
    fullName
    classroomName
    sdq(semesterId: 1448) {
      respondent
      totalLevel
      totalScore
    }
  }
}

SdqRespondentResult

FieldTypeDescription
respondentRespondentTypeTEACHER, PARENT, or STUDENT
totalScoreFloatSum of dimensions 1–4
totalAnsweredIntCount of answered questions across dimensions 1–4
totalLevelSdqLevelNORMAL | RISK | PROBLEM | PARTIAL | NOT_ASSESSED
totalLevelTextStringThai label for totalLevel (e.g. ปกติ, เสี่ยง, มีปัญหา, ยังไม่ประเมิน)
dimensions[SdqDimension]Five entries: EMOTIONAL, CONDUCT, HYPERACTIVITY, PEER, PROSOCIAL

SdqDimension

FieldTypeDescription
nameSdqDimensionNameEMOTIONAL | CONDUCT | HYPERACTIVITY | PEER | PROSOCIAL
nameTextStringThai dimension name (e.g. ด้านอารมณ์, ด้านความประพฤติเกเร)
scoreFloatRaw score for this dimension
answeredCountIntNumber of answered questions in this dimension (0 – 5)
levelSdqLevelLevel for this dimension. PROSOCIAL uses STRENGTH / NO_STRENGTH / NOT_ASSESSED
levelTextStringThai label for level (e.g. ปกติ, เสี่ยง, มีปัญหา, มีจุดแข็ง, ไม่มีจุดแข็ง, ยังไม่ประเมิน)

Errors

All queries return a GraphQL error with these codes when validation fails:

CodeCause
UNAUTHENTICATEDNo valid JWT or API key
FORBIDDENJWT has no schoolId
NOT_FOUNDstudentId does not belong to your school, SDQ template is missing, or no active semester found when semesterId is omitted

On this page