joerg edited this page Oct 27, 2018 · 21 revisions

lxHive

Introduction

lxHive is a new LRS (Learning Record Store), actively developed by Brightcookie G3 International. It's main intent is to be an intersection between flexibility, readability and speed.

Features

  • Aims to implement the xAPI spec in its entirety
  • Follows OpenSource PHP-FIG conventions and coding standards
  • Built on top of a solid and extensively tested framework - Slim
  • Tested and well-documented

Supported xAPI versions

  • 1.0.3

Installation

Requirements

You should use composer to install lxHive. It will automatically install any dependencies you might need and want.

API

xAPI introduction

xAPI is a service that allows for statements of experience to be delivered to and stored securely in a Learning Record Store (LRS). The xAPI specification is maintainted by the Advanced Distributed Learning (ADL) Initiative, sponsored by the Office of the United States Under Secretary of Defense for Personnel and Readiness.

Supported xAPI endpoints

All xAPI endpoints, as specified by the xAPI spec, are supported.

Additional endpoints and parameters

In addition, lxHive supports several additional, non-spec endpoints and parameters by default.

These include:

An additional count parameter is provided in the root of the returned document to help developers iterate through all of the Statements.

Stored statements with file attachments are always served as type application/json with a fileUrl (GET).

Extending lxHive

Extending lxHive is easy. It's as simple as creating a couple new classes and adding them to your project. We are working towards adding an even simpler integration model, where you'd only need to include a composer package to add a new feature.

Plus endpoints

lxHive was written ground up with the goal of being easily extensible. As such, it is simple to add your own endpoints in the Plus namespace. To add a new basic endpoint you will most likely create 3 files - a controller, residing in the "Resource/{version}" folder, a "Service" where you manipulate/parse any data that needs to be presented and a "View" which is then presented to the user. More advanced use cases may require adding a new MongoDB collection and documents.

xAPI Versioning

When issuing all requests, except to /about and /oauth endpoints, you must include the X-API-Version header, so that lxHive knows by which version of the xAPI spec it should treat your request. As a result of careful planning, lxHive is inherently backwards and forwards compatible, meaning your xAPI-reliant apps will never stop working.

Server modes

lxHive can run either in development or production mode. When in development mode, stack traces are printed when errors and exceptions are raised instead of their xAPI spec counterparts. This is important when testing xAPI spec compliance, as you will get several failures if you do not switch to production mode.

The server mode can be specified during setup, written directly in your Config.yml file or overridden using the SLIM_MODE environment variable. The names of the modes for production and development are "production" and "development", respectively.

Authorisation model

Clients

A client is the application that is requesting the permissions in the users' name. This is usually an LMS or a standalone activity.

Agents

An agent is classified as a Person, which is the actual end-user performing all the actions that need to be tracked via xAPI.

Basic authentication

lxHive supports basic authentication as a method to authenticate. At the moment, setting up a basic token is recommended for machine-to-machine communication and for creation of administrative supertokens.

OAuth

lxHive supports OAuth 2.0 out of the box. Currently, we support the "Auth Code" flow. It is the preferred method of authentication when dealing with end users (real humans).

Administration

Using the console

Using the configuration files

Functional tests

The aim of the lxHive is to eventually achieve full (100%) compatibility with ADL's official test suite. We also regularly perform tests using other tools such as our own proprietary test suites, one of which is publicly available here.

Semantic versioning

lxHive follows the guidelines of semantic versioning, as described here.

Development guidelines

If you're a developer, we greatly encourage you to open issues, make enhancements and fix any bugs you might find. When doing so, you should follow our development guidelines.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.