Kiosks

Last Updated: April 15, 2013

This document lays out the specification of interacting with the Qgiv Kiosk management system, allowing for reading, writing, and updating kiosk settings and kiosk navigation.

Kiosk Properties

GET : https://secure.qgiv.com/admin/api/kiosk/list

Returns all kiosks associated with the current form

Reception Kiosk Thank you for getting involved with such a great cause! [email protected] Kiosk Receipt [email protected] Kiosk Transaction Receipt Our organization was founded to help serve the community 1183 1133 0 1 Events 2 0 all Contact 1 10 http://www.qgiv.com/contact
{
    "kiosks": [
    {
     "id": "1294"
        "settings": {
      "id": "12"
            "name": "Reception Kiosk",
            "receipt": {
                "receiptBody": "Thank you for getting involved with such a great cause!",
                "receiptFromAddress": "[email protected]",
                "receiptFromName": "Kiosk Receipt",
                "receiptNotificationAddress": "[email protected]",
                "receiptSubject": "Kiosk Transaction Receipt"
            },
            "aboutText": "Our organization was founded to help serve the community...",
            "kioskLogoPrimary": "1183",
            "permitGuestsOnly": "",
            "kioskLogoSecondary": "1133",
            "colorScheme": "1"
        },
        "navigation": {
            "navigation_item": [
                {
        "id": "63"
                    "title": "Events",
                    "type": "2",
                    "mode": "",
                    "data": "all"
                },
                {
        "id": "61"
                    "title": "Contact",
                    "type": "1",
                    "mode": "10",
                    "data": "http://www.qgiv.com/contact"
                },
       ...
            ]
        },
      }
   ...
   ]
}
Libraries to use :
using System.Net;
using System.Text;
using System.IO;


string postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP";
HttpWebResponse resp = null;
string result = null;

try {
HttpWebRequest req = WebRequest.Create(new Uri("https://secure.qgiv.com/admin/api/kiosk/list.xml")) as HttpWebRequest;
req.Method = "POST";
req.Accept = "*/*";
req.UserAgent = "http_request/0.1";
req.Timeout = 50000;
req.ContentType = "application/x-www-form-urlencoded";
byte[] formData = UTF8Encoding.UTF8.GetBytes(postData);
using (Stream post = req.GetRequestStream()) {
post.Write(formData, 0, formData.Length);
}
// Pick up the response:
resp = req.GetResponse() as HttpWebResponse;

if (resp.StatusCode == System.Net.HttpStatusCode.OK) {
using (resp) {
StreamReader reader =
new StreamReader(resp.GetResponseStream());
result = reader.ReadToEnd();
}
}
} catch (Exception e) {
result = "error : " + e.Message;
}
String data = URLEncoder.encode("token", "UTF-8") + "=" + URLEncoder.encode("skyMV9YeaxQ7EjbEUHt8TUiP", "UTF-8");

URL url = new URL("https://secure.qgiv.com/admin/api/kiosk/list.xml");
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
wr.write(data);
wr.flush();

BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
String output;
while ((line = rd.readLine()) != null) {
output += line;
}

wr.close();
rd.close();
return output;
var apiRequest = false;
var url = "https://secure.qgiv.com/admin/api/kiosk/list.xml";
var postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP";
var results;

var isIE8 = window.XDomainRequest ? true : false;
if (typeof XMLHttpRequest != "undefined") {
if(isIE8) {
apiRequest = new Window.XDomainRequest()
} else {
apiRequest = new XMLHttpRequest();
}
} else if (window.ActiveXObject) {
var ieVersions = ["MSXML2.XMLHttp.5.0","MSXML2.XMLHttp.4.0","MSXML2.XMLHttp.3.0","MSXML2.XMLHttp","Microsoft.XMLHttp"];
for (var i = 0; i < ieVersions.length; i++) {
try {
apiRequest = new ActiveXObject(aVersions[i]);
} catch(oError) {
throw new Error("XMLHttp object could be created.");
}
}
}

