Submit form
The sumbit form provides a way for the users to register for an event or an offer or something else. The form can gather different profile information before submitting.
Method: get
Authorization is required.
Request
HTTP request
GET https://<YOUR_DOMAIN>/api/v1/en_US/submit-form/{submitFormId}
Parameters
property | value | description |
---|---|---|
submitFormId | guid | The form's ID |
Request body
Do not supply a request body with this method.
Response
If successful, this method returns a response JSON with the following structure:
{ "success": true, "message": "Magna laborum commodo ut laborum mollit laborum aliqua laboris magna exercitation velit eu consequat.", "timestamp": "2014-03-03T23:20:23Z", "errors": [], "object": { "id": "447fb038-1475-43ac-bd49-11809638f9b1", "type": "submitForm", "createdOn": "2014-03-03T23:20:23Z", "author": { "id": "c7d9aa24-2682-44c9-a0e3-00fdff21bc90", "alias": "elit occaecat", "extendedAlias": "incididunt ipsum incididunt nulla occaecat", "slug": "Home", "avatarUrl": "http://demo.hivesocialnow.com/bigavatar/bc7fbf51-7930-4550-98b0-6a3ff6111ebe.jpg", "url": "http://demo.hivesocialnow.com/blog/GeorgiRaykov/site/profile/" }, "enabled": true, "allowMultipleSubmissions": true, "addPrimaryAffiliationSection": false, "title": "minim fugiat ullamco ipsum", "slug": "form-url", "metaTags": "<meta name='keywords' content='mykeyword1, mykeyword2'/>", "header": "<div><img alt='' src='http://www.socialbiztrends.com/ClientFiles/7a7aac74-90d7-4e7e-9dde-9bac42ac243d/ELANCE_GamificationIDC_Header_v1%20(2).jpg'><p>form header html</p></div>", "content": "<div>form html area</div>", "topFormText": "<div>html above the form</div>", "footerFormText": "<div>html above the form</div>", "exitScenarioTypeId": 2, "exitScenarioTypeName": "Change user level and url redirect", "exitScenarioTargetGroup": { "id": "e532e792-4101-4ef5-8cd7-68380bbbc703", "name": "home", "slug": "Home", "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png", "url": "http://demo.hivesocialnow.com/Home/" }, "exitScenarioTargetUrl": "http://edu1world.org?jobRole={JobRole}", "exitScenarioUserRole": 2, "exitScenarioUserRoleName": "regular", "profileFields": [ { "id": "11197a91-b4eb-45b2-958a-07dae621304e", "name": "Company", "typeId": 1, "typeName": "TextBox", "position": 1, "sectionId": 1, "sectionName": "Work Focus", "parentId": "028bd127-4677-4deb-8232-6202348fb521", "parentName": "Job title", "parentSelectedValueId": "5157e632-d6a3-4c20-aaa5-a48a2c93ddbd", "parentSelectedValueName": "Board member", "data": { "taggable": true, "defaultValue": "", "description": "quis sit proident ipsum laborum cupidatat enim eu", "type": "SingleLine", "lines": "", "maxLength": 50, "required": false, "requiredMessage": "", "validateRegEx": "", "validateMessage": "" }, "formData": { "visible": true, "tag": "company", "position": 1 } } ] } }
The general response properties are described on the Response format page. Here are the list of the specific properties for this method.
property | value | description |
---|---|---|
id | integer | the id of the record |
createdOn | date | When the form was created in ISO 8601 format and UTC time zone |
author | object | some common properties of the user that created the record: id, alias, extendedAlias, slug, avatarUrl, url (of the profile page) |
enabled | boolean | Whether the form is enabled and publicly available |
allowMultipleSubmissions | boolean | Whether one user / IP can submit the form multiple times |
addPrimaryAffiliationSection | boolean | Should be set to false . |
title | string | The form's title |
slug | string | The form's unique part of the URL string |
metaTags | string | html snippet that will be inserted in the page's HEAD, suitable for meta information |
header | string | copy of the form's header |
content | string | copy of the form's content |
topFormText | string | text that will appear above the Submit form's input fields |
footerFormText | string | text that will appear below the Submit form's input fields |
exitScenarioTypeId | integer | The Id of the selected exit scenario that will apply once the form is submitted by the user. The alternatives are:
|
exitScenarioTypeName | string | text label of the exit scenario |
exitScenarioTargetGroup | object | target group of exit scenario 2 is selected |
exitScenarioTargetUrl | string | the redirect url for the exit scenario |
exitScenarioUserRole | integer | The id of the role, which should be assigned to the user if exit scenario 2 is selected |
exitScenarioUserRoleName | string | The label of the role, which should be assigned to the user if exit scenario 2 is selected |
profileFields | list (objects) | The fields that need to be filled by the user (besides the mandatory ones). Field objects are according to the Dynamic profile field object schema |
Method: list
Authorization is required.
Request
HTTP request
GET https://<YOUR_DOMAIN>/api/v1/en_US/submit-form/list?offset={offset}&pageSize={pageSize}&filter={filter}
Parameters
property | value | description |
---|---|---|
groupId | guid | The elements group's ID |
offset | integer | Needed for the infinite scroll functionality. It is the ID of the last presented item to the user. After the request list is generated the system will skip all records from the beginning up to the record with the provided ID (including it). The next batch of records will be returned in the response. |
pageSize | integer | How many records to be returned by the system. Usually 15 |
filter | string | Query string to be looked for when filtering the records |
Request body
Do not supply a request body with this method.
Response
If successful, this method returns a response JSON with the following structure:
{ "success": true, "message": "Dolor et voluptate occaecat qui et.", "timestamp": "2014-03-03T23:20:23Z", "errors": [], "object": { "offset": "57296782-d851-4946-983a-263b6df83778", "submitForms": [ { "id": "57296782-d851-4946-983a-263b6df83778", "type": "submitForm", "createdOn": "2014-03-03T23:20:23Z", "author": { "id": "8cfb00b3-e4ab-472a-97b2-20c0a570b001", "alias": "officia veniam", "extendedAlias": "tempor amet aute in mollit", "slug": "Home", "avatarUrl": "http://demo.hivesocialnow.com/bigavatar/bc7fbf51-7930-4550-98b0-6a3ff6111ebe.jpg", "url": "http://demo.hivesocialnow.com/blog/GeorgiRaykov/site/profile/" }, "enabled": false, "allowMultipleSubmissions": false, "addPrimaryAffiliationSection": false, "title": "Lorem duis adipisicing culpa", "slug": "form-url", "metaTags": "<meta name='keywords' content='mykeyword1, mykeyword2'/>", "header": "header text", "content": "<div>form html area</div>", "topFormText": "<div>html above the form</div>", "footerFormText": "<div>html above the form</div>", "exitScenarioTypeId": 2, "exitScenarioTypeName": "Change user level and url redirect", "exitScenarioTargetGroup": { "id": "e532e792-4101-4ef5-8cd7-68380bbbc703", "name": "home", "slug": "Home", "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png", "url": "http://demo.hivesocialnow.com/Home/" }, "exitScenarioTargetUrl": "http://edu1world.org?jobRole={JobRole}&email={email}", "exitScenarioUserRole": 1, "exitScenarioUserRoleName": "regular", "profileFields": [ { "id": "d7c1e02c-6a72-405e-b3f9-8d5cea026f68", "name": "enim", "typeId": 1, "typeName": "TextBox", "position": 1, "sectionId": 1, "sectionName": "Work Focus", "parentId": "028bd127-4677-4deb-8232-6202348fb521", "parentName": "Job title", "parentSelectedValueId": "5157e632-d6a3-4c20-aaa5-a48a2c93ddbd", "parentSelectedValueName": "Board member", "data": { "taggable": true, "defaultValue": "", "description": "labore in do ullamco cupidatat voluptate amet nostrud", "type": "SingleLine", "lines": "", "maxLength": 50, "required": false, "requiredMessage": "", "validateRegEx": "", "validateMessage": "" }, "formData": { "visible": false, "tag": "exercitation", "position": 1 } } ] } ] } }
The general response properties are described on the Response format page. Here are the list of the specific properties for this method.
Method: create
Authorization is required.
Request
HTTP request
POST https://<YOUR_DOMAIN>/api/v1/en_US/submit-form
Parameters
Do not supply a request parameters with this method.
Request body
property | value | description |
---|---|---|
title | string | The form's title |
enabled | boolean | Whether the form is enabled and publicly available |
allowMultipleSubmissions | boolean | Whether one user / IP can submit the form multiple times |
addPrimaryAffiliationSection | boolean | Should be set to false . |
slug | string | The form's unique part of the URL string |
metaTags | string | html snippet that will be inserted in the page's HEAD, suitable for meta information |
header | string | copy of the form's header |
content | string | copy of the form's content |
topFormText | string | text that will appear above the Submit form's input fields |
footerFormText | string | text that will appear below the Submit form's input fields |
exitScenarioTypeId | integer | The Id of the selected exit scenario that will apply once the form is submitted by the user. The alternatives are:
|
exitScenarioTargetGroupId | guid | target group's id of exit scenario 2 is selected |
exitScenarioTargetUrl | string | the redirect url for the exit scenario |
exitScenarioUserRole | integer | The id of the role, which should be assigned to the user if exit scenario 2 is selected |
exitScenarioUserRoleName | string | The label of the role, which should be assigned to the user if exit scenario 2 is selected |
profileFields | list (object) | The fields (objects) that need to be filled by the user (besides the mandatory ones). The field post object should include the following properties:
|
Response
If successful, this method returns a response JSON with the following structure:
{ "timestamp": "2014-03-03T23:20:23Z", "success": true, "message":"Section not created due to an error", "errors":[ { "key":"footerFormText", "value":"", "message": "Exit scenario Url error" }], "object": { "id": "447fb038-1475-43ac-bd49-11809638f9b1", "type": "submitForm", "createdOn": "2014-03-03T23:20:23Z", "author": { "id": "c7d9aa24-2682-44c9-a0e3-00fdff21bc90", "alias": "elit occaecat", "extendedAlias": "incididunt ipsum incididunt nulla occaecat", "slug": "Home", "avatarUrl": "http://demo.hivesocialnow.com/bigavatar/bc7fbf51-7930-4550-98b0-6a3ff6111ebe.jpg", "url": "http://demo.hivesocialnow.com/blog/GeorgiRaykov/site/profile/" }, "enabled": true, "allowMultipleSubmissions": true, "addPrimaryAffiliationSection": false, "title": "minim fugiat ullamco ipsum", "slug": "form-url", "metaTags": "<meta name='keywords' content='mykeyword1, mykeyword2'/>", "header": "header text", "content": "<div>form html area</div>", "topFormText": "<div>html above the form</div>", "footerFormText": "<div>html above the form</div>", "exitScenarioTypeId": 2, "exitScenarioTypeName": "Change user level and url redirect", "exitScenarioTargetGroup": { "id": "e532e792-4101-4ef5-8cd7-68380bbbc703", "name": "home", "slug": "Home", "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png", "url": "http://demo.hivesocialnow.com/Home/" }, "exitScenarioTargetUrl": "http://edu1world.org?jobRole={JobRole}&email={email}", "exitScenarioUserRole": 1, "exitScenarioUserRoleName": "regular", "profileFields": [ { "id": "7d67994a-136c-4554-9c2e-f119c2c17ec9", "name": "eiusmod", "typeId": 1, "typeName": "TextBox", "position": 1, "sectionId": 1, "sectionName": "Work Focus", "parentId": "028bd127-4677-4deb-8232-6202348fb521", "parentName": "Job title", "parentSelectedValueId": "5157e632-d6a3-4c20-aaa5-a48a2c93ddbd", "parentSelectedValueName": "Board member", "data": { "taggable": true, "defaultValue": "", "description": "quis sit proident ipsum laborum cupidatat enim eu", "type": "SingleLine", "lines": "", "maxLength": 50, "required": false, "requiredMessage": "", "validateRegEx": "", "validateMessage": "" }, "formData": { "visible": true, "tag": "voluptate", "position": 1 } } ] } }
The general response properties are described on the Response format page. Here are the list of the specific properties for this method.
property | value | description |
---|---|---|
success | Boolean | Whether the requested operation is successful or not |
message | String | Human readable error information |
errors | List (object) | List of validation errors, if any. The "key" property value is matched to one of the record's fields |
object | object | The object that caused the validation errors or that was created. Have in mind that, if the server requires string trimming or data manipulation after the user submission, it is applied in this object. In this way the returned object can differ from the posted one. |
Method: update
Authorization is required.
Request
HTTP request
PUT https://<YOUR_DOMAIN>/api/v1/en_US/submit-form/{submitFormId}
Parameters
property | value | description |
---|---|---|
submitFormId | integer | In id of the updated record |
Request body
property | value | description |
---|---|---|
title | string | The form's title |
enabled | boolean | Whether the form is enabled and publicly available |
allowMultipleSubmissions | boolean | Whether one user / IP can submit the form multiple times |
addPrimaryAffiliationSection | boolean | Should be set to false . |
slug | string | The form's unique part of the URL string |
metaTags | string | html snippet that will be inserted in the page's HEAD, suitable for meta information |
header | string | copy of the form's header |
content | string | copy of the form's content |
topFormText | string | text that will appear above the Submit form's input fields |
footerFormText | string | text that will appear below the Submit form's input fields |
exitScenarioTypeId | integer | The Id of the selected exit scenario that will apply once the form is submitted by the user. The alternatives are:
|
exitScenarioTargetGroupId | guid | target group's id of exit scenario 2 is selected |
exitScenarioTargetUrl | string | the redirect url for the exit scenario |
exitScenarioUserRole | integer | The id of the role, which should be assigned to the user if exit scenario 2 is selected |
exitScenarioUserRoleName | string | The label of the role, which should be assigned to the user if exit scenario 2 is selected |
profileFields | list (object) | The fields (objects) that need to be filled by the user (besides the mandatory ones). The field post object should include the following properties:
|
Response
If successful, this method returns a response JSON with the following structure:
{ "timestamp": "2014-03-03T23:20:23Z", "success": true, "message":"Section not created due to an error", "errors":[ { "key":"footerFormText", "value":"", "message": "Exit scenario Url error" }], "object": { "id": "447fb038-1475-43ac-bd49-11809638f9b1", "type": "submitForm", "createdOn": "2014-03-03T23:20:23Z", "author": { "id": "c7d9aa24-2682-44c9-a0e3-00fdff21bc90", "alias": "elit occaecat", "extendedAlias": "incididunt ipsum incididunt nulla occaecat", "slug": "Home", "avatarUrl": "http://demo.hivesocialnow.com/bigavatar/bc7fbf51-7930-4550-98b0-6a3ff6111ebe.jpg", "url": "http://demo.hivesocialnow.com/blog/GeorgiRaykov/site/profile/" }, "enabled": true, "allowMultipleSubmissions": true, "addPrimaryAffiliationSection": false, "title": "minim fugiat ullamco ipsum", "slug": "form-url", "metaTags": "<meta name='keywords' content='mykeyword1, mykeyword2'/>", "header": "header text", "content": "<div>form html area</div>", "topFormText": "<div>html above the form</div>", "footerFormText": "<div>html above the form</div>", "exitScenarioTypeId": 2, "exitScenarioTypeName": "Change user level and url redirect", "exitScenarioTargetGroup": { "id": "e532e792-4101-4ef5-8cd7-68380bbbc703", "name": "home", "slug": "Home", "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png", "url": "http://demo.hivesocialnow.com/Home/" }, "exitScenarioTargetUrl": "http://edu1world.org?jobRole={JobRole}&email={email}", "exitScenarioUserRole": 1, "exitScenarioUserRoleName": "regular", "profileFields": [ { "id": "7d67994a-136c-4554-9c2e-f119c2c17ec9", "name": "eiusmod", "typeId": 1, "typeName": "TextBox", "position": 1, "sectionId": 1, "sectionName": "Work Focus", "parentId": "028bd127-4677-4deb-8232-6202348fb521", "parentName": "Job title", "parentSelectedValueId": "5157e632-d6a3-4c20-aaa5-a48a2c93ddbd", "parentSelectedValueName": "Board member", "data": { "taggable": true, "defaultValue": "", "description": "quis sit proident ipsum laborum cupidatat enim eu", "type": "SingleLine", "lines": "", "maxLength": 50, "required": false, "requiredMessage": "", "validateRegEx": "", "validateMessage": "" }, "formData": { "visible": true, "tag": "voluptate", "position": 1 } } ] } }
The general response properties are described on the Response format page. Here are the list of the specific properties for this method.
property | value | description |
---|---|---|
success | Boolean | Whether the requested operation is successful or not |
message | String | Human readable error information |
errors | List (object) | List of validation errors, if any. The "key" property value is matched to one of the record's fields |
object | object | The object that caused the validation errors or that was updated. Have in mind that, if the server requires string trimming or data manipulation after the user submission, it is applied in this object. In this way the returned object can differe from the posted one. |
Method: delete
Authorization is required.
Request
HTTP request
DELETE https://<YOUR_DOMAIN>/api/v1/en_US/submit-form/{submitFormId}
Parameters
property | value | description |
---|---|---|
submitFormId | integer | In id of the deleted record |
Request body
Do not supply a request body with this method.
Response
If successful, this method returns a response JSON with the following structure:
{ "timestamp": "2014-03-03T23:20:23Z", "success": true, "message":"Section not created due to an error", "errors":[], "object": { "id": "447fb038-1475-43ac-bd49-11809638f9b1", "type": "submitForm", "createdOn": "2014-03-03T23:20:23Z", "author": { "id": "c7d9aa24-2682-44c9-a0e3-00fdff21bc90", "alias": "elit occaecat", "extendedAlias": "incididunt ipsum incididunt nulla occaecat", "slug": "Home", "avatarUrl": "http://demo.hivesocialnow.com/bigavatar/bc7fbf51-7930-4550-98b0-6a3ff6111ebe.jpg", "url": "http://demo.hivesocialnow.com/blog/GeorgiRaykov/site/profile/" }, "enabled": true, "allowMultipleSubmissions": true, "addPrimaryAffiliationSection": false, "title": "minim fugiat ullamco ipsum", "slug": "form-url", "metaTags": "<meta name='keywords' content='mykeyword1, mykeyword2'/>", "header": "header text", "content": "<div>form html area</div>", "topFormText": "<div>html above the form</div>", "footerFormText": "<div>html above the form</div>", "exitScenarioTypeId": 2, "exitScenarioTypeName": "Change user level and url redirect", "exitScenarioTargetGroup": { "id": "e532e792-4101-4ef5-8cd7-68380bbbc703", "name": "home", "slug": "Home", "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png", "url": "http://demo.hivesocialnow.com/Home/" }, "exitScenarioTargetUrl": "http://edu1world.org?jobRole={JobRole}&email={email}", "exitScenarioUserRole": 1, "exitScenarioUserRoleName": "regular", "profileFields": [ { "id": "7d67994a-136c-4554-9c2e-f119c2c17ec9", "name": "eiusmod", "typeId": 1, "typeName": "TextBox", "position": 1, "sectionId": 1, "sectionName": "Work Focus", "parentId": "028bd127-4677-4deb-8232-6202348fb521", "parentName": "Job title", "parentSelectedValueId": "5157e632-d6a3-4c20-aaa5-a48a2c93ddbd", "parentSelectedValueName": "Board member", "data": { "taggable": true, "defaultValue": "", "description": "quis sit proident ipsum laborum cupidatat enim eu", "type": "SingleLine", "lines": "", "maxLength": 50, "required": false, "requiredMessage": "", "validateRegEx": "", "validateMessage": "" }, "formData": { "visible": true, "tag": "voluptate", "position": 1 } } ] } }
The general response properties are described on the Response format page. Here are the list of the specific properties for this method.
property | value | description |
---|---|---|
success | Boolean | Whether the requested operation is successful or not |
message | String | Human readable error information |
errors | List (object) | This list very rarely contains records during delete method processing |
object | object | The object that was deleted |