You can access the current presentation:
// Using the SDK:
mobilelocker.getPresentation()
.then(presentation => {
// do something with the presentation JSON object
})
// Using axios (https://github.com/mzabriskie/axios):
axios.get('mobilelocker/api/presentation')
.then(response => {
// do something with the presentation JSON object
})
// Using jQuery:
$.get('mobilelocker/api/presentation', function(data) {
// do something with the presentation JSON object
})
The JSON looks like this:
{
"name": "Demo Presentation 1",
"status": "Installed",
"installed": true,
"id": 1,
"files": [
{
"status": "Installed",
"installed": true,
"path": "pdf_template.html",
"id": 1,
"size": 198,
"mime_type": "text/html"
},
{
"status": "Installed",
"installed": true,
"path": "email_template.html",
"id": 10,
"size": 374,
"mime_type": "text/html"
},
{
"status": "Installed",
"installed": true,
"path": "js/mobilelocker-user.js",
"id": 24,
"size": 762,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "css/site.css",
"id": 11,
"size": 1417,
"mime_type": "text/css"
},
{
"status": "Installed",
"installed": true,
"path": "js/mobilelocker-screenshot.js",
"id": 18,
"size": 2134,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/site.js",
"id": 12,
"size": 2245,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/jquery.plugin.html2canvas.js",
"id": 21,
"size": 2438,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/base64.js",
"id": 15,
"size": 2986,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "images/kazaam_mobileicon.png",
"id": 3,
"size": 3209,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "js/jquery.url.js",
"id": 17,
"size": 4776,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/mobilelocker-tracking-2.0.js",
"id": 14,
"size": 5166,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/canvas2image.js",
"id": 16,
"size": 6770,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "images/thumbnail.png",
"id": 8,
"size": 7962,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "images/fpo_picture.png",
"id": 6,
"size": 13571,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "js/html2canvas.min.js",
"id": 13,
"size": 21916,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "images/fpo_bar_chart.png",
"id": 5,
"size": 22963,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "images/fpo_line_chart.png",
"id": 2,
"size": 25452,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "index.html",
"id": 26,
"size": 26220,
"mime_type": "text/html"
},
{
"status": "Installed",
"installed": true,
"path": "js/jquery.form.js",
"id": 22,
"size": 27135,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "images/fpo_table.png",
"id": 9,
"size": 28766,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "images/fpo_chart.png",
"id": 4,
"size": 32238,
"mime_type": "image/png"
},
{
"status": "Installed",
"installed": true,
"path": "images/kazaam_mobile.jpg",
"id": 7,
"size": 54352,
"mime_type": "image/jpeg"
},
{
"status": "Installed",
"installed": true,
"path": "js/html2canvas.js",
"id": 19,
"size": 76526,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "assets/search-engine-optimization-starter-guide.pdf",
"id": 25,
"size": 4318447,
"mime_type": "application/pdf"
},
{
"status": "Installed",
"installed": true,
"path": "js/mobilelocker-tracking-legacy.js",
"id": 16276,
"size": 7916,
"mime_type": "application/x-javascript"
},
{
"status": "Installed",
"installed": true,
"path": "js/jquery.min.js",
"id": 16277,
"size": 86709,
"mime_type": "application/x-javascript"
}
],
"description": "Quae iure et aspernatur et inventore aut et quia. Distinctio neque vero officia et facilis qui quis alias. Quia temporibus quo officiis et.",
"type": "HTML",
"main_path": "index.html"
}