if (!apiRequest) {
alert("An error has occuerd while creating XMLHttpRequest object");
}


if (apiRequest) {
apiRequest.open("POST", url, true);
apiRequest.onreadystatechange = handleResponse;
apiRequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
apiRequest.send(postData);
}

function handleResponse() {
if (apiRequest.readyState == 4) {
if (apiRequest.status == 200) {
results = apiRequest.responseText;
} else {
results = "Server response is unsuccessful";
}
} else {
results = "Server response is incomplete"
}
}
$postArray = array(
   'token' => '[your API token]'
);

$postString = http_build_query($postArray);

$url = 'https://secure.qgiv.com/admin/api/kiosk/list.xml';

$curlHandler = curl_init();

curl_setopt($curlHandler, CURLOPT_URL, $url);
curl_setopt($curlHandler, CURLOPT_POST, true);
curl_setopt($curlHandler, CURLOPT_POSTFIELDS, $postString);
curl_setopt($curlHandler, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYHOST, false);

$response = curl_exec($curlHandler);

if (curl_errno($curlHandler)) {
$response = 'error : '.curl_error($curlHandler);
} else {
curl_close($curlHandler);
}

return $response;

import urllib, urllib2

postArray = {
   'token' => '[your API token]'
}

postString = urllib.urlencode(postArray)

url = 'https://secure.qgiv.com/admin/api/kiosk/list.xml';

request = urllib2.Request(url, data=data)

try:
  response = urllib2.urlopen(request)
  result = response.read()
  response.close()
except urllib2.URLError, e:
  result = 'error : ' + str(e.code)

return result

GET : https://secure.qgiv.com/admin/api/kiosks/[id]

Returns the kiosk requested, individually specified by ID

Reception Kiosk Thank you for getting involved with such a great cause! [email protected] Kiosk Receipt [email protected] Kiosk Transaction Receipt Our organization was founded to help serve the community 1183 1133 0 1 Events 2 0 all Contact 1 10 http://www.qgiv.com/contact
{
    "kiosk": {
        "id": "1294",
        "settings": {
            "id": "12",
            "name": "Reception Kiosk",
            "receipt": {
                "receiptBody": "Thank you for getting involved with such a great cause!",
                "receiptFromAddress": "[email protected]",
                "receiptFromName": "Kiosk Receipt",
                "receiptNotificationAddress": "[email protected]",
                "receiptSubject": "Kiosk Transaction Receipt"
            },
            "aboutText": "Our organization was founded to help serve the community...",
            "kioskLogoPrimary": "1183",
            "permitGuestsOnly": "",
            "kioskLogoSecondary": "1133",
            "colorScheme": "1"
        },
        "navigation": {
            "navigation_item": [
                {
                    "id": "63",
                    "title": "Events",
                    "type": "2",
                    "mode": "",
                    "data": "all"
                },
                {
                    "id": "61",
                    "title": "Contact",
                    "type": "1",
                    "mode": "10",
                    "data": "http://www.qgiv.com/contact"
                },
                ...
            ]
        },
        
    }
}
Libraries to use :
using System.Net;
using System.Text;
using System.IO;


string postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP";
HttpWebResponse resp = null;
string result = null;

try {
HttpWebRequest req = WebRequest.Create(new Uri("https://secure.qgiv.com/admin/api/kiosks/1294.xml")) as HttpWebRequest;
req.Method = "POST";
req.Accept = "*/*";
req.UserAgent = "http_request/0.1";
req.Timeout = 50000;
req.ContentType = "application/x-www-form-urlencoded";
byte[] formData = UTF8Encoding.UTF8.GetBytes(postData);
using (Stream post = req.GetRequestStream()) {
post.Write(formData, 0, formData.Length);
}
// Pick up the response:
resp = req.GetResponse() as HttpWebResponse;

if (resp.StatusCode == System.Net.HttpStatusCode.OK) {
using (resp) {
StreamReader reader =
new StreamReader(resp.GetResponseStream());
result = reader.ReadToEnd();
}
}
} catch (Exception e) {
result = "error : " + e.Message;
}
String data = URLEncoder.encode("token", "UTF-8") + "=" + URLEncoder.encode("skyMV9YeaxQ7EjbEUHt8TUiP", "UTF-8");

