basePath: /v1.2 definitions: BadRequest: properties: message: type: string type: object Credentials: properties: district_username: type: string type: object District: properties: id: type: string x-validation: true mdr_number: type: string x-nullable: true name: type: string type: object DistrictAdmin: properties: district: type: string x-validation: true email: type: string id: type: string x-validation: true name: $ref: '#/definitions/Name' x-nullable: true title: type: string x-nullable: true type: object DistrictAdminResponse: properties: data: $ref: '#/definitions/DistrictAdmin' type: object DistrictAdminsResponse: properties: data: items: $ref: '#/definitions/DistrictAdmin' type: array type: object DistrictResponse: properties: data: $ref: '#/definitions/District' type: object DistrictStatus: properties: error: type: string id: type: string x-validation: true instant_login: type: boolean last_sync: format: datetime type: string x-nullable: true x-validation: true launch_date: format: datetime type: string x-validation: true pause_end: format: datetime type: string x-nullable: true x-validation: true pause_start: format: datetime type: string x-nullable: true x-validation: true sis_type: type: string x-validation: true state: enum: - running - pending - error - paused type: string x-validation: true type: object DistrictStatusResponse: properties: data: $ref: '#/definitions/DistrictStatus' type: object DistrictStatusResponses: properties: data: items: $ref: '#/definitions/DistrictStatusResponse' type: array type: object DistrictsResponse: properties: data: items: $ref: '#/definitions/DistrictResponse' type: array type: object GradeLevelsResponse: properties: data: items: type: string type: array type: object InternalError: properties: message: type: string type: object Location: properties: address: type: string x-nullable: true city: type: string x-nullable: true lat: type: string x-nullable: true lon: type: string x-nullable: true state: type: string x-nullable: true zip: type: string x-nullable: true type: object Name: properties: first: type: string x-nullable: true last: type: string x-nullable: true middle: type: string x-nullable: true type: object NotFound: properties: message: type: string type: object Principal: properties: email: type: string x-nullable: true name: type: string x-nullable: true type: object School: properties: created: format: datetime type: string x-validation: true district: type: string x-validation: true high_grade: enum: - "1" - "2" - "3" - "4" - "5" - "6" - "7" - "8" - "9" - "10" - "11" - "12" - PreKindergarten - Kindergarten - PostGraduate - Other type: string x-nullable: true x-validation: true id: type: string x-validation: true last_modified: format: datetime type: string x-validation: true location: $ref: '#/definitions/Location' x-nullable: true low_grade: enum: - "1" - "2" - "3" - "4" - "5" - "6" - "7" - "8" - "9" - "10" - "11" - "12" - PreKindergarten - Kindergarten - PostGraduate - Other type: string x-nullable: true x-validation: true mdr_number: type: string x-nullable: true name: type: string nces_id: type: string x-nullable: true phone: type: string x-nullable: true principal: $ref: '#/definitions/Principal' school_number: type: string sis_id: type: string state_id: type: string x-nullable: true type: object SchoolAdmin: properties: credentials: $ref: '#/definitions/Credentials' district: type: string x-validation: true email: type: string id: type: string x-validation: true name: $ref: '#/definitions/Name' schools: items: type: string type: array x-validation: true staff_id: type: string title: type: string x-nullable: true type: object SchoolAdminResponse: properties: data: $ref: '#/definitions/SchoolAdmin' type: object SchoolAdminsResponse: properties: data: items: $ref: '#/definitions/SchoolAdminResponse' type: array type: object SchoolResponse: properties: data: $ref: '#/definitions/School' type: object SchoolsResponse: properties: data: items: $ref: '#/definitions/SchoolResponse' type: array type: object Section: properties: course_description: type: string x-nullable: true course_name: type: string x-nullable: true course_number: type: string x-nullable: true created: format: datetime type: string x-validation: true district: type: string x-validation: true grade: enum: - "1" - "2" - "3" - "4" - "5" - "6" - "7" - "8" - "9" - "10" - "11" - "12" - PreKindergarten - Kindergarten - PostGraduate - Other type: string x-nullable: true x-validation: true id: type: string x-validation: true last_modified: format: datetime type: string x-validation: true name: type: string period: type: string x-nullable: true school: type: string x-validation: true section_number: type: string x-nullable: true sis_id: type: string students: items: type: string type: array x-validation: true subject: enum: - english/language arts - math - science - social studies - language - homeroom/advisory - interventions/online learning - technology and engineering - PE and health - arts and music - other type: string x-validation: true teacher: type: string x-nullable: true x-validation: true teachers: items: type: string type: array x-validation: true term: $ref: '#/definitions/Term' x-nullable: true type: object SectionResponse: properties: data: $ref: '#/definitions/Section' type: object SectionsResponse: properties: data: items: $ref: '#/definitions/SectionResponse' type: array type: object Student: properties: created: format: datetime type: string x-validation: true credentials: $ref: '#/definitions/Credentials' district: type: string x-validation: true dob: pattern: (?:[0-9]{1,2})/([0-9]{1,2})/([0-9]{4}) type: string x-nullable: true x-validation: true ell_status: enum: - "Y" - "N" - "" type: string x-nullable: true x-validation: true email: type: string x-nullable: true gender: enum: - M - F - "" type: string x-nullable: true x-validation: true grade: enum: - "1" - "2" - "3" - "4" - "5" - "6" - "7" - "8" - "9" - "10" - "11" - "12" - PreKindergarten - Kindergarten - PostGraduate - Other type: string x-nullable: true x-validation: true graduation_year: type: string x-nullable: true x-validation: true hispanic_ethnicity: enum: - "Y" - "N" - "" type: string x-nullable: true x-validation: true id: type: string x-validation: true last_modified: format: datetime type: string x-validation: true location: $ref: '#/definitions/Location' x-nullable: true name: $ref: '#/definitions/Name' race: enum: - Caucasian - Asian - Black or African American - American Indian - Hawaiian or Other Pacific Islander - Two or More Races - Unknown - "" type: string x-nullable: true x-validation: true school: type: string x-validation: true schools: items: type: string type: array x-validation: true sis_id: type: string state_id: type: string x-nullable: true student_number: type: string x-nullable: true type: object StudentContact: properties: district: type: string x-validation: true email: type: string x-nullable: true id: type: string x-validation: true name: type: string phone: type: string x-nullable: true phone_type: type: string x-nullable: true relationship: type: string x-nullable: true sis_id: type: string x-nullable: true student: type: string x-validation: true type: type: string type: object StudentContactResponse: properties: data: $ref: '#/definitions/StudentContact' type: object StudentContactsForStudentResponse: properties: data: items: $ref: '#/definitions/StudentContact' type: array type: object StudentContactsResponse: properties: data: items: $ref: '#/definitions/StudentContactResponse' type: array type: object StudentResponse: properties: data: $ref: '#/definitions/Student' type: object StudentsResponse: properties: data: items: $ref: '#/definitions/StudentResponse' type: array type: object Teacher: properties: created: format: datetime type: string x-validation: true credentials: $ref: '#/definitions/Credentials' x-nullable: true district: type: string x-validation: true email: type: string x-nullable: true id: type: string x-validation: true last_modified: format: datetime type: string x-validation: true name: $ref: '#/definitions/Name' school: type: string x-validation: true schools: items: type: string type: array x-validation: true sis_id: type: string state_id: type: string x-nullable: true teacher_number: type: string x-nullable: true title: type: string x-nullable: true type: object TeacherResponse: properties: data: $ref: '#/definitions/Teacher' type: object TeachersResponse: properties: data: items: $ref: '#/definitions/TeacherResponse' type: array type: object Term: properties: end_date: format: datetime type: string x-nullable: true x-validation: true name: type: string x-nullable: true start_date: format: datetime type: string x-nullable: true x-validation: true type: object host: api.clever.com info: description: Serves the Clever Data API title: Data API version: 1.2.0 paths: /contacts: get: description: Returns a list of student contacts operationId: getContacts parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentContactsResponse' tags: - Contacts /contacts/{id}: get: description: Returns a specific student contact operationId: getContact parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentContactResponse' "404": $ref: '#/responses/NotFound' tags: - Contacts /contacts/{id}/district: get: description: Returns the district for a student contact operationId: getDistrictForStudentContact parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Contacts /contacts/{id}/student: get: description: Returns the student for a student contact operationId: getStudentForContact parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentResponse' "404": $ref: '#/responses/NotFound' tags: - Contacts /district_admins: get: description: Returns a list of district admins operationId: getDistrictAdmins parameters: - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: show_links type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictAdminsResponse' tags: - District Admins /district_admins/{id}: get: description: Returns a specific district admin operationId: getDistrictAdmin parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictAdminResponse' "404": $ref: '#/responses/NotFound' tags: - District Admins /districts: get: description: Returns a list of districts. In practice this will only return the one district associated with the bearer token operationId: getDistricts responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictsResponse' tags: - Districts /districts/{id}: get: description: Returns a specific district operationId: getDistrict parameters: - in: path name: id required: true type: string - in: query name: include type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/admins: get: description: Returns the admins for a district operationId: getAdminsForDistrict parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictAdminsResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/schools: get: description: Returns the schools for a district operationId: getSchoolsForDistrict parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolsResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/sections: get: description: Returns the sections for a district operationId: getSectionsForDistrict parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionsResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/status: get: description: Returns the status of the district operationId: getDistrictStatus parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictStatusResponses' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/students: get: description: Returns the students for a district operationId: getStudentsForDistrict parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentsResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /districts/{id}/teachers: get: description: Returns the teachers for a district operationId: getTeachersForDistrict parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeachersResponse' "404": $ref: '#/responses/NotFound' tags: - Districts /school_admins: get: description: Returns a list of school admins operationId: getSchoolAdmins parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolAdminsResponse' tags: - School Admins /school_admins/{id}: get: description: Returns a specific school admin operationId: getSchoolAdmin parameters: - in: path name: id required: true type: string - in: query name: include type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolAdminResponse' "404": $ref: '#/responses/NotFound' tags: - School Admins /school_admins/{id}/schools: get: description: Returns the schools for a school admin operationId: getSchoolsForSchoolAdmin parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolsResponse' "404": $ref: '#/responses/NotFound' tags: - School Admins /schools: get: description: Returns a list of schools operationId: getSchools parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolsResponse' tags: - Schools /schools/{id}: get: description: Returns a specific school operationId: getSchool parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolResponse' "404": $ref: '#/responses/NotFound' tags: - Schools /schools/{id}/district: get: description: Returns the district for a school operationId: getDistrictForSchool parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Schools /schools/{id}/sections: get: description: Returns the sections for a school operationId: getSectionsForSchool parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionsResponse' "404": $ref: '#/responses/NotFound' tags: - Schools /schools/{id}/students: get: description: Returns the students for a school operationId: getStudentsForSchool parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentsResponse' "404": $ref: '#/responses/NotFound' tags: - Schools /schools/{id}/teachers: get: description: Returns the teachers for a school operationId: getTeachersForSchool parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeachersResponse' "404": $ref: '#/responses/NotFound' tags: - Schools /sections: get: description: Returns a list of sections operationId: getSections parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionsResponse' tags: - Sections /sections/{id}: get: description: Returns a specific section operationId: getSection parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /sections/{id}/district: get: description: Returns the district for a section operationId: getDistrictForSection parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /sections/{id}/school: get: description: Returns the school for a section operationId: getSchoolForSection parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /sections/{id}/students: get: description: Returns the students for a section operationId: getStudentsForSection parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentsResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /sections/{id}/teacher: get: description: Returns the primary teacher for a section operationId: getTeacherForSection parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeacherResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /sections/{id}/teachers: get: description: Returns the teachers for a section operationId: getTeachersForSection parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeachersResponse' "404": $ref: '#/responses/NotFound' tags: - Sections /students: get: description: Returns a list of students operationId: getStudents parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentsResponse' tags: - Students /students/{id}: get: description: Returns a specific student operationId: getStudent parameters: - in: path name: id required: true type: string - in: query name: include type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentResponse' "404": $ref: '#/responses/NotFound' tags: - Students /students/{id}/contacts: get: description: Returns the contacts for a student operationId: getContactsForStudent parameters: - in: path name: id required: true type: string - in: query name: limit type: integer responses: "200": description: OK Response schema: $ref: '#/definitions/StudentContactsForStudentResponse' "404": $ref: '#/responses/NotFound' tags: - Students /students/{id}/district: get: description: Returns the district for a student operationId: getDistrictForStudent parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Students /students/{id}/school: get: description: Returns the primary school for a student operationId: getSchoolForStudent parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolResponse' "404": $ref: '#/responses/NotFound' tags: - Students /students/{id}/sections: get: description: Returns the sections for a student operationId: getSectionsForStudent parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionsResponse' "404": $ref: '#/responses/NotFound' tags: - Students /students/{id}/teachers: get: description: Returns the teachers for a student operationId: getTeachersForStudent parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeachersResponse' "404": $ref: '#/responses/NotFound' tags: - Students /teachers: get: description: Returns a list of teachers operationId: getTeachers parameters: - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string - in: query name: where type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeachersResponse' tags: - Teachers /teachers/{id}: get: description: Returns a specific teacher operationId: getTeacher parameters: - in: path name: id required: true type: string - in: query name: include type: string responses: "200": description: OK Response schema: $ref: '#/definitions/TeacherResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers /teachers/{id}/district: get: description: Returns the district for a teacher operationId: getDistrictForTeacher parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/DistrictResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers /teachers/{id}/grade_levels: get: description: Returns the grade levels for sections a teacher teaches operationId: getGradeLevelsForTeacher parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/GradeLevelsResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers /teachers/{id}/school: get: description: Retrieves school info for a teacher. operationId: getSchoolForTeacher parameters: - in: path name: id required: true type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SchoolResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers /teachers/{id}/sections: get: description: Returns the sections for a teacher operationId: getSectionsForTeacher parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/SectionsResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers /teachers/{id}/students: get: description: Returns the students for a teacher operationId: getStudentsForTeacher parameters: - in: path name: id required: true type: string - in: query name: limit type: integer - in: query name: starting_after type: string - in: query name: ending_before type: string responses: "200": description: OK Response schema: $ref: '#/definitions/StudentsResponse' "404": $ref: '#/responses/NotFound' tags: - Teachers produces: - application/json responses: BadRequest: description: Bad Request schema: $ref: '#/definitions/BadRequest' InternalError: description: Internal Error schema: $ref: '#/definitions/InternalError' NotFound: description: Entity Not Found schema: $ref: '#/definitions/NotFound' schemes: - https security: - oauth: [] securityDefinitions: oauth: authorizationUrl: https://clever.com/oauth/authorize flow: accessCode tokenUrl: https://clever.com/oauth/tokens type: oauth2 swagger: "2.0" x-samples-languages: - curl - node - ruby - python - php - java - go