Search Departments

Returns departments grouped by academic year for one or more institutions and academic years.

Api

Route
/Departments/api
Method
POST
Key Required
Yes
Common Response
No
Response Type
Array of Department Results

Request Body

academicYearIds (array of integer)
One or more academic year ids to query (from: Get Academic Years)
institutionParentIds (array of integer)
One or more institution ids to query (from: Get Institutions)
includeTerminated (boolean)
When true, includes departments that have been terminated.

Curl Example

curl -X 'POST' \
  'https://prod.assistng.org/Departments/api' \
  -H 'accept: application/json' \
  -H 'API-Key':'<redacted>' \
  -H 'Content-Type: application/json' \
  -d '{
    "academicYearIds": [74],
    "institutionParentIds": [110],
    "includeTerminated": false
  }'
  • academicYearIds = [74] (2023-2024, from Get Academic Years)
  • institutionParentIds = [110] (Allan Hancock College, from Get Institutions)
  • includeTerminated = false (only active departments)
  • API-Key = <redacted> (You’ll need to provide your own key.)

Sample Response

[
  {
    "academicYear": {
      "id": 74,
      "code": "2023-2024",
      "beginDate": "2023-10-01T00:00:00",
      "endDate": "2024-10-01T00:00:00",
      "isOpenForMaintenance": true,
      "isOpenForPublic": true,
      "isOpenForReporting": true
    },
    "departments": [
      {
        "description": "Visual Arts",
        "id": 13008,
        "institutionParentId": 110,
        "parentId": 13000,
        "begin": {
          "yearTermCode": "F2023",
          "id": 291,
          "beginDate": "2023-10-01T00:00:00",
          "endDate": "2024-01-01T00:00:00",
          "description": "Fall 2023",
          "code": "F2023"
        },
        "end": null,
        "code": "VA"
      }
    ]
  }
]

Department Results Model

academicYear (Academic Year)
The academic year these departments belong to.
departments (array of Department)
The departments for this academic year matching the requested institutions. Departments may appear as multiple versioned records linked via parentId.