URL url = new URL("https://secure.qgiv.com/admin/api/kiosks/1294.xml");
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
wr.write(data);
wr.flush();

BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
String output;
while ((line = rd.readLine()) != null) {
output += line;
}

wr.close();
rd.close();
return output;
var apiRequest = false;
var url = "https://secure.qgiv.com/admin/api/kiosks/1294.xml";
var postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP";
var results;

var isIE8 = window.XDomainRequest ? true : false;
if (typeof XMLHttpRequest != "undefined") {
if(isIE8) {
apiRequest = new Window.XDomainRequest()
} else {
apiRequest = new XMLHttpRequest();
}
} else if (window.ActiveXObject) {
var ieVersions = ["MSXML2.XMLHttp.5.0","MSXML2.XMLHttp.4.0","MSXML2.XMLHttp.3.0","MSXML2.XMLHttp","Microsoft.XMLHttp"];
for (var i = 0; i < ieVersions.length; i++) {
try {
apiRequest = new ActiveXObject(aVersions[i]);
} catch(oError) {
throw new Error("XMLHttp object could be created.");
}
}
}

if (!apiRequest) {
alert("An error has occuerd while creating XMLHttpRequest object");
}


if (apiRequest) {
apiRequest.open("POST", url, true);
apiRequest.onreadystatechange = handleResponse;
apiRequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
apiRequest.send(postData);
}

function handleResponse() {
if (apiRequest.readyState == 4) {
if (apiRequest.status == 200) {
results = apiRequest.responseText;
} else {
results = "Server response is unsuccessful";
}
} else {
results = "Server response is incomplete"
}
}
$postArray = array(
   'token' => '[your API token]'
);

$postString = http_build_query($postArray);

$url = 'https://secure.qgiv.com/admin/api/kiosks/1294.xml';

$curlHandler = curl_init();

curl_setopt($curlHandler, CURLOPT_URL, $url);
curl_setopt($curlHandler, CURLOPT_POST, true);
curl_setopt($curlHandler, CURLOPT_POSTFIELDS, $postString);
curl_setopt($curlHandler, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYHOST, false);

$response = curl_exec($curlHandler);

if (curl_errno($curlHandler)) {
$response = 'error : '.curl_error($curlHandler);
} else {
curl_close($curlHandler);
}

return $response;

import urllib, urllib2

postArray = {
   'token' => '[your API token]'
}

postString = urllib.urlencode(postArray)

url = 'https://secure.qgiv.com/admin/api/kiosks/1294.xml';

request = urllib2.Request(url, data=data)

try:
  response = urllib2.urlopen(request)
  result = response.read()
  response.close()
except urllib2.URLError, e:
  result = 'error : ' + str(e.code)

return result

https://secure.qgiv.com/admin/api/kiosks/create

Creates kiosk settings for a newly created kiosk.

Input

