I've been looking at how LTI integration works between Opencast and a
couple of VLE's for testing - Moodle/Canvas.
Based on the docs[1], it seems that the suggested integration is based
on the role permissions for a series/event which map to the LTI
`context_id` and `roles` parameters passed from the LTI consumer.
E.g. The following LTI parameters would grant access to any series/event
that has the role permission Course1_Learner:
context_id=Course1
roles=Learner
However, a Canvas context_id always seems to be a long random
string/hash (e.g. context_id: 88935db1d505f9c8df590947ed78185a585f8128)
from which you can't determine the associated course within Canvas[2],
even through the APIs[3]. There doesn't seem to be a way of overriding
the value of the context_id to set it to a meaningful name (Course Code
for example), so series identifiers in Opencast would need to match this
unfriendly hash string but we'd also need to know this value in advance
when creating recordings (with Galicaster for example).
Canvas also sends the Course Code as `context_label` and Course Name as
`context_title` which would seem like more sensible names to use as a
series identifier.
Has anyone integrated Canvas with Opencast via LTI and managed to
configure the context_id with a meaningful name?
If not I'm wondering whether it might be worth making Opencast read a
custom parameter that defines which other parameter to use as the
context_id, e.g. `custom_context_id_param=context_label`, falling back
to `context_id` if the `custom_context_id_param` doesn't exist or the
value of the specified param isn't valid? Credit to Paul Pettit for this
idea, apparently this method/approach has been used by other LTI providers.
With Moodle, it seems the `context_id` maps nicely to the course id so
the same issue isn't present here. However I'm a bit confused about how
to do variable substitution in Moodle when setting up the tool..
In Canvas I would set the custom fields to be:
tool=ltitools/series/index.html
series=$Context.id
In Moodle, there doesn't appear to be a way to substitute the
course/context_id to have it automatically configured per course. Has
anyone managed to achieve this? Not really an Opencast issue but others
may have figured this out - at the moment I'm just hard coding the
course id for the custom series parameter.
Thanks,
Paul
[1]
https://docs.opencast.org/develop/admin/modules/ltimodule/#lti-roles
[2]
https://community.canvaslms.com/thread/19463-search-courses-by-contextid
[3]
https://canvas.instructure.com/doc/api/index.html
--
Paul Gration
Multimedia Development
University of Sussex
+44 (0) 1273 873269