Moodle APIs 4.3
Moodle 4.3.6 (Build: 20240812)
|
Topics | |
backup | |
external | |
grade | |
log | |
test | |
Directories | |
directory | backup |
| |
directory | service |
| |
Namespaces | |
namespace | mod_lti |
| |
namespace | mod_lti\analytics\indicator |
Activity base class. | |
namespace | mod_lti\event |
The mod_lti instance list viewed event. | |
namespace | mod_lti\external |
| |
namespace | mod_lti\local |
| |
namespace | mod_lti\local\ltiopenid |
This files exposes functions for LTI 1.3 Key Management. | |
namespace | mod_lti\local\ltiservice |
This file contains an abstract definition of an LTI resource. | |
namespace | mod_lti\output |
| |
namespace | mod_lti\plugininfo |
LTI service plugin info. | |
namespace | mod_lti\privacy |
Privacy Subsystem implementation for mod_lti. | |
namespace | mod_lti\reportbuilder\local\entities |
| |
namespace | mod_lti\reportbuilder\local\systemreports |
| |
namespace | mod_lti\search |
Search area for mod_lti activities. | |
namespace | mod_lti\task |
A scheduled task for lti module. | |
namespace | moodle\mod\lti |
This file contains the OAuth 1.0a implementation used for support for LTI 1.1. | |
Classes | |
class | backup_lti_activity_structure_step |
Define the complete assignment structure for backup, with file and id annotations. More... | |
class | mod_lti\analytics\indicator\activity_base |
Activity base class. More... | |
class | mod_lti\analytics\indicator\cognitive_depth |
Cognitive depth indicator - lti. More... | |
class | mod_lti\analytics\indicator\social_breadth |
Social breadth indicator - lti. More... | |
class | mod_lti\event\course_module_instance_list_viewed |
The mod_lti instance list viewed event class. More... | |
class | mod_lti\event\course_module_viewed |
The mod_lti course module viewed event class. More... | |
class | mod_lti\event\unknown_service_api_called |
The mod_lti unknown service api called event class. More... | |
class | mod_lti\external\delete_course_tool_type |
External function to delete a course tool type. More... | |
class | mod_lti\external\get_tool_types_and_proxies |
External function for fetching all tool types and proxies. More... | |
class | mod_lti\external\get_tool_types_and_proxies_count |
External function for fetching the count of all tool types and proxies. More... | |
class | mod_lti\external\toggle_showinactivitychooser |
External function to toggle showinactivitychooser setting. More... | |
class | mod_lti\helper |
Helper class for LTI activity. More... | |
class | mod_lti\local\ltiopenid\jwks_helper |
This class exposes functions for LTI 1.3 Key Management. More... | |
class | mod_lti\local\ltiopenid\registration_exception |
Exception when transforming the registration to LTI config. More... | |
class | mod_lti\local\ltiopenid\registration_helper |
This class exposes functions for LTI Dynamic Registration. More... | |
class | mod_lti\local\ltiservice\resource_base |
The mod_lti\local\ltiservice\resource_base class. More... | |
class | mod_lti\local\ltiservice\response |
The mod_lti\local\ltiservice\response class. More... | |
class | mod_lti\local\ltiservice\service_base |
The mod_lti\local\ltiservice\service_base class. More... | |
class | mod_lti\local\types_helper |
Helper class specifically dealing with LTI types (preconfigured tools). More... | |
class | mod_lti\output\course_tools_page |
The course tools page renderable, containing a page header renderable and a course tools system report. More... | |
class | mod_lti\output\course_tools_page_header |
Course tools page header renderable, containing the data for the page zero state and 'add tool' button. More... | |
class | mod_lti\output\external_registration_return_page |
Class containing data for tool_configure page. More... | |
class | mod_lti\output\registration_upgrade_choice_page |
Class containing data for rendering LTI upgrade choices page. More... | |
class | mod_lti\output\renderer |
Renderer class for template library. More... | |
class | mod_lti\output\repost_crosssite_page |
Render a page containing a simple form which reposts to self via JS. More... | |
class | mod_lti\output\tool_configure_page |
Class containing data for tool_configure page. More... | |
class | mod_lti\plugininfo\ltiservice |
The mod_lti\plugininfo\ltiservice class. More... | |
class | mod_lti\plugininfo\ltisource |
class | mod_lti\privacy\provider |
Privacy Subsystem implementation for mod_lti. More... | |
class | mod_lti\reportbuilder\local\entities\tool_types |
Course external tools entity class implementation. More... | |
class | mod_lti\reportbuilder\local\systemreports\course_external_tools_list |
Course external tools list system report class implementation. More... | |
class | mod_lti\search\activity |
Search area for mod_lti activities. More... | |
class | mod_lti\service_exception_handler |
Handles exceptions when handling incoming LTI messages. More... | |
class | mod_lti\task\clean_access_tokens |
Class containing the scheduled task for lti module. More... | |
class | mod_lti_edit_types_form |
LTI Edit Form. More... | |
class | mod_lti_mod_form |
class | mod_lti_register_types_form |
The mod_lti_register_types_form class. More... | |
class | mod_lti_testcase |
Abstract base testcase for mod_lti unit tests. More... | |
class | moodle1_mod_lti_handler |
class | moodle\mod\lti\OAuthConsumer |
OAuth 1.0 Consumer class. More... | |
class | moodle\mod\lti\OAuthDataStore |
class | moodle\mod\lti\OAuthException |
Generic exception class. More... | |
class | moodle\mod\lti\OAuthRequest |
class | moodle\mod\lti\OAuthServer |
class | moodle\mod\lti\OAuthSignatureMethod |
class | moodle\mod\lti\OAuthSignatureMethod_HMAC |
Base class for the HMac based signature methods. More... | |
class | moodle\mod\lti\OAuthSignatureMethod_HMAC_SHA1 |
Implementation for SHA 1. More... | |
class | moodle\mod\lti\OAuthSignatureMethod_HMAC_SHA256 |
Implementation for SHA 256. More... | |
class | moodle\mod\lti\OAuthSignatureMethod_PLAINTEXT |
class | moodle\mod\lti\OAuthSignatureMethod_RSA_SHA1 |
class | moodle\mod\lti\OAuthToken |
class | moodle\mod\lti\OAuthUtil |
class | moodle\mod\lti\TrivialOAuthDataStore |
A Trivial memory-based store - no support for tokens. More... | |
class | restore_lti_activity_structure_step |
Structure step to restore one lti activity. More... | |
class | restore_lti_activity_task |
basiclti restore task that provides all the settings and steps to perform one complete restore of the activity More... | |
Functions | |
content_item_to_form (object $tool, object $typeconfig, object $item) | |
Converts LTI 1.1 Content Item for LTI Link to Form data. | |
get_course_history ($course) | |
Build the history chain for this course using the course originalcourseid. | |
get_tag ($tagname, $xpath, $attribute=null) | |
Search for a tag within an XML DOMDocument. | |
get_tool_proxy_edit_url (stdClass $proxy) | |
Returns the edit url for the given tool proxy. | |
get_tool_proxy_urls (stdClass $proxy) | |
Returns the icon and edit urls for the tool proxy. | |
get_tool_type_capability_groups ($type) | |
Returns a summary of each LTI capability this tool type requires in plain language. | |
get_tool_type_config ($type) | |
Returns information on the configuration of the tool type. | |
get_tool_type_course_url (stdClass $type) | |
Returns the course url for the given tool type. | |
get_tool_type_edit_url (stdClass $type) | |
Returns the edit url for the given tool type. | |
get_tool_type_icon_url (stdClass $type) | |
Returns the icon for the given tool type. | |
get_tool_type_instance_ids ($type) | |
Returns the ids of each instance of this tool type. | |
get_tool_type_state_info (stdClass $type) | |
Returns information on the current state of the tool type. | |
get_tool_type_urls (stdClass $type) | |
Returns the icon and edit urls for the tool type and the course url if it is a course type. | |
lti_accepts_grades ($ltiinstance) | |
lti_add_config ($config) | |
Add a tool configuration in the database. | |
lti_add_tool_proxy ($config) | |
Update the database with a tool proxy instance. | |
lti_add_type ($type, $config) | |
lti_build_content_item_selection_request ($id, $course, moodle_url $returnurl, $title='', $text='', $mediatypes=[], $presentationtargets=[], $autocreate=false, $multiple=true, $unsigned=false, $canconfirm=false, $copyadvice=false, $nonce='') | |
Builds a standard LTI Content-Item selection request. | |
lti_build_custom_parameters ($toolproxy, $tool, $instance, $params, $customstr, $instructorcustomstr, $islti2) | |
This function builds the custom parameters. | |
lti_build_login_request ($courseid, $cmid, $instance, $config, $messagetype, $foruserid=0, $title='', $text='') | |
Prepares an LTI 1.3 login request. | |
lti_build_registration_request ($toolproxy) | |
Gets the parameters for the regirstration request. | |
lti_build_request ($instance, $typeconfig, $course, $typeid=null, $islti2=false, $messagetype='basic-lti-launch-request', $foruserid=0) | |
This function builds the request that must be sent to the tool producer. | |
lti_build_request_lti2 ($tool, $params) | |
This function builds the request that must be sent to an LTI 2 tool provider. | |
lti_build_sourcedid ($instanceid, $userid, $servicesalt, $typeid=null, $launchid=null) | |
Build source ID. | |
lti_build_standard_message ($instance, $orgid, $ltiversion, $messagetype='basic-lti-launch-request') | |
This function builds the standard parameters for an LTI message that must be sent to the tool producer. | |
lti_build_standard_request ($instance, $orgid, $islti2, $messagetype='basic-lti-launch-request') | |
This function builds the standard parameters for an LTI 1 or 2 request that must be sent to the tool producer. | |
lti_calculate_custom_parameter ($value) | |
Calculates the value of a custom parameter that has not been specified earlier. | |
lti_convert_content_items ($param) | |
Converts the new Deep-Linking format for Content-Items to the old format. | |
lti_convert_from_jwt ($typeid, $jwtparam) | |
Verfies the JWT and converts its claims to their equivalent message parameter. | |
lti_delete_grade ($ltiinstance, $userid) | |
lti_delete_tool_proxy ($id) | |
Delete a Tool Proxy. | |
lti_delete_type ($id) | |
Delete a Basic LTI configuration. | |
lti_ensure_url_is_https ($url) | |
lti_extend_lti_services ($data) | |
Extend the LTI services through the ltisource plugins. | |
lti_filter_get_types ($course) | |
Returns all basicLTI tools configured by the administrator. | |
lti_filter_tool_proxy_types (array $toolproxies, $state) | |
Given an array of tool proxies, filter them based on their state. | |
lti_filter_tool_types (array $tools, $state) | |
Given an array of tools, filter them based on their state. | |
lti_force_type_config_settings ($instance, array $typeconfig) | |
Enforce type config settings onto the LTI instance. | |
lti_get_best_tool_by_url ($url, $tools, $courseid=null) | |
lti_get_capabilities () | |
Initializes an array with the capabilities supported by the LTI module. | |
lti_get_config ($ltiobject) | |
Transforms a basic LTI object to an array. | |
lti_get_configured_types ($courseid, $sectionreturn=0) | |
Returns a list of configured types in the given course. | |
lti_get_contexts ($json) | |
Extracts the named contexts from a tool proxy. | |
lti_get_custom_parameters ($toolproxy, $tool, $params, $parameters) | |
Adds the custom parameters to an array. | |
lti_get_domain_from_url ($url) | |
lti_get_enabled_capabilities ($tool) | |
Extracts the enabled capabilities into an array, including those implicitly declared in a parameter. | |
lti_get_fqid ($contexts, $id) | |
Converts an ID to a fully-qualified ID. | |
lti_get_ims_role ($user, $cmid, $courseid, $islti2) | |
Gets the IMS role string for the specified user and LTI course module. | |
lti_get_instance_type (object $instance) | |
Return the type of the instance, using domain matching if no explicit type is set. | |
lti_get_jwt_claim_mapping () | |
Return the mapping for standard message parameters to JWT claim. | |
lti_get_jwt_message_type_mapping () | |
Return the mapping for standard message types to JWT message_type claim. | |
lti_get_launch_container ($lti, $toolconfig) | |
lti_get_launch_data ($instance, $nonce='', $messagetype='basic-lti-launch-request', $foruserid=0) | |
Return the launch data required for opening the external tool. | |
lti_get_lti_types_and_proxies (int $limit=0, int $offset=0, bool $orphanedonly=false, int $toolproxyid=0) | |
Get both LTI tool proxies and tool types. | |
lti_get_lti_types_and_proxies_count (bool $orphanedonly=false, int $toolproxyid=0) | |
Get the total number of LTI tool types and tool proxies. | |
lti_get_lti_types_by_course ($courseid, $coursevisible=null) | |
Returns all lti types visible in this course. | |
lti_get_organizationid ($typeconfig) | |
get Organization ID using default if no value provided | |
lti_get_permitted_service_scopes ($type, $typeconfig) | |
Initializes an array with the scopes for services supported by the LTI module and authorized for this particular tool instance. | |
lti_get_response_xml ($codemajor, $description, $messageref, $messagetype) | |
lti_get_service_by_name ($servicename) | |
Initializes an instance of the named service. | |
lti_get_service_by_resource_id ($services, $resourceid) | |
Finds a service by id. | |
lti_get_services () | |
Initializes an array with the services supported by the LTI module. | |
lti_get_shared_secrets_by_key ($key) | |
lti_get_shortcuts () | |
List of deprecated mod_lti functions. | |
lti_get_tool_by_url_match ($url, $courseid=null, $state=LTI_TOOL_STATE_CONFIGURED) | |
lti_get_tool_proxies ($orphanedonly) | |
Returns lti tool proxies. | |
lti_get_tool_proxies_from_registration_url ($regurl) | |
Get the tool proxy instance given its registration URL. | |
lti_get_tool_proxy ($id) | |
Generates some of the tool proxy configuration based on the admin configuration details. | |
lti_get_tool_proxy_config ($id) | |
Generates some of the tool proxy configuration based on the admin configuration details. | |
lti_get_tool_proxy_from_guid ($toolproxyguid) | |
Get the tool proxy instance given its GUID. | |
lti_get_tool_proxy_table ($toolproxies, $id) | |
This function builds the tab for a category of tool proxies. | |
lti_get_tool_settings ($toolproxyid, $courseid=null, $instanceid=null) | |
Gets the tool settings. | |
lti_get_tool_table ($tools, $id) | |
lti_get_tools_by_domain ($domain, $state=null, $courseid=null) | |
lti_get_tools_by_url ($url, $state, $courseid=null) | |
lti_get_type ($typeid) | |
lti_get_type_config ($typeid) | |
Returns configuration details for the tool. | |
lti_get_type_config_by_instance ($instance) | |
Fetches LTI type configuration for an LTI instance. | |
lti_get_type_config_from_instance ($id) | |
Generates some of the tool configuration based on the instance details. | |
lti_get_type_type_config ($id) | |
Generates some of the tool configuration based on the admin configuration details. | |
lti_get_types_for_add_instance () | |
Returns tool types for lti add instance and edit page. | |
lti_get_url_thumbprint ($url) | |
lti_initiate_login ($courseid, $cmid, $instance, $config, $messagetype='basic-lti-launch-request', $title='', $text='', $foruserid=0) | |
Generate the form for initiating a login request for an LTI 1.3 message. | |
lti_is_cartridge ($url) | |
Determines if the given url is for a IMS basic cartridge. | |
lti_launch_tool ($instance, $foruserid=0) | |
Launch an external tool activity. | |
lti_libxml_disable_entity_loader (bool $value) | |
Wrapper for function libxml_disable_entity_loader() deprecated in PHP 8. | |
lti_load_cartridge ($url, $map, $propertiesmap=array()) | |
Search for a tag within an XML DOMDocument. | |
lti_load_tool_from_cartridge ($url, $lti) | |
Allows you to load in the configuration for an external tool from an IMS cartridge. | |
lti_load_tool_if_cartridge ($lti) | |
Loads the cartridge information into the new tool, if the launch url is for a cartridge file. | |
lti_load_type_from_cartridge ($url, $type) | |
Allows you to load settings for an external tool type from an IMS cartridge. | |
lti_load_type_if_cartridge ($type) | |
Loads the cartridge information into the tool type, if the launch url is for a cartridge file. | |
lti_log_request ($rawbody) | |
Logs the request to a file in temp dir. | |
lti_log_response ($responsexml, $e=null) | |
Log an LTI response. | |
lti_map_keyname ($key, $tolower=true) | |
Used for building the names of the different custom parameters. | |
lti_new_access_token ($typeid, $scopes) | |
Create a new access token. | |
lti_parse_custom_parameter ($toolproxy, $tool, $params, $value, $islti2) | |
Parse a custom parameter to replace any substitution variables. | |
lti_parse_grade_delete_message ($xml) | |
lti_parse_grade_read_message ($xml) | |
lti_parse_grade_replace_message ($xml) | |
lti_parse_message_id ($xml) | |
lti_post_launch_html ($newparms, $endpoint, $debug=false) | |
Posts the launch petition HTML. | |
lti_prepare_type_for_save ($type, $config) | |
lti_read_grade ($ltiinstance, $userid) | |
lti_register ($toolproxy) | |
Prepares an LTI registration request message. | |
lti_request_is_using_ssl () | |
lti_set_session_user ($userid) | |
Set the passed user ID to the session user. | |
lti_set_state_for_type ($id, $state) | |
lti_set_tool_settings ($settings, $toolproxyid, $courseid=null, $instanceid=null) | |
Sets the tool settings (. | |
lti_should_log_request ($rawbody) | |
Determines if we should try to log the request. | |
lti_sign_jwt ($parms, $endpoint, $oauthconsumerkey, $typeid=0, $nonce='') | |
Converts the message paramters to their equivalent JWT claim and signs the payload to launch the external tool using JWT. | |
lti_sign_parameters ($oldparms, $endpoint, $method, $oauthconsumerkey, $oauthconsumersecret) | |
Signs the petition to launch the external tool using OAuth. | |
lti_split_custom_parameters ($toolproxy, $tool, $params, $customstr, $islti2=false) | |
Splits the custom parameters field to the various parameters. | |
lti_split_parameters ($customstr) | |
Splits the custom parameters. | |
lti_tool_configuration_from_content_item ($typeid, $messagetype, $ltiversion, $consumerkey, $contentitemsjson) | |
Processes the tool provider's response to the ContentItemSelectionRequest and builds the configuration data from the selected content item. | |
lti_type_add_categories (int $typeid, string $lticoursecategories='') | |
Add LTI Type course category. | |
lti_update_config ($config) | |
Updates a tool configuration in the database. | |
lti_update_grade ($ltiinstance, $userid, $launchid, $gradeval) | |
lti_update_tool_proxy ($toolproxy) | |
Updates a tool proxy in the database. | |
lti_update_type ($type, $config) | |
lti_verify_jwt_signature ($typeid, $consumerkey, $jwtparam) | |
Verifies the JWT signature of an incoming message. | |
lti_verify_message ($key, $sharedsecrets, $body, $headers=null) | |
lti_verify_oauth_signature ($typeid, $consumerkey) | |
Verifies the OAuth signature of an incoming message. | |
lti_verify_sourcedid ($ltiinstance, $parsed) | |
Validate source ID from external request. | |
lti_verify_with_keyset ($jwtparam, $keyseturl, $clientid) | |
Verifies the JWT signature using a JWK keyset. | |
mod_lti_verify_private_key () | |
This function checks if a private key has been generated for this site. | |
params_to_string (object $params) | |
Converts an array of custom parameters to a new line separated string. | |
serialise_tool_type (stdClass $type) | |
Serialises this tool type. | |
xmldb_lti_install () | |
Stub for database installation. | |
xmldb_lti_upgrade ($oldversion) | |
xmldb_lti_upgrade is the function that upgrades the lti module database when is needed | |
Variables | |
$capabilities | |
global | $CFG |
global | $CFG |
global | $CFG |
global | mod_lti\external::$CFG |
global | mod_lti\local\ltiservice::$CFG |
$definitions | |
$deprecatedcapabilities | |
moodle\mod\lti::$lastcomputedsignature = false | |
admin_settingpage | $modltifolder = new admin_category('modltifolder', new lang_string('pluginname', 'mod_lti'), $module->is_enabled() === false) |
$plugin = 2023100400 | |
$proxieslink | |
if($ADMIN->fulltree) | $settings = null |
$tasks | |
foreach(core_plugin_manager::instance() ->get_plugins_of_type('ltisource') as $plugin) | $toolproxiesurl = new moodle_url('/mod/lti/toolproxies.php') |
$plugin | component = 'mod_lti' |
$plugin | cron = 0 |
$settings | hidden = true |
const | LTI_ACCESS_TOKEN_LIFE 3600 |
const | LTI_COURSEVISIBLE_ACTIVITYCHOOSER 2 |
const | LTI_COURSEVISIBLE_NO 0 |
const | LTI_COURSEVISIBLE_PRECONFIGURED 1 |
const | LTI_DEFAULT_ORGID_SITEHOST 'SITEHOST' |
const | LTI_DEFAULT_ORGID_SITEID 'SITEID' |
const | LTI_ITEM_MODULE 'lti' |
const | LTI_ITEM_TYPE 'mod' |
const | LTI_JWK_KEYSET 'JWK_KEYSET' |
const | LTI_JWT_CLAIM_PREFIX 'https://purl.imsglobal.org/spec/lti' |
const | LTI_LAUNCH_CONTAINER_DEFAULT 1 |
const | LTI_LAUNCH_CONTAINER_EMBED 2 |
const | LTI_LAUNCH_CONTAINER_EMBED_NO_BLOCKS 3 |
const | LTI_LAUNCH_CONTAINER_REPLACE_MOODLE_WINDOW 5 |
const | LTI_LAUNCH_CONTAINER_WINDOW 4 |
const | LTI_RSA_KEY 'RSA_KEY' |
const | LTI_SETTING_ALWAYS 1 |
const | LTI_SETTING_DELEGATE 2 |
const | LTI_SETTING_NEVER 0 |
const | LTI_SOURCE 'mod/lti' |
const | LTI_TOOL_PROXY_STATE_ACCEPTED 3 |
const | LTI_TOOL_PROXY_STATE_CONFIGURED 1 |
const | LTI_TOOL_PROXY_STATE_PENDING 2 |
const | LTI_TOOL_PROXY_STATE_REJECTED 4 |
const | LTI_TOOL_PROXY_TAB 4 |
const | LTI_TOOL_STATE_ANY 0 |
const | LTI_TOOL_STATE_CONFIGURED 1 |
const | LTI_TOOL_STATE_PENDING 2 |
const | LTI_TOOL_STATE_REJECTED 3 |
const | LTI_URL_DOMAIN_REGEX '/(?:https?:\/\/)?(?:www\.)?([^\/]+)(?:\/|$)/i' |
const | LTI_VERSION_1 'LTI-1p0' |
const | LTI_VERSION_1P3 '1.3.0' |
const | LTI_VERSION_2 'LTI-2p0' |
$plugin | version = 2023100900 |
$settings | visiblename = new lang_string('manage_tools', 'mod_lti') |
content_item_to_form | ( | object | $tool, |
object | $typeconfig, | ||
object | $item ) |
Converts LTI 1.1 Content Item for LTI Link to Form data.
object | $tool | Tool for which the item is created for. |
object | $typeconfig | The tool configuration. |
object | $item | Item populated from JSON to be converted to Form form |
stdClass | Form config for the item |
get_course_history | ( | $course | ) |
Build the history chain for this course using the course originalcourseid.
object | $course | course for which the history is returned. |
array | ids of the source course in ancestry order, immediate parent 1st. |
get_tag | ( | $tagname, | |
$xpath, | |||
$attribute = null ) |
Search for a tag within an XML DOMDocument.
stdClass | $tagname | The name of the tag to search for |
XPath | $xpath | The XML to find the tag in |
XPath | $attribute | The attribute to search for (if we should search for a child node with the given value for the name attribute |
get_tool_proxy_edit_url | ( | stdClass | $proxy | ) |
Returns the edit url for the given tool proxy.
stdClass | $proxy | The tool proxy |
string | The url to edit the tool type |
get_tool_proxy_urls | ( | stdClass | $proxy | ) |
Returns the icon and edit urls for the tool proxy.
stdClass | $proxy | The tool proxy |
array | The urls of the tool proxy |
get_tool_type_capability_groups | ( | $type | ) |
Returns a summary of each LTI capability this tool type requires in plain language.
stdClass | $type | The tool type |
array | An array of text descriptions of each of the capabilities this tool type requires |
get_tool_type_config | ( | $type | ) |
Returns information on the configuration of the tool type.
stdClass | $type | The tool type |
array | An array with configuration details |
get_tool_type_course_url | ( | stdClass | $type | ) |
Returns the course url for the given tool type.
stdClass | $type | The tool type |
string | The url to the course of the tool type, void if it is a site wide type |
get_tool_type_edit_url | ( | stdClass | $type | ) |
Returns the edit url for the given tool type.
stdClass | $type | The tool type |
string | The url to edit the tool type |
get_tool_type_icon_url | ( | stdClass | $type | ) |
Returns the icon for the given tool type.
stdClass | $type | The tool type |
string | The url to the tool type's corresponding icon |
get_tool_type_instance_ids | ( | $type | ) |
Returns the ids of each instance of this tool type.
stdClass | $type | The tool type |
array | An array of ids of the instances of this tool type |
get_tool_type_state_info | ( | stdClass | $type | ) |
Returns information on the current state of the tool type.
stdClass | $type | The tool type |
array | An array with a text description of the state, and boolean for whether it is in each state: pending, configured, rejected, unknown |
get_tool_type_urls | ( | stdClass | $type | ) |
Returns the icon and edit urls for the tool type and the course url if it is a course type.
stdClass | $type | The tool type |
array | The urls of the tool type |
lti_add_config | ( | $config | ) |
Add a tool configuration in the database.
object | $config | Tool configuration |
int | Record id number |
lti_add_tool_proxy | ( | $config | ) |
Update the database with a tool proxy instance.
object | $config | Tool proxy definition |
int | Record id number |
lti_build_content_item_selection_request | ( | $id, | |
$course, | |||
moodle_url | $returnurl, | ||
$title = '', | |||
$text = '', | |||
$mediatypes = [], | |||
$presentationtargets = [], | |||
$autocreate = false, | |||
$multiple = true, | |||
$unsigned = false, | |||
$canconfirm = false, | |||
$copyadvice = false, | |||
$nonce = '' ) |
Builds a standard LTI Content-Item selection request.
int | $id | The tool type ID. |
stdClass | $course | The course object. |
moodle_url | $returnurl | The return URL in the tool consumer (TC) that the tool provider (TP) will use to return the Content-Item message. |
string | $title | The tool's title, if available. |
string | $text | The text to display to represent the content item. This value may be a long description of the content item. |
array | $mediatypes | Array of MIME types types supported by the TC. If empty, the TC will support ltilink by default. |
array | $presentationtargets | Array of ways in which the selected content item(s) can be requested to be opened (via the presentationDocumentTarget element for a returned content item). If empty, "frame", "iframe", and "window" will be supported by default. |
bool | $autocreate | Indicates whether any content items returned by the TP would be automatically persisted without |
bool | $multiple | Indicates whether the user should be permitted to select more than one item. False by default. any option for the user to cancel the operation. False by default. |
bool | $unsigned | Indicates whether the TC is willing to accept an unsigned return message, or not. A signed message should always be required when the content item is being created automatically in the TC without further interaction from the user. False by default. |
bool | $canconfirm | Flag for can_confirm parameter. False by default. |
bool | $copyadvice | Indicates whether the TC is able and willing to make a local copy of a content item. False by default. |
string | $nonce |
stdClass | The object containing the signed request parameters and the URL to the TP's Content-Item selection interface. |
moodle_exception | When the LTI tool type does not exist.` |
coding_exception | For invalid media type and presentation target parameters. |
lti_build_custom_parameters | ( | $toolproxy, | |
$tool, | |||
$instance, | |||
$params, | |||
$customstr, | |||
$instructorcustomstr, | |||
$islti2 ) |
This function builds the custom parameters.
object | $toolproxy | Tool proxy instance object |
object | $tool | Tool instance object |
object | $instance | Tool placement instance object |
array | $params | LTI launch parameters |
string | $customstr | Custom parameters defined for tool |
string | $instructorcustomstr | Custom parameters defined for this placement |
boolean | $islti2 | True if an LTI 2 tool is being launched |
array | Custom parameters |
lti_build_login_request | ( | $courseid, | |
$cmid, | |||
$instance, | |||
$config, | |||
$messagetype, | |||
$foruserid = 0, | |||
$title = '', | |||
$text = '' ) |
Prepares an LTI 1.3 login request.
int | $courseid | Course ID |
int | $cmid | Course Module instance ID |
stdClass | null | $instance | LTI instance |
stdClass | $config | Tool type configuration |
string | $messagetype | LTI message type |
int | $foruserid | Id of the user targeted by the launch |
string | $title | Title of content item |
string | $text | Description of content item |
array | Login request parameters |
lti_build_registration_request | ( | $toolproxy | ) |
Gets the parameters for the regirstration request.
object | $toolproxy | Tool Proxy instance object |
array | Registration request parameters |
lti_build_request | ( | $instance, | |
$typeconfig, | |||
$course, | |||
$typeid = null, | |||
$islti2 = false, | |||
$messagetype = 'basic-lti-launch-request', | |||
$foruserid = 0 ) |
This function builds the request that must be sent to the tool producer.
object | $instance | Basic LTI instance object |
array | $typeconfig | Basic LTI tool configuration |
object | $course | Course object |
int | null | $typeid | Basic LTI tool ID |
boolean | $islti2 | True if an LTI 2 tool is being launched |
string | $messagetype | LTI Message Type for this launch |
int | $foruserid | User targeted by this launch |
array | Request details |
lti_build_request_lti2 | ( | $tool, | |
$params ) |
This function builds the request that must be sent to an LTI 2 tool provider.
object | $tool | Basic LTI tool object |
array | $params | Custom launch parameters |
array | Request details |
lti_build_sourcedid | ( | $instanceid, | |
$userid, | |||
$servicesalt, | |||
$typeid = null, | |||
$launchid = null ) |
Build source ID.
int | $instanceid | |
int | $userid | |
string | $servicesalt | |
null | int | $typeid | |
null | int | $launchid |
stdClass |
lti_build_standard_message | ( | $instance, | |
$orgid, | |||
$ltiversion, | |||
$messagetype = 'basic-lti-launch-request' ) |
This function builds the standard parameters for an LTI message that must be sent to the tool producer.
stdClass | $instance | Basic LTI instance object |
string | $orgid | Organisation ID |
boolean | $ltiversion | LTI version to be used for tool messages |
string | $messagetype | The request message type. Defaults to basic-lti-launch-request if empty. |
array | Message parameters |
lti_build_standard_request | ( | $instance, | |
$orgid, | |||
$islti2, | |||
$messagetype = 'basic-lti-launch-request' ) |
This function builds the standard parameters for an LTI 1 or 2 request that must be sent to the tool producer.
stdClass | $instance | Basic LTI instance object |
string | $orgid | Organisation ID |
boolean | $islti2 | True if an LTI 2 tool is being launched |
string | $messagetype | The request message type. Defaults to basic-lti-launch-request if empty. |
array | Request details |
lti_calculate_custom_parameter | ( | $value | ) |
Calculates the value of a custom parameter that has not been specified earlier.
string | $value | Custom parameter value |
string | Calculated value of custom parameter |
lti_convert_content_items | ( | $param | ) |
Converts the new Deep-Linking format for Content-Items to the old format.
string | $param | JSON string representing new Deep-Linking format |
string | JSON representation of content-items |
lti_convert_from_jwt | ( | $typeid, | |
$jwtparam ) |
Verfies the JWT and converts its claims to their equivalent message parameter.
int | $typeid | |
string | $jwtparam | JWT parameter |
array | message parameters |
moodle_exception |
lti_delete_tool_proxy | ( | $id | ) |
Delete a Tool Proxy.
int | $id | Tool Proxy id |
lti_delete_type | ( | $id | ) |
Delete a Basic LTI configuration.
int | $id | Configuration id |
lti_extend_lti_services | ( | $data | ) |
Extend the LTI services through the ltisource plugins.
stdClass | $data | LTI request data |
bool |
coding_exception |
lti_filter_get_types | ( | $course | ) |
Returns all basicLTI tools configured by the administrator.
int | $course |
array |
lti_filter_tool_proxy_types | ( | array | $toolproxies, |
$state ) |
Given an array of tool proxies, filter them based on their state.
array | $toolproxies | An array of lti_tool_proxies records |
int | $state | One of the LTI_TOOL_PROXY_STATE_* constants |
array |
lti_filter_tool_types | ( | array | $tools, |
$state ) |
Given an array of tools, filter them based on their state.
array | $tools | An array of lti_types records |
int | $state | One of the LTI_TOOL_STATE_* constants |
array |
lti_force_type_config_settings | ( | $instance, | |
array | $typeconfig ) |
Enforce type config settings onto the LTI instance.
stdClass | $instance | |
array | $typeconfig |
lti_get_capabilities | ( | ) |
Initializes an array with the capabilities supported by the LTI module.
array | List of capability names (without a dollar sign prefix) |
lti_get_config | ( | $ltiobject | ) |
Transforms a basic LTI object to an array.
object | $ltiobject | Basic LTI object |
array | Basic LTI configuration details |
lti_get_configured_types | ( | $courseid, | |
$sectionreturn = 0 ) |
Returns a list of configured types in the given course.
int | $courseid | The id of the course to retieve types for |
int | $sectionreturn | section to return to for forming the URLs |
array | Array of lti types. Each element is object with properties: name, title, icon, help, helplink, link |
lti_get_contexts | ( | $json | ) |
Extracts the named contexts from a tool proxy.
object | $json |
array | Contexts |
lti_get_custom_parameters | ( | $toolproxy, | |
$tool, | |||
$params, | |||
$parameters ) |
Adds the custom parameters to an array.
object | $toolproxy | Tool proxy instance object |
object | $tool | Tool instance object |
array | $params | LTI launch parameters |
array | $parameters | Array containing the parameters |
array | Array of custom parameters |
lti_get_enabled_capabilities | ( | $tool | ) |
Extracts the enabled capabilities into an array, including those implicitly declared in a parameter.
object | $tool | Tool instance object |
array | List of enabled capabilities |
lti_get_fqid | ( | $contexts, | |
$id ) |
Converts an ID to a fully-qualified ID.
array | $contexts | |
string | $id |
string | Fully-qualified ID |
lti_get_ims_role | ( | $user, | |
$cmid, | |||
$courseid, | |||
$islti2 ) |
Gets the IMS role string for the specified user and LTI course module.
mixed | $user | User object or user id |
int | $cmid | The course module id of the LTI activity |
int | $courseid | The course id of the LTI activity |
boolean | $islti2 | True if an LTI 2 tool is being launched |
string | A role string suitable for passing with an LTI launch |
lti_get_instance_type | ( | object | $instance | ) |
Return the type of the instance, using domain matching if no explicit type is set.
object | $instance | the external tool activity settings |
object|null |
lti_get_jwt_claim_mapping | ( | ) |
Return the mapping for standard message parameters to JWT claim.
array |
lti_get_jwt_message_type_mapping | ( | ) |
Return the mapping for standard message types to JWT message_type claim.
array |
lti_get_launch_data | ( | $instance, | |
$nonce = '', | |||
$messagetype = 'basic-lti-launch-request', | |||
$foruserid = 0 ) |
Return the launch data required for opening the external tool.
stdClass | $instance | the external tool activity settings |
string | $nonce | the nonce value to use (applies to LTI 1.3 only) |
array | the endpoint URL and parameters (including the signature) |
lti_get_lti_types_and_proxies | ( | int | $limit = 0, |
int | $offset = 0, | ||
bool | $orphanedonly = false, | ||
int | $toolproxyid = 0 ) |
Get both LTI tool proxies and tool types.
If limit and offset are not zero, a subset of the tools will be returned. Tool proxies will be counted before tool types. For example: If 10 tool proxies and 10 tool types exist, and the limit is set to 15, then 10 proxies and 5 types will be returned.
int | $limit | Maximum number of tools returned. |
int | $offset | Do not return tools before offset index. |
bool | $orphanedonly | If true, only return orphaned proxies. |
int | $toolproxyid | If not 0, only return tool types that have this tool proxy id. |
array | list(proxies[], types[]) List containing array of tool proxies and array of tool types. |
lti_get_lti_types_and_proxies_count | ( | bool | $orphanedonly = false, |
int | $toolproxyid = 0 ) |
Get the total number of LTI tool types and tool proxies.
bool | $orphanedonly | If true, only count orphaned proxies. |
int | $toolproxyid | If not 0, only count tool types that have this tool proxy id. |
int | Count of tools. |
lti_get_lti_types_by_course | ( | $courseid, | |
$coursevisible = null ) |
Returns all lti types visible in this course.
int | $courseid | The id of the course to retieve types for |
array | $coursevisible | options for 'coursevisible' field, default [LTI_COURSEVISIBLE_PRECONFIGURED, LTI_COURSEVISIBLE_ACTIVITYCHOOSER] |
stdClass[] | All the lti types visible in the given course |
lti_get_organizationid | ( | $typeconfig | ) |
get Organization ID using default if no value provided
object | $typeconfig |
string |
lti_get_permitted_service_scopes | ( | $type, | |
$typeconfig ) |
Initializes an array with the scopes for services supported by the LTI module and authorized for this particular tool instance.
object | $type | LTI tool type |
array | $typeconfig | LTI tool type configuration |
array | List of scopes |
lti_get_service_by_name | ( | $servicename | ) |
Initializes an instance of the named service.
string | $servicename | Name of service |
bool|mod_lti\local\ltiservice\service_base | Service |
lti_get_service_by_resource_id | ( | $services, | |
$resourceid ) |
Finds a service by id.
mod_lti\local\ltiservice\service_base[] | $services | Array of services |
string | $resourceid | ID of resource |
mod_lti\local\ltiservice\service_base | Service |
lti_get_services | ( | ) |
Initializes an array with the services supported by the LTI module.
array | List of services |
lti_get_shortcuts | ( | ) |
List of deprecated mod_lti functions.
lti_get_tool_proxies | ( | $orphanedonly | ) |
Returns lti tool proxies.
bool | $orphanedonly | Only retrieves tool proxies that have no type associated with them |
array | of basicLTI types |
lti_get_tool_proxies_from_registration_url | ( | $regurl | ) |
Get the tool proxy instance given its registration URL.
string | $regurl | Tool proxy registration URL |
array | The record of the tool proxy with this url |
lti_get_tool_proxy | ( | $id | ) |
Generates some of the tool proxy configuration based on the admin configuration details.
int | $id |
mixed | Tool Proxy details |
lti_get_tool_proxy_config | ( | $id | ) |
Generates some of the tool proxy configuration based on the admin configuration details.
int | $id |
mixed | Tool Proxy details |
lti_get_tool_proxy_from_guid | ( | $toolproxyguid | ) |
Get the tool proxy instance given its GUID.
string | $toolproxyguid | Tool proxy GUID value |
object |
lti_get_tool_proxy_table | ( | $toolproxies, | |
$id ) |
This function builds the tab for a category of tool proxies.
object | $toolproxies | Tool proxy instance objects |
string | $id | Category ID |
string | HTML for tab |
lti_get_tool_settings | ( | $toolproxyid, | |
$courseid = null, | |||
$instanceid = null ) |
Gets the tool settings.
int | $toolproxyid | Id of tool proxy record (or tool ID if negative) |
int | $courseid | Id of course (null if system settings) |
int | $instanceid | Id of course module (null if system or context settings) |
array | Array settings |
lti_get_type_config | ( | $typeid | ) |
Returns configuration details for the tool.
int | $typeid | Basic LTI tool typeid |
array | Tool Configuration |
lti_get_type_config_by_instance | ( | $instance | ) |
Fetches LTI type configuration for an LTI instance.
stdClass | $instance |
array | Can be empty if no type is found |
lti_get_type_config_from_instance | ( | $id | ) |
Generates some of the tool configuration based on the instance details.
int | $id |
object | configuration |
lti_get_type_type_config | ( | $id | ) |
Generates some of the tool configuration based on the admin configuration details.
int | $id |
stdClass | Configuration details |
lti_get_types_for_add_instance | ( | ) |
Returns tool types for lti add instance and edit page.
array | Array of lti types |
lti_initiate_login | ( | $courseid, | |
$cmid, | |||
$instance, | |||
$config, | |||
$messagetype = 'basic-lti-launch-request', | |||
$title = '', | |||
$text = '', | |||
$foruserid = 0 ) |
Generate the form for initiating a login request for an LTI 1.3 message.
int | $courseid | Course ID |
int | $cmid | LTI instance ID |
stdClass | null | $instance | LTI instance |
stdClass | $config | Tool type configuration |
string | $messagetype | LTI message type |
string | $title | Title of content item |
string | $text | Description of content item |
int | $foruserid | Id of the user targeted by the launch |
string |
lti_is_cartridge | ( | $url | ) |
Determines if the given url is for a IMS basic cartridge.
string | $url | The url to be checked |
True | if the url is for a cartridge |
lti_launch_tool | ( | $instance, | |
$foruserid = 0 ) |
Launch an external tool activity.
stdClass | $instance | the external tool activity settings |
int | $foruserid | for user param, optional |
string | The HTML code containing the javascript code for the launch |
lti_libxml_disable_entity_loader | ( | bool | $value | ) |
Wrapper for function libxml_disable_entity_loader() deprecated in PHP 8.
Method was deprecated in PHP 8 and it shows deprecation message. However it is still required in the previous versions on PHP. While Moodle supports both PHP 7 and 8 we need to keep it.
bool | $value |
bool |
lti_load_cartridge | ( | $url, | |
$map, | |||
$propertiesmap = array() ) |
Search for a tag within an XML DOMDocument.
string | $url | The url of the cartridge to be loaded |
array | $map | The map of tags to keys in the return array |
array | $propertiesmap | The map of properties to keys in the return array |
array | An associative array with the given keys and their values from the cartridge |
moodle_exception | if the cartridge could not be loaded correctly |
lti_load_tool_from_cartridge | ( | $url, | |
$lti ) |
Allows you to load in the configuration for an external tool from an IMS cartridge.
string | $url | The URL to the cartridge |
stdClass | $lti | LTI object |
moodle_exception | if the cartridge could not be loaded correctly |
lti_load_tool_if_cartridge | ( | $lti | ) |
Loads the cartridge information into the new tool, if the launch url is for a cartridge file.
stdClass | $lti | The tools config |
lti_load_type_from_cartridge | ( | $url, | |
$type ) |
Allows you to load settings for an external tool type from an IMS cartridge.
string | $url | The URL to the cartridge |
stdClass | $type | The tool type object to be filled in |
moodle_exception | if the cartridge could not be loaded correctly |
lti_load_type_if_cartridge | ( | $type | ) |
Loads the cartridge information into the tool type, if the launch url is for a cartridge file.
stdClass | $type | The tool type object to be filled in |
lti_log_request | ( | $rawbody | ) |
Logs the request to a file in temp dir.
string | $rawbody |
lti_log_response | ( | $responsexml, | |
$e = null ) |
Log an LTI response.
string | $responsexml | The response XML |
Exception | $e | If there was an exception, pass that too |
lti_map_keyname | ( | $key, | |
$tolower = true ) |
Used for building the names of the different custom parameters.
string | $key | Parameter name |
bool | $tolower | Do we want to convert the key into lower case? |
string | Processed name |
lti_new_access_token | ( | $typeid, | |
$scopes ) |
Create a new access token.
int | $typeid | Tool type ID |
string[] | $scopes | Scopes permitted for new token |
stdClass | Access token |
lti_parse_custom_parameter | ( | $toolproxy, | |
$tool, | |||
$params, | |||
$value, | |||
$islti2 ) |
Parse a custom parameter to replace any substitution variables.
object | $toolproxy | Tool proxy instance object |
object | $tool | Tool instance object |
array | $params | LTI launch parameters |
string | $value | Custom parameter value |
boolean | $islti2 | True if an LTI 2 tool is being launched |
string | Parsed value of custom parameter |
lti_post_launch_html | ( | $newparms, | |
$endpoint, | |||
$debug = false ) |
Posts the launch petition HTML.
array | $newparms | Signed parameters |
string | $endpoint | URL of the external tool |
bool | $debug | Debug (true/false) |
string |
lti_register | ( | $toolproxy | ) |
Prepares an LTI registration request message.
object | $toolproxy | Tool Proxy instance object |
lti_set_session_user | ( | $userid | ) |
Set the passed user ID to the session user.
int | $userid |
lti_set_tool_settings | ( | $settings, | |
$toolproxyid, | |||
$courseid = null, | |||
$instanceid = null ) |
Sets the tool settings (.
array | $settings | Array of settings |
int | $toolproxyid | Id of tool proxy record (or tool ID if negative) |
int | $courseid | Id of course (null if system settings) |
int | $instanceid | Id of course module (null if system or context settings) |
lti_should_log_request | ( | $rawbody | ) |
Determines if we should try to log the request.
string | $rawbody |
bool |
lti_sign_jwt | ( | $parms, | |
$endpoint, | |||
$oauthconsumerkey, | |||
$typeid = 0, | |||
$nonce = '' ) |
Converts the message paramters to their equivalent JWT claim and signs the payload to launch the external tool using JWT.
array | $parms | Parameters to be passed for signing |
string | $endpoint | url of the external tool |
string | $oauthconsumerkey | |
string | $typeid | ID of LTI tool type |
string | $nonce | Nonce value to use |
array|null |
lti_sign_parameters | ( | $oldparms, | |
$endpoint, | |||
$method, | |||
$oauthconsumerkey, | |||
$oauthconsumersecret ) |
Signs the petition to launch the external tool using OAuth.
array | $oldparms | Parameters to be passed for signing |
string | $endpoint | url of the external tool |
string | $method | Method for sending the parameters (e.g. POST) |
string | $oauthconsumerkey | |
string | $oauthconsumersecret |
array|null |
lti_split_custom_parameters | ( | $toolproxy, | |
$tool, | |||
$params, | |||
$customstr, | |||
$islti2 = false ) |
Splits the custom parameters field to the various parameters.
object | $toolproxy | Tool proxy instance object |
object | $tool | Tool instance object |
array | $params | LTI launch parameters |
string | $customstr | String containing the parameters |
boolean | $islti2 | True if an LTI 2 tool is being launched |
array | of custom parameters |
lti_split_parameters | ( | $customstr | ) |
Splits the custom parameters.
string | $customstr | String containing the parameters |
array | of custom parameters |
lti_tool_configuration_from_content_item | ( | $typeid, | |
$messagetype, | |||
$ltiversion, | |||
$consumerkey, | |||
$contentitemsjson ) |
Processes the tool provider's response to the ContentItemSelectionRequest and builds the configuration data from the selected content item.
This configuration data can be then used when adding a tool into the course.
int | $typeid | The tool type ID. |
string | $messagetype | The value for the lti_message_type parameter. |
string | $ltiversion | The value for the lti_version parameter. |
string | $consumerkey | The consumer key. |
string | $contentitemsjson | The JSON string for the content_items parameter. |
stdClass | The array of module information objects. |
moodle_exception | |
lti\OAuthException |
lti_type_add_categories | ( | int | $typeid, |
string | $lticoursecategories = '' ) |
Add LTI Type course category.
int | $typeid | |
string | $lticoursecategories | Comma separated list of course categories. |
void |
lti_update_config | ( | $config | ) |
Updates a tool configuration in the database.
object | $config | Tool configuration |
mixed | Record id number |
lti_update_tool_proxy | ( | $toolproxy | ) |
Updates a tool proxy in the database.
object | $toolproxy | Tool proxy |
int | Record id number |
lti_verify_jwt_signature | ( | $typeid, | |
$consumerkey, | |||
$jwtparam ) |
Verifies the JWT signature of an incoming message.
int | $typeid | The tool type ID. |
string | $consumerkey | The consumer key. |
string | $jwtparam | JWT parameter value |
stdClass | Tool type |
moodle_exception | |
UnexpectedValueException | Provided JWT was invalid |
SignatureInvalidException | Provided JWT was invalid because the signature verification failed |
BeforeValidException | Provided JWT is trying to be used before it's eligible as defined by 'nbf' |
BeforeValidException | Provided JWT is trying to be used before it's been created as defined by 'iat' |
ExpiredException | Provided JWT has since expired, as defined by the 'exp' claim |
lti_verify_oauth_signature | ( | $typeid, | |
$consumerkey ) |
Verifies the OAuth signature of an incoming message.
int | $typeid | The tool type ID. |
string | $consumerkey | The consumer key. |
stdClass | Tool type |
moodle_exception | |
lti\OAuthException |
lti_verify_sourcedid | ( | $ltiinstance, | |
$parsed ) |
Validate source ID from external request.
object | $ltiinstance | |
object | $parsed |
Exception |
lti_verify_with_keyset | ( | $jwtparam, | |
$keyseturl, | |||
$clientid ) |
Verifies the JWT signature using a JWK keyset.
string | $jwtparam | JWT parameter value. |
string | $keyseturl | The tool keyseturl. |
string | $clientid | The tool client id. |
object | The JWT's payload as a PHP object |
moodle_exception | |
UnexpectedValueException | Provided JWT was invalid |
SignatureInvalidException | Provided JWT was invalid because the signature verification failed |
BeforeValidException | Provided JWT is trying to be used before it's eligible as defined by 'nbf' |
BeforeValidException | Provided JWT is trying to be used before it's been created as defined by 'iat' |
ExpiredException | Provided JWT has since expired, as defined by the 'exp' claim |
mod_lti_verify_private_key | ( | ) |
This function checks if a private key has been generated for this site.
If the key does not exist it generates a new one. If the openssl extension is not installed or configured properly it returns a warning message.
string | A warning message if a private key does not exist and cannot be generated. |
params_to_string | ( | object | $params | ) |
Converts an array of custom parameters to a new line separated string.
object | $params | list of params to concatenate |
string |
serialise_tool_type | ( | stdClass | $type | ) |
Serialises this tool type.
stdClass | $type | The tool type |
array | An array of values representing this type |
xmldb_lti_upgrade | ( | $oldversion | ) |
xmldb_lti_upgrade is the function that upgrades the lti module database when is needed
This function is automaticly called when version number in version.php changes.
int | $oldversion | New old version number. |
boolean |
$definitions |
$deprecatedcapabilities |
$proxieslink |
$tasks |