Xapi.Lrs 0.2.0

dotnet add package Xapi.Lrs --version 0.2.0
                    
NuGet\Install-Package Xapi.Lrs -Version 0.2.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Xapi.Lrs" Version="0.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Xapi.Lrs" Version="0.2.0" />
                    
Directory.Packages.props
<PackageReference Include="Xapi.Lrs" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Xapi.Lrs --version 0.2.0
                    
#r "nuget: Xapi.Lrs, 0.2.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Xapi.Lrs@0.2.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Xapi.Lrs&version=0.2.0
                    
Install as a Cake Addin
#tool nuget:?package=Xapi.Lrs&version=0.2.0
                    
Install as a Cake Tool

Xapi.Lrs

An embeddable Experience API (xAPI 2.0, IEEE 9274.1.1, and 1.0.3) Learning Record Store for ASP.NET Core: minimal API endpoints under a path prefix, version negotiation, Basic or delegated authentication with xAPI scopes, and EF Core storage. It passes the ADL LRS Conformance Test Suite for both versions.

This package needs a database provider, and the provider brings it in. Install one of them:

dotnet add package Xapi.Lrs.Sqlite
dotnet add package Xapi.Lrs.PostgreSql

Usage

In Program.cs, with the SQLite provider:

var builder = WebApplication.CreateBuilder(args);

builder.Services
    .AddXapiLrs(builder.Configuration.GetSection("Lrs"), options => options.MigrateOnStartup = true)
    .UseSqlite("Data Source=lrs.db");

var app = builder.Build();
app.MapXapiLrs("/xapi");
app.Run();

appsettings.json lists the credentials under Lrs, without their secrets:

{
  "Lrs": {
    "Credentials": [ { "Key": "my-app", "Scopes": [ "all" ] } ]
  }
}

The secret comes from user secrets or the environment (Lrs__Credentials__0__Secret). Clients then use https://<your app>/xapi/ as their endpoint, with the key my-app and that secret.

Target frameworks

net10.0. EF Core cannot be trimmed or published with Native AOT, so neither can this package.

License

Apache License 2.0. The package contains the LICENSE, NOTICE and THIRD-PARTY-NOTICES.md files.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on Xapi.Lrs:

Package Downloads
Xapi.Lrs.PostgreSql

PostgreSQL storage for the Xapi.Lrs Learning Record Store: UsePostgreSql(connectionString) and migrations.

Xapi.Lrs.Sqlite

SQLite storage for the Xapi.Lrs Learning Record Store: UseSqlite(connectionString), migrations, WAL mode and serialized writes.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.2.0 50 10/17/2026
0.1.0-preview.1 42 10/17/2026