Reception Kiosk Thank you for getting involved with such a great cause! [email protected] Kiosk Receipt [email protected] Kiosk Transaction Receipt Our organization was founded to help serve the community 1183 1133 0 1 Events 2 0 all Contact 1 10 http://www.qgiv.com/contact
{
    "kiosks": [
    {
        "id": "1294",
        "settings": {
            "name": "Reception Kiosk",
            "receipt": {
                "receiptBody": "Thank you for getting involved with such a great cause!",
                "receiptFromAddress": "[email protected]",
                "receiptFromName": "Kiosk Receipt",
                "receiptNotificationAddress": "[email protected]",
                "receiptSubject": "Kiosk Transaction Receipt"
            },
            "aboutText": "Our organization was founded to help serve the community...",
            "kioskLogoPrimary": "1183",
            "permitGuestsOnly": "",
            "kioskLogoSecondary": "1133",
            "colorScheme": "1"
        },
        "navigation": {
            "navigation_item": [
                {
                    "title": "Events",
                    "type": "2",
                    "mode": "",
                    "data": "all"
                },
                {
                    "title": "Contact",
                    "type": "1",
                    "mode": "10",
                    "data": "http://www.qgiv.com/contact"
                }
                ...
            ]
        },
      }
   ...
   ]
}
Libraries to use :
using System.Net;
using System.Text;
using System.IO;


string postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP&package=[xml or json formatted input]";
HttpWebResponse resp = null;
string result = null;

try {
HttpWebRequest req = WebRequest.Create(new Uri("https://secure.qgiv.com/admin/api/kiosks/create.xml")) as HttpWebRequest;
req.Method = "POST";
req.Accept = "*/*";
req.UserAgent = "http_request/0.1";
req.Timeout = 50000;
req.ContentType = "application/x-www-form-urlencoded";
byte[] formData = UTF8Encoding.UTF8.GetBytes(postData);
using (Stream post = req.GetRequestStream()) {
post.Write(formData, 0, formData.Length);
}
// Pick up the response:
resp = req.GetResponse() as HttpWebResponse;

if (resp.StatusCode == System.Net.HttpStatusCode.OK) {
using (resp) {
StreamReader reader =
new StreamReader(resp.GetResponseStream());
result = reader.ReadToEnd();
}
}
} catch (Exception e) {
result = "error : " + e.Message;
}
String data = URLEncoder.encode("token", "UTF-8") + "=" + URLEncoder.encode("skyMV9YeaxQ7EjbEUHt8TUiP", "UTF-8");
data += "&" + URLEncoder.encode("package", "UTF-8") + "=" URLEncoder.encode("[xml or json formatted input]", "UTF-8");

URL url = new URL("https://secure.qgiv.com/admin/api/kiosks/create.xml");
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
wr.write(data);
wr.flush();

BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
String output;
while ((line = rd.readLine()) != null) {
output += line;
}

wr.close();
rd.close();
return output;
var apiRequest = false;
var url = "https://secure.qgiv.com/admin/api/kiosks/create.xml";
var postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP&package=[xml or json formatted input]";
var results;

var isIE8 = window.XDomainRequest ? true : false;
if (typeof XMLHttpRequest != "undefined") {
if(isIE8) {
apiRequest = new Window.XDomainRequest()
} else {
apiRequest = new XMLHttpRequest();
}
} else if (window.ActiveXObject) {
var ieVersions = ["MSXML2.XMLHttp.5.0","MSXML2.XMLHttp.4.0","MSXML2.XMLHttp.3.0","MSXML2.XMLHttp","Microsoft.XMLHttp"];
for (var i = 0; i < ieVersions.length; i++) {
try {
apiRequest = new ActiveXObject(aVersions[i]);
} catch(oError) {
throw new Error("XMLHttp object could be created.");
}
}
}

if (!apiRequest) {
alert("An error has occuerd while creating XMLHttpRequest object");
}


if (apiRequest) {
apiRequest.open("POST", url, true);
apiRequest.onreadystatechange = handleResponse;
apiRequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
apiRequest.send(postData);
}

function handleResponse() {
if (apiRequest.readyState == 4) {
if (apiRequest.status == 200) {
results = apiRequest.responseText;
} else {
results = "Server response is unsuccessful";
}
} else {
results = "Server response is incomplete"
}
}
$postArray = array(
'token' => '[your API token]',
'package' => '[xml or json formatted input]'
);

$postString = http_build_query($postArray);

$url = 'https://secure.qgiv.com/admin/api/kiosks/create.xml';

