LearningApps API
Use of API functions:
api?getcategories
api?getlevels
api?search=s
api?search=s&category=0&offset=0
api?search=s&category=0&subcategory=0&offset=0
api?getapps&category=0&offset=0
api?getapps&category=0&subcategory=0&offset=0
api?getapps&category=0&subcategory=0&offset=0&levelStart=1&levelEnd=1
api?gettemplates
api?createapp&template=71
api?getappbyid=ID
api?getappbyguid=GUID
api?getuserapps (will require an active session with login first)
add &lang=EN for different languages
You can fetch the content data of a specific app by calling:
https://learningapps.org/data?app=ID or
https://learningapps.org/data?id=GUID
A more complex example: https://jsfiddle.net/rz6y4cue/
You can provide a login form with an iframe to:
https://learningapps.org/login?form&lang=EN
The form will postMessage("LearningApps_LoginSuccessfull","*"); on success
Creating a new app with api.php?createapp will postMessage("LEARNINGAPP|SAVED|NewAppGUID", "*"); to the parent page.
You can read the data and close/remove the editor iframe:
window.addEventListener("message",function(e){
if(e.data.indexOf("LEARNINGAPP") === 0){
var parts = e.data.split("|");
console.log("new app created with GUID: " + parts[2]);
}
})
You can embed LearningApps into your own pages and inform your page when app is solved.
See example here: https://jsfiddle.net/24xdn78q/
You can also use the message API to fetch data from the app. See a more advanced example
here: https://jsfiddle.net/M_H_S/098beag4/1/ or
here: https://jsfiddle.net/03ktca78/1/
Embedding LearningApps in other pages also allowes custom styling. Find some examples here:
https://sites.google.com/view/learningapps-beispiel/
If you like to disable Matomo Analytics for embedded Apps you can add
disableanalytics=1 as parameter to the embed URL.