---
openapi: 3.0.3
info:
  title: API V2P3
  version: v2p3
  description: This API set Orchestrates Faria Services Manager and School Administration
    with the ManageBac GUI.
  contact:
    name: Faria International School
    email: hello@managebac.com
    url: https://www.faria.org/support
tags:
- name: Academics
  description: This group refers to top-level entities such as School, Programs, Subjects,
    and Academic Years. Programs are curriculum frameworks that ManageBac supports,
    and a Subject is a collection of delivered curricula. Academic Years define when
    the school is in session.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: This group refers to top-level entities such as School, Programs,
            Subjects, and Academic Years. Programs are curriculum frameworks that
            ManageBac supports, and a Subject is a collection of delivered curricula.
            Academic Years define when the school is in session.
          marks: []
  x-gitbook-description-html: "<p>This group refers to top-level entities such as
    School, Programs, Subjects, and Academic Years. Programs are curriculum frameworks
    that ManageBac supports, and a Subject is a collection of delivered curricula.
    Academic Years define when the school is in session.</p>"
- name: Year Groups
  description: A Year Group is a collection of student memberships in a cohort that
    share the same Program.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: A Year Group is a collection of student memberships in a cohort that
            share the same Program.
          marks: []
  x-gitbook-description-html: "<p>A Year Group is a collection of student memberships
    in a cohort that share the same Program.</p>"
- name: Classes
  description: Classes are scheduled sessions in which teachers deliver a given curriculum
    to a group of students.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: Classes are scheduled sessions in which teachers deliver a given curriculum
            to a group of students.
          marks: []
  x-gitbook-description-html: "<p>Classes are scheduled sessions in which teachers
    deliver a given curriculum to a group of students.</p>"
- name: Students
  description: Students are child users who use ManageBac to learn
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: Students are child users who use ManageBac to learn
          marks: []
  x-gitbook-description-html: "<p>Students are child users who use ManageBac to learn</p>"
- name: Coursework
  description: This group refers to entities tied to student learning delivery or
    feedback, such as Tasks and Grades.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: This group refers to entities tied to student learning delivery or
            feedback, such as Tasks and Grades.
          marks: []
  x-gitbook-description-html: "<p>This group refers to entities tied to student learning
    delivery or feedback, such as Tasks and Grades.</p>"
- name: Attendance
  description: This group describes all the APIs relating to attendance records
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: This group describes all the APIs relating to attendance records
          marks: []
  x-gitbook-description-html: "<p>This group describes all the APIs relating to attendance
    records</p>"
- name: Teachers
  description: Teachers are users who use ManageBac to delivery curriculum
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: Teachers are users who use ManageBac to delivery curriculum
          marks: []
  x-gitbook-description-html: "<p>Teachers are users who use ManageBac to delivery
    curriculum</p>"
- name: Parents
  description: Parents are users who are adults connected to students
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: Parents are users who are adults connected to students
          marks: []
  x-gitbook-description-html: "<p>Parents are users who are adults connected to students</p>"
- name: Relationships
  description: A relationship defines the kind of association between a student and
    a parent
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: A relationship defines the kind of association between a student and
            a parent
          marks: []
  x-gitbook-description-html: "<p>A relationship defines the kind of association between
    a student and a parent</p>"
- name: Memberships
  description: A membership defines the kind of association between a class and a
    student or teacher
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: A membership defines the kind of association between a class and a
            student or teacher
          marks: []
  x-gitbook-description-html: "<p>A membership defines the kind of association between
    a class and a student or teacher</p>"
- name: Behavior Notes
  description: A Behavior Note is a positive or negative report about an occurance
    about a student submitted by a teacher.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: A Behavior Note is a positive or negative report about an occurance
            about a student submitted by a teacher.
          marks: []
  x-gitbook-description-html: "<p>A Behavior Note is a positive or negative report
    about an occurance about a student submitted by a teacher.</p>"
- name: Utilities
  description: This documentation describes miscellaneous APIs.
  x-gitbook-description-document:
    object: document
    data:
      schemaVersion: 8
    nodes:
    - object: block
      type: paragraph
      isVoid: false
      data: {}
      nodes:
      - object: text
        leaves:
        - object: leaf
          text: This documentation describes miscellaneous APIs.
          marks: []
  x-gitbook-description-html: "<p>This documentation describes miscellaneous APIs.</p>"
- name: Authentication
  description: This group refers to endpoints related to authentication.
- name: Projects
  description: This group refers to endpoints related to projects.
