从Valence的课程名称中获取orgUnitId

I'm trying to retrieve the orgUnitId of a course from the full course name (ie: CHM-1210-01 - General Chemistry I). Any suggestions on how to get the orgUnitId from this?

I've tried /d2l/api/lp/(version)/courses/?Name=CHM-1210-01 - General Chemistry I and /d2l/api/lp/(version)/courses/?Name=CHM-1210-01%20-%20General%20Chemistry%20I with no success.

Any help would be appreciated!

Thanks in advance,

--Valence Newbie

Check out the documentation for GET /d2l/api/lp/(version)/orgstructure/

http://docs.valence.desire2learn.com/res/orgunit.html#get--d2l-api-lp-(version)-orgstructure-

It has options for OrgUnitType (set to whatever your orgUnitTypeId is for courses) and orgUnitName which would be your course name. Then it would return matching org units.

As per the documentation the query parameter you should be using is "orgUnitName" (not "Name").