Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Code Your Own Tool Integration Using the Basic Learning Tools Interoperability (LTI) Standard#blticode<br />Jim Riecken & ...
Basic<br />Learning<br />Tools<br />Interoperability<br />with Blackboard Learn™, Release 9.1 SP4<br />
Q’s we will try to A<br />What is LTI?<br />What is Basic LTI?<br />What does being a Tool Provider mean?<br />What does b...
What is LTI?<br />“a single framework or standard way of integrating rich learning applications...to allow the seamless co...
What is Basic LTI?<br />Simplify, Simplify, Simplify<br />one launch mechanism with one security policy<br />no access to ...
What’s a Tool Provider?<br />A (typically centrally hosted) service that interacts with users who are “launched” from insi...
What’s a Tool Consumer?<br />A LMS, VLE or portal environment<br />Sets policy about the payload privacy, who can provisio...
What does that look like in Blackboard Learn?<br />
Basic LTI & Blackboard Building Blocks™<br />
Why use a Blackboard Building Block?<br />More seamless integration<br />Tool placement<br />Content Handler placement<br ...
How to use Basic LTI in a Blackboard Building Block<br />Two Parts<br />Declare permissions in bb-manifest.xml<br />Use bl...
Basic LTI Permissions<br />New “basiclti” permission type.<br />Name is the domain you intent to launch to.<br />Use “*” i...
Basic LTI PermissionsExample<br /><permission type="basiclti" <br />name="example.com" actions="" /><br /><permission type...
BasicLTILauncher<br />Encapsulates the logic for performing a Basic LTI launch.<br />blackboard.platform.blti.BasicLTILaun...
BasicLTILauncher<br />Constructor<br />BasicLTILauncher(String url, String key, String secret, String resourceLinkId)<br /...
BasicLTILauncher - Examples<br />Simple Launch<br />BasicLTILauncherlauncher=newBasicLTILauncher(<br />"http://url.to.my.t...
BasicLTILauncher - Examples<br />The kitchen sink<br />Useruser=...;// Get user somehow<br />Coursecourse=...;// Get cours...
Hungry yet? Let’s make a sandwichTool Provider<br />
Tool Provider… Tool Provider?HOW DO I WRITE A TOOL PROVIDER!!!<br />You could:<br />Go to http://www.imsglobal.org/lti<br ...
BLTI-sandwich to the Rescue!<br />But… If you like Java<br />I’ve done this for you!<br />BLTI-sandwich<br />http://projec...
BLTI-Sandwich<br />Two main classes to deal with<br />BLTIMessage<br />Contains all of the Basic LTI launch data in an eas...
BLTIMessage<br />Container for Basic LTI Launch Data<br />E.g.<br />msg.getKey()<br />msg.getResourceLink().getId()<br />m...
BLTIProvider<br />Static methods to grab Basic LTI launch data and validate it.<br />BLTIMessagegetMessage(HttpServletRequ...
Let’s make a tool<br />Simple polling tool<br />Let instructor create an ad-hoc poll<br />Let students vote (and see resul...
Demo Time<br />http://blti-sandwich.appspot.com<br />Running on App Engine<br />
Code Walkthrough<br />
  /**<br />   * Performs the Basic LTI launch using blti-sandwich.<br />   */<br />@RequestMapping("/blti/tool")<br />publ...
Resources<br />IMS http://www.imsglobal.org/toolsinteroperability2.cfm<br />Learn Help Center http://help.blackboard.com<b...
Please provide feedback for this session by emailingDevConFeedback@blackboard.com. <br />The title of this session is:<br ...
Upcoming SlideShare
Loading in …5
×

Code Your Own: Tool Integration using the Basic Learning Tools Interoperability (LTI) Standard

7,005 views

Published on

Originally presented by Jim Riecken and Dan Rinzel of Blackboard Learn Product Development on Monday, July 11th at 10AM Pacific Time in Titian 2310B at the Sands Expo Center in the Venetian hotel, Las Vegas, Nevada, USA as part of the Blackboard Developers’ Conference 2011.

This presentation covers Blackboard Learn's capabilities as a Tool Consumer according to the IMS specificiations for Learning Tools Interoperability, beginning with the Service Pack 4 release of Learn 9.1 in December of 2010.

Published in: Technology
  • Be the first to comment

Code Your Own: Tool Integration using the Basic Learning Tools Interoperability (LTI) Standard

  1. 1. Code Your Own Tool Integration Using the Basic Learning Tools Interoperability (LTI) Standard#blticode<br />Jim Riecken & Dan Rinzel<br />Blackboard Learn Product Development<br />
  2. 2. Basic<br />Learning<br />Tools<br />Interoperability<br />with Blackboard Learn™, Release 9.1 SP4<br />
  3. 3. Q’s we will try to A<br />What is LTI?<br />What is Basic LTI?<br />What does being a Tool Provider mean?<br />What does being a Tool Consumer mean?<br />What does that look like in Learn?<br />What does it look like for Blackboard Building Blocks?<br />Hungry yet? Code your own Tool Provider<br />
  4. 4. What is LTI?<br />“a single framework or standard way of integrating rich learning applications...to allow the seamless connection of web-based, externally hosted applications and content…to platforms that present them to users”<br /><br />http://www.imsglobal.org/toolsinteroperability2.cfm<br />
  5. 5. What is Basic LTI?<br />Simplify, Simplify, Simplify<br />one launch mechanism with one security policy<br />no access to run-time services on the platform <br />
  6. 6. What’s a Tool Provider?<br />A (typically centrally hosted) service that interacts with users who are “launched” from inside their platform<br />Launch mechanism and authN as specified, including extra data in the launch “payload”<br />
  7. 7. What’s a Tool Consumer?<br />A LMS, VLE or portal environment<br />Sets policy about the payload privacy, who can provision links<br />
  8. 8. What does that look like in Blackboard Learn?<br />
  9. 9. Basic LTI & Blackboard Building Blocks™<br />
  10. 10. Why use a Blackboard Building Block?<br />More seamless integration<br />Tool placement<br />Content Handler placement<br />Bypass global provider settings<br />Permissions declared in bb-manifest.xml<br />Instructors don’t need to deal with URLs, Keys, and Secrets<br />They might not even know that the tool is running on another server!<br />
  11. 11. How to use Basic LTI in a Blackboard Building Block<br />Two Parts<br />Declare permissions in bb-manifest.xml<br />Use blackboard.platform.blti.BasicLTILauncher<br />In your Tool page or Content Handler view page<br />
  12. 12. Basic LTI Permissions<br />New “basiclti” permission type.<br />Name is the domain you intent to launch to.<br />Use “*” if you want to launch to any domain<br />Specifying a domain allows subdomains as well<br />Value is some combination of<br />“sendroles” – Allow user’s role to be sent.<br />“sendname” – Allow user’s full name to be sent.<br />“sendemail” – Allow user’s email address to be sent.<br />If the value is empty, you will just be able to launch to that domain.<br />
  13. 13. Basic LTI PermissionsExample<br /><permission type="basiclti" <br />name="example.com" actions="" /><br /><permission type="basiclti" <br />name="foo.example.com" actions="sendroles" /><br /><permission type="basiclti" <br />name="bar.example.com" actions="sendname,sendemail" /><br /><permission type="basiclti" <br />name="baz.example.com" actions="sendemail" /><br />
  14. 14. BasicLTILauncher<br />Encapsulates the logic for performing a Basic LTI launch.<br />blackboard.platform.blti.BasicLTILauncher<br />blackboard.platform.blti.BasicLTIConstants<br />Simple API<br />Can add user/course information<br />Can add custom parameters<br />Does OAuth signing and redirects to an automatic launch page.<br />
  15. 15. BasicLTILauncher<br />Constructor<br />BasicLTILauncher(String url, String key, String secret, String resourceLinkId)<br />Data Population (all return BasicLTILauncher)<br />addResourceLinkInformation(String title, String description)<br />addCurrentUserInformation(booleanincludeRoles, booleanincludeName, booleanincludeEmail)<br />addUserInformation(User user, CourseMembership membership, booleanincludeRoles, booleanincludeName, booleanincludeEmail)<br />addCurrentCourseInformation()<br />addCourseInformation(Course course)<br />addLaunchPresentationInformation(Map<String,String> params)<br />addCustomToolParameters(Map<String,String> params)<br />Launch<br />Map<String,String> prepareParameters()<br />void launch(HttpServletRequestreq, HttpServletResponse res, booleanuseSplashScreen, FormattedTextsplashScreenMessage)<br />
  16. 16. BasicLTILauncher - Examples<br />Simple Launch<br />BasicLTILauncherlauncher=newBasicLTILauncher(<br />"http://url.to.my.tool","my.key","s3cr3t","resourceId_1");<br />launcher.launch(req,res,false,null);<br />Launch with current user and current course (from Context) and a splash message<br />BasicLTILauncherlauncher=newBasicLTILauncher(<br />"http://url.to.my.tool","my.key","s3cr3t","resourceId_1")<br />//Send roles and name, but not email<br />.addCurrentUserInformation(true,true,false)<br /> .addCurrentCourseInformation();<br />launcher.launch(req,res,true,newFormattedText("You are launching my tool. Click Submit.",FormattedText.Type.PLAIN_TEXT));<br />
  17. 17. BasicLTILauncher - Examples<br />The kitchen sink<br />Useruser=...;// Get user somehow<br />Coursecourse=...;// Get course somehow<br />CourseMembershipmembership=...;// Get user membership in course<br />Map<String,String>launchPresentation=newHashMap<String,String>();<br />launchPresentation.put(BasicLTIConstants.PARAM_LAUNCH_PRESENTATION_DOCUMENT_TARGET,<br />BasicLTIConstants.PARAM_LAUNCH_PRESENTATION_TARGET_WINDOW);<br />launchPresentation.put(BasicLTIConstants.PARAM_LAUNCH_PRESENTATION_RETURN_URL,<br />PlugInUtil.getUri("vendor","handle","/path/to/my/return"));<br />Map<String,String>customParams=newHashMap<String,String>();<br />customParams.put("param1","value1");<br />customParams.put("param2","value2");<br />BasicLTILauncherlauncher=newBasicLTILauncher(<br />"http://url.to.my.tool","my.key","s3cr3t","resourceId_1")<br />.addResourceLinkInformation("resourceTitle","resourceDescription")<br />.addUserInformation(user,membership,true,true,true)<br />.addCourseInformation(course)<br />.addCustomToolParameters(customParams)<br />.addLaunchPresentationInformation(launchPresentation);<br />launcher.launch(req,res,true,newFormattedText("You are launching my tool. Click Submit.", FormattedText.Type.PLAIN_TEXT));<br />
  18. 18. Hungry yet? Let’s make a sandwichTool Provider<br />
  19. 19. Tool Provider… Tool Provider?HOW DO I WRITE A TOOL PROVIDER!!!<br />You could:<br />Go to http://www.imsglobal.org/lti<br />Download the Basic LTI spec<br />Read the spec<br />Implement the Tool Provider side of the spec<br />Find bugs, tear out hair, fix bugs.<br />Rinse, Repeat until working.<br />Benefit:<br />You can use any language to do this<br />Like Ruby? Ok. Like PHP? Ok. Like Node.js? Ok.<br />
  20. 20. BLTI-sandwich to the Rescue!<br />But… If you like Java<br />I’ve done this for you!<br />BLTI-sandwich<br />http://projects.oscelot.org/gf/project/blti-sandwich/<br />Simple Java library that implements the glue between Tool Consumers and Tool Providers<br />Implements Basic LTI 1.0<br />Mostly for creating Tool Providers<br />Can also use to help create a Tool Consumer<br />
  21. 21. BLTI-Sandwich<br />Two main classes to deal with<br />BLTIMessage<br />Contains all of the Basic LTI launch data in an easy to use format<br />BLTIProvider<br />Allows you to pull a BLTIMessage off of an HttpServletRequest and validate it.<br />
  22. 22. BLTIMessage<br />Container for Basic LTI Launch Data<br />E.g.<br />msg.getKey()<br />msg.getResourceLink().getId()<br />msg.getUser().getFullName()<br />msg.getUser().isInRole( Role.CONTEXT_NAMESPACE, Role.MENTOR )<br />msg.getContext().getLabel()<br />msg.getLaunchPresentation().getReturnUrl()<br />msg.getCustomParameters().get("the-custom-param")<br />
  23. 23. BLTIProvider<br />Static methods to grab Basic LTI launch data and validate it.<br />BLTIMessagegetMessage(HttpServletRequest request)<br />Pulls launch data off the request.<br />booleanisValid(BLTIMessagemsg, String secret)<br />Checks whether the message contains all of the required Basic LTI fields and was signed using the specified shared secret.<br />
  24. 24. Let’s make a tool<br />Simple polling tool<br />Let instructor create an ad-hoc poll<br />Let students vote (and see results)<br />Let instructors see detailed results (who voted on what)<br />What we’ll use<br />blti-sandwich<br />Spring MVC<br />Google App Engine<br />Objectify (App Engine Datastore ORM)<br />
  25. 25. Demo Time<br />http://blti-sandwich.appspot.com<br />Running on App Engine<br />
  26. 26. Code Walkthrough<br />
  27. 27. /**<br /> * Performs the Basic LTI launch using blti-sandwich.<br /> */<br />@RequestMapping("/blti/tool")<br />publicStringlaunch(HttpServletRequestrequest)<br />{<br />// Parse out the BLTI launch<br />BLTIMessagemsg=BLTIProvider.getMessage(request);<br />// Load the consumer that matches the key passed in the launch<br />Consumerconsumer=consumerDAO.get(Consumer.generateKey(msg.getKey()));<br />// Validate the message (make sure the message was signed by the shared secret)<br />if(consumer==null||!BLTIProvider.isValid(msg,consumer.getSharedSecret()))<br />{<br />returnerrorRedirect(msg,"Error: Not Authorized!");<br />}<br />// [More validation edited out here...]<br />else<br />{<br />// Provision a user object<br />provisionUser(msg,consumer);<br />// Set up the HTTP session for the user<br />HttpSessionsession=request.getSession(false);<br />if(session!=null)<br />{<br />session.invalidate();<br />}<br />session=request.getSession();<br />// Keep the BLTI message in session for use in other pages.<br />session.setAttribute("bltiSessionMsg",msg);<br />// Redirect to the tool (Poll) display page<br />return"redirect:/blti/tool/index";<br />}<br />}<br />
  28. 28. Resources<br />IMS http://www.imsglobal.org/toolsinteroperability2.cfm<br />Learn Help Center http://help.blackboard.com<br />blti-sandwich library on OSCELOT <br />http://projects.oscelot.org/gf/project/blti-sandwich/<br />This presentation and example code will be <br />available via http://edugarage.com at some <br />point after the conference ends.<br />jim.riecken@blackboard.com<br />dan.rinzel@blackboard.com<br />
  29. 29. Please provide feedback for this session by emailingDevConFeedback@blackboard.com. <br />The title of this session is:<br />Code Your Own: Tool Integration Using the Basic Learning Tools Interoperability (LTI) Standard<br />

×