During a session at InstructureCon 2016 I realized that there are quite a few people who are interested in developing LTI tools for their institution, and looking for instruction on how to get started. I thought maybe I could help, at least from a .NET perspective.
I do realize that Canvas lives on the *nix platform, but .NET is fully capable of communicating with it. The department I'm in currently uses the Microsoft stack (except for virtualization). So, for those of you out there who are also using Microsoft technology I hope to make this easy. Those who are not using Microsoft tech will hopefully be able to at least follow along.
If you're diving into LTI I'm going to assume that you have a background in web application development in general, and will not get bogged down in setting up a development environment. I will be happy to provide additional details later as needed, based on feedback.
What you will need...
I'll be working through this project using Visual Studio 2015, community edition should be fine.
I realize this is a simple tutorial, which is why I chose it for this task: I do not want to get bogged down in what the app actually does. The focus here is really on how to wire up the LTI side of things, the app is almost irrelevant.
Note: If you do follow along using this tutorial, add a default value for the "Name" parameter when you add the "Welcome" controller. Or, remove the parameter completely. You'll see why later.
Going through this process will give us a common point of reference. For those who are more advanced, start from where ever you are comfortable, or whatever project you have in mind. If you do nothing but implement the first three steps of the "Getting Started..." tutorial, you will have enough to launch your first LTI application in Canvas. The key here is that through the process of creating the sample project, you have implemented methods capable of recognizing specific HTTP verbs, i.e. GET, PUT, POST, etc. This is required in order to work with LTI.
Launching your first LTI tool
Step 1: Create the XML Application Definition
So, let's see how we can launch our new LTI tool in Canvas (we'll get into OAuth and user validation later).
The first thing we'll need is an XML file that defines our application, go to this URL to use a tool to help create your XML file: XML Config Builder
For this example, we'll add launch points for our LTI app to the Account navigation, and to the Courses navigation.
Here is a description of how I completed the entry fields in the XML tool:
ID: <generated guid>
Description: Demo app to illustrate how to launch an LTI application in Canvas