Is there a REST Api available for D2L which can be used to make a course inactive?
If it is an existing course, you can use the PUT method to Update a current course offering and set IsActive to false.
PUT /d2l/api/lp/(D2LVERSION: version)/courses/(D2LID: orgUnitId)
It expects the following JSON object:
{
"Name": "<string>",
"Code": "<string>",
"StartDate": "<string:UTCDateTime>|null",
"EndDate": "<string:UTCDateTime>|null",
"IsActive": "<boolean>"
}
You will likely want to retrieve the course offering information first, and then modify the IsActive flag and send back the full object data.
GET /d2l/api/lp/(D2LVERSION: version)/courses/(D2LID: orgUnitId)