Including H5P Activities in the Cloning Routine

We’re currently building Pressbooks and embedding interactive content using the H5P plugin for WordPress. H5P activities are created in/for individual sites/books, and once published can be embedded anywhere. The plugin allows us to embed the activities using shortcodes, which most authors do. One problem that we’re encountering is that we haven’t yet tightly integrated H5P activities with the Pressbooks cloning routine. My understanding (which is admittedly limited) is that while H5P does provide an javascript API: https://h5p.org/documentation/api/H5P.html, it doesn’t currently produce the REST API endpoints we would need to clone these activities along with other content in a Pressbooks.

As I understand it, in order to allow H5P activities in book to be cloned using the Pressbooks cloning tool, two things need to happen: 1) REST API endpoints need to be added to H5P activities via the WordPress REST API and 2) The Pressbooks cloning routine should be modified so that it looks for and copy/clones any H5P activities exposed via the WordPress REST API. I’m interested in working with the H5P developer community to do #1, namely, to add custom endpoints to their H5P activities in their WordPress plugin. I’m sharing this here in the hope that others in the Pressbooks community may be interested in this work and can help me to better describe the use case and technical requirements for the H5P folks and because others here might be able to either figure out how to fund or contribute to a pull request with H5P and then move on to doing #2 above. Thoughts/advice/discussion/direction welcome!

1 Like

We pursued H5P in the past, but student data/security concerns came up and the project fizzled. I love the tool, however, and would like to use it in projects I currently have brewing, so I’ll bring up your interests to a few of my colleagues on the Dev team at my Uni and see what insights they have to offer for most efficiently accomplishing the aforementioned.

I filed an issue on the H5P WordPress plugin GitHub repo, and it has been assigned to a developer there (who is currently on vacation). Anyone interested in monitoring that conversation can see: https://github.com/h5p/h5p-wordpress-plugin/issues/63

1 Like

The developer responsible for H5P’s wordpress plugin has replied:

“This sounds like an interesting project and without looking at what’s really needed in details, I can’t see any reason why the H5P plugin shouldn’t offer these kinds of endpoints and features. I’m happy to help or contribute in any way I can. If you’d like an offer on the work, feel free to send us a detail description of the requirements.”

Are there others in the PB community (@paradisojr @brad, @shiflet.16, @ned) who would be interested in co-writing these requirements with me so that we can get a development bid/estimate from Joubel?

2 Likes

FYI @dac.chartrand.

We have some time dedicated to investigating interactive content more thoroughly over this sprint and next sprint. Let’s follow up on this later in the week.

1 Like

I’m in. Let me know how you’d like to proceed, Steel. (BTW: I finally got POS2041 - American Government up and running in Pressbooks [w/H5P activities]. Chapter 1 went live today!)

1 Like