# LTI

## Overview

This guide explains how to integrate Instruqt tracks within an **LTI 1.1** and **LTI 1.3** compliant **learning management system (LMS).**

Instruqt offers LTI integrations using the **LTI 1.1** specification with **LTI Basic Outcomes** for result feedback, as well as the **LTI 1.3** specification with the **Assignment and Grading service** for result feedback.

Scoring is done on **completion** of a track, where the result given is always a score of **1.0 or (100%).** Meaning a track can either be complete or incomplete. More precise scoring is not supported at this point in time.

Most major **LMS** platforms such as Moodle, Thought Industries and Canvas support **LTI 1.1** and **LTI 1.3**. Follow the steps below to integrate one of your Instruqt tracks with your LMS of choice.

To get started a unique **Consumer Key** and **Consumer Secret** will need to be generated for your team. This step is only required once and the same credentials can be used across tracks and LMS platforms.

{% hint style="info" %}
When LTI credentials are generated a new webhook with the endpoint `https://lti.instruqt.com/webhook` will automatically be created, this is needed to provide basic outcomes feedback to consumer tools.
{% endhint %}

{% hint style="danger" %}
Instruqt creates a dedicated user account for each unique user record received from your LMS. This ensures that sessions remain consistent between Instruqt and the LMS, providing a seamless experience for learners. This means that as a content creator, accessing a track through an LTI integration versus directly on the Instruqt platform will result in different users playing.
{% endhint %}

{% tabs %}
{% tab title="🌐 Web UI" %}

1. Click **Settings** → **API keys**
2. Under the *LTI Credentials section,* click **Generate credentials**.\
   ↳ You will have the ability to regenerate credentials later on.

{% hint style="warning" %}
When credentials are regenerated all existing integrations with the old credentials will need to be updated or they will cease to work.
{% endhint %}
{% endtab %}
{% endtabs %}

##

## LTI version 1.1

### Step 1: Integrate an Instruqt track

Once LTI credentials have been generated, tracks will each have a unique `lti.instruqt.com` URL. This URL is visible through the Web UI.&#x20;

{% tabs %}
{% tab title="🌐 Web UI" %}

1. Click the track you want to integrate.
2. Click **Share** at the top of the page, and select **LTI** **integration** from the dropdown.&#x20;
3. Copy the URL and the consumer key + secret to your LMS LTI 1.1 configuration section.&#x20;

{% hint style="info" %}
LMS call these values different things. They are most commonly named **Tool URL**, **Consumer Key**, and **Secret Key.**
{% endhint %}
{% endtab %}
{% endtabs %}

{% hint style="warning" %}
Keep your **Consumer Key** and **Secret Key** safe, exposing these credentials could lead to unwanted plays on your Instruqt tracks.
{% endhint %}

## LTI version 1.3

Currently Instruqt only supports [*Resource linking*](http://www.imsglobal.org/spec/lti/v1p3#resource-link-launch-request-message)  and the [*Assignment and Grading Services*](https://www.imsglobal.org/spec/lti-ags/v2p0/). [*Deep Linking*](https://www.imsglobal.org/spec/lti-dl/v2p0/) *and the* [*Names and Role Provisioning Services*](http://www.imsglobal.org/spec/lti-nrps/v2p0) have not been implemented yet.

### Step 1: Integrate an Instruqt track

Once LTI credentials have been generated, you will need to configure Instruqt as a **Tool Provider** on your **LMS**. All configuration details for a specific track can be found on the web UI.

{% tabs %}
{% tab title="🌐 Web UI" %}

1. Click the track you want to integrate.
2. Click **Share** at the top of the page, and select **LTI** **integration** from the dropdown.&#x20;
3. Copy the required details from the **LTI 1.3** configuration section to your LMS. The LMS will will require the **Tool URL**, the **Login URL** and either the **Public Key** or the **Public Key Set URL** for authentication.

{% hint style="info" %}
LMS call these values different things. They are most commonly named **Tool URL** or **Redirection URL**, **Initiate login URL**, and **Public Keyset URL.**\
\
\*\* The **Tool URL** should be added as one of the Redirect URI's when configuring the track on your LMS.
{% endhint %}
{% endtab %}
{% endtabs %}

Below is an example of configuring an instruqt track as an LTI 1.3 external tool on the Moodle LMS:

<figure><img src="https://2094212015-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MGJDYBXyftBAZb1Wq0e%2Fuploads%2FUZ47Fcddm7xuEmyZo06M%2FScreenshot%202024-04-22%20at%2013.35.57.png?alt=media&#x26;token=bba9e01d-e61b-477d-8900-dff85df5c012" alt=""><figcaption><p>Example tool configuration on the Moodle LMS</p></figcaption></figure>

### Step 2: Register your LMS as a Tool Consumer&#x20;

Once the Instruqt track has been configured on your LMS, the LMS will need be configured as a **Tool Consumer** on the Instrqut platform. This can be done using the Web UI.

{% tabs %}
{% tab title="🌐 Web UI" %}

1. On the side menu, under **Settings**, click the **LTI integratons** item.
2. Click **Add** on the top-right of the page.&#x20;
3. Copy the required details from your LMS into the **LTI Tool Registration** form. The following details are needed:
   1. **Name** - This can be any name as it is only used to display the configuration on the Instruqt **LTI integrations** page.
   2. **Client ID** -  This is an unique ID that is used for authorisation and should be provided by your LMS.
   3. **Issuer** - Platform/Issuer ID of the LMS, generally the URL of the LMS.
   4. **Key Set URL** - The Public Key Set URL used to fetch a Public Key from the LMS.&#x20;
   5. **Public Key** -  The raw Public Key provided by the LMS if providing a Key Set URL is not supported.
   6. **Access Token URL** - An Access Token URL provided by the LMS, used for authentication.
   7. **Auth URL** - An Authentication request URL provided by the LMS, used for authentication.
   8. **Deployment ID's** - Each Tool configuration will have a unique deployment ID provided by the LMS once configured. If the Client ID and Issuer are the same for multiple tools on your LMS and only the deployment ID differs, only one LTI integration needs to be configured on Instruqt with a list of the Deployment ID's.
4. Click **Save** on the top-right of the screen.

{% hint style="warning" %}
Either a **Key Set URL** or a **Public key** must be provided, it is not required to have both
{% endhint %}
{% endtab %}
{% endtabs %}

Once you have done the configuration on both your LMS and the Instruqt platform you should have the track available for use in your lessons.

Below is an example of adding the Tool Configuration from the Moodle LMS to Instruqt as an LTI integration:

<figure><img src="https://2094212015-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MGJDYBXyftBAZb1Wq0e%2Fuploads%2Fe38z4evnEjHdvCKZbEBC%2FScreenshot%202024-04-22%20at%2014.46.44.png?alt=media&#x26;token=e37fdcf1-406a-47de-925f-b5126e62a4f3" alt=""><figcaption><p>Example tool configuration details from the Moodle LMS</p></figcaption></figure>

<figure><img src="https://2094212015-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MGJDYBXyftBAZb1Wq0e%2Fuploads%2FBjAyyIWB98T68dSIVDxe%2FScreenshot%202024-04-22%20at%2014.49.04.png?alt=media&#x26;token=bbcd0680-cb3f-4d7d-86ba-46e654f6efec" alt=""><figcaption><p>Example configuration of a Moodle integration on Instruqt</p></figcaption></figure>
