PHPackages                             tinhr/laravel-h5p - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. tinhr/laravel-h5p

ActivePackage

tinhr/laravel-h5p
=================

H5P integration for Laravel without any additional dependencies.

08PHP

Since Jun 19Pushed 10mo agoCompare

[ Source](https://github.com/iamtinhr/Laravel-H5P)[ Packagist](https://packagist.org/packages/tinhr/laravel-h5p)[ RSS](/packages/tinhr-laravel-h5p/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Headless H5P Laravel API
========================

[](#headless-h5p-laravel-api)

Forked from [https://github.com/EscolaLMS](https://github.com/EscolaLMS/h5p)

Description
-----------

[](#description)

This package provides a Laravel API for interacting with H5P content without installing ***unrelated*** dependencies.

Main repository requires 8 unrelated packages - most of them are escolalms dependencies - to be installed:

- EscolaLms/core
- EscolaLms/auth
- EscolaLms/settings
- EscolaLms/files
- EscolaLms/categories
- EscolaLms/model-fields
- spatie/permission
- laravel/socialite

Original Documentation
======================

[](#original-documentation)

Features
--------

[](#features)

The lib allows headlessly

- play all h5p content - exposed all essential data, yet player is needed
- edit all h5p content - exposed all essential data, yet editor is needed
- CRUD libraries
- CRUD content
- upload library from `.h5p` file
- upload content from `.h5p` file

See [Swagger](https://escolalms.github.io/H5P/) documented endpoints.

Some [tests](tests) can also be a great point of start.

To play the content you can use [EscolaLMS H5P Player](https://github.com/EscolaLMS/H5P-player)

Install
-------

[](#install)

1. `composer require brnysn/headless-h5p`
2. `php artisan migrate`
3. `php artisan h5p:storage-link` see below

### Storage links

[](#storage-links)

You need to publish many of files to be availabe as public link.

`php artisan h5p:storage-link` which creates a symbolic link from `storage/app/h5` and `vendor/h5p/h5p-core` and `vendor/h5p/h5p-editor` to be accesible to public, as follows

```
public_path('h5p') => storage_path('app/h5p'),
public_path('h5p-core') => base_path().'vendor/h5p/h5p-core',
public_path('h5p-editor') => base_path().'vendor/h5p/h5p-editor',

```

### Cors

[](#cors)

All the endpoints need to be accesible from other domains, so [CORS](https://laravel.com/docs/8.x/routing#cors) must be properlly set.

Except of endpoints assets must expose CORS headers as well. You achive that by setting Apache/Nginx/Caddy/Whatever settings - below is example for Nginx for wildcard global access.

```
location ~* \.(eot|ttf|woff|woff2|jpg|jpeg|gif|png|wav|mp3|mp4|mov|ogg|webv)$ {
    add_header Access-Control-Allow-Origin *;
}

```

### Authorisation

[](#authorisation)

Most of the endpoints require authorisation, this is possible with laravel passport

There is a [seeder](database/seeders/PermissionTableSeeder.php) to must be run in order to authrize

User model is taken from [Auth](https://github.com/EscolaLMS/Auth) package.

### Seeder

[](#seeder)

To seed content and library

```
php artisan db:seed --class="\EscolaLms\HeadlessH5P\Database\Seeders\ContentLibrarySeeder"

```

You can seed library and content with build-in seeders as command that are accessible with

- `php artisan h5p:seed` to add just libraries
- `php artisan h5p:seed --addContent` to add content with libraries

Road map
--------

[](#road-map)

- rewrite h5p core in a way like [luminare in typescript](https://github.com/lumieducation/lumi)

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance38

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity14

Early-stage or recently created project

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/7488c1407b51f24238323de8495e8447f979a9e6040d79b3e54ea6abbe5b6caa?d=identicon)[iamtinhr](/maintainers/iamtinhr)

---

Top Contributors

[![qunabu](https://avatars.githubusercontent.com/u/214608?v=4)](https://github.com/qunabu "qunabu (75 commits)")[![brnysn](https://avatars.githubusercontent.com/u/31011885?v=4)](https://github.com/brnysn "brnysn (52 commits)")[![KrzysztofDziedziechEscolasoft](https://avatars.githubusercontent.com/u/96292232?v=4)](https://github.com/KrzysztofDziedziechEscolasoft "KrzysztofDziedziechEscolasoft (21 commits)")[![dyfero](https://avatars.githubusercontent.com/u/59400506?v=4)](https://github.com/dyfero "dyfero (16 commits)")[![HerbertIV](https://avatars.githubusercontent.com/u/62691459?v=4)](https://github.com/HerbertIV "HerbertIV (5 commits)")[![mako321](https://avatars.githubusercontent.com/u/59456825?v=4)](https://github.com/mako321 "mako321 (4 commits)")[![krzEscola](https://avatars.githubusercontent.com/u/85549830?v=4)](https://github.com/krzEscola "krzEscola (3 commits)")[![iamtinhr](https://avatars.githubusercontent.com/u/151376853?v=4)](https://github.com/iamtinhr "iamtinhr (1 commits)")[![pa-cholek](https://avatars.githubusercontent.com/u/5345420?v=4)](https://github.com/pa-cholek "pa-cholek (1 commits)")

### Embed Badge

![Health badge](/badges/tinhr-laravel-h5p/health.svg)

```
[![Health](https://phpackages.com/badges/tinhr-laravel-h5p/health.svg)](https://phpackages.com/packages/tinhr-laravel-h5p)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
