This topic is under construction.
This document covers the consolidated schema and structures for the Web Configuration Portal (WCP).
Updates
Mar 20,2019 v1.7
- Added “other” in Question Step of multiple choice
Nov 20,2017 v1.6
- Added “operator” in Question Step for each destination
- Added “kickCount” for Fetel Kick Active Task Format
- Added “dateRange” for Date Type Question Format
Mar 16, 2017 v1.5
- Expanded text choices array for text scale, text choices and value pickers.
Mar 5, 2017 v1.4
- Added Destinations structure for question step
- Updated Form Step result structure. It is array of array(iterations) of question results.
- Removed configuration from the activity metadata.
Feb 22, 2017 v1.3
- Added TowerOfHanoi and SpatialSpanMemory in supported active task types.
- Updated Active Task type to ‘task’ from ‘activeTask’
Feb 16, 2017 v1.2
- Changed Active Task Step result to “grouped” result
- Added activityRunId to activity result metadata
Feb 09, 2017 v1.1
- Changed ‘info’ to ‘metadata’ in Activity Metadata Structures
- Changed ‘response’ to ‘data’ in Activity Result Structures
- Changed ‘description’ to ‘text’ in Active Task Step
Feb 08, 2017 v1.0
- Consolidated schema and structure document
Steps
Instruction Step
Param | Value |
---|
"type" | String; "instruction" |
"resultType" | null |
"key" | String |
"title" | String |
"text" | String |
"skippable" | Boolean; false |
"groupName" | String; null |
"repeatable" | Boolean; false |
"repeatableText" | String; null |
"destinations" | Array |
Question Step
Param | Value |
---|
"type" | String; "question" |
"resultType" | String; QuestionResultType |
"key" | String |
"title" | String |
"text" | String |
"skippable" | Boolean |
"groupName" | String |
"repeatable" | Boolean; false |
"repeatableText" | String; null |
"destinations" | [ { "condition": string, default for no condition "destination": string, completion for last "operator": string e/gt/lt/gte/lte/range/ne for formula based branching } ] |
“healthDataKey” | String |
"format" | Dictionary; QuestionFormat |
QuestionResultType:
- scale
- continuousScale
- textScale
- valuePicker
- imageChoice
- textChoice
- boolean
- numeric
- timeOfDay
- date
- text
- email
- timeInterval
- height
- location
QuestionFormat:
- Scale
- "maxValue" - Int; Max:10000
- "minValue" - Int; Min:-10000
- "default" - Int
- "step" - Int; Min:1, Max:13
- "vertical" - Bool
- "maxDesc" - String
- "minDesc" - String
- "maxImage" - Image
- "minImage" - Image
- ContinuousScale
- "maxValue" - Number
- "minValue" - Number
- "default" - Number
- "maxFractionDigits" - Integer
- "vertical" - Bool
- "maxDesc" - String
- "minDesc" - String
- "maxImage" - Image
- "minImage" - Image
- TextScale
- "textChoices" -
[
{
"text": string,
"value": string,
"detail": string, nil
"exclusive": bool true
}
]; Min:2, Max:8
- "default" - Int
- "vertical" - Bool
- ValuePicker
- "textChoices" -
[
{
"text": string,
"value": string,
"detail": string, nil
"exclusive": bool, true
}
];
- ImageChoice
- "imageChoices" -
[
{
"image": string,
"selectedImage": string,
"text": string,
"value": string
}
]; Image Size 45px-60px
- TextChoice
- "textChoices" -
[
{
"text": string,
"value": string,
"detail": string, nil
"exclusive" : bool,
"other": {
"placeholder": string,
"isMandatory": bool,
"textfieldReq": bool
}
}
];
- "selectionStyle" - String; Single/Multiple
- Numeric
- "style" - String; Integer/Decimal
- "unit" - String
- "minValue" - Number
- "maxValue" - Number
- "placeholder" - String
- Date
- "style" - String; Date/Date-Time;
- "minDate" - Date; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "maxDate" - Date; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "default" - Date
- “dateRange” - String; (untilCurrent/afterCurrent/custom)
- Text
- "maxLength" - Int; =0 -> No max length
- "validationRegex" - String
- "invalidMessage" - String
- "multipleLines" - Bool
- "placeholder" - String
- Email
- TimeInterval
- "default" - Number
- "step" - Integer; In minutes 1-30
- Height
- "measurementSystem" - String; Local/Metric/US
- "placeholder" - String
- Location
- "useCurrentLocation" - Bool
Question Result:
- "resultType" - String; QuestionResultType
- "key" - String
- "startTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "endTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "skipped" - Boolean
- "value" - ResultFormat
ResultFormat:
- Scale
- ContinuousScale
- TextScale
- ValuePicker
- ImageChoice
- TextChoice
- Boolean
- Numeric
- TimeOfDay
- "value" - String; "HH:mm:ss"
- Date
- "value" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- Text
- Email
- TimeInterval
- Height
- Location
- "value" - String; (lat,long)
Form Step
Param | Value |
---|
"type" | String; "form" |
"resultType" | String; "grouped" |
"key" | String |
"title" | String |
"text" | String |
"skippable" | Boolean |
"groupName" | String; null |
"repeatable" | Boolean |
"repeatableText" | String |
"destinations" | Array |
"steps" | Array; [Question] |
Form Result:
- "resultType" - String; "grouped"
- "key" - String
- "startTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "endTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "skipped" - Boolean
- "value" - [[QuestionResult]] Array of number of iterations of Q-results
Active Task Step
Param | Value |
---|
"type" | String; "task" |
"resultType" | String; ActiveTaskType |
"key" | String |
"text" | String |
"options" | [ActiveTaskOptions] |
"format" | Dictionary; ActiveTaskFormat |
ActiveTaskType:
- fetalKickCounter
- spatialSpanMemory
- towerOfHanoi
ActiveTaskOptions:
- excludeInstructions
- excludeConclusion
- excludeAccelerometer
- excludeDeviceMotion
- excludePedometer
- excludeLocation
- excludeHeartRate
- excludeAudio
ActiveTaskFormat:
- FetalKickCounter
- "duration" - Number; in hours
- “kickCount” - Number
- SpatialSpanMemory
- “initialSpan” - Integer
- “minimumSpan” - Integer
- “maximumSpan” - Integer
- “playSpeed” - Integer
- “maximumTests” - Integer
- “maximumConsecutiveFailures” - Integer
- “customTargetImage” - Image
- “customTargetPluralName” - String
- “requireReversal” - Bool
- TowerOfHanoi
- "numberOfDisks" - Integer;
Active Task Result:
- "resultType" - String; ActiveTaskType (“grouped”)
- "key" - String
- "startTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "endTime" - String; "yyyy-MM-dd'T'HH:mm:ss.SSSZ"
- "value" - ActiveTaskResult
ActiveTaskResult:
- FetalKickCounter
[
{
"resultType": string, numeric
"key": string, duration
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": double
} ,
{
"resultType": string, numeric
"key": string, count
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": double
}
]
- SpatialSpanMemory
[
{
"resultType": string, numeric
"key": string, score
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": Integer
} ,
{
"resultType": string, numeric
"key": string, number of games
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": Integer
},
{
"resultType": string, numeric
"key": string, number of failures
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": Integer
}
]
- TowerOfHanoi
[
{
"resultType": string, numeric
"key": string, puzzle was solved
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": bool
} ,
{
"resultType": string, numeric
"key": string, number of moves
"startTime": string, null
"endTime": string, null
"skipped": bool, false
"value": Integer
}
]
Activity
Questionnaire
Param | Value |
---|
"type" | String; "questionnaire" |
"metadata" | Dictionary; { "studyId": string, "activityId": string, "name": string, "version": string, "lastModified": string, "startDate": string, "endDate": string } |
"steps" | [Steps]; Does not contain ActiveTaskStep |
Questionnaire Result:
- "type" - String; "questionnaire"
- "metadata" - Dictionary;
{
"studyId": string,
"activityId": string,
"version": string,
"activityRunId": string
},
- "participantId" - String
- "data" - Dictionary;
{
"startTime": string,
"endTime": string,
"results": [StepResult]
}
Active Task
Param | Value |
---|
"type" | String; "task" |
"metadata" | Dictionary { "studyId": string, "activityId": string, "name": string, "version": string, "lastModified": string, "startDate": string, "endDate": string } |
"steps" | [Steps]; Contains ActiveTaskStep |
Active Task Result:
- "type" - String; "task"
- "metadata" - Dictionary;
{
"studyId" string,
"activityId" string,
"version" string,
"activityRunId" string
},
- "participantId" - String
- "data" - Dictionary;
{
"startTime": string,
"endTime": string,
"results": [StepResult]
}
Related Topics