External Integrations

Contents

Integration Preferences
Moodle
MailChimp
SurveyMonkey
SurveyGizmo
Cloud Assess

Integration Preferences

onCourse allows you to create integration points with a number of popular commercial tools. These integrations allow you to create your own links to external services and products you have purchased, and define with a corresponding script how onCourse utilises these services.

You can find all the current built in integrations by go File -> Preferences -> General. Then click on the 'Add' button next to the heading 'INTEGRATIONS' to see all the integrations, as shown below.

Integration preferences window

Moodle

Moodle is a free, open-source PHP web application for producing modular internet-based courses that supports a modern social constructionist pedagogy.

To add a Moodle integration you will need to click on the 'Add' button below the Moodle icon. You will then see a number of fields that are needed to enable the integration.

IMPORTANT: For this to work, courses to be integrated with Moodle are required to have a specific user-created tag associated with them that must be created separately in the Preferences > Tags screen. You can see how to do that here. The bottom field 'Only activate for enrolments in courses tagged with' is where the name of this tag is defined, so you must make sure the name you put in here matches the name of the tag you created precisely.

Moodle integration preferences

Once these preferences have been defined you will need to enable the 'moodle enrol' script to automatic the process. The Moodle script can be found by going File -> Preferences -> Scripts, doubling clicking on 'moodle enrol', clicking on the checkbox 'Enabled' and saving the script.

Moodle enrol script

Where to find the preferences in Moodle

