v1.5 Documentation

These reference documents are designed to help you when things don't go as planned. The individual screen type documents are useful for looking up available JSON properties.

Menus
Content Screens
Settings Screens
Splash Screens
Other Actions
Data URL's and Merge Fields
In some cases, you may need to dynamically create content or screens based on some variables only known at run-time, when your app is actually running. For example, you may need to know the devices location before knowing what content to display. Merge fields can help you do this.
When you use URL's in your application you can append device specfic information to the end of the URL's (this is called the querystring) allowing you to capture dynamic information about the device or the user on your backend server. There are lots of reasons this could be helpful. Experienced web-developers understand how powerful this concept is and don't usually need an explanation.
A Simple Example
You have a backend script that produces a list of JSON Location Items that you use to power a Location Map Screen.
The dataURL property of the Location Map Screen would look like this: "dataURL":"http://www.mysite.com/locationsScript.php"
However, you want to get a bit creative and only show locations that are a certain distance from the device. The only way to do this would be to know where the device was when the dataURL was requested. You accomplish this by appending the devices location in the querystring (at the end of the URL) so that the script on your server can do custom processing and output only the locations within the per-determined distance.
Here how the dataURL would look: "dataURL":"http://www.mysite.com/locationsScript.php&deviceLatitude=[deviceLatitude]&deviceLongitude=[deviceLongitude]
The device would turn the URL into something like this before making the request. "dataURL":"http://www.mysite.com/locationsScript.php&deviceLatitude=38.44423&deviceLongitude=-103.48848
Then, on your backend script (assuming you use .PHP) you could read the latitude and longitude information with: $_GET["deviceLatitude"] and $_GET["deviceLongitude"].
Available Merge Fields
  • [buzztouchAppId] This is the App Id from your buzztouch control panel
  • [buzztouchAPIKey] This is the app API Key from your buzztouch control panel
  • [screenId] The unique id of the current screen (useful for determing the app context)
  • [userId] The Unique Id of a logged in user (if the app uses login screens)
  • [userEmail] The email address of a logged in user
  • [deviceId] A globally unique string value assigned to the device.
  • [deviceModel] A string value controlled by the device manufacturer.
  • [deviceLatitude] A latitude coordinate value (if the device is reporting it's location).
  • [deviceLongitude] A longitude coordinate value (if the device is reporting it's location).
Merge Field Usage
http://www.mysite.com/localrestaurants.php?deviceLatitude=[deviceLatitude]&deviceLongitude=[deviceLongitude]&userId=[userId]
turns into: http://www.mysite.com/localrestaurants.php?latitude=38.4456&longitude=-102.3444&userId=00000