openapi: 3.0.3 info: title: D2L Brightspace Valence Learning Framework Assignments Org Units API description: 'The Valence Learning Framework API is the public REST API for the D2L Brightspace learning management system (LMS). It is served from an institution''s own Brightspace host under https://{host}/d2l/api/ and is divided into two product components: "lp" (Learning Platform - users, roles, enrollments, org units, and Data Hub) and "le" (Learning Environment - content, grades, assignments/dropbox, quizzes, discussions, calendar, news, and learning outcomes). Each component is independently versioned; the version segment in a route (for example lp/1.53 or le/1.92) varies by installed Brightspace product version, and clients should confirm supported versions via GET /d2l/api/versions/ before hard-coding a value. Requests are authenticated with OAuth 2 bearer tokens issued by the D2L auth service (https://auth.brightspace.com/core/connect/token) using the authorization code grant; the older ID-Key (app-id/user-id signed URL) scheme is deprecated. Scopes take the form group:resource:action, for example users:userdata:read. The version values baked into the paths below are illustrative of a recent release and must be adjusted to the target instance. "Valence" is the historical name of the API framework; "D2L" is the vendor and "Brightspace" the product.' version: '1.0' contact: name: D2L Developer Platform url: https://docs.valence.desire2learn.com license: name: D2L Developer Terms url: https://www.d2l.com/legal/ servers: - url: https://{host}/d2l/api description: An institution's Brightspace instance variables: host: default: myschool.brightspace.com description: Your Brightspace instance hostname. security: - oauth2: [] tags: - name: Org Units description: Organization structure, course offerings, departments, and semesters. paths: /lp/1.53/orgstructure/: get: operationId: listOrgStructure tags: - Org Units summary: List org units description: Retrieves a paged list of org units in the organization structure, filterable by type and other query parameters. parameters: - name: orgUnitType in: query schema: type: integer - name: bookmark in: query schema: type: string responses: '200': description: A paged list of org units. content: application/json: schema: $ref: '#/components/schemas/OrgUnitPagedResultSet' /lp/1.53/orgstructure/{orgUnitId}: parameters: - $ref: '#/components/parameters/OrgUnitId' get: operationId: getOrgUnit tags: - Org Units summary: Get an org unit description: Retrieves the properties of the identified org unit. responses: '200': description: The requested org unit. content: application/json: schema: $ref: '#/components/schemas/OrgUnit' /lp/1.53/orgstructure/{orgUnitId}/children/: get: operationId: listOrgUnitChildren tags: - Org Units summary: List an org unit's children description: Retrieves the child org units of the identified org unit. parameters: - $ref: '#/components/parameters/OrgUnitId' responses: '200': description: A list of child org units. content: application/json: schema: type: array items: $ref: '#/components/schemas/OrgUnit' /lp/1.53/courses/{orgUnitId}: parameters: - $ref: '#/components/parameters/OrgUnitId' get: operationId: getCourseOffering tags: - Org Units summary: Get a course offering description: Retrieves the CourseOffering information for the identified course org unit. responses: '200': description: The course offering. content: application/json: schema: $ref: '#/components/schemas/CourseOffering' /lp/1.53/organization/info: get: operationId: getOrganizationInfo tags: - Org Units summary: Get organization info description: Retrieves top-level information about the organization. responses: '200': description: Organization info. content: application/json: schema: $ref: '#/components/schemas/Organization' components: schemas: PagingInfo: type: object properties: Bookmark: type: string HasMoreItems: type: boolean OrgUnit: type: object properties: Identifier: type: string Name: type: string Code: type: string Type: type: object properties: Id: type: integer Code: type: string Name: type: string CourseOffering: type: object properties: Identifier: type: string Name: type: string Code: type: string IsActive: type: boolean StartDate: type: string format: date-time EndDate: type: string format: date-time Organization: type: object properties: Identifier: type: string Name: type: string TimeZone: type: string OrgUnitPagedResultSet: type: object properties: PagingInfo: $ref: '#/components/schemas/PagingInfo' Items: type: array items: $ref: '#/components/schemas/OrgUnit' parameters: OrgUnitId: name: orgUnitId in: path required: true schema: type: integer format: int64 securitySchemes: oauth2: type: oauth2 description: OAuth 2 authorization code grant. Tokens are issued by the D2L auth service. Scopes take the form group:resource:action (for example users:userdata:read). flows: authorizationCode: authorizationUrl: https://auth.brightspace.com/oauth2/auth tokenUrl: https://auth.brightspace.com/core/connect/token scopes: core:*:*: Full access consistent with the registered application users:userdata:read: Read user data enrollment:orgunit:read: Read enrollments datahub:dataexports:read: Read Data Hub exports