LtiLibrary is now a NuGet Package

To make it even easier to add IMS LTI support to your learning app, I wrapped LtiLibrary into its own NuGet Package. To add LtiLibrary to your application, run the following command in the Package Manager Console:

PM> Install-Package LtiLibrary

There is also an LtiLibrary.Sample package which adds sample MVC and Web Forms to an empty ASP.NET Web Application.

PM> Install-Package LtiLibrary.Sample

Using the LtiLibrary.Sample Package

Want to poke around a simple sample application? Try this:

  1. In Visual Studio start a New Project.
  2. Select the ASP.NET Web Application template:
    New Project dialog in Visual Student 2013
  3. Select the Empty template and add folders and core references for Web Forms, MVC, and Web API:
    New ASP.NET Web Application dialog in Visual Student 2013
  4. After the project is created, enter the following command in the Package Manager Console to install LtiLibrary.Sample:
    Package Manager Console in Visual Studio 2013
  5. Run the project and click on the Launch link to launch a sample tool.
    LtiLibrary.Sample MVC home page

LtiLibrary.Sample has MVC, Web Forms, and Web API sample code that implements LTI 1.0, 1.1, and draft 1.2 services. Here is a table of contents for the sample files:

  • LTI 1.0 Tool Consumer and Tool Provider
    • MVC
      • Tool Consumer
        • Controllers\ConsumerController.cs
        • Views\Consumer\Launch.cshtml
      • Tool Provider
        • Controllers\ProviderController.cs
        • Views\Provider\Tool.cshtml
    • Web Forms
      • Tool Consumer
        • WebForms\Launch.ashx
      • Tool Provider
        • WebForms\Tool.aspx
  • LTI 1.1 Outcomes Service
    • Web API and MVC
      • Tool Consumer
        • Controllers\OutcomesApiController.cs
      • Tool Provider
        • Views\Provider\Outcomes.cshtml
  • LTI 1.2 Tool Consumer Profile
    • Web API
      • Tool Consumer
        • Controllers\ToolConsumerProfileApiController.cs

If you are looking for a more robust example of a Tool Consumer and Tool Provider, check out the LtiSamples code in CodePlex.

Let me know if you find this useful.

This entry was posted in Uncategorized and tagged , , , , , . Bookmark the permalink.

7 Responses to LtiLibrary is now a NuGet Package

  1. Kevin Scott says:

    I followed the steps for installing LtiLibrary.Sample but am getting the follow error:

    Parser Error Message: Could not load type ‘WebApplication5.WebForms.Default’.
    Source Error:
    Line 1:
    Line 2:
    Line 3:
    Source File: /WebForms/Default.aspx Line: 1

  2. .net Programmer says:

    Hi,

    i did a test to connect the consumer to another provider (Big Blue Button),
    the Asp .net MVC works very well, but not the Web Forms sample.

    > for Asp .net MVC project i modified:
    on ConsumerController/Launch() methode:

    ConsumerKey = “***”,
    ResourceLinkId = “launch”,
    Url = new Uri(“******”)

    and modify the secret key here
    return View(ltiRequest.GetLtiRequestViewModel(“*******”)); and it works!
    > i did the same thing in the Web Form project: on Launch.ashx.cs

    and modify the secret key here: context.Response.WriteLtiRequest(ltiRequest, “****”);

    but it doesn’t work 😦 , do you see something wrong…? or any suggestion please?

    • Andy says:

      I’m sorry, but I’m not able to help debug your code.

      • .Net programmer says:

        Thank you for your answer, could you debeug with this values please?:
        ConsumerKey =”bbb”,
        ResourceLinkId = “launch”,
        Url = new Uri(“http://test-install.blindsidenetworks.com/lti/tool.xml”)

        context.Response.WriteLtiRequest(ltiRequest, “b00be971feb0726fa697671c9cf2e883”);

        It Works on ie but not on chrome and firefox;

        Sincerely.

  3. .net Programmer says:

    i’ve done a test on IE 10 and it works, but not on chrome

  4. lily says:

    Thank you for the sample, the WebForm works only on Internet Explorer and not with chrome and firefox.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.