flutter3d_lti 0.7.1
flutter3d_lti: ^0.7.1 copied to clipboard
LTI 1.3 launch and xAPI reporting: OIDC login, id_token verification against a platform's JWKS, an Assignment and Grade Services client, and an xAPI statement client — no shelf, no jaspr, no Flutter.
flutter3d_lti #
LTI 1.3 launch and xAPI reporting, for the edu-03 line of doc/tooling-plan.md
(doc/edu-03-lti-plan.md has the full plan). Plain Dart — no shelf, no
jaspr, no Flutter — so a service that only needs to verify a launch or file
a grade does not have to carry any of them.
What is here #
LtiPlatformConfig— one LMS registration (issuer, client ID, deployment ID, JWKS URL, auth-login URL), read once from environment variables the same waycloud/lessons/cloud/serveralready read theirs.OidcLoginInitiation— builds the redirect for LTI's OIDC third-party login initiation, with a freshstate/nonceper login.LtiLaunchValidator— verifies an incomingid_token's signature against the platform's JWKS (cached bykid), its issuer/audience/expiry, and thestate/noncefrom the login that started it; parses the result intoLtiLaunchClaims.AgsClient— gets a Bearer token from the platform via a client-credentials grant this tool signs itself (LtiToolCredentials), then posts anAgsScoreto a line item's/scoresendpoint. The access token is cached until it is close to expiring.XapiClient— PUTs anXapiStatement(actor/verb/object/result) to a Learning Record Store, keyed by the statement's own UUID so a retried submission cannot double a student's record.
What is not here yet #
cloud/lti(lti-03) — the service that actually runs/loginand/launchroutes over this package.- The wire from
checkto both clients above (lti-04) — a launch's quiz result does not yet reachAgsClient/XapiClienton its own; seedoc/edu-03-lti-plan.md§2–3 for the order.
Tests #
dart test
test/support/test_platform.dart generates a real RSA key pair per test run
and signs real id_tokens with it — LtiLaunchValidator is proven against
an actual RS256 signature and an actual JWKS document, not a mock of either.