$curlHandler = curl_init();

curl_setopt($curlHandler, CURLOPT_URL, $url);
curl_setopt($curlHandler, CURLOPT_POST, true);
curl_setopt($curlHandler, CURLOPT_POSTFIELDS, $postString);
curl_setopt($curlHandler, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYHOST, false);

$response = curl_exec($curlHandler);

if (curl_errno($curlHandler)) {
$response = 'error : '.curl_error($curlHandler);
} else {
curl_close($curlHandler);
}

return $response;

import urllib, urllib2

postArray = {
'token' : '[your API token]',
'package' : '[xml or json formatted input]'
}

postString = urllib.urlencode(postArray)

url = 'https://secure.qgiv.com/admin/api/kiosks/create.xml';

request = urllib2.Request(url, data=data)

try:
  response = urllib2.urlopen(request)
  result = response.read()
  response.close()
except urllib2.URLError, e:
  result = 'error : ' + str(e.code)

return result

Output

Reception Kiosk Thank you for getting involved with such a great cause! [email protected] Kiosk Receipt [email protected] Kiosk Transaction Receipt Our organization was founded to help serve the community 1183 1133 0 1 Events 2 0 all Contact 1 10 http://www.qgiv.com/contact
{
    "kiosks": [
    {
        "id": "1294",
        "settings": {
            "id": "12",
            "name": "Reception Kiosk",
            "receipt": {
                "receiptBody": "Thank you for getting involved with such a great cause!",
                "receiptFromAddress": "[email protected]",
                "receiptFromName": "Kiosk Receipt",
                "receiptNotificationAddress": "[email protected]",
                "receiptSubject": "Kiosk Transaction Receipt"
            },
            "aboutText": "Our organization was founded to help serve the community...",
            "kioskLogoPrimary": "1183",
            "permitGuestsOnly": "",
            "kioskLogoSecondary": "1133",
            "colorScheme": "1"
        },
        "navigation": {
            "navigation_item": [
                {
                    "id": "63",
                    "title": "Events",
                    "type": "2",
                    "mode": "",
                    "data": "all"
                },
                {
                    "id": "61",
                    "title": "Contact",
                    "type": "1",
                    "mode": "10",
                    "data": "http://www.qgiv.com/contact"
                },
                ...
            ]
        },
      }
      ...
   ]
}

https://secure.qgiv.com/admin/api/kiosks/[id]

Updates a kiosk, with the values passed in, returning the updated kiosk.

Input

Thank you! Kiosk Receipt Our organization was founded to help serve the community 1 2 145,167,198 Restrictions 2 0 all
{
    "kiosk": {
        "id": "1294",
        "settings": {
            "id": "12",
            "receipt": {
                "receiptBody": "Thank you!",
                "receiptSubject": "Kiosk Receipt"
            },
            "permitGuestsOnly": "1",
            "colorScheme": "2"
        },
        "navigation": {
            "navigation_item": [
                {
                    "id": "63",
                    "data": "145, 167, 198"
                },
                {
                    "id": "61",
                    "title": "Restrictions",
                    "type": "3",
                    "mode": "0",
                    "data": "all"
                },
                ...
            ]
        },
        
    }
}
Libraries to use :
using System.Net;
using System.Text;
using System.IO;


string postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP&package=[xml or json formatted input]";
HttpWebResponse resp = null;
string result = null;