components:
  securitySchemes:
    authTokenQuery:
      type: apiKey
      name: auth_token
      in: query
      description: Your V2 API authentication token may be passed in the parameters.
        To protect your key, use [environment variables](https://cloud.google.com/docs/authentication/api-keys#securing_an_api_key).
    authTokenHeader:
      type: apiKey
      name: auth-token
      in: header
      description: Your V2 API authentication token may be passed in the header. To
        protect your key, use [environment variables](https://cloud.google.com/docs/authentication/api-keys#securing_an_api_key).
  schemas:
    YearGroupPBL:
      type: object
      properties:
        pbl:
          type: array
          items:
            allOf:
            - type: object
              properties:
                id:
                  type: integer
                title:
                  type: string
                abbreviation:
                  type: string
                archived:
                  type: boolean
                subject:
                  type: object
                  properties:
                    id:
                      type: integer
                    title:
                      type: string
                description:
                  type: string
                components:
                  type: array
                  items:
                    allOf:
                    - type: object
                      properties:
                        slug:
                          type: string
                        label:
                          type: string
                        enabled:
                          type: boolean
    NotFound:
      type: object
      properties:
        error:
          type: string
          description: Record was not found
          example: Couldn't find CoreTask with 'id'=record_id"
    AccessDeniedError:
      type: object
      properties:
        error:
          type: string
          description: Unauthorized to perform an action
          example: Access Denied
    InvalidPayloadError:
      type: object
      properties:
        error:
          type: string
          description: Invalid payload data structure error.
          example: Invalid payload data structure.
    YearGroup:
      type: object
      properties:
        id:
          type: integer
          description: Year Group ID.
          example: 11076103
        name:
          type: string
          description: Year Group name
          example: IB MYP Group of 2025 (Year 4)
        short_name:
          type: string
          description: Year Group short name
          example: IB MYP Group of 2025
        program:
          type: string
          description: Programe name
          example: IB Middle Years
        program_code:
          type: string
          description: Programe code
          example: myp
        grade:
          type: string
          description: Grade name
          example: Year 4
        archived:
          type: boolean
          description: Archived status of Year Group
          example: false
        grade_number:
          type: integer
          description: Grade number
          example: 10
        graduation_year:
          type: integer
          description: Year Group graduation year
          example: 2019
        student_ids:
          type: array
          items:
            type: integer
            description: Year Group student ids
          example:
          - 12459565
          - 11456849
          - 12068809
    ToggleSchoolSubjectsRequest:
      properties:
        subject_ids:
          type: array
          items:
            type: integer
          example:
          - 10001
          - 10002
    AuthPermissionsResponse:
      type: object
      properties:
        permissions:
          type: array
          items:
            type: string
            example: students/excusals/index
    SubjectRequest:
      type: object
      properties:
        subject:
          type: object
          properties:
            subject_group_id:
              type: integer
              description: Unique ID for subject group in ManageBac.
              example: 10001
            name:
              type: string
              description: Subject name.
              example: English
            title:
              type: string
              description: Subject title.
              example: English
            description:
              type: string
              description: Subject description.
              example: Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed
                do eiusmod tempor incididunt ut labore et dolore magna aliqua.
            scope_and_sequence_based_on:
              type: string
              description: Subject Scope & Sequence based on value.
              example: phases
            sl:
              type: boolean
              description: Subject SL level.
              example: false
            hl:
              type: boolean
              description: Subject HL level.
              example: true
            enabled:
              type: boolean
              description: Enable/disable school subject.
              example: true
            code:
              type: string
              description: Subject custom code
              example: X128
    SubjectsResponse:
      type: object
      properties:
        meta:
          "$ref": "#/components/schemas/Meta"
        subjects:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                description: Unique ID for subject in ManageBac.
                example: 10001
              subject_group_id:
                type: integer
                description: Unique ID for subject group in ManageBac.
                example: 10001
              custom:
                type: boolean
                description: The boolean value defines whether the Subject is custom
                  or system.
                example: false
              name:
                type: string
                description: Subject name.
                example: English
              title:
                type: string
                description: Subject title.
                example: English
              sl:
                type: boolean
                description: Subject SL level.
                example: false
              hl:
                type: boolean
                description: Subject HL level.
                example: true
              sl_code:
                type: string
                description: Subject SL code
                example: 138
              hl_code:
                type: string
                description: Subject HL code
                example: 128
              description:
                type: string
                description: Subject description
                example: Lorem ipsum dolor sit amet, consectetur adipiscing elit,
                  sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
              scope_and_sequence_based_on:
                type: string
                description: Subject Scope & Sequence based on value.
                example: phases
              updated_at:
                type: string
                description: Updated date; yyyy-mm-dd.
                example: '2021-05-13T10:27:47Z'
              self_taught:
                type: boolean
                description: Self taught subject
                example: true
              phases:
                type: array
                items:
                  type: string
                example:
                - '1'
                - '2'
                - '3'
                - '4'
              levels:
                type: array
                description: Language levels
                items:
                  type: string
                example:
                - Literature
                - Language and literature
              enabled:
                type: boolean
                description: Describe if school subject enabled
                example: true
    SubjectResponse:
      type: object
      properties:
        subject:
          type: object
          properties:
            id:
              type: integer
              description: Unique ID for subject in ManageBac.
              example: 10001
            subject_group_id:
              type: integer
              description: Unique ID for subject group in ManageBac.
              example: 10001
            custom:
              type: boolean
              description: The boolean value defines whether the Subject is custom
                or system.
              example: true
            name:
              type: string
              description: Subject name.
              example: English
            title:
              type: string
              description: Subject title.
              example: English
            sl:
              type: boolean
              description: Subject SL level.
              example: false
            hl:
              type: boolean
              description: Subject HL level.
              example: true
            code:
              type: string
              description: Subject custom code
              example: X128
            description:
              type: string
              description: Subject description.
              example: Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed
                do eiusmod tempor incididunt ut labore et dolore magna aliqua.
            scope_and_sequence_based_on:
              type: string
              description: Subject Scope & Sequence based on value.
              example: phases
            updated_at:
              type: string
              description: Updated date; yyyy-mm-dd.
              example: '2021-05-13T10:27:47Z'
            self_taught:
              type: boolean
              description: Self taught subject
              example: true
            phases:
              type: array
              items:
                type: string
              example:
              - '1'
              - '2'
              - '3'
              - '4'
            levels:
              type: array
              description: Language levels
              items:
                type: string
              example:
              - Literature
              - Language and literature
            enabled:
              type: boolean
              description: Describe if school subject enabled
              example: true
    SubjectGroupRequest:
      type: object
      properties:
        subject_group:
          type: object
          properties:
            name:
              type: string
              description: Subject Group name.
              example: Language
            max_phase:
              type: string
              description: Phases Range (only allowed in the IB PYP program). Possible
                values are '4' or '5'. The default value is '5'.
              example: '4'
    SubjectGroupResponse:
      type: object
      properties:
        subject_group:
          type: object
          properties:
            id:
              type: integer
              description: Unique ID for Subject Group in ManageBac.
              example: 10010
            name:
              type: string
              description: Subject Group name.
              example: Language
            custom:
              type: boolean
              description: Whether the Subject Group is a custom one created by the
                school.
              example: true
            max_phase:
              type: string
              description: Phases Range (only allowed in the IB PYP program). Possible
                values are '4' or '5'. The default value is '5'.
              example: '4'
            program:
              type: string
              description: Program code (allowed values are ib_pyp, hs, ms, ps).
              example: ibpyp
            updated_at:
              type: string
              description: Updated datetime.
              example: '2021-05-13T10:27:47Z'
    SubjectGroupsResponse:
      type: object
      properties:
        meta:
          "$ref": "#/components/schemas/Meta"
        subject_groups:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                description: Unique ID for Subject Group in ManageBac.
                example: 10010
              name:
                type: string
                description: Subject Group name.
                example: Language
              max_phase:
                type: string
                description: Phases Range (only allowed in the IB PYP program). Possible
                  values are '4' or '5'. The default value is '5'.
                example: '4'
              program:
                type: string
                description: Program code (allowed values are ib_pyp, hs, ms, ps).
                example: ibpyp
              updated_at:
                type: string
                description: Updated datetime.
                example: '2021-05-13T10:27:47Z'
    TermGradeScale:
      type: object
      properties:
        score:
          type: number
          description: Score (% or greater)
          example: 95.5
          multipleOf: 0.1
        mark:
          type: string
          description: Mark
          example: A+
        program_code:
          type: string
          description: Program code
          example: diploma
    Program:
      type: object
      properties:
        name:
          type: string
          description: Program name in full.
          example: IB Diploma
        short_name:
          type: string
          description: Short program name.
          example: IB DP
        uid:
          type: integer
          description: Unique identificator for a program.
          example: 100120
        code:
          type: string
          description: Program code.
          example: diploma
        grades:
          type: array
          description: Grade of program.
          items:
            type: object
            properties:
              grade_number:
                type: integer
                description: Grade number.
                example: 7
              uid:
                type: integer
                description: Unique identificator for grade.
                example: 700700010
              name:
                type: string
                description: Grade name.
                example: Grade 6
              enabled:
                type: boolean
                description: Switch to enable/disable grade.
                example: true
              program:
                type: string
                description: Program name.
                example: Primary School
    BehaviorNote:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID for note in ManageBac.
          example: 123
        student_id:
          type: string
          description: School’s own unique ID for student.
          example: '1423421'
        email:
          type: string
          example: chloe.epelbaum@eduvo.com
        first_name:
          type: string
          description: Student’s first given name.
          example: Chloe
        last_name:
          type: string
          description: Student’s surname.
          example: Epelbaum
        grade:
          type: string
          description: Grade name.
          example: MYP 3
        incident_time:
          type: string
          description: Date/time stamp for incident.
          example: '2020-12-28T12:45:00.000-05:00'
        behavior_type:
          type: string
          description: Behavior triggering intervention.
          example: Bullying
        notes:
          type: string
          description: Reporter’s notes.
          example: Teasing classmate during first period.
        next_step:
          type: string
          description: Intervention.
          example: Detention
        next_step_date:
          type: string
          description: Date of intervention; yyyy-mm-dd.
          example: '2020-12-28'
        reported_by:
          type: string
          description: Reporter name.
          example: Richard Chandler
        homeroom_advisor:
          type: string
          description: Homeroom Advisor name.
          example: Shannon Eckersley
    Membership:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID for membership in ManageBac.
          example: 123
        user_id:
          type: integer
          description: Unique user ID in ManageBac.
          example: 132
        level:
          type: integer
          description: Class level; 0 is standard-level, 1 is higher-level.
          enum:
          - 0
          - 1
        created_at:
          type: string
          description: Created date; yyyy-mm-dd.
          example: '2021-07-24'
        updated_at:
          type: string
          description: Updated date; yyyy-mm-dd.
          example: '2021-07-24'
        class_id:
          type: integer
          description: Unique class ID in ManageBac.
          example: 231
        user_email:
          type: string
          description: User email
          example: test@managebac.com
        uniq_class_id:
          type: string
          description: Unique ID in class.
          example: ASDF2
        uniq_student_id:
          type: string
          description: School’s own unique ID.
          example: '1423421'
        role:
          type: string
          description: User role.
          example: student
    AcademicTerm:
      type: object
      required:
      - name
      - starts_on
      - ends_on
      properties:
        name:
          type: string
          description: Term name.
          example: Term one.
        starts_on:
          type: string
          description: Term start date.
          example: '2024-05-29'
        ends_on:
          type: string
          description: Term end date.
          example: '2024-07-29'
        locked:
          type: boolean
          description: Restrict teachers from making any changes to term grades.
          example: true
        enable_exam_grade:
          type: boolean
          description: Enable Exam Grade.
          example: false
    AcademicTermRequest:
      type: object
      properties:
        academic_term:
          "$ref": "#/components/schemas/AcademicTerm"
    AcademicYearRequest:
      type: object
      properties:
        academic_year:
          type: object
          properties:
            terms_attributes:
              type: array
              description: Academic Terms.
              items:
                "$ref": "#/components/schemas/AcademicTerm"
    AcademicYearResponse:
      type: object
      properties:
        academic_year:
          type: object
          properties:
            id:
              type: integer
              description: Unique ID in ManageBac.
              example: 123
            name:
              type: string
              description: Academic Year name.
              example: August 2023 – January 2024
            starts_on:
              type: string
              description: Academic Year start date.
              example: '2024-05-29'
            ends_on:
              type: string
              description: Academic Year end date.
              example: '2024-07-29'
            updated_at:
              type: string
              description: Updated date; yyyy-mm-dd.
              example: '2023-06-26T08:54:47.000Z'
            program:
              type: string
              description: Academic Year program.
              example: diploma
            academic_terms:
              type: array
              description: Academic Terms.
              items:
                "$ref": "#/components/schemas/AcademicTermAttributes"
    AcademicTermResponse:
      type: object
      properties:
        academic_term:
          "$ref": "#/components/schemas/AcademicTermAttributes"
    AcademicTermAttributes:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID in ManageBac.
          example: 123
        academic_year_id:
          type: integer
          description: Unique ID in ManageBac.
          example: 124
        name:
          type: string
          description: Academic Term name.
          example: Term 1
        starts_on:
          type: string
          description: Academic Term start date
          example: '2024-05-29'
        ends_on:
          type: string
          description: Academic Term end date
          example: '2024-07-29'
        locked:
          type: boolean
          description: Restrict teachers from making any changes to term grades.
          example: true
        exam_grade:
          type: boolean
          description: Enable Exam Grade.
          example: true
        updated_at:
          type: string
          description: Updated date; yyyy-mm-dd.
          example: '2023-06-26T08:54:47.000Z'
    AcademicYearCalendarResponse:
      type: object
      properties:
        calendar:
          type: object
          properties:
            start_date:
              type: string
              format: date
              example: '2024-06-16'
            end_date:
              type: string
              format: date
              example: '2025-06-15'
            calendar_type:
              type: string
              example: Rotation Cycle
            rotation_cycle:
              type: integer
              example: 5
            ignore_holidays:
              type: boolean
              example: true
            days_off:
              type: array
              items:
                type: integer
                example: 0
            dates:
              type: array
              items:
                type: object
                properties:
                  date:
                    type: string
                    format: date
                    example: '2024-06-17'
                  rotation_day:
                    type: integer
                    example: 1
    AttendanceCategoriesResponse:
      type: object
      properties:
        categories:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                nullable: true
                example: 123
              status:
                type: integer
                example: 1
              label:
                type: string
                example: Present
              abbreviation:
                type: string
                example: P
              enabled:
                type: boolean
                nullable: true
                example: true
              color_code:
                type: string
                example: "#008800"
    AttendanceExcusalsResponse:
      type: object
      properties:
        excusals:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                description: Unique ID for the excusal.
                example: 123
              student_id:
                type: integer
                description: Unique ID for the student.
                example: 123
              parent_id:
                type: integer
                description: Unique ID for the parent.
                example: 456
              start_date:
                type: string
                format: date
                description: Start date of the excusal.
                example: '2024-06-17'
              end_date:
                type: string
                format: date
                description: End date of the excusal.
                example: '2024-06-19'
              duration:
                type: integer
                description: Duration of the excusal in days.
                example: 3
              comment:
                type: string
                description: Comment or reason for the excusal.
                example: Doctor's appointment
              created_at:
                type: string
                description: Created datetime.
                example: '2024-11-29T13:40:10.000Z'
              updated_at:
                type: string
                description: Updated datetime.
                example: '2024-11-29T18:22:10.000Z'
    CreateAttendanceExcusalRequest:
      type: object
      properties:
        excusal:
          type: object
          properties:
            parent_id:
              type: integer
              description: Unique ID for the parent.
              example: 456
            start_date:
              type: string
              format: date
              description: Start date of the excusal.
              example: '2024-06-17'
            end_date:
              type: string
              format: date
              description: End date of the excusal.
              example: '2024-06-19'
            comment:
              type: string
              description: Comment or reason for the excusal.
              example: Doctor's appointment
    UpdateAttendanceExcusalRequest:
      type: object
      properties:
        excusal:
          type: object
          properties:
            end_date:
              type: string
              format: date
              description: End date of the excusal.
              example: '2024-06-19'
            comment:
              type: string
              description: Comment or reason for the excusal.
              example: Doctor's appointment
    UpsertNotFoundError:
      type: object
      properties:
        index:
          type: integer
          description: Positional item index
          example: 0
        errors:
          type: object
          properties:
            id:
              type: array
              items:
                type: string
                description: Not found error description
                example: Cannot find Class with ID=1001
        status:
          type: string
          description: Status code
          example: not_found
    UpsertUnprocessableEntityError:
      type: object
      properties:
        index:
          type: integer
          description: Positional item index
          example: 0
        errors:
          type: object
          description: Validation errors
        status:
          type: string
          description: Status code
          example: unprocessable_entity
    UpsertClasses:
      type: object
      properties:
        classes:
          type: array
          items:
            anyOf:
            - type: object
              properties:
                id:
                  type: integer
                  description: Unique ID in ManageBac.
                  example: 123
                archived:
                  type: boolean
                  description: Archive Class.
                  example: false
                name:
                  type: string
                  description: Class Name.
                  example: IB DP Biology (Grade 12)
                description:
                  type: string
                  description: Class description.
                  example: Lorem ipsum dolor sitamet.
                language:
                  type: string
                  description: Language of Instruction. Receives a language code.
                  example: en
                uniq_id:
                  type: string
                  description: Unique ID in ManageBac.
                  example: DG333
                class_section:
                  type: string
                  description: Identifier for a duplicated class/grade.
                  example: A
                subject_ids:
                  type: array
                  description: Subjects unique IDs.
                  example:
                  - 123434
                  - 10001
                  items:
                    type: integer
                sl:
                  type: boolean
                  description: SL level
                  example: true
                hl:
                  type: boolean
                  description: HL level
                  example: false
                subject_option:
                  description: Subject option.
                  oneOf:
                  - type: string
                    description: Allowed for Subject that support language level (e.g.
                      Language and literature).
                    example: Language and literature
                  - type: array
                    description: Allowed for Subject that support phases.
                    items:
                      type: string
                    example:
                    - '1'
                    - '2'
                    - '3'
                lock_memberships:
                  type: string
                  description: Lock Memberships.
                  example: students_only
            - "$ref": "#/components/schemas/CreateClass"
    UpsertClassesResponse:
      type: array
      items:
        anyOf:
        - "$ref": "#/components/schemas/UpsertUnprocessableEntityError"
        - "$ref": "#/components/schemas/UpsertNotFoundError"
        - type: object
          properties:
            index:
              type: integer
              description: Positional item index
              example: 0
            class:
              "$ref": "#/components/schemas/Class"
            status:
              type: string
              description: Status code
              example: ok
    UpdateClass:
      type: object
      properties:
        archived:
          type: boolean
          description: Archive Class.
          example: false
        name:
          type: string
          description: Class Name.
          example: IB DP Biology (Grade 12)
        description:
          type: string
          description: Class description.
          example: Lorem ipsum dolor sitamet.
        language:
          type: string
          description: Language of Instruction. Receives a language code.
          example: en
        uniq_id:
          type: string
          description: Unique ID in ManageBac.
          example: DG333
        class_section:
          type: string
          description: Identifier for a duplicated class/grade.
          example: A
        subject_ids:
          type: array
          description: Subjects unique IDs.
          example:
          - 123434
          - 10001
          items:
            type: integer
        sl:
          type: boolean
          description: SL level
          example: true
        hl:
          type: boolean
          description: HL level
          example: false
        subject_option:
          description: Subject option.
          oneOf:
          - type: string
            description: Allowed for Subject that support language level (e.g. Language
              and literature).
            example: Language and literature
          - type: array
            description: Allowed for Subject that support phases.
            items:
              type: string
            example:
            - '1'
            - '2'
            - '3'
        lock_memberships:
          type: string
          description: Lock Memberships.
          example: students_only
    CreateClass:
      type: object
      properties:
        start_term_id:
          type: integer
          description: Academic term ID.
          example: 123
        end_term_id:
          type: integer
          description: Academic term ID.
          example: 132
        subject_id:
          type: integer
          description: Subject’s unique ID.
          example: 123434
        program:
          type: string
          description: Program code.
          example: diploma
        grade_number:
          type: integer
          description: Grade number.
          example: 13
        name:
          type: string
          description: Class Name.
          example: IB DP Biology (Grade 12)
        description:
          type: string
          description: Class description.
          example: Lorem ipsum dolor sitamet.
        language:
          type: string
          description: Language of Instruction. Receives a language code.
          example: en
        uniq_id:
          type: string
          description: Unique ID in ManageBac.
          example: DG333
        class_section:
          type: string
          description: Identifier for a duplicated class/grade.
          example: A
        subject_ids:
          type: array
          description: Subjects unique IDs.
          example:
          - 123434
          - 10001
          items:
            type: integer
        sl:
          type: boolean
          description: SL level
          example: true
        hl:
          type: boolean
          description: HL level
          example: false
        subject_option:
          description: Subject option.
          oneOf:
          - type: string
            description: Allowed for Subject that support language level (e.g. Language
              and literature).
            example: Language and literature
          - type: array
            description: Allowed for Subject that support phases.
            items:
              type: string
            example:
            - '1'
            - '2'
            - '3'
        lock_memberships:
          type: string
          description: Lock Memberships.
          example: students_only
    Class:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID in ManageBac.
          example: 123
        name:
          type: string
          description: Class Name.
          example: IB DP Biology (Grade 12)
        description:
          type: string
          description: Class description.
          example: Lorem ipsum dolor sitamet.
        language:
          type: string
          description: Language of Instruction. Receives a language code.
          example: en
        uniq_id:
          type: string
          description: Unique ID in ManageBac.
          example: DG333
        class_section:
          type: string
          description: Identifier for a duplicated class/grade.
          example: A
        start_term_id:
          type: integer
          description: Academic term ID.
          example: 123
        end_term_id:
          type: integer
          description: Academic term ID.
          example: 132
        created_at:
          type: string
          description: Created date; yyyy-mm-dd.
          example: '2023-07-24T15:12:58.000Z'
        updated_at:
          type: string
          description: Updated date; yyyy-mm-dd.
          example: '2023-07-24T15:12:58.000Z'
        grade:
          type: string
          description: Grade name.
          example: Grade 12
        grade_number:
          type: integer
          description: Grade number.
          example: 7
        applicable_levels:
          type: array
          description: Applicable Levels.
          items:
            type: string
          example:
          - HL
          - SL
        program:
          type: string
          description: Program name.
          example: IB Diploma
        program_code:
          type: string
          description: Program code.
          example: diploma
        subject_id:
          type: integer
          description: Subject’s unique ID.
          example: 123434
        subject_name:
          type: string
          description: Subject Name.
          example: Norwegian
        subject_group:
          type: string
          description: Subject group.
          example: Studies in language and literature
        subject_option:
          type: string
          description: Subject option.
          example: Language and literature
        lock_memberships:
          type: string
          description: Lock Memberships.
          example: students_only
        archived:
          type: boolean
          description: Archive Class.
          example: false
        subjects:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                description: Unique ID in ManageBac.
                example: 123
              name:
                type: string
                description: Subject Name.
                example: Spanish
              subject_group_id:
                type: integer
                description: Unique ID in ManageBac.
                example: 123
              subject_group:
                type: string
                description: Subject group.
                example: Language
        teachers:
          type: array
          items:
            type: object
            properties:
              teacher_id:
                type: integer
                description: Uniq ID in ManageBac.
                example: 123
              show_on_reports:
                type: boolean
                description: Determines if teach should be shown on reports.
                example: true
              teacher_archived:
                type: boolean
                description: DDetermines if teacher is archived.
                example: false
    BulkUpdateStudents:
      type: object
      required:
      - students
      properties:
        students:
          type: array
          description: An array of student IDs to add or update in the class.
          items:
            type: object
            properties:
              id:
                type: integer
                description: Student ID
                example: 123
              level:
                type: string
                description: Student level.
                enum:
                - HL
                - SL
    BulkUpdateTeachers:
      type: object
      required:
      - teachers
      properties:
        teachers:
          type: array
          description: An array of teacher IDs to add or update in the class.
          items:
            type: object
            properties:
              id:
                type: integer
                description: Teacher ID
                example: 123
              show_on_reports:
                type: boolean
                description: Show Teacher on Reports
                example: false
    BulkUpdateAttendance:
      type: object
      required:
      - attendances
      properties:
        attendances:
          type: array
          description: An array of Attendances data.
          items:
            type: object
            properties:
              student_id:
                type: integer
                description: Student ID.
                example: 123
              date:
                type: string
                format: date
                description: Date of attendance.
                example: '2024-06-19'
              period:
                type: integer
                description: Attendance period number.
                example: 1
              status:
                type: integer
                description: Attendance status ID.
                example: 0
              notes:
                type: string
                description: Teacher notes.
                example: Student was five minutes late
    SetAttendanceSettingsRequest:
      type: object
      required:
      - settings
      properties:
        settings:
          type: array
          items:
            type: object
            required:
            - period
            - day
            properties:
              period:
                type: integer
                description: Attendance period number.
                example: 1
              day:
                type: integer
                description: Day of the week or rotation day number.
                example: 1
              location:
                type: string
                description: Lesson location.
                example: A101
    UpdateStudentAssessPrepTaskGrade:
      type: object
      properties:
        assess_prep_uuid:
          type: string
          description: Unique AssessPrep task UUID
        assess_prep_uid:
          type: string
          description: Unique identifier for an AssessPrep task
        author_id:
          type: integer
          description: Unique identifier for an author in ManageBac
        assessment_file_url:
          type: string
          description: Submission PDF file
        points:
          type: integer
          description: Grade points
        comment:
          type: string
          description: Grade comment
        submission_id:
          type: integer
          description: Unique identifier for an AssessPrep Submission
        is_late:
          type: boolean
          description: Determines if submission is late
      example:
        assess_prep_uuid: '088190c6-aa0e-4126-9651-dca132229658'
        assess_prep_uid: 6JIYJCBZ6D11OS48D4A6R3UNXY
        author_id: 123434
        assessment_file_url: https://path.to/file.pdf
        points: 50
        comment: Good job!
        submission_id: 12343
        is_late: true
    UpdateStudentTaskGrade:
      type: object
      properties:
        author_id:
          type: integer
          description: Unique identifier for an author in ManageBac
        points:
          type: integer
          description: Grade points
        comment:
          type: string
          description: Grade comment
        binary:
          type: boolean
          description: Determines if task is completed or not
      example:
        author_id: 123434
        points: 50
        comment: Well done!
        binary: true
    StudentAssessPrepTaskGrade:
      type: object
      properties:
        assess_prep_uuid:
          type: string
          description: Unique AssessPrep task UUID
        assess_prep_uid:
          type: string
          description: Unique identifier for an AssessPrep task
        assessment_file_url:
          type: string
          description: Submission PDF file
        submission_id:
          type: integer
          description: Unique identifier for an AssessPrep Submission
        author_id:
          type: integer
          description: Unique identifier for an author in ManageBac
      example:
        assess_prep_uuid: '088190c6-aa0e-4126-9651-dca132229658'
        assess_prep_uid: 6JIYJCBZ6D11OS48D4A6R3UNXY
        assessment_file_url: https://path.to/file.pdf
        submission_id: 12343
        author_id: 123434
    BulkUpdateStudentTaskGradeRequest:
      type: object
      properties:
        students:
          type: array
          items:
            type: object
            properties:
              id:
                type: integer
                description: Unique identifier for a student in ManageBac
                example: 12345
              task_grade:
                oneOf:
                - "$ref": "#/components/schemas/UpdateStudentTaskGrade"
                - "$ref": "#/components/schemas/UpdateStudentAssessPrepTaskGrade"
    BulkDestroyStudentTaskGradeRequest:
      type: object
      properties:
        student_ids:
          type: array
          items:
            type: integer
          description: List of student IDs whose grades and submissions will be reset
      example:
        student_ids:
        - 12345
        - 67890
    BulkStudentTaskGradeResponse:
      type: array
      items:
        type: object
        properties:
          id:
            type: integer
            description: Unique identifier for a student in ManageBac
            example: 12343
          status:
            type: string
            description: Response status for a student
            example: unprocessable_entity
          error:
            type: object
            description: Error details if any
    OnlineAssessment:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID in ManageBac
          example: 123434
        user_id:
          type: integer
          description: Unique user ID in ManageBac
          example: 123445
        title:
          type: string
          description: Online Assessment title
          example: My Task
        mode:
          type: string
          enum:
          - online
          - online_secure
          - offline
        points:
          type: integer
          description: Max points for Diploma task with points assessment model or
            MYP task with local points assessment model
          example: 50
        duration:
          type: integer
          description: Online Assessment duration in minutes
          example: 60
        assess_prep_uid:
          type: string
          description: Unique identifier for an AssessPrep task
          example: 6JIYJCBZ6D11OS48D4A6R3UNXY
        assess_prep_uuid:
          type: string
          description: Unique AssessPrep task UUID
          example: '088190c6-aa0e-4126-9651-dca132229658'
        start_at:
          type: string
          description: ISO8601 datetime for Online Assessment due date & time.
          example: '2021-05-13T10:27:47Z'
        created_at:
          type: string
          description: Created date; yyyy-mm-dd.
          example: '2021-05-13T10:27:47Z'
        updated_at:
          type: string
          description: Updated date; yyy-mm-dd
          example: '2021-05-13T10:27:47Z'
        task_id:
          type: integer
          description: Unique task ID in ManageBac
        email:
          type: string
          description: Author email
          example: user@managebac.com
        program_code:
          type: string
          description: Program code
          example: diploma
        grade_code:
          type: string
          description: Grade code
          example: diploma;12
        role:
          type: string
          description: Author role in ManageBac
          example: Advisor
        subject:
          type: string
          description: Subject name
          example: English
        subject_group:
          type: string
          description: Subject Group name
          example: Studies in language and literature
    UpdateOnlineAssessment:
      type: object
      required:
      - title
      - mode
      properties:
        assess_prep_uid:
          type: string
          description: Unique identifier for an AssessPrep task
          example: 6JIYJCBZ6D11OS48D4A6R3UNXY
        title:
          type: string
          description: New ManageBac task title
        mode:
          type: string
          description: Online Assessment mode
          enum:
          - online
          - online_secure
          - offline
        questions_count:
          type: integer
          description: Questions count in online assessment
          example: 8
        points:
          type: integer
          description: Max points for Diploma task with points assessment model or
            MYP task with local points assessment model
          example: 50
        duration:
          type: integer
          description: Online Assessment duration in minutes
          example: 60
        start_at:
          type: string
          description: ISO8601 datetime for Online Assessment due date & time.
          example: '2021-05-13T10:27:47Z'
        status:
          type: string
          enum:
          - draft
          - published
          - closed
        video_monitoring:
          type: boolean
          description: Switch to enable/disable video monitoring
          example: true
        criteria_labels:
          type: array
          description: Criteria labels
          items:
            type: object
            properties:
              label:
                type: string
                description: Criteria name without label
                example: Analysing
              title:
                type: string
                description: Criteria label
                example: A
              descriptors:
                type: array
                items:
                  allOf:
                  - type: object
                    properties:
                      level:
                        type: string
                        description: Descriptor level
                        example: 1-1
                      descriptor:
                        type: string
                        description: Descriptor
                        example: The student work meets expectation.
    PersonalInformation:
      type: object
      properties:
        email:
          type: string
          description: User’s work email address
          example: richard.chandler@eduvo.com
        first_name:
          type: string
          description: User’s first given name.
          example: Richard
        middle_name:
          type: string
          description: User’s additional name.
          example: David
        password:
          type: string
          description: Minimum 6-character password.
          example: qwerty9876
        last_name:
          type: string
          description: User’s surname.
          example: Chandler
        nickname:
          type: string
          description: User’s handle (may differ to given name).
          example: Ricky
        other_name:
          type: string
          description: User’s additional names or variant in a different language.
          example: ''
        identifier:
          type: string
          description: School’s own unique ID for user.
          example: AA1001
        gender:
          type: string
          description: Binary gender.
          example: Male
        birthday:
          type: string
          description: User’s dob; yyyy-mm-dd.
          example: '1972-10-24'
        phone_number:
          type: string
          description: User’s home number.
          example: 977 840-2231
        mobile_phone_number:
          type: string
          description: User’s mobile number.
          example: 977 840-2231
        street_address:
          type: string
          description: First line of user’s home address.
          example: 301 Massachusetts Ave
        street_address_ii:
          type: string
          description: Second (optional) line of user’s home address.
          example: ''
        city:
          type: string
          description: City of user’s home address.
          example: Lunenburg
        state:
          type: string
          description: State of user’s home address.
          example: Virginia
        zipcode:
          type: string
          description: Postal/zip code of user’s home address.
          example: '1462'
        country:
          type: string
          description: Country of user’s home address.
          example: United States
        nationalities:
          type: array
          description: One or more nationalities of the user.
          items:
            type: string
          example:
          - US
          - GB
        languages:
          type: array
          items:
            type: string
          description: Fluent language/s of the user.
          example:
          - ENG
        account_uid:
          type: string
          readOnly: true
          description: A user's Portal Account UID
          example: B2njeGhtX68bNSRM6bY3eLYU
        timezone:
          type: string
          description: The time zone of the user.
          example: Europe/Kyiv
    Parent:
      anyOf:
      - "$ref": "#/components/schemas/PersonalInformation"
      - type: object
        properties:
          id:
            type: integer
            description: Unique ID for a parent in ManageBac.
            example: 123
          salutation:
            type: string
            description: Parent/guardian’s title.
            enum:
            - Mr.
            - Ms.
            - Mrs.
            - Dr.
          title:
            type: string
            description: Parent/guardian’s work position.
            example: Manager
          employer:
            type: string
            description: Parent/guardian’s employer.
            example: Amazon
          work_email:
            type: string
            description: Parent/guardian’s work email address (may differ to email
              field).
            example: adrienne@managebac.com
          work_phone:
            type: string
            description: Parent/guardian’s work number.
            example: 977 840-9171
          work_address:
            type: string
            description: First line of parent/guardian’s work address.
            example: 301 Massachusetts Ave
          work_address_ii:
            type: string
            description: Second (optional) line of parent/guardian’s work address.
            example: ''
          work_fax:
            type: string
            description: Fax number for parent/guardian’s work
            example: '31432'
          work_city:
            type: string
            description: City of parent/guardian’s work address.
            example: Lunenburg
          work_state:
            type: string
            description: State of parent/guardian’s work address.
            example: MA
          work_postal_code:
            type: string
            description: Postal/zip code of parent/guardian’s work address.
            example: '134'
          work_country:
            type: string
            description: Country of parent/guardian’s address.
            example: United States
          sb_id:
            type: string
            description: SchoolsBuddy uniq ID
            example: '123'
          oa_id:
            type: string
            description: OpenApply uniq ID
            example: '123'
          child_ids:
            type: array
            readOnly: true
            items:
              type: integer
            description: Unique ID for offspring/wards of the parent/guardian.
            example:
            - 10193652
            - 11124234
    ChildRelation:
      type: object
      properties:
        id:
          type: integer
          description: Child ID
        relationship:
          type: string
          nullable: true
          enum:
          - Mother
          - Father
          - Stepmother
          - Stepfather
          - Legal Guardian
          - Grandmother
          - Grandfather
          - Sister
          - Brother
          - Uncle
          - Aunt
          - Other Guardian
          - Consultant Recruiter
          description: Parent-child relashionship name
    Teacher:
      anyOf:
      - "$ref": "#/components/schemas/PersonalInformation"
      - type: object
        properties:
          id:
            type: integer
            description: Unique ID in ManageBac.
            example: 123
          role:
            type: string
            description: Teacher role as defined in the User table
            example: Teacher
          sb_id:
            type: string
            description: SchoolsBuddy uniq ID
            example: '123'
          oa_id:
            type: string
            description: OpenApply uniq ID
            example: '123'
          programs:
            type: array
            description: Program/s the teacher facilitates.
            items:
              type: string
            example:
            - '100_120'
    Student:
      anyOf:
      - "$ref": "#/components/schemas/PersonalInformation"
      - type: object
        properties:
          id:
            type: integer
            description: Unique ID in ManageBac.
            example: 123
          sb_id:
            type: string
            description: SchoolsBuddy uniq ID
            example: '123'
          oa_id:
            type: string
            description: OpenApply uniq ID
            example: '123'
          graduated_on:
            type: string
            description: Graduation date; yyyy-mm-dd.
            example: '2018-12-11'
          withdrawn_on:
            type: string
            description: Termination of arrangement with School; yyyy-mm-dd.
            example: '1998-09-23'
          student_id:
            type: string
            description: School’s own unique ID for student.
            example: AA1001
          homeroom_advisor_id:
            type: integer
            description: Unique ID for tutor/home room administrator.
            example: 10752544
          year_group_id:
            type: integer
            description: Unique ID for student’s current year group.
            example: 10209272
          graduating_year:
            type: integer
            description: Graduation from School; yyyy-mm-dd.
            example: 2018
          parent_ids:
            type: array
            description: Unique ManageBac ID for the parent/guardian.
            items:
              type: integer
            example:
            - 12334
            - 3114
    Meta:
      type: object
      properties:
        current_page:
          type: integer
          description: Current page.
          example: 1
        total_pages:
          type: integer
          description: How many pages.
          example: 10
        total_count:
          type: integer
          description: How many items.
          example: 20
        per_page:
          type: integer
          description: How many items on page.
          example: 2
    AssessmentTypesResponse:
      type: object
      properties:
        assessment_type:
          "$ref": "#/components/schemas/AssessmentTypeAttributes"
    AssessmentTypeAttributes:
      type: object
      properties:
        id:
          type: integer
          example: 3
        kind:
          type: string
          example: summative
        name:
          type: string
          example: Summative
        color_code:
          type: string
          example: "#478cfe"
        available_assessments:
          type: array
          items:
            type: string
            example: binary
        required_assessments:
          type: array
          items:
            type: string
            example: criteria
    CriteriaResponse:
      type: object
      properties:
        criteria:
          type: array
          items:
            "$ref": "#/components/schemas/CriteriaAttributes"
    CriteriaAttributes:
      type: object
      properties:
        id:
          type: integer
          example: 25324
        title:
          type: string
          example: Criteria Title
        descriptors:
          type: array
          items:
            oneOf:
            - type: object
              properties:
                value:
                  type: string
                  example: Good
                descriptor:
                  type: string
                  example: The student demonstrates a good understanding of the concept.
              additionalProperties: false
            - type: object
              properties:
                phase:
                  type: integer
                  example: 12
                descriptor:
                  type: string
                  example: The student demonstrates a good understanding of the concept.
                min_value:
                  type: integer
                  example: 7
                max_value:
                  type: integer
                  example: 8
                formative_descriptor:
                  type: string
                  example: The student is making good progress towards understanding
                    the concept.
              additionalProperties: false
    TaskCategory:
      type: object
      properties:
        id:
          type: integer
          description: Unique ID in ManageBac.
          example: 123
        name:
          type: string
          description: Task category name.
          example: Homework
        background_color:
          type: string
          description: Background color for Task Category.
          example: "#205C00"
        color:
          type: string
          description: Text color for Task Category.
          example: "#fff"
        weight:
          type: integer
          description: The weight of the Task Category.
          example: 10
    YearGroupPblTodosComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: todos
            items:
              anyOf:
              - type: object
                properties:
                  id:
                    type: integer
                    description: Todo ID
                  type:
                    type: string
                    description: Todo type
                  title:
                    type: string
                    description: Todo title
                  completed:
                    type: boolean
                    description: Student completion status for a todo
              - type: object
                properties:
                  id:
                    type: integer
                    description: Item ID
                  type:
                    type: string
                    description: Item type
                    example: deadline
                  title:
                    type: string
                    description: Item title
                  todos:
                    type: array
                    items:
                      allOf:
                      - type: object
                        properties:
                          id:
                            type: integer
                            description: Todo ID
                          type:
                            type: string
                            description: Todo type
                          title:
                            type: string
                            description: Todo title
                          completed:
                            type: boolean
                            description: Student completion status for a todo
    YearGroupPblPresentationComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: presentation
            title:
              type: string
              nullable: true
              description: Presentation title
            duration:
              type: integer
              nullable: true
              description: Presentation duration
            documents:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Document ID
                    caption:
                      type: string
                      nullable: true
                      description: Document name
                    url:
                      type: string
                      nullable: true
                      description: Document URL
                    created_at:
                      type: string
                      description: Document creation time (ISO 8601)
            items:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    title:
                      type: string
                      nullable: true
                      description: Presentation item title
                    value:
                      type: string
                      nullable: true
                      description: Presentation item value (formatted)
    YearGroupPblReflectionsComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: reflections
            items:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Reflection ID
                    title:
                      type: string
                      description: Reflection title
                    submitted:
                      type: boolean
                      description: Reflection submission status for a student
    YearGroupPblStudentNotesReviewsComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: notes_and_interviews
            items:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Note ID
                    author:
                      type: object
                      properties:
                        id:
                          type: integer
                          description: Author ID
                    interview:
                      type: boolean
                      description: Identifies interview
                    title:
                      type: string
                      nullable: true
                      description: Interview title
                    body:
                      type: string
                      description: Note details
    YearGroupPblStudentDocumentsComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: documents
            items:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Document ID
                    filename:
                      type: string
                      description: Document file name
                    url:
                      type: string
                      description: Document URL
                    created_at:
                      type: string
                      description: Document creation time (ISO 8601)
    YearGroupPblStudentProposalComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: proposal
            items:
              type: array
              items:
                anyOf:
                - type: object
                  properties:
                    type:
                      type: string
                      description: Item identifier
                      example: subject
                    name:
                      type: string
                      description: Subject name
                      example: EE English
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Field ID
                      example: 12
                    type:
                      type: string
                      description: Field identifier
                      example: field
                    title:
                      type: string
                      description: Field title
                      example: Prescribed Title
                    kind:
                      type: string
                      description: Field type
                      example: radio_buttons
                    value:
                      anyOf:
                      - type: string
                        description: Result value
                      - type: boolean
                        description: Result value
                      - type: number
                        description: Result value
    YearGroupPblStudentJournalComponent:
      type: object
      properties:
        id:
          type: integer
          description: Student ID
          example: 12301
        identifier:
          type: string
          description: Student identifier
          example: S2025-52-4
        status:
          type: object
          properties:
            completed:
              type: boolean
              description: Completed status
              example: false
            approved:
              type: boolean
              description: Approved status
              example: true
            progress:
              type: object
              properties:
                id:
                  type: integer
                  description: Progress status ID
                  example: 28
                default:
                  type: boolean
                  description: Progress status is set by default
                  example: false
                title:
                  type: string
                  description: Progress status title
                  example: Excellent
        supervisor:
          type: object
          properties:
            id:
              type: integer
              description: Supervisor ID.
              example: 5324
            identifier:
              type: string
              description: Supervisor ID identifier.
              example: S2025-52-s
        component:
          type: object
          properties:
            slug:
              type: string
              description: Identifier of component
              example: journal
            items:
              type: array
              items:
                allOf:
                - type: object
                  properties:
                    id:
                      type: integer
                      description: Journal entry ID
                      example: 22
                    kind:
                      type: string
                      description: Entry kind
                      example: file
                    title:
                      type: string
                      nullable: true
                      description: Entry title
                    description:
                      type: string
                      nullable: true
                      description: Entry description
                    author_id:
                      type: integer
                      description: Entry author ID
                    created_at:
                      type: string
                      description: Entry creation time (ISO 8601)
                    files:
                      type: array
                      items:
                        anyOf:
                        - type: object
                          properties:
                            id:
                              type: integer
                              description: File ID
                            filename:
                              type: string
                              description: File name
                            url:
                              type: string
                              description: File URL
                    body:
                      type: string
                      description: Entry body
                    photos:
                      type: array
                      items:
                        anyOf:
                        - type: object
                          properties:
                            id:
                              type: integer
                              description: Photo ID
                            caption:
                              type: string
                              description: Photo name
                            url:
                              type: string
                              description: Photo URL
                    url:
                      type: string
                      nullable: true
                      description: Entry URL
    CoreTaskAttributes:
      type: object
      required:
      - author_id
      - name
      - due_date
      - assessment_type_id
      properties:
        author_id:
          type: integer
          example: 42
        name:
          type: string
          example: 'Math Assignment #1'
        due_date:
          type: string
          format: date-time
          example: '2025-10-01T12:00:00'
        assessment_type_id:
          type: integer
          example: 3
        task_category_id:
          type: integer
          example: 5
        notify_group:
          type: boolean
          example: true
        notify_parents:
          type: boolean
          example: false
        unit_id:
          type: integer
          example: 101
        lesson_experience_id:
          type: integer
          example: 202
        hl:
          type: boolean
          example: true
        sl:
          type: boolean
          example: false
        notes:
          type: string
          example: This is a note for the task.
        enable_dropbox:
          type: boolean
          example: true
        enable_turnitin:
          type: boolean
          example: true
        dropbox_opening_days:
          type: integer
          example: 3
        assigned_student_ids:
          type: array
          items:
            type: integer
            example: 12345
        draft:
          type: boolean
          example: false
        phase:
          type: integer
          example: 1
        assessments:
          type: object
          properties:
            criteria:
              type: object
              properties:
                enabled:
                  type: boolean
                  example: true
                criterion_ids:
                  type: array
                  items:
                    type: integer
                    example: 25324
            points:
              type: object
              properties:
                enabled:
                  type: boolean
                  example: true
                max_points:
                  type: integer
                  example: 100
            binary:
              type: object
              properties:
                enabled:
                  type: boolean
                  example: false
            comment:
              type: object
              properties:
                enabled:
                  type: boolean
                  example: true
    PaginationMeta:
      type: object
      properties:
        current_page:
          type: integer
        next_page:
          type: integer
          nullable: true
        prev_page:
          type: integer
          nullable: true
        total_pages:
          type: integer
        total_count:
          type: integer
        per_page:
          type: integer
    CasSettings:
      type: object
      properties:
        cas:
          type: object
          properties:
            components:
              type: array
              items:
                "$ref": "#/components/schemas/CasComponent"
          required:
          - components
      required:
      - cas
    CasComponent:
      type: object
      properties:
        slug:
          type: string
        label:
          type: string
        track_hours:
          type: boolean
        show_hours_chart:
          type: boolean
        cas_total_hours:
          type: integer
        show_aims_and_goals:
          type: boolean
        optional_question:
          type: string
          nullable: true
        activity_description_title:
          type: string
      required:
      - slug
      - label
    CasExperiencesStudentsResponse:
      type: object
      properties:
        students:
          type: array
          items:
            "$ref": "#/components/schemas/CasStudent"
        meta:
          "$ref": "#/components/schemas/PaginationMeta"
      required:
      - students
      - meta
    CasStudent:
      type: object
      properties:
        id:
          type: integer
        identifier:
          type: string
          nullable: true
        component:
          "$ref": "#/components/schemas/CasStudentComponent"
      required:
      - id
      - component
    CasStudentComponent:
      type: object
      properties:
        items:
          type: array
          items:
            "$ref": "#/components/schemas/CasExperience"
      required:
      - items
    CasExperience:
      type: object
      properties:
        id:
          type: integer
        name:
          type: string
        status:
          "$ref": "#/components/schemas/CasExperienceStatus"
        status_annotations:
          "$ref": "#/components/schemas/CasExperienceStatusAnnotations"
        supervisor:
          "$ref": "#/components/schemas/CasExperienceSupervisor"
        cas_project:
          type: boolean
        creativity:
          type: boolean
        creativity_hours:
          type: number
        activity:
          type: boolean
        activity_hours:
          type: number
        service:
          type: boolean
        service_hours:
          type: number
        service_action_type:
          type: string
          nullable: true
          enum:
          - Direct
          - Indirect
          - Advocacy
          - Research
        ongoing_approach:
          type: boolean
        school_based_approach:
          type: boolean
        community_based_approach:
          type: boolean
        individual_approach:
          type: boolean
        start_date:
          type: string
          nullable: true
          format: date
        end_date:
          type: string
          nullable: true
          format: date
        slug:
          type: string
      required:
      - id
      - name
      - status
      - slug
    CasExperienceStatus:
      type: object
      properties:
        post_approved:
          type: boolean
        pre_approved:
          type: boolean
        progress:
          type: object
          properties:
            title:
              type: string
              enum:
              - approved
              - completed
              - to_be_determined
          required:
          - title
      required:
      - post_approved
      - pre_approved
      - progress
    CasExperienceStatusAnnotations:
      type: object
      properties:
        incomplete:
          type: boolean
        rejected:
          type: boolean
        reviewed:
          type: boolean
      required:
      - incomplete
      - rejected
      - reviewed
    CasExperienceSupervisor:
      type: object
      nullable: true
      properties:
        name:
          type: string
        email:
          type: string
        title:
          type: string
        contact_number:
          type: string
  parameters:
    idsQueryParam:
      name: ids[]
      in: query
      description: Return only records with the given IDs.
      required: false
      allowReserved: true
      style: form
      explode: true
      schema:
        type: array
        items:
          type: integer
security:
- authTokenQuery: []
- authTokenHeader: []
paths:
  "/v2p3/classes/{class_id}/assessments/term/{term_id}/grades":
    get:
      summary: Get all Grades for a Class during an Academic Term
      operationId: listGradesForClass
      tags:
      - Coursework
      description: |
        This endpoint retrieves all gradebook grades belonging to a class for a term, as specified by term ID and class ID.
        Returned fields for each task can include:
        - `group_mark`
          > The percentage achieved on the task is converted using the grade scale set for the program, and the result is returned as <code>group_mark</code>.
        - `score`
          > The number of points a student achieved on the task.
        - `max_points`
          > The available number of points for the task.
        - `dropbox_status`
          > Dropbox upload status of student submission on task. Property is present if "Dropbox Coursework Submission" is configured for task.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: term_id
        in: path
        description: Unique identifier for term.
        schema:
          type: integer
        required: true
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      - name: include_archived_students
        in: query
        description: Include archived students in the response.
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12068821
                      name: Epelbaum, Chloe
                      assignments:
                      - id: 18376636
                        name: Short Story Analysis Quiz
                        group_mark: 5
                        dropbox_status: waiting
                        due_date_extension_days: 2
                        due_date: '2023-04-25T14:05:00.000Z'
                        comment:
                        score: 22
                        max_points: 32
                      - id: 18376694
                        name: Write a Short Story Themed on Katharine Mansfield
                        group_mark: 7
                        dropbox_status: waiting
                        due_date: '2023-04-25T14:05:00.000Z'
                        comment:
                        score: 5
                        max_points: 5
                      - id: 18376845
                        name: Read a Selected Short Story by Anton Chekhov
                        group_mark: 7
                        dropbox_status: early
                        due_date: '2023-04-25T14:05:00.000Z'
                        comment: Great analysis, the improvement is noticeable
                        score: 11
                        max_points: 12
                      - id: 18376852
                        name: Gwendolyn Brooks Seminar
                        group_mark: 7
                        dropbox_status: early
                        due_date: '2023-04-25T14:05:00.000Z'
                        comment: Your presentation included insightful analysis of
                          The Near-Johannesburg Boy
                        score: 19
                        max_points: 20
                      - id: 18376858
                        name: Practice Commentary
                        group_mark: 4
                        dropbox_status: early
                        due_date: '2023-04-25T14:05:00.000Z'
                        comment: Your commentary shows a lack of understanding about
                          how form is used to convey the message of the extract
                        score: 14
                        max_points: 21
                    - id: 12068757
                      name: Evans, Raymond
                      assignments:
                      - id: 18376636
                        name: Short Story Analysis Quiz
                        group_mark: 7
                        comment: Impressive analysis.
                        due_date: '2023-04-25T14:05:00.000Z'
                        score: 29
                        max_points: 32
                        binary: completed
                      - id: 18376694
                        name: Write a Short Story Themed on Katharine Mansfield
                        group_mark: 7
                        comment:
                        due_date: '2023-04-25T14:05:00.000Z'
                        score: 5
                        max_points: 5
                        binary: completed
                      - id: 18376845
                        name: Read a Selected Short Story by Anton Chekhov
                        group_mark: 5
                        comment:
                        due_date: '2023-04-25T14:05:00.000Z'
                        score: 9
                        max_points: 12
                        binary: incompleted
                      - id: 18376852
                        name: Gwendolyn Brooks Seminar
                        group_mark: 5
                        comment:
                        due_date: '2023-04-25T14:05:00.000Z'
                        score: 16
                        max_points: 21
                        binary: completed
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 2
                      per_page: 10
  "/v2p3/classes/{class_id}/assessments/term/{term_id}/term-grades":
    get:
      summary: Get Term Grades for a Class
      operationId: listTermGradesForClass
      tags:
      - Coursework
      description: This endpoint retrieves all term grades for a class, as specified
        by term ID and class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: term_id
        in: path
        description: Unique identifier for term.
        schema:
          type: integer
        required: true
      - name: student_ids
        in: query
        required: false
        schema:
          description: List of student ids. Accepts repeated params or a comma-separated
            string.
          example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
          type: array
          items:
            type: integer
          style: form
          explode: true
      - name: include_archived_students
        in: query
        description: Include archived students in the response.
        required: false
        schema:
          type: boolean
      - name: unenrolled_only
        in: query
        description: A flag that indicates the response should only include records
          associated to students who are not currently enrolled in the given class.
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                Other term grades:
                  value:
                    students:
                    - id: 12068821
                      name: Epelbaum, Chloe
                      term_grade:
                        grade: 6
                        average:
                          percent: 85
                          grade: 6
                        comments: Your class participation and determination to help
                          your peers is remarkable.
                        rubrics:
                        - id: 11181
                          title: Class Participation
                          grade: Excellent
                    - id: 12068757
                      name: Evans, Raymond
                      term_grade:
                        grade: 5
                        average:
                          percent: 86.5
                          grade: '5'
                        comments: You've managed to meet expectations.
                        rubrics:
                        - id: 11181
                          title: Class Participation
                          grade: Satisfactory
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 2
                      per_page: 10
                IB Primary Class term grades:
                  value:
                    students:
                    - id: 12068821
                      name: Epelbaum, Chloe
                      term_grade:
                        comments: Your class participation and determination to help
                          your peers is remarkable.
                        rubrics:
                        - id: 11181
                          title: Class Participation
                          grade:
                        learner_profile:
                          comment: Learner Profile comment
                          standards:
                          - id: 1241
                            title: Inquirers
                            criteria:
                            - id: 123
                              title: All Subjeects Criterion
                              score: A
                        subjects:
                        - id: 789
                          title: English
                          comment: English skills grew well
                          overall_assessment:
                            criteria:
                            - id: 123
                              title: All Subjects Criterion
                              score: A
                          phases:
                          - phase: 1
                            strands:
                            - title: Oral language - listening and speaking
                              criteria:
                              - id: 123
                                title: All Subjects Criterion
                                score: A
                              standards:
                              - title: Learning Outcomes
                                standards:
                                - title: tell their own stories using words, gestures,
                                    and objects/artifacts
                                  standards:
                                  - title: use gestures, actions, body language and/or
                                      words to communicate needs and to express ideas
                                    criteria:
                                    - id: 123
                                      title: All Subjects Criterion
                                      score: A
                        - id: 788
                          title: French
                          comment: "<p>Great improvements in french</p>"
                          overall_assessment:
                            criteria:
                            - id: 123
                              title: All Subjects Criterion
                              score: B
                          strands:
                          - title: Oral language - listening and speaking
                            criteria:
                            - id: 123
                              title: All Subjects Criterion
                              score: B
                        units:
                        - id: 50
                          title: English Unit 1
                          comment: "<p>A Unit grade comment</p>"
                          subjects:
                          - id: 12
                            title: English
                          transdisciplinary_theme:
                            id: 1
                            title: Who we are
                            components:
                            - An inquiry into the nature of the self
                            - Beliefs and values
                          overall_assessment:
                            criteria:
                            - id: 123
                              title: All Subjects Criterion
                              score: B
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 10
  "/v2p3/classes/{class_id}/academic-years/{academic_year_id}/attendance/settings":
    put:
      summary: Set or Update an Attendance Settings for a Class in an Academic Year
      operationId: SetAttendanceSettings
      tags:
      - Attendance
      description: |
        Define the rotation slots for when and where the given class meets. This operation enables slots in the payload and disables slots not in the payload.

        While it does not delete any individual attendance records,
        it does directly affect how class attendance records for students are counted over the given academic year.
        For example, if absent records exist at a given slot, they will no longer be tallied when disabled.

        Note that the “Start period count from 0” setting should be ignored when forming the payload; the first slot in a day will always be `period: 1`.
        There is a known incompatibility with “Get Class Timetable” endpoint that responds with periods zero- or one-indexed, depending on that setting,
        but will be fixed in `v2p3`.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class
        required: true
        schema:
          type: integer
      - name: academic_year_id
        in: path
        description: Academic Year (Term Set) ID
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    settings:
                    - index: 0
                      status: unprocessable_entity
                      errors:
                        period:
                        - on day 1 must be in [1, 3, 4, 5, 6]
                    - index: 1
                      status: unprocessable_entity
                      errors:
                        day:
                        - must be in [1, 2, 3, 4, 5]
                    - index: 2
                      status: ok
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/SetAttendanceSettingsRequest"
        required: true
        description: Attendance settings payload
  "/v2p3/school/academic-years/{academic_year_id}/attendance_categories":
    get:
      summary: Get Attendance Categories
      operationId: listCategories
      tags:
      - Categories
      description: This endpoint retrieves Attendance Categories for an Academic Year.
        Responses show configuration available at Settings > Attendance & Calendar
        > Attendance Categories.
      parameters:
      - name: academic_year_id
        in: path
        description: Academic Year ID
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    categories:
                    - status: -1
                      label: Present
                      abbreviation: P
                      enabled: true
                      color_code: "#54e33b"
                    - status: 0
                      label: Absent
                      abbreviation: A
                      enabled: true
                      color_code: "#c00"
                    - status: 1
                      label: Present
                      abbreviation: P
                      enabled: true
                      color_code: "#008800"
                    - status: 2
                      label: Late
                      abbreviation: L
                      enabled: false
                      color_code: "#fa8c00"
              schema:
                type: object
                properties:
                  categories:
                    type: array
                    items:
                      "$ref": "#/components/schemas/AttendanceCategoriesResponse"
  "/v2p3/auth/permissions":
    get:
      summary: Get all Permissions
      operationId: listTokenResources
      tags:
      - Authentication
      description: Retrieves all resources that the passed authentication token is
        currently authorized to access. Nomenclature matches /settings/develop/api-reference
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AuthPermissionsResponse"
  "/v2p3/avatars/{id}":
    get:
      summary: Get Avatar
      operationId: showAvatarByID
      tags:
      - Utilities
      description: This endpoint retrieves the avatar of a user, as specified by user
        ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for user.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
        '302':
          description: Redirect
  "/v2p3/ping":
    get:
      summary: Ping
      operationId: ping
      tags:
      - Utilities
      description: This endpoint determines whether the API key is valid.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    pong: ok
  "/v2p3/behavior/notes":
    get:
      summary: Get all behavior notes
      operationId: listBehaviorNotes
      tags:
      - Behavior Notes
      description: This endpoint retrieves all the available behavior notes for the
        School.
      parameters:
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    behavior_notes:
                    - id: 1
                      student_id: chloe-42
                      first_name: Chloe
                      preferred_name: M
                      last_name: Epelbaum
                      email: chloe.epelbaum@eduvo.com
                      grade: Grade 12
                      incident_time: '2017-07-07T00:00:00.000Z'
                      behavior_type: Behaviour
                      notes: "<p>Chloe's behaviour is unacceptable</p>"
                      next_step: Phone call home
                      next_step_date: '2017-09-09'
                      author_id: 1
                      reported_by: Richard Chandler
                      homeroom_advisor: Risa Aoki
                      visible_to_parents: true
                      visible_to_students: false
                      created_at: '2022-12-11T01:42:16.000-08:00'
                      updated_at: '2023-04-08T06:34:38.000-07:00'
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 0
                      per_page: 100
              schema:
                type: object
                properties:
                  behavior_notes:
                    type: array
                    items:
                      "$ref": "#/components/schemas/BehaviorNote"
                  meta:
                    "$ref": "#/components/schemas/Meta"
  "/v2p3/classes/{id}/criteria":
    get:
      summary: Get Criteria for a Class
      operationId: listCriteriaforClass
      tags:
      - Coursework
      description: This endpoint retrieves all criteria belonging to the class as
        specified by ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/CriteriaResponse"
  "/v2p3/classes/{class_id}/students":
    get:
      summary: Get Students for a Class
      operationId: getStudentsForClass
      tags:
      - Memberships
      description: This endpoint retrieves all students belonging to a class as specified
        by class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      - name: include_archived_students
        in: query
        required: false
        schema:
          type: boolean
          default: false
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    student_ids:
                    - 10193652
                    student_levels:
                      '10193652': SL
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
    patch:
      summary: Bulk update Students from a Class
      operationId: bulkUpdateStudentsFromClass
      tags:
      - Extended API
      - Classes
      description: This endpoint updates students belonging to a class as specified
        by class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 1
                      status: ok
                    - id: 2
                      status: unprocessable_entity
                      errors:
                        level:
                        - is not included in the list
                    - id: 3
                      status: not_found
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/BulkUpdateStudents"
  "/v2p3/classes/{id}/task_categories":
    get:
      summary: Get Task Categories for Class
      operationId: listClassTaskCategories
      tags:
      - Coursework
      description: This endpoint retrieves task categories for a class specified by
        class ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    task_categories:
                    - id: 1
                      name: Quiz
                      background_color: "#205C00"
                      color: "#fff"
                      weight: 10
                    - id: 2
                      name: Homework
                      background_color: "#2175C6"
                      color: "#fff"
                      weight: 10
                    - id: 3
                      name: Essay
                      background_color: "#33C"
                      color: "#fff"
                      weight: 10
                    - id: 6
                      name: Paper
                      background_color: "#A2C400"
                      color: "#fff"
                      weight: 10
                    - id: 7
                      name: Test
                      background_color: "#FFAD3A"
                      color: "#fff"
                      weight: 10
              schema:
                type: object
                properties:
                  task_categories:
                    type: array
                    items:
                      "$ref": "#/components/schemas/TaskCategory"
  "/v2p3/classes/{id}/tasks":
    get:
      summary: Get Tasks for a Class
      operationId: listTasksforClass
      tags:
      - Coursework
      description: This endpoint retrieves all tasks belonging to the class as specified
        by ID. If term ID is not specified, all tasks that the term class covers will
        be returned.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: term_id
        in: query
        description: Unique identifier for term.
        required: false
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    tasks:
                    - id: 22301859
                      name: 'Test Task #1'
                      notes: ''
                      author:
                        id: 10193613
                      enable_dropbox: true
                      draft: false
                      assessment_type:
                        id: 17
                        kind: summative
                        name: Summative
                      category:
                        id: 1848
                        name: Homework
                      dropbox_id: 11099399
                      google_drive_dropbox: false
                      ib_class_id: 10342450460
                      assigned_students:
                      - 11084604
                      - 10193652
                      - 10241839
                      due_date: '2025-05-08T21:10:00+03:00'
                      turnitin: false
                      assessments:
                        points:
                          title: Points
                          max_points: 10
                    - id: 22301866
                      name: 'Test Task #2'
                      notes: ''
                      author:
                        id: 10193613
                      enable_dropbox: false
                      draft: false
                      assessment_type:
                        id: 17
                        kind: summative
                        name: Summative
                      category:
                        id: 1848
                        name: Homework
                      google_drive_dropbox: false
                      ib_class_id: 10342450460
                      assigned_students: []
                      due_date: '2025-05-22T16:00:00+03:00'
                      turnitin: false
                      assessments:
                        points:
                          title: Points
                          max_points: 12
                    - id: 22301867
                      name: 'Test Task #3'
                      notes: Test
                      author:
                        id: 10193613
                      enable_dropbox: false
                      draft: false
                      assessment_type:
                        id: 18
                        kind: formative
                        name: Formative
                      category:
                        id: 1884
                        name: Homework
                      google_drive_dropbox: false
                      ib_class_id: 10342450460
                      assigned_students: []
                      due_date: '2025-05-23T15:10:00+03:00'
                      turnitin: true
                      assessments:
                        binary:
                          title: Binary
                        points:
                          title: Points
                          max_points: 150
                        criteria:
                          title: Criteria
                          criterions:
                          - 24
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 3
                      per_page: 100
        '401':
          description: Unauthorized
        '404':
          description: Not Found
  "/v2p3/classes/{class_id}/tasks/{id}":
    get:
      summary: Get a Task for a Class
      operationId: getTasksByIDforClass
      tags:
      - Coursework
      description: This endpoint retrieves a task as specified by task ID and class
        ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for task.
        schema:
          type: integer
        required: true
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    task:
                      id: 22301867
                      name: 'Test Task #3'
                      notes: Test
                      draft: false
                      task_type: formative
                      task_type_name: Formative
                      linked_to:
                        class_id: 10299022
                        task_id: 11921323
                      dropbox: false
                      google_drive_dropbox: false
                      task_work_templates:
                      - id: 60
                        name: Lab Report
                        details: Complete the given lab report template based on the
                          in-class lab that was held on Monday.
                      - id: 61
                        name: Post-Lab Reflection
                        details: After completing your lab report, answer the questions
                          in the post-lab reflection.
                      turnitin: true
                      due_date: '2025-05-23T15:10:00+03:00'
                      unit:
                        id: 67396
                        title: Dynamics & Kinematics
                      hl: true
                      sl: true
                      category:
                        id: 1884
                        name: Homework
                        weight: 20
                      assessment_types:
                        comments: {}
                        points:
                          max_score: 7
                      author:
                        id: 10193613
                      enable_dropbox: false
                      assessment_type:
                        id: 18
                        kind: formative
                        name: Formative
                      ib_class_id: 10342450460
                      assigned_students: []
                      assessments:
                        binary:
                          title: Binary
                        points:
                          title: Points
                          max_points: 150
                        criteria:
                          title: Criteria
                          criterions:
                          - 24
        '401':
          description: Unauthorized
        '404':
          description: Not Found
    put:
      summary: Update a Task for a Class
      operationId: updateTaskforClass
      tags:
      - Coursework
      description: This endpoint updates a task for a class as specified by class
        ID and task ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: id
        in: path
        description: Unique identifier for task.
        schema:
          type: integer
        required: true
      responses:
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      due_date:
                        type: array
                        items:
                          type: string
                          example: can't be blank
                      task_category_id:
                        type: array
                        items:
                          type: string
                          example: can't be blank
                      sl:
                        type: array
                        items:
                          type: string
                          example: cat least one must be selected
                      hl:
                        type: array
                        items:
                          type: string
                          example: at least one must be selected
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    task:
                      id: 22301936
                      name: 'Updated Test Task #3'
                      notes: This is an updated task.
                      author:
                        id: 10193613
                      dropbox_opening_days: 3
                      enable_dropbox: true
                      draft: false
                      assessment_type:
                        id: 18
                        kind: formative
                        name: Formative
                      category:
                        id: 1884
                        name: Homework
                      dropbox_id: 11099448
                      google_drive_dropbox: false
                      ib_class_id: 10342450460
                      unit_id: 172
                      lesson_experience_id: 22
                      assigned_students:
                      - 11084385
                      due_date: '2025-05-23T15:10:00+03:00'
                      turnitin: true
                      assessments:
                        points:
                          title: Points
                          max_points: 50
                        criteria:
                          title: Criteria
                          criterions:
                          - 24
                        comment:
                          title: Comment
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                core_task:
                  "$ref": "#/components/schemas/CoreTaskAttributes"
              required:
              - core_task
        required: true
        description: Task attributes to update
    delete:
      summary: Delete a Task for a Class
      operationId: deleteTaskforClass
      tags:
      - Coursework
      description: This endpoint deletes a task for a class as specified by class
        ID and task ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: id
        in: path
        description: Unique identifier for task.
        schema:
          type: integer
        required: true
      responses:
        '401':
          description: Unauthorized
        '404':
          description: Not Found
        '204':
          description: No Content
  "/v2p3/classes/{class_id}/tasks/{id}/students":
    get:
      summary: Get Student Assessment Results for a Task and Class
      operationId: listStudentAssessmentResultsForClassTask
      tags:
      - Coursework
      description: |
        This endpoint retrieves all assessment result scores belonging to a class as specified by ID.
        If term ID is not specified, all assessed tasks that the term class covers will be returned.

        Optional properties:

        **Assessments:**
        - `dropbox_status` - Student Dropbox Submission status for a task if enabled
      parameters:
      - name: id
        in: path
        description: Unique identifier for task.
        schema:
          type: integer
        required: true
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10752610
                      name: Epelbaum, Chloe
                      task_works:
                      - id: 11861277
                        template_id: 54
                        submission_status: submitted
                      - id: 11861277
                        template_id: 55
                        submission_status: late
                      assessments:
                        dropbox_status: waiting
                        comments: Chloe has done a great job on both portions of the
                          task
                        points:
                          score: 6
                          max_score: 7
                        binary: 0
                    - id: 12068799
                      name: Bailey, Jenna
                      task_works:
                      - id: 11861277
                        template_id: 55
                        submission_status: waiting
                      assessments:
                        comments:
                        points:
                          score:
                          max_score: 7
                        binary: 1
                    - id: 10851648
                      name: Francisco, Lewis
                      task_works:
                      - id: 11861277
                        template_id: 55
                        submission_status: late
                      assessments:
                        comments: Lewis submitted his task late and did not meet expectations
                        points:
                          score: 4
                          max_score: 7
                    - id: 10866190
                      name: Lucy, Jasmine
                      task_works:
                      - id: 11861277
                        template_id: 54
                        submission_status: submitted
                      - id: 11861277
                        template_id: 55
                        submission_status: submitted
                      assessments:
                        comments: Great improvement Jasmine. Your hard work is showing.
                        points:
                          score: 5
                          max_score: 7
                    - id: 10813990
                      name: Bowen, James
                      task_works:
                      - id: 11861277
                        template_id: 54
                        submission_status: submitted
                      - id: 11861277
                        template_id: 55
                        submission_status: submitted
                      assessments:
                        comments: Great analysis, but your writing needs to be more
                          concise.
                        points:
                          score: 5
                          max_score: 7
                    - id: 11183705
                      name: Howard, Jessica
                      task_works:
                      - id: 11861277
                        template_id: 54
                        submission_status: waiting
                      - id: 11861277
                        template_id: 55
                        submission_status: submitted
                      assessments:
                        comments:
                        points:
                          score:
                          max_score: 7
                    - id: 12068760
                      name: Boyd, Keith
                      task_works: []
                      assessments:
                        comments:
                        points:
                          score:
                          max_score: 7
                    - id: 12472028
                      name: McNeil, Ian
                      task_works: []
                      assessments:
                        comments:
                        points:
                          score:
                          max_score: 7
  "/v2p3/classes/{class_id}/timetable":
    get:
      summary: Get Class timetable
      operationId: getClassTimetable
      tags:
      - Attendance
      description: |
        This endpoint retrieves a class timetable specified by class ID.

        Note that the `period_starts_count_from` response field available in earlier API versions has been removed in v2p3. Periods are now always 1-indexed.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      - name: include_disabled
        in: query
        description: Configure response to include or exclude disabled slots.
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    timetable:
                      academic_years:
                      - id: 19
                        name: December 2021 – July 2022
                        start_date: '2021-12-22'
                        end_date: '2022-07-22'
                        slots:
                        - day: 2
                          period: 1
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 1
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 1
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 1
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 3
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 3
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 3
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 3
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 3
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 4
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 4
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 4
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 4
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 4
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 5
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 5
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 5
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 5
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 5
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 6
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 6
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 6
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 6
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 6
                          location: Classroom E
                          enabled: true
                      - id: 20
                        name: August 2022 – July 2023
                        start_date: '2022-08-01'
                        end_date: '2023-07-31'
                        slots:
                        - day: 2
                          period: 1
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 1
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 1
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 1
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 2
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 2
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 2
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 2
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 2
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 4
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 4
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 4
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 4
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 4
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 5
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 5
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 5
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 5
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 5
                          location: Classroom E
                          enabled: true
                        - day: 1
                          period: 6
                          location: Classroom A
                          enabled: true
                        - day: 2
                          period: 6
                          location: Classroom B
                          enabled: true
                        - day: 3
                          period: 6
                          location: Classroom C
                          enabled: true
                        - day: 4
                          period: 6
                          location: Classroom D
                          enabled: true
                        - day: 5
                          period: 6
                          location: Classroom E
                          enabled: true
  "/v2p3/classes":
    get:
      summary: Get all Classes
      operationId: listClasses
      tags:
      - Classes
      description: This endpoint retrieves all classes. It returns class name, class
        ID, grade, program, and any School-defined values.
      parameters:
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      - name: deleted_since
        in: query
        description: A timestamp to filter the deleted date of results.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: archived
        in: query
        description: A boolean that, if set to True, returns only archived classes.
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    classes:
                    - id: 852
                      name: IB DP English A (Grade 11)
                      start_term_id: 1
                      end_term_id: 2
                      created_at: '2021-06-28T12:39:36.000Z'
                      updated_at: '2021-06-28T12:39:36.000Z'
                      grade: Grade 11
                      grade_number: 12
                      applicable_levels:
                      - HL
                      - SL
                      program: IB Diploma
                      program_code: diploma
                      subject_id: 927
                      subject_name: English
                      subject_group: Studies in Language and Literature
                      subject_group_id: 13
                      teachers:
                      - teacher_id: 1960
                        show_on_reports: false
                        teacher_archived: false
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
              schema:
                type: object
                properties:
                  classes:
                    type: array
                    items:
                      "$ref": "#/components/schemas/Class"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create a class
      operationId: createClass
      tags:
      - Classes
      description: This endpoint creates a class. It returns class details and the
        IDs of teachers.
      parameters: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/Class"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    example:
                      subject_ids: must be blank
                    properties:
                      subject_ids:
                        type: array
                        items:
                          type: string
                          example: must be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/CreateClass"
        required: true
    patch:
      summary: Upsert many classes
      operationId: upsertClasses
      tags:
      - Extended API
      - Classes
      description: This endpoint creates and updates many classes. It returns indexed
        classes details and the IDs of teachers. It returns indexed errors for invalid
        classes.
      parameters: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/UpsertClassesResponse"
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/UpsertClasses"
        required: true
  "/v2p3/classes/{id}":
    get:
      summary: Get a Class
      operationId: getClassByID
      tags:
      - Classes
      description: This endpoint retrieves a single class as specified by ID. It returns
        class details and the IDs of teachers.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    class:
                      id: 854
                      name: IB DP English A (Grade 11)
                      created_at: '2021-06-28T12:39:37.000Z'
                      updated_at: '2021-06-28T12:39:37.000Z'
                      grade: Grade 11
                      grade_number: 12
                      applicable_levels:
                      - HL
                      - SL
                      program: IB Diploma
                      program_code: diploma
                      subject_id: 929
                      subject_name: English
                      subject_group: Studies in Language and Literature
                      subject_group_id: 13
                      teachers: []
              schema:
                type: object
                properties:
                  class:
                    "$ref": "#/components/schemas/Class"
    patch:
      summary: Update a class
      operationId: updateClass
      tags:
      - Classes
      description: This endpoint updates a class. It returns class details and the
        IDs of teachers.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/Class"
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: "'Couldn't find IbCLass with 'id'=1001'"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: 'found unpermitted parameters: :language'
                  allowed_params:
                    type: array
                    items:
                      oneOf:
                      - type: string
                      - type: object
                    example:
                    - name
                    - description
                    - sl
                    - hl
                    - subject_option
                    - class_section
                    - uniq_id
                    - end_term_id
                    - lock_memberships
                    - archived
                    - subject_ids: []
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/UpdateClass"
        required: true
  "/v2p3/classes/{id}/add_students":
    post:
      summary: Add Students to a Class
      operationId: addStudentsToClass
      tags:
      - Classes
      description: This endpoint adds students, as specified by student ID/s, to a
        class as specified by class ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student_ids:
                  description: An array of student IDs to add to the class.
                  type: array
                  items:
                    type: integer
              required:
              - student_ids
  "/v2p3/classes/{id}/remove_students":
    post:
      summary: Remove Students from a Class
      operationId: removeStudentsFromClass
      tags:
      - Classes
      description: This endpoint removes students from a class, as specified by student
        ID/s and class ID.</p>
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student_ids:
                  description: An array of student IDs to remove from the class.
                  type: array
                  items:
                    type: integer
              required:
              - student_ids
  "/v2p3/classes/{id}/attendance/term/{term_id}":
    get:
      summary: Get Attendance for a Class during an Academic Term
      operationId: getAttendanceForClass
      tags:
      - Attendance
      description: This endpoint retrieves summary attendance data for all students
        within a class as specified by class ID for an academic term as specified
        by term ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      - name: term_id
        in: path
        description: Unique identifier for academic term.
        required: true
        schema:
          type: integer
      - name: archived_students
        in: query
        description: Filter students by archived status
        required: false
        schema:
          type: boolean
          default: false
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10193652
                      attendance:
                        Present: 91
                        Absent: 3
                        Late: 2
                      attendance_categories:
                      - label: Present
                        status: 1
                        value: 90
                      - label: Absent
                        status: 0
                        value: 3
                      - label: Late
                        status: 2
                        value: 2
                      - label: Present
                        status: -1
                        value: 1
                    - id: 10193654
                      attendance:
                        Present: 96
                      attendance_categories:
                      - label: Present
                        status: 1
                        value: 95
                      - label: Present
                        status: -1
                        value: 1
                    timetable:
                      period_starts_count_from: 0
                      period_offset: -1
  "/v2p3/classes/{id}/attendance/date/{date}":
    get:
      summary: Get Class Attendance for a Date
      operationId: getClassAttendanceForDate
      tags:
      - Attendance
      description: This endpoint retrieves summary attendance data for all students
        on a given date, as specified by class ID. Note, the specified date must be
        between the class’s start and end dates. A student’s attendance is returned
        as a sparse array of attendance periods. For further information, see [the
        help article](https://faria.managebac.com/help/articles/360018804292).
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      - name: date
        in: path
        description: A date string to define required day as yyyy-mm-dd.
        required: true
        schema:
          type: string
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10193652
                      attendance:
                        '1':
                          status: Present
                          note: ''
                          category:
                            status: 1
                        '5':
                          status: Absent
                          note: Chloe left after the first period for an appointment.
                          category:
                            status: 0
                    - id: 10193615
                      attendance:
                        '1':
                          status: Present
                          note: ''
                          category:
                            status: 1
                        '5':
                          status: Present
                          note: ''
                          category:
                            status: 1
                    timetable:
                      period_starts_count_from: 0
                      period_offset: -1
  "/v2p3/classes/{id}/attendance":
    put:
      summary: Set or Update a Class Attendance for Students
      operationId: setClassAttendanceForStudents
      tags:
      - Attendance
      description: This endpoint creates or Updates the Attendance records according
        to the provided payload. If an Attendance record for a specific student, date,
        and period already exists, it will be updated; otherwise, a new record will
        be created.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    attendance:
                    - index: 0
                      student_id: 1
                      status: unprocessable_entity
                      errors:
                        date:
                        - out of class term date range
                    - index: 1
                      student_id: 2
                      status: unprocessable_entity
                      errors:
                        period:
                        - must be in [1, 3, 4, 5, 6]
                    - index: 2
                      student_id: 3
                      status: unprocessable_entity
                      errors:
                        status:
                        - is not included in the list
                    - index: 3
                      student_id: 4
                      status: not_found
                    - index: 4
                      student_id: 5
                      status: ok
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/BulkUpdateAttendance"
        required: true
        description: An array of Attendances data
  "/v2p3/classes/{id}/terms":
    get:
      summary: Get Class terms details
      operationId: getClassTerms
      tags:
      - Classes
      description: This endpoint allows to retrieve details on class terms.
      parameters:
      - name: id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      - name: academic_year_id
        in: query
        description: Filter results by unique identifier for an academic term.
        required: false
        schema:
          type: integer
      - name: active_only
        in: query
        description: Filter results by active academic terms.
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    terms:
                    - id: 1
                      name: Current Year Term 1
                      starts_on: '2026-09-01'
                      ends_on: '2026-12-31'
                      academic_year:
                        id: 1
                        name: September 2026 – December 2026
                    - id: 2
                      name: Current Year Term 2
                      starts_on: '2027-01-01'
                      ends_on: '2027-05-31'
                      academic_year:
                        id: 2
                        name: January 2027 - May 2027
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
  "/v2p3/students/excusals/{date}":
    get:
      summary: Get all Attendance Excusals for a date
      operationId: getDateExcusals
      tags:
      - Attendance
      description: Retrieve submitted excusals for a students for a date. Responses
        include dates the excusal applies to and comment given as submitted.
      parameters:
      - name: date
        in: path
        description: A date string to define required day as yyyy-mm-dd.
        required: true
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    excusals:
                    - student_id: 210
                      parent_id: 175
                      start_date: '2025-01-29'
                      end_date: '2025-01-29'
                      duration: 1
                      comment: Chloe has a dentist appointment and will be out of
                        school the entire day.
                      created_at: '2025-01-29T15:56:10.000Z'
                      updated_at: '2025-01-30T12:30:10.000Z'
                    - student_id: 219
                      parent_id: 185
                      start_date: '2024-11-28'
                      end_date: '2024-11-28'
                      duration: 1
                      comment: John was sick.
                      created_at: '2024-11-29T10:45:10.000Z'
                      updated_at: '2024-11-29T10:45:10.000Z'
                    - student_id: 224
                      parent_id: 192
                      start_date: '2024-11-27'
                      end_date: '2024-11-29'
                      duration: 3
                      comment: Need to travel for a family event
                      created_at: '2024-11-29T13:40:10.000Z'
                      updated_at: '2024-11-29T18:22:10.000Z'
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 3
                      per_page: 100
              schema:
                type: object
                properties:
                  excusals:
                    type: array
                    items:
                      "$ref": "#/components/schemas/AttendanceExcusalsResponse"
                  meta:
                    "$ref": "#/components/schemas/Meta"
  "/v2p3/year-groups/{year_group_id}/homeroom/attendance/term/{term_id}":
    get:
      summary: Get Homeroom Attendance for a Year Group and Term
      operationId: getAttendanceForYearGroupByTerm
      tags:
      - Attendance
      description: This endpoint retrieves homeroom attendance for students belonging
        to a year group. Attendance is retrieved by academic term, as specified by
        academic term ID.
      parameters:
      - name: year_group_id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      - name: term_id
        in: path
        description: Unique identifier for academic term.
        required: true
        schema:
          type: integer
      - name: archived_students
        in: query
        description: Filter students by archived status
        required: false
        schema:
          type: boolean
          default: false
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10193652
                      attendance:
                        Present: 57
                        Late: 2
                        Absent: 1
                      attendance_categories:
                      - label: Present
                        status: 1
                        value: 56
                      - label: Absent
                        status: 0
                        value: 1
                      - label: Late
                        status: 2
                        value: 2
                      - label: Present
                        status: -1
                        value: 1
                    - id: 12449380
                      attendance:
                        Present: 60
                      attendance_categories:
                      - label: Present
                        status: 1
                        value: 59
                      - label: Present
                        status: -1
                        value: 1
  "/v2p3/year-groups/{year_group_id}/homeroom/attendance/date/{date}":
    get:
      summary: Get Homeroom Attendance for a Year Group by Date
      operationId: getAttendanceForYearGroupByDate
      tags:
      - Attendance
      description: This endpoint retrieves homeroom attendance for students as specified
        by year group ID and date.
      parameters:
      - name: year_group_id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      - name: date
        in: path
        description: A date string
        required: true
        schema:
          type: string
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10193652
                      attendance:
                        status: Present
                        note: ''
                        category:
                          status: -1
                    - id: 12449380
                      attendance:
                        status: Absent
                        note: Chloe was absent due to a dentist appointment.
                        category:
                          status: 0
  "/v2p3/year-groups/{year_group_id}/homeroom/attendance/term/{term_id}/adjustments":
    get:
      summary: Get Homeroom Attendance Adjustments for a Year Group and Term
      operationId: getAttendanceAdjustmentsForYearGroupByTerm
      tags:
      - Attendance
      description: This endpoint retrieves Year Group Attendance Adjustments for a
        reporting term. Attendance adjustments is retrieved by academic term, as specified
        by academic term ID.
      parameters:
      - name: year_group_id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      - name: term_id
        in: path
        description: Unique identifier for academic term.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 10949004
                      attendance_adjustments:
                      - id: 29863
                        name: Present
                        adjustment: 3
                    - id: 10752628
                      attendance_adjustments:
                      - id: 29870
                        name: Absent
                        adjustment: 2
                      - id: 29871
                        name: Present
                        adjustment: 1
                      - id: 29872
                        name: Late
                        adjustment: 3
  "/v2p3/memberships":
    get:
      summary: Get all Memberships
      operationId: listMemberships
      tags:
      - Memberships
      description: This endpoint retrieves all members for each class (students, teachers
        and admin). It returns for each user the class ID, user ID, user role in the
        class and other details.
      parameters:
      - name: class_ids[]
        in: query
        required: false
        allowReserved: true
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
        description: The list of class IDs to select membership for
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      - name: deleted_since
        in: query
        description: A timestamp to filter the deletion date of results.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: user_ids[]
        in: query
        description: An integer list of users ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: true
      - name: user_ids
        in: query
        description: An integer list of users ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: class_happens_on
        in: query
        description: A date param to filter by start term and end term date range.
        required: false
        schema:
          type: string
          format: date
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: successful
          content:
            application/json:
              examples:
                example_0:
                  value:
                    memberships:
                    - id: 922
                      user_id: 2012
                      level: 1
                      created_at: '2021-06-28T12:39:52.000Z'
                      updated_at: '2021-06-28T12:39:52.000Z'
                      class_id: 899
                      user_email: 301-cdavis@skimia.biz
                      role: Student
                    - id: 923
                      user_id: 2013
                      created_at: '2021-06-28T12:39:52.000Z'
                      updated_at: '2021-06-28T12:39:52.000Z'
                      class_id: 900
                      user_email: 302-jgray@tagcat.org
                      role: Student
                    - id: 924
                      user_id: 2014
                      created_at: '2021-06-28T12:39:52.000Z'
                      updated_at: '2021-06-28T12:39:52.000Z'
                      class_id: 901
                      user_email: 303-lpatterson@plambee.gov
                      role: Student
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 3
                      per_page: 100
              schema:
                type: object
                properties:
                  memberships:
                    type: array
                    items:
                      "$ref": "#/components/schemas/Membership"
                  meta:
                    "$ref": "#/components/schemas/Meta"
  "/v2p3/parents/{parent_id}/children":
    get:
      summary: List of parent-children relationships
      operationId: listOfParentChildrenRelationships
      tags:
      - Relationships
      description: This endpoint retrieves all children relationships of parent
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      - name: page
        in: query
        required: false
        schema:
          type: string
        description: An integer defining which page to display.
      - name: per_page
        in: query
        required: false
        schema:
          type: string
        description: An integer defining the number of records to display per page.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    children:
                    - id: 1
                      relationship: Mother
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
              schema:
                type: object
                properties:
                  children:
                    type: array
                    items:
                      "$ref": "#/components/schemas/ChildRelation"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create a parent-child relationship
      operationId: createParentChildRelationship
      tags:
      - Relationships
      description: This endpoint creates parent-child relationship
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      responses:
        '201':
          description: Created
          content:
            application/json:
              examples:
                example_0:
                  value:
                    child:
                      id: 1
                      relationship: Mother
              schema:
                type: object
                properties:
                  child:
                    "$ref": "#/components/schemas/ChildRelation"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              examples:
                example_0:
                  value:
                    errors:
                      relationship:
                      - 'must be one of: Mother, Father, Stepmother, Stepfather, Legal
                        Guardian, Grandmother, Grandfather, Sister, Brother, Uncle,
                        Aunt, Other Guardian, Consultant Recruiter'
                      child:
                      - must exist
              schema:
                type: object
                properties:
                  child:
                    "$ref": "#/components/schemas/ChildRelation"
                  errors:
                    type: object
                    properties:
                      relationship:
                        type: array
                        items:
                          allOf:
                          - type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                child:
                  "$ref": "#/components/schemas/ChildRelation"
              required:
              - child
    put:
      summary: Bulk update a parent-children relationships
      operationId: bulkUpdateParentChildrenRelationships
      tags:
      - Relationships
      description: This endpoint updates all parent-children relationships
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    children:
                    - id: 1
                      relationship: Mother
                    - id: 2
                      relationship: Brother
              schema:
                type: object
                properties:
                  children:
                    type: array
                    items:
                      allOf:
                      - "$ref": "#/components/schemas/ChildRelation"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              examples:
                example_0:
                  value:
                    errors:
                      relationship:
                      - 'must be one of: Mother, Father, Stepmother, Stepfather, Legal
                        Guardian, Grandmother, Grandfather, Sister, Brother, Uncle,
                        Aunt, Other Guardian, Consultant Recruiter'
              schema:
                type: object
                properties:
                  children:
                    type: array
                    items:
                      allOf:
                      - "$ref": "#/components/schemas/ChildRelation"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                children:
                  type: array
                  items:
                    allOf:
                    - "$ref": "#/components/schemas/ChildRelation"
              required:
              - children
  "/v2p3/parents/{parent_id}/children/{id}":
    get:
      summary: Get parent-child relationship
      operationId: getParentChildRelationship
      tags:
      - Relationships
      description: This endpoint retrieves all information about child relationship
        to parent
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      - name: id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child ID
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    child:
                      id: 1
                      relationship: Mother
              schema:
                type: object
                properties:
                  child:
                    "$ref": "#/components/schemas/ChildRelation"
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  reason:
                    type: string
                required:
                - error
                additionalProperties: false
    put:
      summary: Update parent-child relationship
      operationId: updateParentChildRelationship
      tags:
      - Relationships
      description: This endpoint updates parent-child relationship
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      - name: id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child ID
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    child:
                      id: 1
                      relationship: Mother
              schema:
                type: object
                properties:
                  child:
                    "$ref": "#/components/schemas/ChildRelation"
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  reason:
                    type: string
                required:
                - error
                additionalProperties: false
        '422':
          description: Unprocessable entity
          content:
            application/json:
              examples:
                example_0:
                  value:
                    errors:
                      relationship:
                      - 'must be one of: Mother, Father, Stepmother, Stepfather, Legal
                        Guardian, Grandmother, Grandfather, Sister, Brother, Uncle,
                        Aunt, Other Guardian, Consultant Recruiter'
              schema:
                type: object
                properties:
                  error:
                    type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                child:
                  type: object
                  properties:
                    relationship:
                      type: string
                      enum:
                      - Mother
                      - Father
                      - Stepmother
                      - Stepfather
                      - Legal Guardian
                      - Grandmother
                      - Grandfather
                      - Sister
                      - Brother
                      - Uncle
                      - Aunt
                      - Other Guardian
                      - Consultant Recruiter
              required:
              - child
    delete:
      summary: Remove parent-child relationship
      operationId: deleteParentChildRelationship
      tags:
      - Relationships
      description: This endpoint removes child relationship to parent
      parameters:
      - name: parent_id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child's Parent ID
      - name: id
        in: path
        required: true
        schema:
          type: string
        description: An integer of child ID
      responses:
        '204':
          description: No content
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  reason:
                    type: string
                required:
                - error
                additionalProperties: false
  "/v2p3/parents":
    get:
      summary: Get all Parents
      operationId: listParents
      tags:
      - Parents
      description: This endpoint retrieves all parents. Returns an ID, personal details
        and the IDs of their associated students.
      parameters:
      - "$ref": "#/components/parameters/idsQueryParam"
      - name: archived
        in: query
        description: Return only archived (1) or only active (0) parents. If value
          is not specified, all parents are returned.
        required: false
        schema:
          type: boolean
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: deleted_since
        in: query
        description: A timestamp to filter the deletion date of results.
        required: false
        schema:
          type: string
      - name: q
        in: query
        description: A string to search across all fields for.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    parents:
                    - id: 2020
                      email: 308-jmoore@kwilith.com
                      first_name: Kevin
                      last_name: Dixon
                      identifier: AA1001
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: Europe/Kyiv
                      child_ids: []
                      children: []
                      street_address: 714 Hoard Terrace
                      city: Menlo Park
                      state: '33117'
                      zipcode: '65092'
                      country: PG
                      nationalities: []
                      languages: []
                      role: Parent
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
              schema:
                type: object
                properties:
                  parents:
                    type: array
                    items:
                      "$ref": "#/components/schemas/Parent"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create New Parent
      operationId: createParent
      tags:
      - Parents
      description: This endpoint creates a new parent record. The <code>Content-Type</code>
        header must be set to <code>application/json</code>, and the request body
        should contain the field structure as a JSON payload. <b>Note</b> only users
        with the <code>admin</code> <code>role</code> are able to create users.
      parameters: []
      responses:
        '201':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    parent:
                      id: 2033
                      title: MD
                      employer: FEG
                      salutation: Mr.
                      email: parent@gmail.com
                      first_name: Stepan
                      last_name: Bandera
                      archived: false
                      ui_language: en
                      child_ids: []
                      children: []
                      nationalities: []
                      languages: []
              schema:
                type: object
                properties:
                  parent:
                    "$ref": "#/components/schemas/Parent"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                parent:
                  allOf:
                  - "$ref": "#/components/schemas/Parent"
                  - description: Fields for create parent
              required:
              - parent
  "/v2p3/parents/{id}":
    get:
      summary: Get a Parent
      operationId: getParentByID
      tags:
      - Parents
      description: This endpoint retrieves a single parent as specified by ID. It
        returns personal details and the IDs of their associated students.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a parent.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    parent:
                      id: 2029
                      email: 317-vward@zoomzone.com
                      first_name: Justin
                      last_name: Henderson
                      identifier: AA1001
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: America/Lima
                      child_ids: []
                      children: []
                      street_address: 561 Center Avenue
                      city: Solvang
                      state: 46590-9842
                      zipcode: 81834-7928
                      country: '99'
                      nationalities: []
                      languages: []
                      role: Parent
              schema:
                type: object
                properties:
                  parent:
                    "$ref": "#/components/schemas/Parent"
    patch:
      summary: Update a Parent
      operationId: updateParent
      tags:
      - Parents
      description: This endpoint updates a parent record as specified by ID. The <code>Content-Type</code>
        header must be set to <code>application/json</code>, and the request body
        should contain the fields you want to update as a JSON payload.</br>Only users
        with the <code>admin</code> <code>role</code> are able to update users.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a parent.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    parent:
                      id: 2036
                      email: s.banderad@eduvo.com
                      first_name: Stepan
                      last_name: Bandera
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: America/Indiana/Knox
                      child_ids: []
                      children: []
                      street_address: 49702 Melrose Junction
                      city: El Cajon
                      state: '59637'
                      zipcode: 64840-0647
                      country: BA
                      nationalities: []
                      languages: []
              schema:
                type: object
                properties:
                  parent:
                    "$ref": "#/components/schemas/Parent"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                parent:
                  allOf:
                  - "$ref": "#/components/schemas/Parent"
                  - description: Fields for update parent
              required:
              - parent
  "/v2p3/parents/{id}/archive":
    put:
      summary: Archive a Parent
      operationId: archiveParent
      tags:
      - Parents
      description: This endpoint archives a parent record as specified by ID. This
        effectively removes the parent from groups they are members of.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a parent.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/parents/{id}/unarchive":
    put:
      summary: Unarchive a Parent
      operationId: unarchiveParent
      tags:
      - Parents
      description: This endpoint reverses the archive operation on the parent record
        as specified by ID. This effectively restores the parent’s group memberships.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a parent.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/school/programs/{program_code}/academic-years/{academic_year_id}/academic-terms":
    post:
      summary: Create Academic Term
      operationId: createAcademicTerm
      tags:
      - Academics
      description: This endpoint creates an Academic Term for the specified Academic
        Year. It returns created Academic Term.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: diploma
        required: true
        schema:
          type: string
      - name: academic_year_id
        in: path
        description: Academic Year ID
        example: 123
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AcademicTermResponse"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      starts_on:
                        type: array
                        items:
                          type: string
                          example: can't be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/AcademicTermRequest"
  "/v2p3/school/programs/{program_code}/academic-years/{academic_year_id}/academic-terms/{id}":
    patch:
      summary: Update Academic Term
      operationId: updateAcademicTerm
      tags:
      - Academics
      description: This endpoint updates an Academic Term for the specified Academic
        Year by ID. It returns updated Academic Term.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: diploma
        required: true
        schema:
          type: string
      - name: academic_year_id
        in: path
        description: Academic Year ID
        example: 123
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Academic Term ID
        example: 123
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AcademicTermResponse"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      starts_on:
                        type: array
                        items:
                          type: string
                          example: can't be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/AcademicTermRequest"
    delete:
      summary: Delete Academic Term
      operationId: deleteAcademicTerm
      tags:
      - Academics
      description: This endpoint deletes an Academic Term for the specified Academic
        Year by ID. It returns deleted Academic Term.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: diploma
        required: true
        schema:
          type: string
      - name: academic_year_id
        in: path
        description: Academic Year ID
        example: 123
        required: true
        schema:
          type: integer
      - name: id
        in: path
        description: Academic Term ID
        example: 123
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AcademicTermResponse"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      base:
                        type: array
                        items:
                          type: string
                          example: can't be deleted
  "/v2p3/school/programs/{program_code}/academic-years/{id}":
    get:
      summary: Retrieve Academic Year
      tags:
      - Academics
      description: This endpoint retrieves an Academic Year. It returns Academic Year
        by ID with belonged Academic Terms.
      parameters:
      - name: program_code
        in: path
        description: Program code
        example: diploma
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Unique ID in ManageBac.
        example: 10010
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AcademicYearResponse"
  "/v2p3/school/programs/{program_code}/academic-years":
    post:
      summary: Create Academic Year
      operationId: createAcademicYear
      tags:
      - Academics
      description: This endpoint creates an Academic Year. It returns created Academic
        Year with belonged Academic Terms.
      parameters:
      - name: program_code
        in: path
        description: Program code
        example: diploma
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AcademicYearResponse"
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/InvalidPayloadError"
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/AcademicYearRequest"
  "/v2p3/school/programs/{program_code}/assessment_types":
    get:
      summary: Retrieves Assessment Types
      operationId: getAssessmentTypes
      tags:
      - Assessment Type
      description: This endpoint retrieves Assessment Types list.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AssessmentTypesResponse"
  "/v2p3/school/programs/{program_code}/academic-years/{academic_year_id}/calendar":
    get:
      summary: Get Academic Year Calendar
      tags:
      - Academics
      description: This endpoint retrieves an Academic Year Calendar. It returns Calendar
        configuration and dates array.
      parameters:
      - name: program_code
        in: path
        description: Program code
        example: diploma
        required: true
        schema:
          type: string
      - name: academic_year_id
        in: path
        description: Unique ID in ManageBac.
        example: 10010
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    calendar:
                      start_date: '2024-06-17'
                      end_date: '2025-06-15'
                      calendar_type: Rotation Cycle
                      rotation_cycle: 5
                      ignore_holidays: true
                      days_off:
                      - 0
                      - 6
                      dates:
                      - date: '2024-06-17'
                        rotation_day: 1
                      - date: '2024-06-18'
                        rotation_day: 2
                      - date: '2024-06-19'
                        rotation_day: 3
                      - date: '2024-06-24'
                        rotation_day: 5
              schema:
                "$ref": "#/components/schemas/AcademicYearCalendarResponse"
  "/v2p3/school/programs/{program_code}/subject-groups":
    get:
      summary: Retrieves Subject Groups
      operationId: getSubjectGroups
      tags:
      - Academics
      description: This endpoint retrieves paginated Subject Groups list.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectGroupsResponse"
    post:
      summary: Create Subject Group
      operationId: createSubjectGroup
      tags:
      - Academics
      description: This endpoint creates a Subject Group. It returns created Subject
        Group.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: hs
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectGroupResponse"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      name:
                        type: array
                        description: name validation errors
                        items:
                          type: string
                          example: can't be blank
                      max_phase:
                        type: array
                        description: max_phase validation errors
                        items:
                          type: string
                          example: is not included in the list
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/SubjectGroupRequest"
  "/v2p3/school/programs/{program_code}/subject-groups/{id}":
    get:
      summary: Get Subject Group
      operationId: getSubjectGroup
      tags:
      - Academics
      description: This endpoint retrieves a Subject Group.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: hs
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Unique ID for Subject Group in ManageBac.
        example: 10001
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectGroupResponse"
    patch:
      summary: Update Subject Group
      operationId: updateSubjectGroup
      tags:
      - Academics
      description: This endpoint updates a Subject Group. It returns udpated Subject
        Group.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: hs
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Subject Group ID
        example: 10010
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectGroupResponse"
        '403':
          description: Forbidden
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Couldn't find CoreSubjectGroup with 'id'=10001
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/SubjectGroupRequest"
    delete:
      summary: Remove Subject Group
      operationId: destroySubjectGroup
      tags:
      - Academics
      description: This endpoint destroys a Subject Group. It returns destroyed Subject
        Group.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: hs
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Subject Group ID
        example: 10010
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectGroupResponse"
        '403':
          description: Forbidden
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Couldn't find CoreSubjectGroup with 'id'=10001
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      base:
                        type: array
                        items:
                          type: string
                          example: can't be deleted
  "/v2p3/school/programs/{program_code}/subjects":
    get:
      summary: Retrieves Subjects
      operationId: getSubjects
      tags:
      - Academics
      description: This endpoint retrieves paginated Subjects list.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectsResponse"
    post:
      summary: Creates Subject
      operationId: createSubject
      tags:
      - Academics
      description: This endpoint creates a Subject.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: hs
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectResponse"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      subject_group_id:
                        type: array
                        items:
                          type: string
                          example: can't be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/SubjectRequest"
  "/v2p3/school/programs/{program_code}/subjects/{id}":
    get:
      summary: Retrieves Subject
      operationId: getSubject
      tags:
      - Academics
      description: This endpoint retrieves a Subject.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Unique ID for Subject in ManageBac.
        example: 10001
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectResponse"
    put:
      summary: Updates Subject
      operationId: updateSubject
      tags:
      - Academics
      description: This endpoint updates a Subject.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Unique ID for Subject in ManageBac.
        example: 10001
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectResponse"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: 'found unpermitted parameter: :description'
                  allowed_params:
                    type: array
                    items:
                      type: string
                    example:
                    - subject_group_id
                    - enabled
                    - name
                    - title
                    - scope_and_sequence_based_on
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Record was not found
                    example: Couldn't find CoreSubject with 'id'=record_id
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/SubjectRequest"
    delete:
      summary: Delete Subject
      operationId: deleteSubject
      tags:
      - Academics
      description: This endpoint deletes a Subject.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      - name: id
        in: path
        description: Unique ID for Subject in ManageBac.
        example: 10001
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/SubjectResponse"
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Record was not found
                    example: Couldn't find CoreSubject with 'id'=record_id
  "/v2p3/school/programs/{program_code}/subjects/bulk-enable":
    post:
      summary: Bulk Enable Subjects
      operationId: bulkEnableSubjects
      tags:
      - Extended API
      - Academics
      description: This endpoint enable school Subjects.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/ToggleSchoolSubjectsRequest"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      subject_ids:
                        type: array
                        items:
                          type: string
                          example: can't be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/ToggleSchoolSubjectsRequest"
  "/v2p3/school/programs/{program_code}/subjects/bulk-disable":
    post:
      summary: Bulk Disable Subjects
      operationId: bulkDisableSubjects
      tags:
      - Extended API
      - Academics
      description: This endpoint disable school Subjects.
      parameters:
      - name: program_code
        in: path
        description: Program scope
        example: ibpyp
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/ToggleSchoolSubjectsRequest"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      subject_ids:
                        type: array
                        items:
                          type: string
                          example: can't be blank
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/ToggleSchoolSubjectsRequest"
  "/v2p3/school":
    get:
      summary: Get School Details
      operationId: getSchool
      tags:
      - Academics
      description: This endpoint retrieves School details and its enabled programs.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    school:
                      subdomain: faria
                      name: Faria International School
                      country: US
                      language: en
                      session_in_may: true
                      logo: path/to/logo.png
                      top_nav_logo: path/to/top_nav_logo.png
                      high_res_logo: path/to/high_res_logo.png
                      programs:
                      - IB Diploma
                      - IB Middle Years
                      - IB Primary Years
                      - High School
                      - Middle School
                      - Primary School
                      enabled_programs:
                      - name: IB Diploma
                        code: diploma
                      - name: IB Middle Years
                        code: myp
                      - name: IB Primary Years
                        code: ibpyp
                      - name: High School
                        code: hs
                      - name: Middle School
                        code: ms
                      - name: Primary School
                        code: ps
                      kbl_id: 5
  "/v2p3/school/academic-years":
    get:
      summary: Get Academic Years
      operationId: listAcademicYears
      tags:
      - Academics
      description: This endpoint retrieves a list of academic years and terms as defined
        for each program enabled for the School.
      parameters:
      - name: program_code
        in: query
        required: false
        description: Academic years program code
        schema:
          type: string
      - name: active
        in: query
        required: false
        description: Academic years active state
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    academic_years:
                      diploma:
                        academic_years:
                        - id: 26278
                          name: August 2018 – July 2019
                          active: true
                          starts_on: '2018-08-15'
                          ends_on: '2019-07-30'
                          updated_at: '2017-12-21T16:50:47.000+08:00'
                          academic_terms:
                          - id: 62755
                            name: Term 1
                            active: true
                            starts_on: '2018-08-15'
                            ends_on: '2018-12-31'
                            updated_at: '2018-04-21T16:50:47.000+08:00'
                            exam_grade: false
                          - id: 62756
                            name: Term 2
                            active: false
                            starts_on: '2019-01-03'
                            ends_on: '2019-07-30'
                            updated_at: '2018-04-14T17:37:35.000+08:00'
                            exam_grade: false
                      myp:
                        academic_years:
                        - id: 24648
                          name: August 2018 – July 2019
                          active: true
                          starts_on: '2018-08-19'
                          ends_on: '2019-07-01'
                          updated_at: '2018-04-09T05:09:12.000+08:00'
                          academic_terms:
                          - id: 58813
                            name: Term 1
                            active: false
                            starts_on: '2018-08-19'
                            ends_on: '2019-01-29'
                            updated_at: '2018-04-09T05:09:12.000+08:00'
                            exam_grade: false
                          - id: 58814
                            name: Term 2
                            active: true
                            starts_on: '2019-02-01'
                            ends_on: '2019-07-01'
                            updated_at: '2016-04-09T05:09:12.000+08:00'
                            exam_grade: false
                      ib_pyp:
                        academic_years:
                        - id: 31796
                          name: August 2018 – June 2019
                          active: false
                          starts_on: '2018-08-10'
                          ends_on: '2019-06-03'
                          updated_at: '2018-04-28T23:54:16.000+08:00'
                          academic_terms:
                          - id: 76082
                            name: Term One
                            active: false
                            starts_on: '2018-08-10'
                            ends_on: '2019-01-01'
                            updated_at: '2018-05-28T23:54:16.000+08:00'
                            exam_grade: false
                          - id: 76083
                            name: Quarter 1
                            active: false
                            starts_on: '2019-01-04'
                            ends_on: '2019-06-03'
                            updated_at: '2018-05-28T23:54:16.000+08:00'
                            exam_grade: false
  "/v2p3/school/grades":
    get:
      summary: Get School Grades
      operationId: listGrades
      tags:
      - Academics
      description: This endpoint retrieves the grade details defined for each program
        that a School runs. It returns grades grouped by each program.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    school:
                      programs:
                      - name: IB Diploma
                        code: diploma
                        grades:
                        - name: Grade 9
                          label: Pre-DP Grade 10
                          code: diploma;10
                          uid: 100120013
                          grade_number: 10
                        - name: Grade 10
                          label: Pre-DP Grade 11
                          code: diploma;11
                          uid: 100120014
                          grade_number: 11
                      - name: IB Middle Years
                        code: myp
                        grades:
                        - name: Year 1
                          label: Grade 6
                          code: myp;7
                          uid: 100110010
                          grade_number: 7
                        - name: Year 2
                          label: Grade 7
                          code: myp;8
                          uid: 100110011
                          grade_number: 8
                      - name: IB Primary Years
                        code: pyp
                        grades:
                        - name: Pre-Nursery
                          label: Test
                          code: pyp;-2
                          uid: 100100001
                          grade_number: -2
                        - name: Nursery
                          label: Pre-K3
                          code: pyp;-1
                          uid: 100100002
                          grade_number: -1
              schema:
                type: object
                properties:
                  school:
                    type: object
                    properties:
                      programs:
                        type: array
                        items:
                          "$ref": "#/components/schemas/Program"
  "/v2p3/school/subjects":
    get:
      summary: Get School Subjects
      operationId: listSubjects
      tags:
      - Academics
      description: This endpoint retrieves subject details for programs enabled at
        the School.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    subjects:
                      diploma:
                      - id: 1
                        name: Mathematical Studies
                        group: Mathematics
                        group_id: 1
                        hl: true
                        sl: true
                      - id: 16
                        name: Chinese
                        group: Language acquisition
                        group_id: 2
                        hl: true
                        sl: true
                        self_taught: false
                        levels:
                        - B
                        - ab initio
                      - id: 27
                        name: French
                        group: Language acquisition
                        group_id: 3
                        hl: true
                        sl: true
                        self_taught: false
                        levels:
                        - B
                        - ab initio
                      myp:
                      - id: 348
                        name: Physical and health education
                        group: Physical and health education
                        group_id: 4
                      - id: 350
                        name: Arts
                        group: Arts
                        group_id: 5
  "/v2p3/school/term-grade-scales":
    get:
      summary: Get School Term Grade Scales
      operationId: listSchoolTermGradeScales
      tags:
      - Academics
      description: This endpoint retrieves the term grade scales details defined for
        each program that a School runs.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    school:
                      term_grade_scales:
                      - score: 95.0
                        mark: '7'
                        program_code: diploma
                      - score: 80.0
                        mark: '6'
                        program_code: diploma
                      - score: 70.0
                        mark: '5'
                        program_code: diploma
                      - score: 60.0
                        mark: '4'
                        program_code: diploma
                      - score: 50.0
                        mark: '3'
                        program_code: diploma
                      - score: 40.0
                        mark: '2'
                        program_code: diploma
                      - score: 0.0
                        mark: '1'
                        program_code: diploma
              schema:
                type: object
                properties:
                  school:
                    type: object
                    properties:
                      term_grade_scales:
                        type: array
                        items:
                          "$ref": "#/components/schemas/TermGradeScale"
  "/v2p3/school/term-rubrics":
    get:
      summary: Get School Term Grade Rubrics
      operationId: listTermRubrics
      tags:
      - Academics
      description: This endpoint retrieves term grade rubrics with details.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    school:
                      term_rubrics:
                      - id: 273
                        title: DP General Rubric 1
                        program_code: diploma
                        rubric_type: All Subjects
                        type: Criteria
                        status: active
                        rubric_options:
                        - id: 613
                          value: '0'
                          descriptor: Desc 0
                        - id: 614
                          value: '1'
                          descriptor: Desc 1
                        - id: 615
                          value: '2'
                          descriptor: Desc 2
                      - id: 274
                        title: DP Subject Rubric 1
                        program_code: diploma
                        rubric_type: All Subjects
                        type: Criteria
                        status: active
                        rubric_options:
                        - id: 616
                          value: '0'
                          descriptor: Desc 0
                        - id: 617
                          value: '1'
                          descriptor: Desc 1
                        - id: 618
                          value: '2'
                          descriptor: Desc 2
                      - id: 275
                        title: DP Avg Rubric 1
                        program_code: diploma
                        rubric_type: All Subjects
                        type: Formula
                        formula: AVG
                        status: active
                        formula_rubric_ids: []
                      - id: 276
                        title: DP Sum Rubric 1
                        program_code: diploma
                        rubric_type: All Subjects
                        type: Formula
                        formula: SUM
                        status: active
                        formula_rubric_ids:
                        - 274
                      - id: 277
                        title: DP Subject Rubric 2
                        program_code: diploma
                        rubric_type: All Subjects
                        suffix: "-CF-"
                        type: Custom Field
                        status: active
                      - id: 278
                        title: MYP General Rubric 1
                        program_code: myp
                        rubric_type: All Subjects
                        type: Criteria
                        status: active
                        rubric_options:
                        - id: 622
                          value: '0'
                          descriptor: Desc 0
                        - id: 623
                          value: '1'
                          descriptor: Desc 1
                        - id: 624
                          value: '2'
                          descriptor: Desc 2
                      - id: 279
                        title: MYP Subject Rubric 1
                        program_code: myp
                        rubric_type: All Subjects
                        type: Criteria
                        subject_id: 4119
                        status: active
                        rubric_options:
                        - id: 625
                          value: '0'
                          descriptor: Desc 0
                        - id: 626
                          value: '1'
                          descriptor: Desc 1
                        - id: 627
                          value: '2'
                          descriptor: Desc 2
                      - id: 280
                        title: MYP Sum Rubric 1
                        program_code: myp
                        rubric_type: All Subjects
                        type: Formula
                        formula: SUM
                        formula_rubric_ids: []
                        status: active
                      - id: 281
                        title: MYP Avg Rubric 1
                        program_code: myp
                        rubric_type: All Subjects
                        type: Formula
                        formula: AVG
                        formula_rubric_ids: []
                        status: active
  "/v2p3/students/{id}/avatar":
    put:
      summary: Update Student Avatar
      operationId: updateStudentAvatar
      tags:
      - Students
      description: This endpoint allows to update student's avatar.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
              schema:
                type: object
                properties:
                  status:
                    type: string
        '422':
          description: Bad Request
          content:
            application/json:
              examples:
                example_0:
                  value:
                    errors:
                      base:
                      - file or remote_file_url can't be blank
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      base:
                        type: array
                        items:
                          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                avatar:
                  type: object
                  anyOf:
                  - properties:
                      remote_file_url:
                        type: string
                        description: Avatar URL to upload
                    required:
                    - remote_file_url
                  - properties:
                      file:
                        type: string
                        format: binary
                        description: Avatar file data
                    required:
                    - file
          multipart/form-data:
            schema:
              type: object
              properties:
                avatar:
                  type: object
                  anyOf:
                  - properties:
                      remote_file_url:
                        type: string
                        description: Avatar URL to upload
                    required:
                    - remote_file_url
                  - properties:
                      file:
                        type: string
                        format: binary
                        description: Avatar file data
                    required:
                    - file
        required: true
        description: Avatar params
    delete:
      summary: Delete Student Avatar
      operationId: deleteStudentAvatar
      tags:
      - Students
      description: This endpoint allows to delete student's avatar.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
              schema:
                type: object
                properties:
                  status:
                    type: string
  "/v2p3/students/{student_id}/excusals":
    get:
      summary: Get all Attendance Excusals for a student
      operationId: getStudentExcusals
      tags:
      - Attendance
      description: Retrieve Attendance Excusals submitted by a parent for their child.
        Responses include dates the excusal applies to and comment given as submitted.
      parameters:
      - name: student_id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      - name: applies_on
        in: query
        description: A date string to define required day as yyyy-mm-dd.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    excusals:
                    - id: 1
                      student_id: 210
                      parent_id: 176
                      start_date: '2024-11-28'
                      end_date: '2024-11-28'
                      duration: 1
                      comment: Chloe was sick.
                      created_at: '2024-11-29T10:45:10.000Z'
                      updated_at: '2024-11-29T10:45:10.000Z'
                    - id: 2
                      student_id: 210
                      parent_id: 176
                      start_date: '2024-11-27'
                      end_date: '2024-11-29'
                      duration: 3
                      comment: Need to travel for a family event
                      created_at: '2024-11-29T13:40:10.000Z'
                      updated_at: '2024-11-29T18:22:10.000Z'
                    - id: 3
                      student_id: 210
                      parent_id: 175
                      start_date: '2025-01-29'
                      end_date: '2025-01-29'
                      duration: 1
                      comment: Chloe has a dentist appointment and will be out of
                        school the entire day.
                      created_at: '2025-01-29T15:56:10.000Z'
                      updated_at: '2025-01-30T12:30:10.000Z'
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 3
                      per_page: 100
              schema:
                type: object
                properties:
                  excusals:
                    type: array
                    items:
                      "$ref": "#/components/schemas/AttendanceExcusalsResponse"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create Excusal for a Student
      operationId: createStudentExcusal
      tags:
      - Attendance
      description: This endpoint creates an Attendance Excusal for a Student. It returns
        created Attendance Excusal.
      parameters:
      - name: student_id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '201':
          description: Created
          content:
            application/json:
              examples:
                example_0:
                  value:
                    excusal:
                      id: 1
                      student_id: 210
                      parent_id: 175
                      start_date: '2025-01-01'
                      end_date: '2025-01-01'
                      duration: 1
                      comment: Chloe was sick.
                      created_at: '2025-01-01T15:56:10.000Z'
                      updated_at: '2025-01-01T12:30:10.000Z'
              schema:
                "$ref": "#/components/schemas/AttendanceExcusalsResponse"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              examples:
                Validates for relationship:
                  value:
                    errors:
                      parent_id:
                      - Parent with ID=175 is not linked to the Student with ID=210
                        via a relationship
                Validates for date range:
                  value:
                    errors:
                      duration:
                      - The duration must be a positive number, and it must be between
                        1 and 12, inclusively
                Validates for duration overlapping:
                  value:
                    errors:
                      duration:
                      - The selected duration overlaps with another attendance excusal.
                        Please adjust so that the duration is up to 1 day.
              schema:
                oneOf:
                - type: object
                  properties:
                    errors:
                      type: object
                      properties:
                        parent_id:
                          type: array
                          items:
                            type: string
                      required:
                      - parent_id
                - type: object
                  properties:
                    errors:
                      type: object
                      properties:
                        duration:
                          type: array
                          items:
                            type: string
                      required:
                      - duration
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/CreateAttendanceExcusalRequest"
  "/v2p3/students/{student_id}/excusals/{id}":
    patch:
      summary: Update Excusal for a Student
      operationId: updateStudentExcusal
      tags:
      - Extended API
      - Attendance
      description: This endpoint updates an Attendance Excusal for a Student. It returns
        updated Attendance Excusal.
      parameters:
      - name: student_id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      - name: id
        in: path
        description: Unique identifier for an excusal.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    excusal:
                      id: 1
                      student_id: 210
                      parent_id: 175
                      start_date: '2025-01-01'
                      end_date: '2025-01-01'
                      duration: 1
                      comment: Chloe was sick.
                      created_at: '2025-01-01T15:56:10.000Z'
                      updated_at: '2025-01-01T12:30:10.000Z'
              schema:
                "$ref": "#/components/schemas/AttendanceExcusalsResponse"
        '422':
          description: Unprocessable entity
          content:
            application/json:
              examples:
                Validates for date range:
                  value:
                    errors:
                      duration:
                      - The duration must be a positive number, and it must be between
                        1 and 12, inclusively
                Validates for duration overlapping:
                  value:
                    errors:
                      duration:
                      - The selected duration overlaps with another attendance excusal.
                        Please adjust so that the duration is up to 1 day.
              schema:
                type: object
                properties:
                  errors:
                    type: object
                    properties:
                      duration:
                        type: array
                        items:
                          type: string
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/UpdateAttendanceExcusalRequest"
    delete:
      summary: Delete Excusal for a Student
      operationId: deleteStudentExcusal
      tags:
      - Extended API
      - Attendance
      description: This endpoint deletes an Attendance Excusal for a Student. It returns
        deleted Attendance Excusal.
      parameters:
      - name: student_id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      - name: id
        in: path
        description: Unique identifier for an excusal.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    excusal:
                      id: 1
                      student_id: 210
                      parent_id: 175
                      start_date: '2025-01-01'
                      end_date: '2025-01-01'
                      duration: 1
                      comment: Chloe was sick.
                      created_at: '2025-01-01T15:56:10.000Z'
                      updated_at: '2025-01-01T12:30:10.000Z'
              schema:
                "$ref": "#/components/schemas/AttendanceExcusalsResponse"
  "/v2p3/students":
    get:
      summary: Get all Students
      operationId: listStudents
      tags:
      - Students
      description: This endpoint retrieves all students. It returns personal details
        and program as well as any School-defined values.
      parameters:
      - "$ref": "#/components/parameters/idsQueryParam"
      - name: archived
        in: query
        description: Return only archived (1) or only active (0) students. If value
          is not specified, all students are returned.
        required: false
        schema:
          type: boolean
      - name: status
        in: query
        description: 'Return students by status. Available statuses: <code>enrolled</code>,
          <code>withdrawn</code>, <code>graduated</code>. If value is not specified,
          all students are returned.'
        required: false
        schema:
          type: string
      - name: modified_since
        in: query
        description: A timestamp to filter the modification date of results.
        required: false
        schema:
          type: string
      - name: year_group_ids
        in: query
        description: An integer list of year group ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: year_group_ids[]
        in: query
        description: An integer list of year group ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: true
      - name: homeroom_advisor_ids
        in: query
        description: An integer list of homeroom advisor ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: homeroom_advisor_ids[]
        in: query
        description: An integer list of homeroom advisor ids to filter by.
        required: false
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: true
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: deleted_since
        in: query
        description: A timestamp to filter the deletion date of results.
        required: false
        schema:
          type: string
      - name: q
        in: query
        description: 'A string to search across the following fields: <code>first_name</code>,
          <code>last_name</code>, <code>middle_name</code>, <code>nickname</code>,
          <code>other_name</code>, <code>email</code>, <code>student_id</code>.'
        required: false
        schema:
          type: string
      - name: ids
        in: query
        required: false
        style: form
        explode: true
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 2054
                      email: 331-cstewart@mita.name
                      first_name: Kevin
                      last_name: Williams
                      archived: false
                      ui_language: en
                      created_at: '2021-06-28T12:40:05.000Z'
                      updated_at: '2021-06-28T12:40:05.000Z'
                      student_id: AA1001
                      identifier: AA1001
                      gender: Male
                      timezone: Europe/Kyiv
                      parent_ids: []
                      street_address: 81856 Upham Place
                      city: San Diego
                      state: '56981'
                      zipcode: '82211'
                      country: SI
                      nationalities: []
                      languages: []
                      role: Student
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
              schema:
                type: object
                properties:
                  students:
                    type: array
                    items:
                      "$ref": "#/components/schemas/Student"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create New Student
      operationId: createStudent
      tags:
      - Students
      description: |
        This endpoint creates a new student record. The <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the field structure as a JSON payload. Only users with <code>admin</code> <code>role</code>
        are able to create new student records.
      parameters: []
      responses:
        '201':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    student:
                      id: 2063
                      email: kevin.epelbaum@eduvo.com
                      first_name: Kevin
                      last_name: Epelbaum
                      archived: false
                      ui_language: en
                      created_at: '2021-06-28T12:40:10.000Z'
                      updated_at: '2021-06-28T12:40:10.000Z'
                      student_id: AA1001
                      identifier: AA1001
                      parent_ids: []
                      nationalities: []
                      languages: []
              schema:
                type: object
                properties:
                  student:
                    "$ref": "#/components/schemas/Student"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student:
                  allOf:
                  - "$ref": "#/components/schemas/Student"
                  - description: Fields for create student.
              required:
              - student
  "/v2p3/students/{id}":
    get:
      summary: Get a Student
      operationId: getStudentByID
      tags:
      - Students
      description: This endpoint retrieves a single student as specified by ID. It
        returns personal details, including the IDs of parents. Depending on the value
        of the <code>status</code> field (<code>withdrawn</code> or <code>graduated</code>),
        the related date field will have a different name.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    student:
                      id: 2057
                      email: mimimi@yahoo.com
                      first_name: Jessica
                      last_name: Ortiz
                      archived: false
                      ui_language: en
                      created_at: '2021-06-28T12:40:06.000Z'
                      updated_at: '2021-06-28T12:40:06.000Z'
                      student_id: AA1001
                      identifier: AA1001
                      gender: Male
                      timezone: Australia/Adelaide
                      ee_advisor_id: 456
                      parent_ids: []
                      street_address: 709 Fieldstone Plaza
                      city: Pinole
                      state: '54245'
                      zipcode: '39977'
                      country: NI
                      nationalities: []
                      languages: []
                      role: Student
              schema:
                type: object
                properties:
                  student:
                    "$ref": "#/components/schemas/Student"
    patch:
      summary: Update a Student
      operationId: updateStudent
      tags:
      - Students
      description: |
        This endpoint updates a student record as specified by student ID. The <code>Content-Type</code> header must
        be set to <code>application/json</code>, and the request body should contain the fields you want to update as
        a JSON payload. Only users with <code>admin</code> <code>role</code> are able to update students.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    student:
                      id: 2070
                      email: kevin.epelbaum@eduvo.com
                      first_name: Kevin
                      last_name: Epelbaum
                      archived: false
                      ui_language: en
                      created_at: '2021-06-28T12:40:12.000Z'
                      updated_at: '2021-06-28T12:40:12.000Z'
                      student_id: AA1002
                      identifier: AA1002
                      gender: Male
                      timezone: Atlantic/Cape_Verde
                      parent_ids: []
                      street_address: 9 Aberg Drive
                      city: Fowler
                      state: 70059-4573
                      zipcode: '93186'
                      country: PT
                      nationalities: []
                      languages: []
              schema:
                type: object
                properties:
                  student:
                    "$ref": "#/components/schemas/Student"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student:
                  allOf:
                  - "$ref": "#/components/schemas/Student"
                  - description: Fields for create student.
  "/v2p3/students/{id}/archive":
    put:
      summary: Archive a Student
      operationId: archiveStudent
      tags:
      - Students
      description: This endpoint archives the student record as specified by student
        ID. This effectively removes the record from classes, groups, etc. Either
        the withdrawl date or graduation date must be supplied to provide a reason
        for the archiving.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              anyOf:
              - properties:
                  withdrawn_on:
                    type: string
                    description: Withdrawl date as yyyy-mm-dd
              - properties:
                  graduated_on:
                    type: string
                    description: Graduation date as yyyy-mm-dd
        description: Archive status
  "/v2p3/students/{id}/unarchive":
    put:
      summary: Unarchive a Student
      operationId: unarchiveStudent
      tags:
      - Students
      description: This endpoint reverses the archive operation on a student record
        as specified by ID. This effectively restores the student in classes, groups,
        etc.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/students/{id}/memberships":
    get:
      summary: Get a Student's memberships
      operationId: getStudentMemberships
      tags:
      - Memberships
      description: This endpoint retrieves details of all student memberships.
      parameters:
      - name: id
        in: path
        description: Unique identifier of a student.
        schema:
          type: integer
        required: true
      - name: archived
        in: query
        description: Boolean value to filter memberships by archived status.
        schema:
          type: boolean
          default: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  memberships:
                    type: object
                    properties:
                      classes:
                        type: array
                        items:
                          allOf:
                          - type: object
                            properties:
                              id:
                                type: integer
                              uniq_id:
                                type: string
                              name:
                                type: string
                              archived:
                                type: boolean
                              start_term_id:
                                type: integer
                              end_term_id:
                                type: integer
                      groups:
                        type: array
                        items:
                          allOf:
                          - type: object
                            properties:
                              id:
                                type: integer
                              name:
                                type: string
                              archived:
                                type: boolean
                      year_groups:
                        type: array
                        items:
                          allOf:
                          - type: object
                            properties:
                              id:
                                type: integer
                              name:
                                type: string
                              program:
                                type: string
                              archived:
                                type: boolean
  "/v2p3/students/{id}/set_homeroom_attendance":
    put:
      summary: Set student homeroom attendance
      operationId: set_student_homeroom_attendance
      tags:
      - Extended API
      - Attendance
      description: Sets student homeroom attendance record. If record doesn't exist,
        it will be created.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                date:
                  type: string
                  format: date
                  description: Attendance date
                status:
                  type: integer
                  enum:
                  - 0
                  - 1
                  - 2
                  - 3
                  - 4
                  - 5
                  - 10
                  - 11
                  - 12
                  - 13
                  - 14
                  - 15
                  - 16
                  - 17
                  - 18
                  description: "Available statuses:  \n 0 - Absent  \n1 - Present
                    \ \n2 - Late  \n3 - Dress Code  \n4 - Late & Dress Code  \n5 -
                    Dismissed  \n10 - Health  \n11 - Sports  \n12 - Fieldtrip  \n13
                    - Excused  \n14 - Other  \n15 - Custom 1  \n16 - Custom 2  \n17
                    - Custom 3  \n18 - Custom 4"
                notes:
                  type: string
                  description: Attendance notes
  "/v2p3/tasks/{task_id}/online_assessments/{assess_prep_uid}":
    patch:
      summary: Update an Online Assessment
      operationId: updateOnlineAssessment
      tags:
      - OnlineAssessment
      description: This endpoint updates an OnlineAssessment record as specified by
        assess_prep_uid. The <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the fields you want to update as a JSON
        payload.
      parameters:
      - name: task_id
        in: path
        description: Unique identifier for a task.
        schema:
          type: integer
        required: true
      - name: assess_prep_uid
        in: path
        description: Unique identifier for an AssessPrep task.
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  online_assessment:
                    "$ref": "#/components/schemas/OnlineAssessment"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      title:
                        type: array
                        items:
                          type: string
                          example: can't be blank
                      mode:
                        type: array
                        items:
                          type: string
                          example: can't be blank
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                online_assessment:
                  "$ref": "#/components/schemas/UpdateOnlineAssessment"
  "/v2p3/tasks/{task_id}/students/{student_id}":
    patch:
      summary: Update or Create a Grade for a Student for a Task
      operationId: UpdateStudentTaskGrades
      tags:
      - Extended API
      - Coursework
      description: |
        Creates or updates a grade for a specific student on a given task.
        If a grade already exists, it will be updated; otherwise, a new grade will be created.

        The <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the fields you want to update as a JSON payload.

        For MYP, only integers are allowed (e.g., '1', 1). For non-MYP programs, floats are allowed (e.g., '1.22', 1.22),
        and if more than two decimal places are provided, the value will be automatically rounded (e.g., 1.448 → 1.45).
      parameters:
      - name: task_id
        in: path
        description: Unique identifier for a task.
        schema:
          type: integer
        required: true
      - name: student_id
        in: path
        description: Unique identifier for a student.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                Task Grade:
                  value:
                    task_grade:
                      author_id: 123434
                      points: 50
                      comment: Well done!
                      binary: true
                AssessPrep Task Grade:
                  value:
                    task_grade:
                      assess_prep_uuid: '088190c6-aa0e-4126-9651-dca132229658'
                      assess_prep_uid: 6JIYJCBZ6D11OS48D4A6R3UNXY
                      assessment_file_url: https://path.to/file.pdf
                      submission_id: 12343
                      author_id: 123434
              schema:
                anyOf:
                - "$ref": "#/components/schemas/UpdateStudentTaskGrade"
                - "$ref": "#/components/schemas/StudentAssessPrepTaskGrade"
        '401':
          description: Not Authorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Request forbidden
                    example: The task is not linked to AssessPrep resource.
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                task_grade:
                  oneOf:
                  - "$ref": "#/components/schemas/UpdateStudentTaskGrade"
                  - "$ref": "#/components/schemas/UpdateStudentAssessPrepTaskGrade"
  "/v2p3/tasks/{task_id}/students":
    patch:
      summary: Bulk Update or Create Grades for Students for a Task
      operationId: BulkUpdateStudentTaskGrades
      tags:
      - Extended API
      - Coursework
      description: |
        Creates or updates a grade for many students on a given task.
        If a grade already exists, it will be updated; otherwise, a new grade will be created.

        The <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the fields you want to update as a JSON payload.

        For MYP, only integers are allowed (e.g., '1', 1). For non-MYP programs, floats are allowed (e.g., '1.22', 1.22),
        and if more than two decimal places are provided, the value will be automatically rounded (e.g., 1.448 → 1.45).
      parameters:
      - name: task_id
        in: path
        description: Unique identifier for a task.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/BulkStudentTaskGradeResponse"
        '401':
          description: Not Authorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Request forbidden
                    example: The task is not linked to AssessPrep resource.
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/BulkUpdateStudentTaskGradeRequest"
    delete:
      summary: Bulk Delete Grades for Students for a Task
      operationId: BulkResetStudentsTaskGrades
      tags:
      - Coursework
      description: Destroys a grade for a specific student on a given task. There
        is no undo. Applies to all Students if no `student_ids` are provided.
      parameters:
      - name: task_id
        in: path
        description: Unique identifier for a task.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/BulkStudentTaskGradeResponse"
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/BulkDestroyStudentTaskGradeRequest"
  "/v2p3/teachers/{id}/avatar":
    put:
      summary: Update Teacher Avatar
      operationId: updateTeacherAvatar
      tags:
      - Teachers
      description: This endpoint allows to update teacher's avatar.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a teacher.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
        '422':
          description: Bad Request
          content:
            application/json:
              examples:
                example_0:
                  value:
                    errors:
                      base:
                      - file or remote_file_url can't be blank
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                avatar:
                  type: object
                  anyOf:
                  - properties:
                      remote_file_url:
                        type: string
                        description: Avatar URL to upload
                    required:
                    - remote_file_url
                  - properties:
                      file:
                        type: string
                        format: binary
                        description: Avatar file data
                    required:
                    - file
          multipart/form-data:
            schema:
              type: object
              properties:
                avatar:
                  type: object
                  anyOf:
                  - properties:
                      remote_file_url:
                        type: string
                        description: Avatar URL to upload
                    required:
                    - remote_file_url
                  - properties:
                      file:
                        type: string
                        format: binary
                        description: Avatar file data
                    required:
                    - file
        required: true
        description: Avatar params
    delete:
      summary: Delete Teacher Avatar
      operationId: deleteTeacherAvatar
      tags:
      - Teachers
      description: This endpoint allows to delete teacher's avatar.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a teacher.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/teachers":
    get:
      summary: Get all Teachers
      operationId: listTeachers
      tags:
      - Teachers
      description: This endpoint retrieves all teachers it returns teacher ID and
        personal details.
      parameters:
      - "$ref": "#/components/parameters/idsQueryParam"
      - name: archived
        in: query
        description: Return only archived (1) or only active (0) teachers. If value
          is not specified, all teachers are returned.
        required: false
        schema:
          type: boolean
      - name: modified_since
        in: query
        description: A timestamp to filter results by modification date.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: deleted_since
        in: query
        description: A timestamp to filter results by deletion date of records.
        required: false
        schema:
          type: string
      - name: q
        in: query
        description: A string to search across all fields for.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teachers:
                    - id: 2139
                      email: 396-bhudson@photobean.edu
                      first_name: Kevin
                      last_name: Reyes
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: Europe/Kyiv
                      street_address: 5 Dovetail Crossing
                      city: Montclair
                      state: '18956'
                      zipcode: 73571-3710
                      country: SY
                      programs: []
                      nationalities: []
                      languages: []
                      role: Advisor
                      identifier: AA1001
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
              schema:
                type: object
                properties:
                  teachers:
                    type: array
                    items:
                      "$ref": "#/components/schemas/Teacher"
                  meta:
                    "$ref": "#/components/schemas/Meta"
    post:
      summary: Create New Teacher
      operationId: createTeacher
      tags:
      - Teachers
      description: |
        This endpoint creates a new teacher record. Note, the <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the field structure as a JSON payload. Only users with <code>admin</code> <code>role</code>
        are able to update users.
      parameters: []
      responses:
        '201':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teacher:
                      id: 2144
                      email: john.epelbaum@eduvo.com
                      first_name: John
                      last_name: Epelbaum
                      archived: false
                      ui_language: en
                      programs: []
                      nationalities: []
                      languages: []
                      role: Advisor
                      identifier: AA1001
              schema:
                type: object
                properties:
                  teacher:
                    "$ref": "#/components/schemas/Teacher"
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                teacher:
                  allOf:
                  - "$ref": "#/components/schemas/PersonalInformation"
                  - description: Fields for create teacher.
              required:
              - teacher
  "/v2p3/teachers/{id}":
    get:
      summary: Get a Teacher
      operationId: getTeacherByID
      tags:
      - Teachers
      description: This endpoint retrieves a teacher as specified by teacher ID. It
        returns the ID and contact details.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a teacher.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teacher:
                      id: 2142
                      email: 399-kalexander@voomm.com
                      first_name: Marie
                      last_name: Fowler
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: Etc/UTC
                      street_address: 70 Morning Trail
                      city: Livermore
                      state: 82919-3933
                      zipcode: '28638'
                      country: RO
                      programs: []
                      nationalities: []
                      languages: []
                      role: Advisor
                      identifier: AA1001
              schema:
                type: object
                properties:
                  teacher:
                    "$ref": "#/components/schemas/Teacher"
    patch:
      summary: Update a Teacher
      operationId: updateTeacher
      tags:
      - Teachers
      description: This endpoint updates a teacher record, as specified by the teacher
        ID. Note, the <code>Content-Type</code> header must be set to <code>application/json</code>,
        and the request body should contain the fields you want to update as a JSON
        payload. Only users with <code>admin</code> <code>role</code> are able to
        update users.
      parameters:
      - name: id
        in: path
        description: A numeric value that specifies a Teacher id.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teacher:
                      id: 2147
                      email: s.banderad@eduvo.com
                      first_name: Sharon
                      last_name: Arese
                      archived: false
                      ui_language: en
                      gender: Male
                      timezone: Etc/UTC
                      street_address: 9 Lindbergh Center
                      city: Hawthorne
                      state: '86249'
                      zipcode: '55539'
                      country: NR
                      programs: []
                      nationalities: []
                      languages: []
                      role: Advisor
                      identifier: AA1001
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                teacher:
                  allOf:
                  - "$ref": "#/components/schemas/PersonalInformation"
                  - description: Fields for update teacher.
              required:
              - teacher
  "/v2p3/teachers/{id}/archive":
    put:
      summary: Archive a Teacher
      operationId: archiveTeacher
      tags:
      - Teachers
      description: This endpoint archives a teacher record as specified by ID. This
        effectively removes the teacher from groups they are members of.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a teacher.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/teachers/{id}/unarchive":
    put:
      summary: Unarchive a Teacher
      operationId: unarchiveTeacher
      tags:
      - Teachers
      description: This endpoint reverses the archive operation on the teacher record
        as specified by ID. This effectively restores the teacher’s group memberships.
      parameters:
      - name: id
        in: path
        description: Unique identifier for a teacher.
        schema:
          type: integer
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
  "/v2p3/teachers/{id}/classes":
    get:
      summary: Get teacher Classes Memberships
      operationId: listTeacherClassesMemberships
      tags:
      - Teachers
      description: This endpoint retrieves all classes memberships of a teacher.
      parameters:
      - name: id
        in: path
        schema:
          type: integer
        required: true
        description: A unique teacher ID.
      - name: show_on_reports
        in: query
        schema:
          type: boolean
          default: true
        description: A boolean param to filter classes memberships by Show on Reports
          status.
      - name: archived
        in: query
        schema:
          type: boolean
          default: false
        description: A boolean param to filter classes memberships by class archived
          status.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    classes:
                    - id: 1
                      name: IB DP Class
                      uniq_id: QAZWSXEDC
                      archived: false
                      start_term_id: 1234
                      end_term_id: 1235
                      show_on_reports: true
              schema:
                type: object
                properties:
                  classes:
                    type: array
                    items:
                      allOf:
                      - type: object
                        properties:
                          id:
                            type: integer
                          uniq_id:
                            type: string
                            nullable: true
                          name:
                            type: string
                          archived:
                            type: boolean
                          start_term_id:
                            type: integer
                            nullable: true
                          end_term_id:
                            type: integer
                            nullable: true
                          show_on_reports:
                            type: boolean
  "/v2p3/teachers/{id}/groups":
    get:
      summary: Get teacher Groups Memberships
      operationId: listTeacherGroupsMemberships
      tags:
      - Teachers
      description: This endpoint retrieves all groups memberships of a teacher.
      parameters:
      - name: id
        in: path
        schema:
          type: integer
        required: true
        description: A unique teacher ID.
      - name: archived
        in: query
        schema:
          type: boolean
          default: false
        description: A boolean param to filter groups memberships by group archived
          status.
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    groups:
                    - id: 1
                      name: Art Group
                      archived: false
                      primary_group_advisor: false
                      group_advisor: true
              schema:
                type: object
                properties:
                  classes:
                    type: array
                    items:
                      allOf:
                      - type: object
                        properties:
                          id:
                            type: integer
                          name:
                            type: string
                          archived:
                            type: boolean
                          group_advisor:
                            type: boolean
                          primary_group_advisor:
                            type: boolean
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/proposal/students":
    get:
      summary: Get Student Proposal Progress for a Year Group PBL
      operationId: listYearGroupPblProposalStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Proposal component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: proposal
                        items:
                        - id: 12
                          title: Field Text
                          kind: radio_buttons
                          value:
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/reflections/students":
    get:
      summary: Get Student Reflection Progress for a Year Group PBL
      operationId: listYearGroupPblReflectionsStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Reflections component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: reflections
                        items:
                        - id: 12
                          title: Field Text
                          submitted: false
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/todos/students":
    get:
      summary: Get Student Personal Todos and Deadlines for a Year Group PBL
      operationId: listYearGroupPblTodosStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Todos component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: todos
                        personal_todos:
                        - id: 1
                          title: Project Title
                          completed: false
                        deadlines:
                        - id: 12
                          title: Deadline Title
                          todos:
                          - id: 123
                            title: Todo Title
                            completed: false
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/journal/students":
    get:
      summary: Get Student Journal Entries for a Year Group PBL
      operationId: listYearGroupPblJournalStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Journal component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: journal
                        items:
                        - id: 1
                          kind: journal
                          title:
                          description:
                          author_id: 12
                          created_at: '2025-11-19T22:06:09Z'
                          files: []
                          body: Test 1
                          photos: []
                          url:
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/documents/students":
    get:
      summary: Get Student Documents for a Year Group PBL
      operationId: listYearGroupPblDocumentsStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Documents component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: documents
                        items:
                        - id: 1
                          filename: document.txt
                          url: https://example.com/uploads/store/asset/file/16/document.txt
                          created_at: '2025-11-20T00:05:14Z'
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/presentation/students":
    get:
      summary: Get Student Presentations for a Year Group PBL
      operationId: listYearGroupPblPresentationStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Presentation component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: presentation
                        title: Presentation
                        duration:
                        documents:
                        - id: 1
                          caption: uploaded file
                          url: https://example.com/uploads/store/asset/file/16/document.txt
                          created_at: '2025-11-20T09:28:39Z'
                        items:
                        - title: Presentation Field Title
                          value: Value 1, Value 2
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{year_group_id}/projects/pbl/{project_id}/notes_and_interviews/students":
    get:
      summary: Get Student Notes & Interviews for a Year Group PBL
      operationId: listYearGroupPblNotesAndInterviewsStudentsDetails
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group students PBL
        details for Notes and Interviews component.
      parameters:
      - name: year_group_id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: project_id
        in: path
        description: A PBL Project ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      - name: include_archived_students
        in: query
        description: A boolean parameter to specify that specifies if archived students
          are included in response
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 12345
                      identifier: S2025-52-4
                      status:
                        progress:
                          id: 312
                          title: Excellent
                          default: true
                        approved: false
                        completed: false
                      supervisor:
                        id: 1232
                        identifier: S2025-52-s
                      component:
                        slug: notes_and_interviews
                        items:
                        - id: 1
                          author:
                            id: 123
                          interview: true
                          title: Interview Title
                          body: Interview Body
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 1
                      per_page: 100
        '404':
          description: Not Found
  "/v2p3/year-groups/{id}/projects/pbl":
    get:
      summary: Get all Year Group Project Based Learning
      operationId: listYearGroupProjectBasedLearningTemplates
      tags:
      - Projects
      description: This endpoint retrieves information about Year Group PBL details.
      parameters:
      - name: id
        in: path
        description: A Year Group ID.
        required: true
        schema:
          type: integer
      - name: archived
        in: query
        description: A boolean parameter to filter archived or active Year Groups
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    pbl:
                    - id: 396
                      title: TOK Essay
                      abbreviation: TOK
                      archived: false
                      subject:
                        id: 798
                        name: Theory of Knowledge
                      description: The TOK essay is the external assessment for TOK.
                        Students are required to write an essay in response to one
                        of the six prescribed titles that are issued by the IB for
                        each examination session.
                      components:
                      - slug: proposal
                        label: Prescribed Title
                        enabled: true
                      - slug: todos
                        label: To Dos
                        enabled: true
                      - slug: documents
                        label: Documents
                        enabled: true
                      - slug: notes_and_interviews
                        label: Notes
                        enabled: true
  "/v2p3/year-groups":
    get:
      summary: Get all Year Groups
      operationId: listYearGroups
      tags:
      - Year Groups
      description: This endpoint retrieves the basic information of all Year Groups.
        It returns the group name, program, program_code, grade level and student
        IDs for members.
      parameters:
      - name: modified_since
        in: query
        description: A timestamp to filter results by modification date.
        required: false
        schema:
          type: string
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: archived
        in: query
        description: A boolean that, if set to true, returns only archived groups.
        required: false
        schema:
          type: boolean
      - name: student_ids
        in: query
        required: false
        description: List of student ids. Accepts repeated params or a comma-separated
          string.
        example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
        style: form
        explode: true
        schema:
          type: array
          items:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    year_groups:
                    - id: 10907398
                      name: IB Diploma Group of 2019 (Grade 12)
                      short_name: IB Diploma Group of 2019
                      program: IB Diploma
                      program_code: diploma
                      grade: Grade 12
                      archived: false
                      grade_number: 13
                      graduation_year: 2025
                      student_ids:
                      - 10193652
                    - id: 11076103
                      name: IB MYP Group of 2019 (Year 4)
                      short_name: IB MYP Group of 2019
                      program: IB Middle Years
                      program_code: myp
                      grade: Year 4
                      archived: false
                      grade_number: 10
                      graduation_year: 2019
                      student_ids:
                      - 12459565
                      - 11456849
                      - 12068809
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 2
                      per_page: 100
  "/v2p3/year-groups/{id}/students":
    get:
      summary: Get Students for a Year Group
      operationId: listStudentsFromYearGroups
      tags:
      - Year Groups
      description: This endpoint retrieves all students belonging to a year group,
        as specified by the year group ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      - name: page
        in: query
        description: An integer defining which page to display.
        required: false
        schema:
          type: string
      - name: per_page
        in: query
        description: An integer defining the number of records to display per page.
        required: false
        schema:
          type: string
      - name: student_ids
        in: query
        required: false
        schema:
          description: List of student ids. Accepts repeated params or a comma-separated
            string.
          example: student_ids=1,2,3 OR student_ids[]=1&student_ids[]=2
          type: array
          items:
            type: integer
          style: form
          explode: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 3
                      per_page: 100
                    student_ids:
                    - 10193652
                    - 12449380
                    - 12569245
                    students:
                    - id: 10193652
                      email: cage@eduvo.com
                      first_name: John
                      last_name: Cage
                      archived: false
                      created_at: '2018-09-15T06:31:08.000-07:00'
                      updated_at: '2021-02-23T00:57:49.000-08:00'
                      last_accessed_at: '2021-02-25T08:13:03.000-08:00'
                      gender: Male
                      birthday: '1994-08-01'
                      mobile_phone_number: ''
                      student_id: '857906'
                      cas_advisor_id: 10559037
                      class_grade: Grade 10
                      class_grade_number: 11
                      program: IB Diploma
                      program_code: diploma
                      ib_group_id: 10342694
                      year_group_id: 10342694
                      parent_ids: []
                      street_address: ''
                      city: New York
                      state: ''
                      zipcode: ''
                      country: US
                      nationalities:
                      - US
                      languages:
                      - ENG
                      - SPA
                      graduating_year: 2023
                      role: Student
                    - id: 12449380
                      email: blue@eduvo.com
                      first_name: Blue Ivy
                      last_name: Carter
                      archived: false
                      created_at: '2014-03-11T06:50:34.000-07:00'
                      updated_at: '2021-02-23T00:57:48.000-08:00'
                      student_id: ''
                      class_grade: Grade 10
                      class_grade_number: 11
                      program: IB Diploma
                      program_code: diploma
                      ib_group_id: 10342694
                      year_group_id: 10342694
                      parent_ids:
                      - 10193613
                      - 12425959
                      nationalities: []
                      languages: []
                      graduating_year: 2023
                      role: Student
                    - id: 12569245
                      email: robyn@managebac.com
                      first_name: Robyn
                      last_name: Anderson
                      archived: false
                      created_at: '2014-10-23T06:12:42.000-07:00'
                      updated_at: '2021-02-23T00:57:49.000-08:00'
                      phone_number: ''
                      mobile_phone_number: ''
                      national_id: ''
                      student_id: ''
                      class_grade: Grade 10
                      class_grade_number: 11
                      program: IB Diploma
                      program_code: diploma
                      ib_group_id: 10342694
                      year_group_id: 10342694
                      parent_ids: []
                      street_address: 99590 Johnson Park
                      street_address_ii: ''
                      city: Fort Lauderdale
                      state: FL
                      zipcode: '72146'
                      country: US
                      nationalities: []
                      languages: []
                      graduating_year: 2023
                      role: Student
  "/v2p3/year-groups/{id}/add_students":
    post:
      summary: Add Students to a Year Group
      operationId: addStudentToYearGroup
      tags:
      - Year Groups
      description: This endpoint adds a list of student IDs to a year group, as specified
        by the year group ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student_ids:
                  description: An array of student IDs to be added to a year group
                  type: array
                  items:
                    type: integer
              required:
              - student_ids
  "/v2p3/year-groups/{id}/remove_students":
    post:
      summary: Remove Students from a Year Group
      operationId: removeStudentToYearGroup
      tags:
      - Year Groups
      description: This endpoint removes a list of student IDs from a year group,
        as specified by the year group ID.
      parameters:
      - name: id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                student_ids:
                  description: An array of Student IDs to remove from the Year Group
                  type: array
                  items:
                    type: integer
              required:
              - student_ids
  "/v2p3/year-groups/{id}/advisors":
    get:
      summary: Get Advisors
      operationId: listAdvisorsFromYearGroup
      tags:
      - Year Groups
      description: Retrieves the Homeroom, CAS, EE, TOK, Project-based Learning advisors
        for a Year Group, specified by `id`. Returns advisor IDs and role abbreviations.
      parameters:
      - name: id
        in: path
        description: Unique identifier for year group.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    advisors:
                    - id: 10193613
                      roles:
                      - homeroom
                      - cas
                      - M25
                      - EXT
                    - id: 12425959
                      roles:
                      - ee
                      - tok
                      - M25
  "/v2p3/classes/{class_id}/teachers":
    get:
      summary: Get Teachers for a Class
      operationId: getTeacherMemberships
      tags:
      - Memberships
      description: This endpoint retrieves all Teachers belonging to a Class as specified
        by class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teachers:
                    - id: 123
                      show_on_reports: true
                      teacher_archived: false
                      first_joined_at: '2025-06-01T12:40:00.000Z'
                      updated_at: '2025-06-01T13:25:15.000Z'
                    - id: 234
                      show_on_reports: false
                      teacher_archived: true
                      first_joined_at: '2025-06-01T13:40:30.000Z'
                      updated_at: '2025-06-01T14:15:00.000Z'
                    meta:
                      current_page: 1
                      total_pages: 1
                      total_count: 2
                      per_page: 100
    put:
      summary: Set Teacher memberships for a Class
      operationId: bulkUpdateTeacherMemberships
      tags:
      - Extended API
      - Classes
      description: Completely replaces the given class's teacher memberships according
        to the provided payload. Specifying a payload of an empty array [] will remove
        all teachers. In addition to defining memberships, also enables or disables
        Show on Reports.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    teachers:
                    - index: 0
                      status: unprocessable_entity
                      errors:
                        id:
                        - can't be blank
                    - index: 1
                      id: 1
                      status: not_found
                    - index: 2
                      id: 2
                      status: ok
        '400':
          description: Bad Request
          content:
            application/json:
              examples:
                example_0:
                  value:
                    error: Invalid payload data structure.
      requestBody:
        content:
          application/json:
            schema:
              "$ref": "#/components/schemas/BulkUpdateTeachers"
  "/v2p3/classes/{class_id}/teachers/add_teachers":
    post:
      summary: Add Teachers to a Class
      operationId: addTeachersToClass
      tags:
      - Classes
      description: This endpoint adds teachers, as specified by teacher ID/s, to a
        class as specified by class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                teacher_ids:
                  description: An array of teacher IDs to add to the class.
                  type: array
                  items:
                    type: integer
              required:
              - teacher_ids
  "/v2p3/classes/{class_id}/teachers/remove_teachers":
    delete:
      summary: Remove Teachers from a Class
      operationId: removeTeachersFromClass
      tags:
      - Memberships
      description: This endpoint removes teachers, as specified by teacher ID/s, from
        a class as specified by class ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        required: true
        schema:
          type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    status: ok
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                teacher_ids:
                  description: An array of teacher IDs to remove from the class.
                  type: array
                  items:
                    type: integer
              required:
              - teacher_ids
  "/v2p3/classes/{class_id}/tasks":
    post:
      summary: Create a Task for a Class
      operationId: createTaskforClass
      tags:
      - Coursework
      description: This endpoint creates a task for a class as specified by class
        ID.
      parameters:
      - name: class_id
        in: path
        description: Unique identifier for class.
        schema:
          type: integer
        required: true
      responses:
        '400':
          description: Bad Request
          content:
            application/json:
              examples:
                example_0:
                  value:
                    error: 'Invalid due_date parameter: ''09-19-2025T25:12:00Z'' is
                      not a valid time.'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      task_category_id:
                        type: array
                        items:
                          type: string
                          example: can't be blank
                      author_id:
                        type: array
                        items:
                          type: string
                          example: is invalid
                      sl:
                        type: array
                        items:
                          type: string
                          example: cat least one must be selected
                      hl:
                        type: array
                        items:
                          type: string
                          example: at least one must be selected
        '201':
          description: Created
          content:
            application/json:
              examples:
                example_0:
                  value:
                    task:
                      id: 22301936
                      name: 'Test Task #3'
                      notes: This is a created task.
                      author:
                        id: 10193613
                      dropbox_opening_days: 0
                      enable_dropbox: true
                      draft: false
                      assessment_type:
                        id: 18
                        kind: formative
                        name: Formative
                      category:
                        id: 1884
                        name: Homework
                      dropbox_id: 11099448
                      google_drive_dropbox: false
                      ib_class_id: 10342450460
                      assigned_students:
                      - 11084385
                      - 10734007
                      due_date: '2025-05-23T15:10:00+03:00'
                      turnitin: true
                      assessments:
                        binary:
                          title: Binary
                        points:
                          title: Points
                          max_points: 25
                        criteria:
                          title: Criteria
                          criterions:
                          - 24
                        comment:
                          title: Comment
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                core_task:
                  "$ref": "#/components/schemas/CoreTaskAttributes"
              required:
              - core_task
        required: true
        description: Task attributes to create
  "/v2p3/year-groups/{id}/projects/cas/experiences/students":
    get:
      summary: Get CAS Experiences for Students in a Year Group
      operationId: listYearGroupCasExperiencesStudents
      tags:
      - Year Groups
      - Projects
      - CAS
      description: This endpoint retrieves CAS experiences for students in a Year
        Group. Results are paginated and can be filtered by student IDs. Each student
        includes a component object containing experiences.
      parameters:
      - name: id
        in: path
        description: Year Group ID
        schema:
          type: integer
        required: true
      - name: student_ids[]
        in: query
        description: Filter by student IDs
        required: false
        schema:
          type: array
          items:
            type: integer
      - name: page
        in: query
        description: Page number for pagination
        required: false
        schema:
          type: integer
      - name: per_page
        in: query
        description: Number of results per page (max 500)
        required: false
        schema:
          type: integer
      responses:
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '404':
          description: Not found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    students:
                    - id: 11084604
                      identifier: STU001
                      component:
                        items:
                        - id: 22301859
                          name: Model United Nations
                          status:
                            post_approved: true
                            pre_approved: true
                            progress:
                              title: completed
                          status_annotations:
                            incomplete: false
                            rejected: false
                            reviewed: true
                          supervisor:
                            name: Jane Smith
                            email: jane.smith@example.com
                            title: Program Coordinator
                            contact_number: "+1234567890"
                          cas_project: true
                          creativity: true
                          creativity_hours: 20.0
                          activity: true
                          activity_hours: 20.0
                          service: true
                          service_hours: 10.0
                          service_action_type: Direct
                          ongoing_approach: true
                          school_based_approach: false
                          community_based_approach: true
                          individual_approach: false
                          start_date: '2025-01-15'
                          end_date: '2025-06-30'
                          slug: experiences
                    - id: 10193652
                      identifier: STU002
                      component:
                        items: []
                    meta:
                      current_page: 1
                      next_page:
                      prev_page:
                      total_pages: 1
                      total_count: 2
                      per_page: 100
              schema:
                "$ref": "#/components/schemas/CasExperiencesStudentsResponse"
  "/v2p3/year-groups/{id}/projects/cas":
    get:
      summary: Get CAS settings for a Year Group
      operationId: getYearGroupCas
      tags:
      - Year Groups
      - Projects
      - CAS
      description: This endpoint retrieves CAS settings and component configuration
        for a Year Group.
      parameters:
      - name: id
        in: path
        description: Year Group ID
        schema:
          type: integer
        required: true
      responses:
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/AccessDeniedError"
        '404':
          description: Not found
          content:
            application/json:
              schema:
                "$ref": "#/components/schemas/NotFound"
        '200':
          description: Success
          content:
            application/json:
              examples:
                example_0:
                  value:
                    cas:
                      components:
                      - slug: experiences
                        label: Experiences
                        track_hours: true
                        show_hours_chart: true
                        cas_total_hours: 150
                        show_aims_and_goals: true
                        optional_question: What are your goals?
                        activity_description_title: Description and Goals
              schema:
                "$ref": "#/components/schemas/CasSettings"
servers:
- url: https://api.managebac.com
  description: CA ManageBac API server.
- url: https://api.managebac.cn
  description: CN ManageBac API server.
- url: https://api.us.managebac.com
  description: US1 ManageBac API server.
- url: https://api.managebac.us
  description: US2 ManageBac API server.
- url: https://api.managebactest.com
  description: UAT ManageBac API server.
- url: https://{Host}
  variables:
    Host:
      default: api.devel.managebac.com
      enum:
      - api.devel.managebac.com
      - api-faria.devel.managebac.com
      - api.managebac.dev
