Datapoint API

This API is used to obtain all of the questions and answers for a datapoint.
For each datapoint you want to map, you should invoke the datapoint command to see the possible answers.

Command

"livealert/datapoint/1"

Recommended Frequency

Once every 12 hours to check for changes to datapoints.



Inputs

The following values are expected in the JSON body:

Name Type Required Description
command String

Must be "livealert/datapoint/1"

name String

The datapoint name.


Outputs

Name Type Description
name String

The datapoint name.

property String

The property name.

mode Integer
  1. profile question - asked once per respondent, response should never change. (ie. ethnicity)
  2. screener question - asked once per session, response will change over time (ie. Which parks did you visit in the past 30 days?)
type Integer

Type of question

0 - Radio Button (Single Selection)
1 - Checkbox (Multiple Selection)
2 - Dropdown (Single Selection)
13 - Derived from postal code (Single Selection)
15 - Age range
16 - List of postal codes
17 - Children
18 - List of zip+4 codes

question JSON

An object containing the text for the question in multiple locales. e.g.

{
  "en-US" : "How many DVDs/Blu-rays do you purchase on a monthly basis (on average)?",
  "en-GB" : "How many DVDs/Blu-rays do you purchase on a monthly basis (on average)?",
  "de-DE" : "Wie viele DVDs oder Blu-ray Discs kaufen Sie normalerweise in einem Monat?",
  "fr-FR" : "Combien de DVD et de Blue-rays achetez-vous chaque mois (en moyenne) ?",
  "en-CA" : "How many DVDs/Blu-rays do you purchase on a monthly basis (on average)?"
}

When a locale is not present, please use the "en-US" value.

answers JSON[]

An array of answer objects.

[null,
 {
    "en-US" : "0",
    "disposition" : 1,
    "en-GB" : "0",
    "de-DE" : "0",
    "fr-FR" : "0",
    "en-CA" : "0"
  }, {
    "en-US" : "1 to 3",
    "disposition" : 1,
    "en-GB" : "1 to 3",
    "de-DE" : "1 bis 3",
    "fr-FR" : "4 à 6",
    "en-CA" : "1 to 3"
  }, {
    "en-US" : "4 to 6",
    "disposition" : 1,
    "en-GB" : "4 to 6",
    "de-DE" : "4 bis 6",
    "fr-FR" : "7 à 10",
    "en-CA" : "4 to 6"
  }, {
    "en-US" : "7 to 10",
    "disposition" : 1,
    "en-GB" : "7 to 10",
    "de-DE" : "7 bis 10",
    "fr-FR" : "7 à 10",
    "en-CA" : "7 to 10"
  }, {
    "en-US" : "11 or more",
    "disposition" : 1,
    "en-GB" : "11 or more",
    "de-DE" : "11 oder mehr",
    "fr-FR" : "11 ou plus",
    "en-CA" : "11 or more"
  }]

The index of the answer is the numeric code for that answer. ie. "4 to 6" is answer #3. Note that the 0th answer is typically null, so the first answer starts with 1.

The disposition values for each answer are: The disposition values for each answer are:

  1. Mandatory
  2. Mandatory, at end of list
  3. Omit
  4. Exclusive
  5. Exclusive, at end of list
countries String[]

The array contains the ISO codes of the countries that are supported by this datapoint.


Example Command

{
    "command": "livealert/datapoint/1",  
    "name": "RFG2_Vote"}

Example Response

"response": {
	"answers": [
	null,
	{
		"en-US": "Yes",
		"disposition": 0
	},
	{
		"en-US": "No",
		"disposition": 0
	}
],
	"mode": 1,
	"name": "RFG2_Vote",
	"property": "rfg2_634",
	"question": {
		"en-US": "Are you registered to vote?"
	},
	"type": 0,
	"countries" : [ "US" , "VN" ]
}