Critical Event Surveys

Note: This page has not yet been converted to the new developer portal format. Please use Swagger to test this API.

Critical Event Surveys

GET /cm/v1/crisisEvent/{eventId}/surveys

Description

Get a paged set of surveys of a critical event for an organization.

Parameters

ParameterPositionTypeOptionalDescription

organizationId

header

Long

n

The ID of the organization.

Authorization

header

String

n

Basic authorization header.

eventId

url path

String

n

The ID of the critical event.

filtered

url parameter

String

y

Like filter-The filter value, in this case, the name of the survey.

tabId

url parameter

String

y

The ID of a survey tab.
"0" will be used as default if this field is absent.

columnName

url parameter

String

y

The name of the column to sort by, allowable values:"lastModifiedDate".

orderDirection

url parameter

String

y

The sort order of the data, allowable values:"ASC, DESC".
"DESC" will be used as default if this field is absent.

pageNumber

url parameter

Integer

y

The page number of the data to return.
1 will be used as default if this field is absent.

pageSize

url parameter

Integer

y

The page size of the data to return.
25 will be used as default if this field is absent.
200 maximum.

existingChart

url parameter

boolean

y

Whether to only query the surveys with charts.
'false' will be used as default if this field is absent.

Response

HTTP Status CodeResponse Body

200Ok

SurveyWrapper object:
{
"pageSize": 25,
"start": 0,
"data": [
{
"id": "6180e6058cef11750c6c4258",
"name": "test rule",
"createdName": "lingxiao jin",
"createdId": 281754149584903,
"createdDate": 1635837445135,
"lastModifiedName": "lingxiao jin",
"lastModifiedId": 281754149584903,
"lastModifiedDate": 1635837445146,
"organizationId": 1328214341320748,
"folderId": "0",
"enableNotification": false,
"scopeId": "612edb902d66c515b7a7d8ec",
"scopeType": "CRISISEVENT",
"tabId": "0",
"formId": "60dbd28aa077b50c3583122a",
"formVersion": 1,
"formName": "test currency",
"surveyStatus": "ACTIVE",
"surveyStrategies": [
"EDIT_SUBMISSION",
"CREATE_SUBMISSION",
"VIEW_ALL"
],
"sharedToContact": [
{
"id": 289725608891844,
"ownerType": "RULE"
}
],
"completedCount": 0,
"totalCount": 11,
"fieldConfs": [],
"chartConfs": []
},
{
"id": "6180e2008cef11750c6c424f",
"name": "recover des",
"createdName": "lingxiao jin",
"createdId": 281754149584903,
"createdDate": 1635836416637,
"lastModifiedName": "lingxiao jin",
"lastModifiedId": 281754149584903,
"lastModifiedDate": 1635836416645,

"organizationId": 1328214341320748,
"folderId": "0",
"enableNotification": false,
"scopeId": "612edb902d66c515b7a7d8ec",
"scopeType": "CRISISEVENT",
"tabId": "0",
"formId": "610909462b8a2734a479f3b3",
"formVersion": 0,
"formName": "test formio pod",
"surveyStatus": "ACTIVE",
"surveyStrategies": [
"EDIT_SUBMISSION",
"CREATE_SUBMISSION",
"VIEW_ALL"
],
"sharedToContact": [
{
"id": 293711338541913,
"ownerType": "CONTACT"
},
{
"id": 884011643741228,
"ownerType": "CONTACT"
}
],
"completedCount": 1,
"totalCount": 5,
"fieldConfs": [],
"chartConfs": []
}
],
"totalCount": 2,
"totalPageCount": 1,
"currentPageNo": 1
}

400

Bad Request

401

Unauthorized

403

Forbidden. No Permission for this Resource

404

Resource Not Found

406

Not Acceptable. Illegal Input.

500

Internal Error

GET /cm/v1/crisisEvent/{eventId}/surveys/{surveyId}/submissions

Description

Get a paged set of submissions of a survey for an organization.

Parameters

ParameterPositionTypeOptionalDescription

organizationId

header

Long

n

The ID of the organization.

Authorization

header

String

n

Basic authorization header.

eventId

url path

String

n

The ID of the critical event.

surveyId

url path

String

n

The ID of the survey.

columnName

url parameter

String

y

The name of the column to sort by, allowable values:"lastModifiedDate".

orderDirection

url parameter

String

y

The sort order of the data, allowable values:"ASC, DESC".
"DESC" will be used as default if this field is absent.

pageNumber

url parameter

Integer

y

The page number of the data to return.
1 will be used as default if this field is absent.

pageSize

url parameter

Integer

y

The page size of the data to return.
25 will be used as default if this field is absent.
200 maximum.

submittedBy

url parameter

String

y

Like filter-The name of the created user.

lastUpdatedBy

url parameter

String

y

Like filter-The name of the last modified user.

Response

HTTP Status CodeResponse Body

200Ok

SubmissionsResponseWrapper object:
{
"pageSize": 10,
"start": 0,
"data": [{
"name": "test demo",
"nameLowerCase": "test demo",
"createdName": "Lingxiao Jin",
"createdId": 293711338541913,
"createdDate": 1635835279261,
"createdType": "CONTACT",
"lastModifiedName": "lingxiao jin",
"lastModifiedId": 281754149584903,
"lastModifiedDate": 1635836623642,
"lastModifiedType": "USER",
"organizationId": 1328214341320748,
"project": "5f43aa928fd85f41438ffee4",
"publicToContact": false,
"sharedToContacts": {
"contactIds": [],
"groupIds": [],
"filterIds": [],
"previewSearchSource": "All"
},
"folderId": "0",
"hasShared": false,
"form": "610909462b8a2734a479f3b3",
"scopeType": "SURVEY",
"scopeId": "6180e2008cef11750c6c424f",
"locked": false,
"formTitle": "test form demo",
"data": {
"textArea": "321"
},
"linkedResourceCount": 0,
"_id": "6180dd8f862e3b0478c614a1"
}, {
"name": "test demo",
"nameLowerCase": "test demo",
"createdName": "lingxiao jin",
"createdId": 281754149584903,
"createdDate": 1635835653518,
"createdType": "USER",
"lastModifiedName": "lingxiao jin",
"lastModifiedId": 281754149584903,
"lastModifiedDate": 1635836623642,
"lastModifiedType": "USER",
"organizationId": 1328214341320748,
"project": "5f43aa928fd85f41438ffee4",

"publicToContact": false,
"sharedToContacts": {
"contactIds": [],
"groupIds": [],
"filterIds": [],
"previewSearchSource": "All"
},
"folderId": "0",
"hasShared": false,
"form": "610909462b8a2734a479f3b3",
"scopeType": "SURVEY",
"scopeId": "6180e2008cef11750c6c424f",
"locked": false,
"formTitle": "test form demo",
"data": {
"textArea": "312"
},
"linkedResourceCount": 0,
"_id": "6180df05862e3bf289c614a3"
}],
"totalCount": 2,
"totalPageCount": 1,
"currentPageNo": 1
}

400

Bad Request

401

Unauthorized

403

Forbidden. No Permission for this Resource

404

Resource Not Found

406

Not Acceptable. Illegal Input.

500

Internal Error