NP.Lti13Platform is a .NET 8 project that provides an implementation of an LTI 1.3 platform. This project is a wrapper for the other LTI 1.3 projects. For specific information regarding any of the specific specs, please see their respective projects.
- LTI 1.3 Core (Launch)
- Deep Linking
- Assignment and Grade Services
- Name and Role Provisioning Services
-
Add the nuget package to your project:
-
Add an implementation of the
IDataService
interface:
public class DataService: IDataService
{
...
}
- Add the required services (most configurations are optional, the required configurations are shown):
*For information regarding configurations, please see the individual projects.
builder.Services
.AddLti13Platform()
.WithLti13DataService<DataService>();
- Setup the routing for the LTI 1.3 platform endpoints:
app.UseLti13Platform();
There is no default IDataService
implementation to allow each project to store the data how they see fit.
The IDataService
interface is a combination of all data services required for all the specs of the LTI 1.3 platform. Each service can be individually overridden instead of implementing the entire data service in a single service.
builder.Services
.AddLti13Platform()
- .WithLti13DataService<DataService>();
+ .WithLti13CoreDataService<CoreDataService>()
+ .WithLti13DeepLinkingDataService<DeepLinkingDataService>()
+ .WithLti13AssignmentGradeDataService<AssignmentGradeDataService>()
+ .WithLti13NameRoleProvisioningDataService<NameRoleProvisioningDataService>();
All of the internal services are transient and therefore the data services may be added at any scope (Transient, Scoped, Singleton).
Many of the specs have default implementations that use a static configuration on startup. If you can't configure the services at startup you can add your own implementation of the services.
builder.Services
.AddLti13Platform()
.WithLti13DataService<DataService>()
+ .WithLti13TokenConfigService<TokenService>()
+ .WithLti13PlatformService<PlatformService>()
+ .WithLti13DeepLinkingConfigService<DeepLinkingConfigService>()
+ .WithLti13DeepLinkingHandler<DeepLinkingHandler>()
+ .WithLti13AssignmentGradeConfigService<AssignmentGradeConfigService>()
+ .WithLti13NameRoleProvisioningConfigService<NameRoleProvisioningConfigService>();