Project

atomic_lti

0.0
The project is in a healthy, maintained state
AtomicLti implements the LTI Advantage specification. This gem does contain source code specific to other Atomic Jolt products
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 1.3
~> 7.0
 Project Readme

AtomicLti

Atomic LTI implements the LTI Advantage specification.

Installation

Add this line to your application's Gemfile:

gem "atomic_lti"

And then execute:

$ bundle

Or install it yourself as:

$ gem install atomic_lti

Then install the migrations:

./bin/rails atomic_lti:install:migrations

Usage

Create a new initializer:

config/initializers/atomic_lti.rb

with the following contents. Adjust paths as needed.

AtomicLti.oidc_init_path = "/oidc/init"
AtomicLti.oidc_redirect_path = "/oidc/redirect"
AtomicLti.target_link_path_prefixes = ["/lti_launches"]
AtomicLti.default_deep_link_path = "/lti_launches"
AtomicLti.jwt_secret = Rails.application.secrets.auth0_client_secret
AtomicLti.scopes = AtomicLti::Definitions.scopes.join(" ")

Add the middleware configuration to application.rb (assuming AtomicTenant is in use)

config.middleware.insert_before AtomicTenant::CurrentApplicationInstanceMiddleware, AtomicLti::OpenIdMiddleware
config.middleware.insert_before AtomicLti::OpenIdMiddleware, AtomicLti::ErrorHandlingMiddleware

Building javascript

Run esbuild:

yarn build

License

The gem is available as open source under the terms of the MIT License.