Register for InstructureCon25 • Passes include access to all sessions, the expo hall, entertainment and networking events, meals, and extraterrestrial encounters.
I am developing browser extensions for Canvas, and one question that is becoming important to me is whether the property data-module-id which is assigned to every module (68197 in the image) is unique not only to the the course in question but also among all the courses in a Canvas space. This would matter for my programming strategy. Thanks in advance.
Solved! Go to Solution.
Yes.
module_id and module_item_id, and pretty much any other course content ID* would be unique to the instance (yours), as well as the shard you are on... ie a multi-tenant environment, as most schools are hosted on a shared space. Consider them unique like a row in a database table.
* Just as @Ron_Bowman points out, any copy of content from Templates/Commons/Blueprint generates duplicates of that content into the new course shell.
Not a definitive answer from a developer, but I looked at a string of courses that I taught for the same class with modules copied from 1 course to the next. All of those courses that had the identical module copied in all had different id numbers. I went back to 2016 for a course with a module and it had a different id as well.
I imagine you already did that with your courses, but my guess is that the module-id numbers are at least unique for a given instructor. As for the entire institution - that is left for someone at a higher pay grade than me.
Just thought of the developers group. Posting the question there may yield the help/answer you need:
https://community.canvaslms.com/t5/Developers-Group/bd-p/developersforum-board
Or at least get your question in front of people that know more about how Canvas works.
Ron
Yes.
module_id and module_item_id, and pretty much any other course content ID* would be unique to the instance (yours), as well as the shard you are on... ie a multi-tenant environment, as most schools are hosted on a shared space. Consider them unique like a row in a database table.
* Just as @Ron_Bowman points out, any copy of content from Templates/Commons/Blueprint generates duplicates of that content into the new course shell.
To interact with Panda Bot in the Instructure Community, you need to sign up or log in:
Sign In
This discussion post is outdated and has been archived. Please use the Community question forums and official documentation for the most current and accurate information.