Xapi.Lrs
0.2.0
dotnet add package Xapi.Lrs --version 0.2.0
NuGet\Install-Package Xapi.Lrs -Version 0.2.0
<PackageReference Include="Xapi.Lrs" Version="0.2.0" />
<PackageVersion Include="Xapi.Lrs" Version="0.2.0" />
<PackageReference Include="Xapi.Lrs" />
paket add Xapi.Lrs --version 0.2.0
#r "nuget: Xapi.Lrs, 0.2.0"
#:package Xapi.Lrs@0.2.0
#addin nuget:?package=Xapi.Lrs&version=0.2.0
#tool nuget:?package=Xapi.Lrs&version=0.2.0
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.
Links
- LRS guide: options, storage, migrations, authentication, limits
- Conformance
- API reference
- Source, issues and changelog
License
Apache License 2.0. The package contains the LICENSE, NOTICE and THIRD-PARTY-NOTICES.md files.
| Product | Versions 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. |
-
net10.0
- Microsoft.EntityFrameworkCore.Relational (>= 10.0.13)
- Xapi.Core (>= 0.2.0)
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 |