try {
HttpWebRequest req = WebRequest.Create(new Uri("https://secure.qgiv.com/admin/api/kiosks/1294.xml")) as HttpWebRequest;
req.Method = "POST";
req.Accept = "*/*";
req.UserAgent = "http_request/0.1";
req.Timeout = 50000;
req.ContentType = "application/x-www-form-urlencoded";
byte[] formData = UTF8Encoding.UTF8.GetBytes(postData);
using (Stream post = req.GetRequestStream()) {
post.Write(formData, 0, formData.Length);
}
// Pick up the response:
resp = req.GetResponse() as HttpWebResponse;

if (resp.StatusCode == System.Net.HttpStatusCode.OK) {
using (resp) {
StreamReader reader =
new StreamReader(resp.GetResponseStream());
result = reader.ReadToEnd();
}
}
} catch (Exception e) {
result = "error : " + e.Message;
}
String data = URLEncoder.encode("token", "UTF-8") + "=" + URLEncoder.encode("skyMV9YeaxQ7EjbEUHt8TUiP", "UTF-8");
data += "&" + URLEncoder.encode("package", "UTF-8") + "=" URLEncoder.encode("[xml or json formatted input]", "UTF-8");

URL url = new URL("https://secure.qgiv.com/admin/api/kiosks/1294.xml");
URLConnection conn = url.openConnection();
conn.setDoOutput(true);
OutputStreamWriter wr = new OutputStreamWriter(conn.getOutputStream());
wr.write(data);
wr.flush();

BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
String output;
while ((line = rd.readLine()) != null) {
output += line;
}

wr.close();
rd.close();
return output;
var apiRequest = false;
var url = "https://secure.qgiv.com/admin/api/kiosks/1294.xml";
var postData = "token=skyMV9YeaxQ7EjbEUHt8TUiP&package=[xml or json formatted input]";
var results;

var isIE8 = window.XDomainRequest ? true : false;
if (typeof XMLHttpRequest != "undefined") {
if(isIE8) {
apiRequest = new Window.XDomainRequest()
} else {
apiRequest = new XMLHttpRequest();
}
} else if (window.ActiveXObject) {
var ieVersions = ["MSXML2.XMLHttp.5.0","MSXML2.XMLHttp.4.0","MSXML2.XMLHttp.3.0","MSXML2.XMLHttp","Microsoft.XMLHttp"];
for (var i = 0; i < ieVersions.length; i++) {
try {
apiRequest = new ActiveXObject(aVersions[i]);
} catch(oError) {
throw new Error("XMLHttp object could be created.");
}
}
}

if (!apiRequest) {
alert("An error has occuerd while creating XMLHttpRequest object");
}


if (apiRequest) {
apiRequest.open("POST", url, true);
apiRequest.onreadystatechange = handleResponse;
apiRequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
apiRequest.send(postData);
}

function handleResponse() {
if (apiRequest.readyState == 4) {
if (apiRequest.status == 200) {
results = apiRequest.responseText;
} else {
results = "Server response is unsuccessful";
}
} else {
results = "Server response is incomplete"
}
}
$postArray = array(
'token' => '[your API token]',
'package' => '[xml or json formatted input]'
);

$postString = http_build_query($postArray);

$url = 'https://secure.qgiv.com/admin/api/kiosks/1294.xml';

$curlHandler = curl_init();

curl_setopt($curlHandler, CURLOPT_URL, $url);
curl_setopt($curlHandler, CURLOPT_POST, true);
curl_setopt($curlHandler, CURLOPT_POSTFIELDS, $postString);
curl_setopt($curlHandler, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curlHandler, CURLOPT_SSL_VERIFYHOST, false);

$response = curl_exec($curlHandler);

if (curl_errno($curlHandler)) {
$response = 'error : '.curl_error($curlHandler);
} else {
curl_close($curlHandler);
}

return $response;

import urllib, urllib2

postArray = {
'token' : '[your API token]',
'package' : '[xml or json formatted input]'
}

postString = urllib.urlencode(postArray)

url = 'https://secure.qgiv.com/admin/api/kiosks/1294.xml';

request = urllib2.Request(url, data=data)

try:
  response = urllib2.urlopen(request)
  result = response.read()
  response.close()
except urllib2.URLError, e:
  result = 'error : ' + str(e.code)

return result


* denotes a required field

** denotes a required field based on Event settings

*** denotes a field that is only required when submitting Form level API credentials