Below are the steps that are needed to be done to enable the Moodle integration.

  1. The Base URL is the site url (e.g. http://localhost:8888/moodle29/)

  2. To create a user go to Site administration -> Users -> Accounts -> Add a new user

    Creating a user

  3. To assign user to a role go to Site administration -> Users -> Permissions -> Assign system roles

  4. To add a service go to Site administration -> Plugins -> Web services -> External services. When you are on the page click on 'Add' and fill in the Service Name and Short Name, then click on 'Add service'

    External services screen

    When you are on this page click on 'Add' and fill in the Service Name and Short Name, then click on 'Add service'

    Adding the service

  5. Once the Service is created click on 'Add functions'

    Functions page

    Add following functions: core_user_create_users, core_user_get_users, core_course_get_courses, enrol_manual_enrol_users

    Adding the functions to the service

  6. The next step is to generate the token, you can do this by going to Site administration -> Plugins -> Web services -> Manage tokens then click on 'Add'.

    Manage tokens page

    Then select the created user and service, and if needed Enable and Set 'Valid Until' date

    Create token page

  7. The last step is to create a course, you can do this by going to Site administration -> Courses -> Manage courses and categories, then Create new course. The ID should be the same as course code in onCourse.

MailChimp

MailChimp is an online email marketing solution to manage contacts, send emails and track results.

There are three types MailChimp integrations available in onCourse:

  1. mailchimp subscribe for onCourse mailing list subscription: This type of integration triggers when you manually attach a Mailing List tag an onCourse contact. You can create multiple mailing list tag groups in onCourse that integrate with multiple MailChimp lists.

  2. mailchimp unsubscribe onCourse mailing list unsubscription: This type of integration triggers when you manually remove a mailing list tag from a contact. This script should be enabled the script 'mailchimp subscribe'.

  3. mailchimp subscribe on enrolment: This type of integration triggers when a contact enrols via onCourse or the web. You can only have one of these types of integrations to subscribe all enrolling students to a single MailChimp list. Your onCourse integration must be named "Enrolment" for this to work.

Creating an onCourse mailing list integration

The name of your onCourse mailing list tag and MailChimp integration must be the same for this to work. This integration will only add new subscribers to your mailing list to MailChimp, once enabled.

  1. Log into MailChimp and obtain an API key for your account at http://kb.mailchimp.com/accounts/management/about-api-keys. Go to Account > Extras > API keys > Create a key

  2. In MailChimp, find your the List Id at http://kb.mailchimp.com/lists/managing-subscribers/find-your-list-id Go to the Lists page > Settings, and scroll to find the unique List ID field

  3. In onCourse, go to File > Preferences > Tags. Find the Tag Group named 'Mailing Lists', and double-click to open the Tag's window.

  4. To create a new mailing list, click the green plus in the bottom left hand corner. Name your tag, then click 'Save'

  5. To add the MailChimp integration, go to File > Preferences > General and click on the 'Add' button next to the heading integrations.

  6. Click the 'Add' button below the MailChimp icon. The name of the integration must be the same as the name of the onCourse mailing list. Insert your API key and List and Id from MailChimp, then save and close this window.

    MailChimp integration for a Mailing List integration

  7. Once the integration has been defined you will need to enable the MailChimp scripts to automate the process. These scripts can be found by going File -> Preferences -> Scripts

  8. Double click on the script called 'mailchimp subscribe', click on the checkbox 'Enabled' and save the script.

  9. You should also enable the 'mailchimp unsubscribe', click on the checkbox 'Enabled' and save the script. Please note that if contacts unsubscribe to the MailChimp list directly, they will not be unsubscribed in the onCourse mailing list (they can unsubscribe to onCourse mailing lists via the portal, which does update MailChimp), but either way, they will not receive further emails from you via MailChimp.

  10. To test this script is working as required, you can manually subscribe some contacts to your onCourse mailing list and check that they have been added to the correct MailChimp list. To manually subscribe some contacts, open the contact window, highlight some records and right click on the mailing list name in the left hand part of the window. Select the option 'add this tag to xx highlighted records'. You can also tag an individual contact by opening their record and adding the tag manually.

  11. If you wish to add additional mailing list integrations, you can repeat steps 1 to 6 as needed, adding multiple mailing list integrations to onCourse. Once the scripts are enabled, you do not need to repeat steps 7 to 9 again.

MailChimp mailing list subscribe script

Creating an 'on enrolment' integration

This type of integration with MailChimp automatically subscribes on enrolment all contacts who have the permission 'accept email marketing material' on their contact record. You can only have on integration of this type in onCourse.

  1. Log into MailChimp and obtain an API key for your account at http://kb.mailchimp.com/accounts/management/about-api-keys. Go to Account > Extras > API keys > Create a key

  2. In MailChimp, find your the List Id at http://kb.mailchimp.com/lists/managing-subscribers/find-your-list-id Go to the Lists page > Settings, and scroll to find the unique List ID field you want to subscribe your enrolling students to.

  3. To add the MailChimp integration, go to File > Preferences > General and click on the 'Add' button next to the heading integrations.

  4. Click the 'Add' button below the MailChimp icon. The name of the integration must be 'Enrolment'. Insert your API key and List and Id from MailChimp, then save and close this window.

  5. Once the integration has been defined you will need to enable the MailChimp script to automate the process. This scripts can be found by going File -> Preferences -> Scripts

  6. Double click on the script called 'mailchimp subscribe on enrolment', click on the checkbox 'Enabled' and save the script.

    Note that there is no corresponding unsubscribe script for this integration - students can unsubscribe from this list directly via MailChimp after receiving an email from you.

SurveyMonkey

SurveyMonkey allows you to create and publish online surveys in minutes, and view the results graphically in real time. SurveyMonkey provides free online questionnaire and survey software.

To add a SurveyMonkey integration you will need to click on the 'Add' button below the SurveyMonkey icon. You will then see a number of fields that are needed to enable the integration. The 'Name' field is what ever you want to call this integration.

SurveyMonkey integration preferences

Once these preferences have been defined you will need to enable at least one of the SurveyMonkey scripts to automate the process. These scripts can be found by going File -> Preferences -> Scripts, doubling clicking on either 'SurveyMonkey send invite on enrolment', 'SurveyMonkey send invite on enrolment completion', or 'VET Course completion survey' clicking on the checkbox 'Enabled' and saving the script.

SurveyMonkey scripts

Access Tokens and Creating a developer account

Survey Monkey introduced access tokens as a means of integration in January 2017. All integrations created after that date will need to use access tokens. API Keys will not be used after this time. Existing integrations using an API key will continue to use the API key. To create an access token, you set up a developer account in SurveyMonkey and add onCourse as an App.

  1. Go to SurveyMonkey.com and login using your regular login. If you do not have a login for SurveyMonkey you will need to create one.

  2. Once logged in, got to the URL https://developer.surveymonkey.com. This will bring you to the developers area to set up your integration.

  3. In the Developers area, go to My Apps. If you already have an App, make sure it's not disabled or expired. If you don't already have an app, or if yours is currently expired/disabled, click on 'Add a New App'.

    SurveyMonkey Developer site Add New App Feature

  4. This will open new window asking you to add an App. You can choose the name of App i.e. 'onCourse'

  5. In the App record, go to Settings, scroll down to the section called Scopes and activate the following three Scopes:

    • Create/Modify Collectors

    • View Collectors

    • View Surveys

    Without these Scopes being activated, the integration will fail to work.

    Scopes in SurveyMonkey

  6. Once you've activated the required Scopes, scroll up to the Credentials section and locate the 'Access Token' field. The Access token is the large string of numbers and letters in the field. Copy all the text in this field and paste it into the 'OAuth token' field within the Integration you're setting up in onCourse. (File > Preferences > General... > Integrations)

    SurveyMonkey Access Token Location

The Survey Name you need to enter in onCourse is the name listed in the 'Title' field on Survey Monkey, in the example below it's simply called 'Test'. This can be found by logging into your account in https://www.surveymonkey.com then clicking on the top menu option 'My Surveys'

All your surveys inSurveyMonkey will be listed in 'My Surveys'

Survey Monkey uses the term 'Collectors' to describe ways you can send out your survey and collect responses. You can read more about Collectors here.

Set up your collector and name it 'onCourse', as this is the default collector name the app looks for. If there is no Collector by this name, then the first Collector in the list is selected. We highly recommend naming the Collector 'onCourse'.

If you haven't used SurveyMonkey before you will need to verify the collectors email address. This is done by clicking on the name of the Survey followed by on the tab 'Collect Responses' and then on the Survey name under the heading 'NICKNAME' and continuing until this email gets sent.

A view of some Collectors, one has yet to be configured

The 'Sender email address' that survey responses are sent to is the same one that you should have stored in the field 'Email from address' in the Messaging tab of the onCourse preferences window.

Messaging tab of the Preferences window

SurveyGizmo

SurveyGizmo is a powerful survey tool designed to make even the most advanced survey projects fun, easy and affordable.

To add a SurveyGizmo integration you will need to click on the 'Add' button below the SurveyGizmo icon. You will then see a number of fields that are needed to enable the integration.

SurveyGizmo integration preferences

Once these preferences have been defined you will need to enable at least one of the SurveyGizmo scripts to automatic the process. These scripts can be found by going File -> Preferences -> Scripts, doubling clicking on either 'SurveyGizmo send invite on enrolment' or 'SurveyGizmo send invite on enrolment completion', clicking on the checkbox 'Enabled' and saving the script.

SurveyGizmo scripts

Where to find the preferences in SurveyGizmo

Below is the information that is needed to enable the integration that can be found in SurveyGizmo.

  1. The User and Password is the same one you use to log into your account at SurveyGizmo

  2. The Survey ID is taken from survey address, so in the example below the Survey ID is 2290616. Please visit here for more information.

    Where to find the SurveyGizmo Survey ID

Cloud Assess

Cloud Assess is an online service for managing the assessment process. It can be used for VET and non-VET enrolments, and can be used by tutors to help manage classroom based assessments as well as online assessments.

When you create an account with Cloud Assess ask for the different user names and keys shown in the image. Then enable the script "cloudassess course enrolment create" in order to automatically push enrolments in onCourse into Cloud Assess. This script assumes that you'll create a course in Cloud Assess with the same course code as the course in onCourse. If there is no matching course in Cloud Assess then the script will do nothing. Of course you can modify the script to suit your own specific needs. Remember that the name of the integration here must match the name given within the script.

Cloud Access integration preferences

Once these preferences have been defined you will need to enable the Cloud Access script to automate the process. This script can be found by going File -> Preferences -> Scripts, double clicking on 'cloudassess course enrolment create' then click on the 'Enabled' check box and save.

Cloud Access script