Feasibility API

This API is used to determine the feasibility of submitting a project to our panel as well as the rate card CPI.

Command

"client/feasibility/1"



Inputs

The following values are expected in the JSON body:

Name Type Required Description
command String

Must be "client/feasibility/1"

daysInField Integer

Number of days to run survey.

Country String

2-letter ISO country code, e.g. US, GB, CA, etc.

ir Integer

Incidence rate as a percent.

lengthOfInterview Integer

Length of interview.

dr Integer

Drop rate as a percent. Defaults to 20%.

datapoints Object[]

Array of datapoints used by feasibility. (See the Add Datapoints API for more detail).

deviceTargeting String[]

An array of strings - desktop, laptop, phone and/or tablet. Short-cut to specifying the Computer Check qualification.


Outputs

The JSON output will always contain the original command and a result. If the result > 0, an error has occurred (refer to Error Codes) and a message field will describe the error. If result = 0, the following is included in the response field:

Name Type Description
feasibility Object[]

Array of all combinations of datapoint values with its feasibility count.

cpi String

The calculated CPI based on customer's rate card in USD.


Example Command

{
     command: "client/feasibility/1",
     daysInField : 7,
     country : "GB",
     ir: 40,
     lengthOfInterview: 25,
     datapoints:[
          {
               name:"Age",
               values:[{"min":24, "max":37}],
          },
          {
               name:"Gender",
               values:[1,2]
          },
          {
               name:"Region (UK)",
               values:[3,4]
          }
     ]
}

Example Response

"response" : {
     cpi: "$2.65",
     "feasibility" : [
          { "Age" : "Range 24 - 37" , "Gender" : 2 , "Region (UK)" : 4 , "count" : 9.7, confidence: 0.5} ,
          { "Age" : "Range 24 - 37" , "Gender" : 1 , "Region (UK)" : 4 , "count" : 15.9, confidence: 0.6},
          { "Age" : "Range 24 - 37" , "Gender" : 1 , "Region (UK)" : 3 , "count" : 8.5, confidence: 0.7},
          { "Age" : "Range 24 - 37" , "Gender" : 2 , "Region (UK)" : 3 , "count" : 5.6, confidence: 0.8}
     ]
}