Adding .h5p activities programmatically to Drupal 8 nodes
I have tried to use the following code and am passing (to my knowledge) a complete $h5p_content array:
$H5PObj = H5PDrupal::getInstance(); $result = $H5PObj->insertContent($h5p_content, $contentMainId = NULL);
Am I missing something ? Do I need to call another function aside from insertContent()?