{"_id":"577be68c5b4f7b0e009f526b","updates":[],"createdAt":"2016-07-05T16:55:40.653Z","excerpt":"Every survey is completed by a user. These registrants may be solo users or part of a family or group of users.  In all cases, the registrant's information can be accessed to be used for contact information or to just create a visual representation of their household/team/group.","parentDoc":null,"sync_unique":"","user":"56548c568975c70d002ea4b4","version":"57334d665bf1bb0e00e40566","isReference":true,"link_url":"","type":"basic","slug":"registrants","__v":2,"hidden":false,"link_external":false,"project":"57334d665bf1bb0e00e40565","order":0,"title":"Registrants","api":{"settings":"","url":"","auth":"required","params":[],"results":{"codes":[{"name":"","status":200,"language":"json","code":"{}"},{"status":400,"language":"json","code":"{}","name":""}]}},"body":"","category":"57334d665bf1bb0e00e40582","githubsync":"","childrenPages":[]}

Registrants

Every survey is completed by a user. These registrants may be solo users or part of a family or group of users. In all cases, the registrant's information can be accessed to be used for contact information or to just create a visual representation of their household/team/group.

{"_id":"577be6b15b4f7b0e009f526e","githubsync":"","isReference":true,"link_url":"","parentDoc":null,"version":"57334d665bf1bb0e00e40566","body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"1-0\": \"first_name\",\n    \"2-0\": \"last_name\",\n    \"3-0\": \"persona_type\",\n    \"4-0\": \"profile_image_url\",\n    \"5-0\": \"date_of_birth\",\n    \"6-0\": \"age\",\n    \"7-0\": \"phone_numbers\",\n    \"8-0\": \"addresses\",\n    \"9-0\": \"email_addresses\",\n    \"0-1\": \"Integer\",\n    \"1-1\": \"String\",\n    \"2-1\": \"String\",\n    \"3-1\": \"String\",\n    \"7-1\": \"Array of Objects\",\n    \"8-1\": \"Array of Objects\",\n    \"9-1\": \"Array of Objects\",\n    \"6-1\": \"Integer\",\n    \"5-1\": \"String\",\n    \"4-1\": \"String\",\n    \"0-2\": \"Id of the persona\",\n    \"1-2\": \"First name of the persona\",\n    \"2-2\": \"Last name of the persona\",\n    \"3-2\": \"Type of persona (self, team, group, orphan, other)\",\n    \"4-2\": \"URL pointing to location of profile image\",\n    \"5-2\": \"Date of birth (DD/MM/YYYY)\",\n    \"6-2\": \"Age of persona\",\n    \"7-2\": \"Array of Persona phone numbers\",\n    \"8-2\": \"Array of Persona addresses\",\n    \"9-2\": \"Array of email addresses\"\n  },\n  \"cols\": 3,\n  \"rows\": 10\n}\n[/block]","excerpt":"","__v":4,"hidden":false,"slug":"user-personas","user":"56548c568975c70d002ea4b4","api":{"auth":"required","examples":{"codes":[{"name":"cURL","language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN  \" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/user_personas\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/user_personas\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/user_personas\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();","language":"java"}]},"method":"get","params":[],"results":{"codes":[{"status":200,"language":"json","code":"[\n    {\n        \"id\": 19433608,\n        \"first_name\": \"API\",\n        \"last_name\": \"User\",\n        \"persona_type\": \"self\",\n        \"profile_image_url\": \"/app_images/avatar_boy.svg\",\n        \"date_of_birth\": \"01/01/1981\",\n        \"age\": 35,\n        \"phone_numbers\": [],\n        \"addresses\": [],\n        \"email_addresses\": [\n            {\n                \"address\": \"apisupport@sportngin.com\",\n                \"label\": null,\n                \"enabled\": false,\n                \"alerts\": false\n            }\n        ]\n    }\n]","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","url":"/user_personas"},"category":"57334d665bf1bb0e00e40582","link_external":false,"sync_unique":"","title":"User Personas","type":"get","updates":[],"createdAt":"2016-07-05T16:56:17.509Z","order":1,"project":"57334d665bf1bb0e00e40565","childrenPages":[]}

getUser Personas


Attributes

Name
Type
Description

id

Integer

Id of the persona

first_name

String

First name of the persona

last_name

String

Last name of the persona

persona_type

String

Type of persona (self, team, group, orphan, other)

profile_image_url

String

URL pointing to location of profile image

date_of_birth

String

Date of birth (DD/MM/YYYY)

age

Integer

Age of persona

phone_numbers

Array of Objects

Array of Persona phone numbers

addresses

Array of Objects

Array of Persona addresses

email_addresses

Array of Objects

Array of email addresses

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN  " -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/user_personas"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/user_personas")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/user_personas")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

[
    {
        "id": 19433608,
        "first_name": "API",
        "last_name": "User",
        "persona_type": "self",
        "profile_image_url": "/app_images/avatar_boy.svg",
        "date_of_birth": "01/01/1981",
        "age": 35,
        "phone_numbers": [],
        "addresses": [],
        "email_addresses": [
            {
                "address": "apisupport@sportngin.com",
                "label": null,
                "enabled": false,
                "alerts": false
            }
        ]
    }
]
{}


{"_id":"57334d665bf1bb0e00e40684","isReference":true,"project":"57334d665bf1bb0e00e40565","slug":"surveys","sync_unique":"","body":"","api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","url":"","auth":"required","params":[]},"category":"57334d665bf1bb0e00e40582","createdAt":"2016-04-05T20:55:17.728Z","link_url":"","version":"57334d665bf1bb0e00e40566","__v":1,"hidden":false,"link_external":false,"parentDoc":null,"githubsync":"","excerpt":"Surveys are the foundation of Registration - every Registration is a Survey.  Registration is comprised of four separate components:\n\n1. A representation of the activity taken by an individual to fill-out the form/survey/registration.  Several users fill out the form, thereby generating a set of answers that need to be stored.  The list of users' activity filling out the form is accessible via the API using the [Survey Results Index](https://sportnginreg.readme.io/docs/survey-results-index) endpoint, and the values themselves are accessible using the [Survey Results Answers Index](https://sportnginreg.readme.io/docs/survey-results-answers) endpoint.\n2. A common typing system provides a set of re-usable parts, which allows form-editors to build surveys/registrations quickly.  These parts are accessible via the API using the [Question Elements](https://sportnginreg.readme.io/docs/question-elements-index) endpoint.\n3. A reporting mechanism allowing for a denormalized export of some or all of the data captured over the life of the form/survey/registration.  The survey report is accessible via the API using the [Surveys Report](https://sportnginreg.readme.io/docs/surveys-report) endpoint.\n\n###Associations\nSurveys belongs to [Sites](https://sportnginsite.readme.io/docs/sites-show).","order":2,"title":"Surveys","type":"basic","updates":[],"user":"56548c568975c70d002ea4b4","childrenPages":[]}

Surveys

Surveys are the foundation of Registration - every Registration is a Survey. Registration is comprised of four separate components: 1. A representation of the activity taken by an individual to fill-out the form/survey/registration. Several users fill out the form, thereby generating a set of answers that need to be stored. The list of users' activity filling out the form is accessible via the API using the [Survey Results Index](https://sportnginreg.readme.io/docs/survey-results-index) endpoint, and the values themselves are accessible using the [Survey Results Answers Index](https://sportnginreg.readme.io/docs/survey-results-answers) endpoint. 2. A common typing system provides a set of re-usable parts, which allows form-editors to build surveys/registrations quickly. These parts are accessible via the API using the [Question Elements](https://sportnginreg.readme.io/docs/question-elements-index) endpoint. 3. A reporting mechanism allowing for a denormalized export of some or all of the data captured over the life of the form/survey/registration. The survey report is accessible via the API using the [Surveys Report](https://sportnginreg.readme.io/docs/surveys-report) endpoint. ###Associations Surveys belongs to [Sites](https://sportnginsite.readme.io/docs/sites-show).

{"_id":"57334d665bf1bb0e00e4065d","api":{"settings":"","url":"/surveys","auth":"required","examples":{"codes":[{"language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/surveys?site_id=11953\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/surveys?site_id=11953\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/surveys?site_id=11953\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();","language":"java"}]},"method":"get","params":[{"type":"int","name":"site_id","in":"query","_id":"56b35f826abc9f2100e503ab","ref":"","required":true,"desc":"Unique identifier for a site on the Sport Ngin platform.","default":""}],"results":{"codes":[{"name":"","code":"[\n    {\n        \"id\": 99164,\n        \"name\": \"Member Questions\",\n        \"site_id\": 11953,\n        \"created_at\": \"2016-02-24T06:32:26-08:00\",\n        \"updated_at\": \"2016-02-24T06:32:26-08:00\",\n        \"status\": 0,\n        \"tst_rate_group_num\": 1,\n        \"code\": \"377379173\",\n        \"survey_type\": \"site_member\",\n        \"registrar_emails\": null,\n        \"allow_multiple_registrations\": false,\n        \"next_event\": false,\n        \"rep_user_id\": null,\n        \"monetary\": false,\n        \"open_date\": null,\n        \"close_date\": null,\n        \"bank_account_id\": null,\n        \"merchant_account_id\": null,\n        \"custom_message\": null,\n        \"login_optional\": true,\n        \"user_id\": null,\n        \"has_barcode\": false,\n        \"barcode_type\": null,\n        \"group_range\": null,\n        \"group_range_question_element_id\": null,\n        \"editable_by_user\": true,\n        \"form_label\": \"\",\n        \"sub_form_label\": \"\",\n        \"custom_css\": null,\n        \"user_can_add_entries\": true,\n        \"skip_welcome_page\": true,\n        \"event_id\": null,\n        \"customer_pays_fee\": null,\n        \"offer_id\": null,\n        \"allow_amex\": false,\n        \"next_form_text_override\": null,\n        \"restrict_invite\": false,\n        \"background_screen_enabled\": false,\n        \"approval_user_id\": null\n    },\n    {\n        \"id\": 99825,\n        \"name\": \"2016 Player Registration\",\n        \"site_id\": 11953,\n        \"created_at\": \"2016-02-26T07:16:42-08:00\",\n        \"updated_at\": \"2016-03-16T08:49:37-07:00\",\n        \"status\": 1,\n        \"tst_rate_group_num\": 66,\n        \"code\": \"673138012\",\n        \"survey_type\": \"registration\",\n        \"registrar_emails\": \"adam.sager@sportngin.com\",\n        \"allow_multiple_registrations\": false,\n        \"next_event\": false,\n        \"rep_user_id\": null,\n        \"monetary\": false,\n        \"open_date\": null,\n        \"close_date\": null,\n        \"bank_account_id\": null,\n        \"merchant_account_id\": null,\n        \"custom_message\": \"\",\n        \"login_optional\": false,\n        \"user_id\": 3156422,\n        \"has_barcode\": false,\n        \"barcode_type\": \"\",\n        \"group_range\": null,\n        \"group_range_question_element_id\": null,\n        \"editable_by_user\": false,\n        \"form_label\": \"Player\",\n        \"sub_form_label\": \"\",\n        \"custom_css\": \"\",\n        \"user_can_add_entries\": false,\n        \"skip_welcome_page\": false,\n        \"event_id\": null,\n        \"customer_pays_fee\": null,\n        \"offer_id\": null,\n        \"allow_amex\": false,\n        \"next_form_text_override\": \"\",\n        \"restrict_invite\": false,\n        \"background_screen_enabled\": false,\n        \"approval_user_id\": 3156422\n    },\n    {\n        \"id\": 102760,\n        \"name\": \"Test Reg\",\n        \"site_id\": 11953,\n        \"created_at\": \"2016-03-11T12:53:48-08:00\",\n        \"updated_at\": \"2016-03-11T12:54:55-08:00\",\n        \"status\": 1,\n        \"tst_rate_group_num\": 66,\n        \"code\": \"710295654\",\n        \"survey_type\": \"registration\",\n        \"registrar_emails\": \"\",\n        \"allow_multiple_registrations\": false,\n        \"next_event\": false,\n        \"rep_user_id\": null,\n        \"monetary\": false,\n        \"open_date\": null,\n        \"close_date\": null,\n        \"bank_account_id\": null,\n        \"merchant_account_id\": null,\n        \"custom_message\": \"\",\n        \"login_optional\": false,\n        \"user_id\": 3156422,\n        \"has_barcode\": false,\n        \"barcode_type\": \"\",\n        \"group_range\": null,\n        \"group_range_question_element_id\": null,\n        \"editable_by_user\": false,\n        \"form_label\": \"\",\n        \"sub_form_label\": \"\",\n        \"custom_css\": \"\",\n        \"user_can_add_entries\": false,\n        \"skip_welcome_page\": false,\n        \"event_id\": null,\n        \"customer_pays_fee\": null,\n        \"offer_id\": null,\n        \"allow_amex\": false,\n        \"next_form_text_override\": \"\",\n        \"restrict_invite\": false,\n        \"background_screen_enabled\": false,\n        \"approval_user_id\": 3156422\n    },\n    {\n        \"id\": 104553,\n        \"name\": \"2016 Hockey Registration\",\n        \"site_id\": 11953,\n        \"created_at\": \"2016-03-23T09:40:07-07:00\",\n        \"updated_at\": \"2016-03-23T09:52:57-07:00\",\n        \"status\": 1,\n        \"tst_rate_group_num\": 66,\n        \"code\": \"895470882\",\n        \"survey_type\": \"registration\",\n        \"registrar_emails\": \"\",\n        \"allow_multiple_registrations\": false,\n        \"next_event\": false,\n        \"rep_user_id\": null,\n        \"monetary\": false,\n        \"open_date\": null,\n        \"close_date\": null,\n        \"bank_account_id\": null,\n        \"merchant_account_id\": null,\n        \"custom_message\": \"\",\n        \"login_optional\": false,\n        \"user_id\": 3156422,\n        \"has_barcode\": false,\n        \"barcode_type\": \"\",\n        \"group_range\": null,\n        \"group_range_question_element_id\": null,\n        \"editable_by_user\": false,\n        \"form_label\": \"Player\",\n        \"sub_form_label\": \"\",\n        \"custom_css\": \"\",\n        \"user_can_add_entries\": false,\n        \"skip_welcome_page\": false,\n        \"event_id\": null,\n        \"customer_pays_fee\": null,\n        \"offer_id\": null,\n        \"allow_amex\": false,\n        \"next_form_text_override\": \"\",\n        \"restrict_invite\": false,\n        \"background_screen_enabled\": false,\n        \"approval_user_id\": 3156422\n    }\n]","language":"json","status":200}]}},"link_external":false,"editedParams":true,"sync_unique":"","category":"57334d665bf1bb0e00e40582","githubsync":"","hidden":false,"isReference":true,"project":"57334d665bf1bb0e00e40565","__v":0,"body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Id of survey\",\n    \"1-0\": \"name\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Name of survey\",\n    \"2-0\": \"site_id\",\n    \"2-1\": \"Integer\",\n    \"2-2\": \"Id of site that the survey belongs to\",\n    \"3-0\": \"created_at\",\n    \"3-1\": \"DateTime\",\n    \"3-2\": \"Timestamp when created\",\n    \"4-2\": \"Timestamp of last update\",\n    \"4-1\": \"DateTime\",\n    \"4-0\": \"updated_at\",\n    \"5-0\": \"status\",\n    \"5-1\": \"Integer\",\n    \"5-2\": \"0 = Disabled \\n1 = Enabled \\n2 = Archived\\n3 = Reviewable \\n4 = Under Construction\",\n    \"6-0\": \"tst_rate_group_num\",\n    \"6-1\": \"Integer\",\n    \"6-2\": \"Code that references the fee setup for the survey\",\n    \"7-0\": \"code\",\n    \"7-2\": \"Internal reference code\",\n    \"7-1\": \"String\",\n    \"8-0\": \"survey_type\",\n    \"8-1\": \"String\",\n    \"9-0\": \"registrar_emails\",\n    \"9-1\": \"String\",\n    \"10-0\": \"allow_multiple_registrations\",\n    \"10-1\": \"Boolean\",\n    \"11-0\": \"next_event\",\n    \"11-1\": \"Boolean\",\n    \"12-0\": \"rep_user_id\",\n    \"12-1\": \"Integer\",\n    \"13-0\": \"monetary\",\n    \"13-1\": \"Boolean\",\n    \"14-0\": \"open_date\",\n    \"14-1\": \"DateTime\",\n    \"15-0\": \"close_date\",\n    \"15-1\": \"DateTime\",\n    \"16-0\": \"bank_account_id\",\n    \"16-1\": \"Integer\",\n    \"17-0\": \"merchant_account_id\",\n    \"17-1\": \"Integer\",\n    \"18-0\": \"custom_message\",\n    \"18-1\": \"String\",\n    \"19-0\": \"login_optional\",\n    \"19-1\": \"Boolean\",\n    \"20-0\": \"user_id\",\n    \"20-1\": \"Integer\",\n    \"21-0\": \"has_barcode\",\n    \"21-1\": \"Boolean\",\n    \"22-0\": \"barcode_type\",\n    \"22-1\": \"String\",\n    \"23-0\": \"group_range\",\n    \"24-0\": \"group_range_question_element_id\",\n    \"24-1\": \"Integer\",\n    \"25-0\": \"editable_by_user\",\n    \"25-1\": \"Boolean\",\n    \"26-0\": \"form_label\",\n    \"26-1\": \"String\",\n    \"27-0\": \"sub_form_label\",\n    \"27-1\": \"String\",\n    \"28-0\": \"custom_css\",\n    \"29-0\": \"user_can_add_entries\",\n    \"29-1\": \"Boolean\",\n    \"30-0\": \"skip_welcome_page\",\n    \"30-1\": \"Boolean\",\n    \"31-0\": \"event_id\",\n    \"31-1\": \"Integer\",\n    \"31-2\": \"Id of event that is associated with the survey\",\n    \"32-0\": \"customer_pays_fee\",\n    \"32-1\": \"Boolean\",\n    \"33-0\": \"offer_id\",\n    \"33-1\": \"Integer\",\n    \"34-0\": \"allow_amex\",\n    \"34-1\": \"Boolean\",\n    \"35-0\": \"next_form_text_override\",\n    \"35-1\": \"String\",\n    \"36-0\": \"restrict_invite\",\n    \"36-1\": \"Boolean\",\n    \"37-0\": \"background_screen_enabled\",\n    \"37-1\": \"Boolean\",\n    \"38-0\": \"approval_user_id\",\n    \"38-1\": \"Integer\",\n    \"8-2\": \"registration, group, site_member\",\n    \"9-2\": \"Email addresses receiving notification of each survey completion\",\n    \"10-2\": \"When true, the survey can be filled out more than once by a given profile\",\n    \"13-2\": \"When true, the survey is collecting money\",\n    \"14-2\": \"Future date registration will be open to be completed\",\n    \"15-2\": \"Future date registration will no longer be available\",\n    \"16-2\": \"Unique ID representing a bank account used for transferring profits\",\n    \"17-2\": \"Unique ID representing a merchant account used to process transactions\",\n    \"18-2\": \"Message to be displayed on receipt email\",\n    \"19-2\": \"When true, the user is not required to log in to complete the survey\",\n    \"20-2\": \"Unique id representing the user in the Sport Ngin system\",\n    \"21-2\": \"When true, denotes that the survey has a barcode associated with it\",\n    \"22-2\": \"A field that allows the survey creator to select from a set of standard barcode types\",\n    \"25-2\": \"When true, denotes that the survey is editable by the user after submission\",\n    \"26-2\": \"Group/team label for group registrations\",\n    \"29-2\": \"When true, denotes that the user can add their own entries to the survey after it has been completed\",\n    \"30-2\": \"When true, denotes that the survey will skip the welcome page and start on the first question form\",\n    \"32-2\": \"When true, denotes that the customer will pay the transaction and processing fees\",\n    \"34-2\": \"When true, denotes that the user can pay using American Express\",\n    \"35-2\": \"???REMOVE??? Next testing.\",\n    \"36-2\": \"When true, denotes that the survey will not automatically invite unregistered users\",\n    \"37-2\": \"When true, denotes that the survey is a background screen\",\n    \"11-2\": \"When true, denotes that the survey is tied to a Next Testing event\",\n    \"12-2\": \"Unique ID assigned by Sport Ngin\",\n    \"23-2\": \"Minimum/maximum number of individuals that can fill out a group registration\",\n    \"24-2\": \"Id of QuestionElement that is used to determine group_range\",\n    \"28-1\": \"String\",\n    \"28-2\": \"???Custom css to adjust the look of the survey??? NOT NEEDED?\",\n    \"33-2\": \"??REMOVE??? Not used.\",\n    \"38-2\": \"???Sport Ngin user ID of survey admin???NEEDED?\",\n    \"27-2\": \"Individual/player label for group registrations\",\n    \"23-1\": \"Serialized String\"\n  },\n  \"cols\": 3,\n  \"rows\": 39\n}\n[/block]","type":"get","updates":[],"link_url":"","order":3,"parentDoc":null,"slug":"surveys-index","title":"Surveys Index","createdAt":"2016-02-03T17:48:18.750Z","editedParams2":true,"excerpt":"The Index method returns an array of Surveys owned by the Organization represented by the `site_id` parameter.  An error is thrown if any of the parameters are invalid.  The Survey object itself represents the attributes of the Survey itself, its type, the rules by how it functions, and what it allows users to do.\n\n###Parameters","user":"56548c568975c70d002ea4b4","version":"57334d665bf1bb0e00e40566","childrenPages":[]}

getSurveys Index

The Index method returns an array of Surveys owned by the Organization represented by the `site_id` parameter. An error is thrown if any of the parameters are invalid. The Survey object itself represents the attributes of the Survey itself, its type, the rules by how it functions, and what it allows users to do. ###Parameters

Query Params

site_id:
required
integer
Unique identifier for a site on the Sport Ngin platform.

Attributes

Name
Type
Description

id

Integer

Id of survey

name

String

Name of survey

site_id

Integer

Id of site that the survey belongs to

created_at

DateTime

Timestamp when created

updated_at

DateTime

Timestamp of last update

status

Integer

0 = Disabled
1 = Enabled
2 = Archived
3 = Reviewable
4 = Under Construction

tst_rate_group_num

Integer

Code that references the fee setup for the survey

code

String

Internal reference code

survey_type

String

registration, group, site_member

registrar_emails

String

Email addresses receiving notification of each survey completion

allow_multiple_registrations

Boolean

When true, the survey can be filled out more than once by a given profile

next_event

Boolean

When true, denotes that the survey is tied to a Next Testing event

rep_user_id

Integer

Unique ID assigned by Sport Ngin

monetary

Boolean

When true, the survey is collecting money

open_date

DateTime

Future date registration will be open to be completed

close_date

DateTime

Future date registration will no longer be available

bank_account_id

Integer

Unique ID representing a bank account used for transferring profits

merchant_account_id

Integer

Unique ID representing a merchant account used to process transactions

custom_message

String

Message to be displayed on receipt email

login_optional

Boolean

When true, the user is not required to log in to complete the survey

user_id

Integer

Unique id representing the user in the Sport Ngin system

has_barcode

Boolean

When true, denotes that the survey has a barcode associated with it

barcode_type

String

A field that allows the survey creator to select from a set of standard barcode types

group_range

Serialized String

Minimum/maximum number of individuals that can fill out a group registration

group_range_question_element_id

Integer

Id of QuestionElement that is used to determine group_range

editable_by_user

Boolean

When true, denotes that the survey is editable by the user after submission

form_label

String

Group/team label for group registrations

sub_form_label

String

Individual/player label for group registrations

custom_css

String

???Custom css to adjust the look of the survey??? NOT NEEDED?

user_can_add_entries

Boolean

When true, denotes that the user can add their own entries to the survey after it has been completed

skip_welcome_page

Boolean

When true, denotes that the survey will skip the welcome page and start on the first question form

event_id

Integer

Id of event that is associated with the survey

customer_pays_fee

Boolean

When true, denotes that the customer will pay the transaction and processing fees

offer_id

Integer

??REMOVE??? Not used.

allow_amex

Boolean

When true, denotes that the user can pay using American Express

next_form_text_override

String

???REMOVE??? Next testing.

restrict_invite

Boolean

When true, denotes that the survey will not automatically invite unregistered users

background_screen_enabled

Boolean

When true, denotes that the survey is a background screen

approval_user_id

Integer

???Sport Ngin user ID of survey admin???NEEDED?

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/surveys?site_id=11953"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/surveys?site_id=11953")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/surveys?site_id=11953")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

[
    {
        "id": 99164,
        "name": "Member Questions",
        "site_id": 11953,
        "created_at": "2016-02-24T06:32:26-08:00",
        "updated_at": "2016-02-24T06:32:26-08:00",
        "status": 0,
        "tst_rate_group_num": 1,
        "code": "377379173",
        "survey_type": "site_member",
        "registrar_emails": null,
        "allow_multiple_registrations": false,
        "next_event": false,
        "rep_user_id": null,
        "monetary": false,
        "open_date": null,
        "close_date": null,
        "bank_account_id": null,
        "merchant_account_id": null,
        "custom_message": null,
        "login_optional": true,
        "user_id": null,
        "has_barcode": false,
        "barcode_type": null,
        "group_range": null,
        "group_range_question_element_id": null,
        "editable_by_user": true,
        "form_label": "",
        "sub_form_label": "",
        "custom_css": null,
        "user_can_add_entries": true,
        "skip_welcome_page": true,
        "event_id": null,
        "customer_pays_fee": null,
        "offer_id": null,
        "allow_amex": false,
        "next_form_text_override": null,
        "restrict_invite": false,
        "background_screen_enabled": false,
        "approval_user_id": null
    },
    {
        "id": 99825,
        "name": "2016 Player Registration",
        "site_id": 11953,
        "created_at": "2016-02-26T07:16:42-08:00",
        "updated_at": "2016-03-16T08:49:37-07:00",
        "status": 1,
        "tst_rate_group_num": 66,
        "code": "673138012",
        "survey_type": "registration",
        "registrar_emails": "adam.sager@sportngin.com",
        "allow_multiple_registrations": false,
        "next_event": false,
        "rep_user_id": null,
        "monetary": false,
        "open_date": null,
        "close_date": null,
        "bank_account_id": null,
        "merchant_account_id": null,
        "custom_message": "",
        "login_optional": false,
        "user_id": 3156422,
        "has_barcode": false,
        "barcode_type": "",
        "group_range": null,
        "group_range_question_element_id": null,
        "editable_by_user": false,
        "form_label": "Player",
        "sub_form_label": "",
        "custom_css": "",
        "user_can_add_entries": false,
        "skip_welcome_page": false,
        "event_id": null,
        "customer_pays_fee": null,
        "offer_id": null,
        "allow_amex": false,
        "next_form_text_override": "",
        "restrict_invite": false,
        "background_screen_enabled": false,
        "approval_user_id": 3156422
    },
    {
        "id": 102760,
        "name": "Test Reg",
        "site_id": 11953,
        "created_at": "2016-03-11T12:53:48-08:00",
        "updated_at": "2016-03-11T12:54:55-08:00",
        "status": 1,
        "tst_rate_group_num": 66,
        "code": "710295654",
        "survey_type": "registration",
        "registrar_emails": "",
        "allow_multiple_registrations": false,
        "next_event": false,
        "rep_user_id": null,
        "monetary": false,
        "open_date": null,
        "close_date": null,
        "bank_account_id": null,
        "merchant_account_id": null,
        "custom_message": "",
        "login_optional": false,
        "user_id": 3156422,
        "has_barcode": false,
        "barcode_type": "",
        "group_range": null,
        "group_range_question_element_id": null,
        "editable_by_user": false,
        "form_label": "",
        "sub_form_label": "",
        "custom_css": "",
        "user_can_add_entries": false,
        "skip_welcome_page": false,
        "event_id": null,
        "customer_pays_fee": null,
        "offer_id": null,
        "allow_amex": false,
        "next_form_text_override": "",
        "restrict_invite": false,
        "background_screen_enabled": false,
        "approval_user_id": 3156422
    },
    {
        "id": 104553,
        "name": "2016 Hockey Registration",
        "site_id": 11953,
        "created_at": "2016-03-23T09:40:07-07:00",
        "updated_at": "2016-03-23T09:52:57-07:00",
        "status": 1,
        "tst_rate_group_num": 66,
        "code": "895470882",
        "survey_type": "registration",
        "registrar_emails": "",
        "allow_multiple_registrations": false,
        "next_event": false,
        "rep_user_id": null,
        "monetary": false,
        "open_date": null,
        "close_date": null,
        "bank_account_id": null,
        "merchant_account_id": null,
        "custom_message": "",
        "login_optional": false,
        "user_id": 3156422,
        "has_barcode": false,
        "barcode_type": "",
        "group_range": null,
        "group_range_question_element_id": null,
        "editable_by_user": false,
        "form_label": "Player",
        "sub_form_label": "",
        "custom_css": "",
        "user_can_add_entries": false,
        "skip_welcome_page": false,
        "event_id": null,
        "customer_pays_fee": null,
        "offer_id": null,
        "allow_amex": false,
        "next_form_text_override": "",
        "restrict_invite": false,
        "background_screen_enabled": false,
        "approval_user_id": 3156422
    }
]


{"_id":"57334d665bf1bb0e00e405d3","sync_unique":"","title":"Survey Results Index","type":"get","api":{"url":"/survey_results","auth":"required","examples":{"codes":[{"language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/survey_results?survey_id=104553\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/survey_results?survey_id=104553\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/survey_results?survey_id=104553\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();"}]},"method":"get","params":[{"name":"survey_id","in":"query","_id":"56b35f826abc9f2100e503ab","ref":"","required":true,"desc":"Id of the Survey the SurveyResult belongs to","default":"","type":"int"}],"results":{"codes":[{"name":"","code":"[\n    {\n        \"id\": 16953112,\n        \"survey_id\": 104553,\n        \"persona_id\": 18922209,\n        \"created_at\": \"2016-03-23T09:58:37-07:00\",\n        \"updated_at\": \"2016-03-23T10:07:47-07:00\",\n        \"order_id\": null,\n        \"completed\": true,\n        \"user_id\": null,\n        \"status\": \"Active\",\n        \"barcode_image_id\": null,\n        \"roster_player_id\": 11575453,\n        \"placed_at\": \"2016-03-23T09:58:47-07:00\"\n    },\n    {\n        \"id\": 16953223,\n        \"survey_id\": 104553,\n        \"persona_id\": 18922316,\n        \"created_at\": \"2016-03-23T10:03:36-07:00\",\n        \"updated_at\": \"2016-03-23T10:07:48-07:00\",\n        \"order_id\": null,\n        \"completed\": true,\n        \"user_id\": null,\n        \"status\": \"Active\",\n        \"barcode_image_id\": null,\n        \"roster_player_id\": 11575454,\n        \"placed_at\": \"2016-03-23T10:03:38-07:00\"\n    },\n    {\n        \"id\": 16953243,\n        \"survey_id\": 104553,\n        \"persona_id\": 18922324,\n        \"created_at\": \"2016-03-23T10:04:16-07:00\",\n        \"updated_at\": \"2016-03-23T10:07:48-07:00\",\n        \"order_id\": null,\n        \"completed\": true,\n        \"user_id\": null,\n        \"status\": \"Active\",\n        \"barcode_image_id\": null,\n        \"roster_player_id\": 11575455,\n        \"placed_at\": \"2016-03-23T10:04:24-07:00\"\n    },\n    {\n        \"id\": 16953262,\n        \"survey_id\": 104553,\n        \"persona_id\": 18922330,\n        \"created_at\": \"2016-03-23T10:04:55-07:00\",\n        \"updated_at\": \"2016-03-23T10:07:52-07:00\",\n        \"order_id\": null,\n        \"completed\": true,\n        \"user_id\": null,\n        \"status\": \"Active\",\n        \"barcode_image_id\": null,\n        \"roster_player_id\": 11575456,\n        \"placed_at\": \"2016-03-23T10:05:01-07:00\"\n    },\n    {\n        \"id\": 16953280,\n        \"survey_id\": 104553,\n        \"persona_id\": 18922338,\n        \"created_at\": \"2016-03-23T10:05:40-07:00\",\n        \"updated_at\": \"2016-03-23T10:07:54-07:00\",\n        \"order_id\": null,\n        \"completed\": true,\n        \"user_id\": null,\n        \"status\": \"Active\",\n        \"barcode_image_id\": null,\n        \"roster_player_id\": 11575457,\n        \"placed_at\": \"2016-03-23T10:05:42-07:00\"\n    },\n...\n]","language":"json","status":200}]},"settings":""},"category":"57334d665bf1bb0e00e40582","editedParams":true,"isReference":true,"link_external":false,"createdAt":"2016-02-10T20:29:31.954Z","excerpt":"The Index method returns an array of Survey Results for the given `survey_id`.  A survey result represents a specific occurrence of a completed survey.  An error is thrown if any parameters are invalid.\n\n###Parameters","hidden":false,"__v":0,"project":"57334d665bf1bb0e00e40565","slug":"survey-results-index","user":"56548c568975c70d002ea4b4","parentDoc":null,"updates":[],"version":"57334d665bf1bb0e00e40566","body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Unique id of the survey_result\",\n    \"1-0\": \"survey_id\",\n    \"1-1\": \"Integer\",\n    \"1-2\": \"Unique Id of the Survey the SurveyResult belongs to\",\n    \"2-0\": \"persona_id\",\n    \"2-1\": \"Integer\",\n    \"2-2\": \"Unique id representing the specific person or team that completed the survey\",\n    \"3-0\": \"created_at\",\n    \"3-1\": \"Datetime\",\n    \"3-2\": \"Timestamp of creation date\",\n    \"4-0\": \"updated_at\",\n    \"5-0\": \"order_id\",\n    \"6-0\": \"completed\",\n    \"7-0\": \"user_id\",\n    \"8-0\": \"status\",\n    \"9-0\": \"barcode_image_id\",\n    \"10-0\": \"roster_player_id\",\n    \"11-0\": \"placed_at\",\n    \"4-1\": \"Datetime\",\n    \"11-1\": \"Datetime\",\n    \"5-1\": \"Integer\",\n    \"7-1\": \"Integer\",\n    \"10-1\": \"Integer\",\n    \"6-1\": \"Boolean\",\n    \"8-1\": \"String\",\n    \"9-1\": \"String\",\n    \"4-2\": \"Timestamp of last update\",\n    \"5-2\": \"Unique id representing a specific order if the survey was part of a purchase transaction\",\n    \"6-2\": \"Boolean representing status of survey_result\",\n    \"7-2\": \"Unique id representing the user account attached to the survey_result\",\n    \"8-2\": \"Entry status used for sales transactions\",\n    \"9-2\": \"Unique id representing a barcode image file tied to a purchase transaction\",\n    \"10-2\": \"Unique id representing a registered player that has been placed on a team\",\n    \"11-2\": \"Timestamp of order placement\"\n  },\n  \"cols\": 3,\n  \"rows\": 12\n}\n[/block]","editedParams2":true,"githubsync":"","link_url":"","order":4,"childrenPages":[]}

getSurvey Results Index

The Index method returns an array of Survey Results for the given `survey_id`. A survey result represents a specific occurrence of a completed survey. An error is thrown if any parameters are invalid. ###Parameters

Query Params

survey_id:
required
integer
Id of the Survey the SurveyResult belongs to

Attributes

Name
Type
Description

id

Integer

Unique id of the survey_result

survey_id

Integer

Unique Id of the Survey the SurveyResult belongs to

persona_id

Integer

Unique id representing the specific person or team that completed the survey

created_at

Datetime

Timestamp of creation date

updated_at

Datetime

Timestamp of last update

order_id

Integer

Unique id representing a specific order if the survey was part of a purchase transaction

completed

Boolean

Boolean representing status of survey_result

user_id

Integer

Unique id representing the user account attached to the survey_result

status

String

Entry status used for sales transactions

barcode_image_id

String

Unique id representing a barcode image file tied to a purchase transaction

roster_player_id

Integer

Unique id representing a registered player that has been placed on a team

placed_at

Datetime

Timestamp of order placement

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/survey_results?survey_id=104553"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/survey_results?survey_id=104553")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/survey_results?survey_id=104553")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

[
    {
        "id": 16953112,
        "survey_id": 104553,
        "persona_id": 18922209,
        "created_at": "2016-03-23T09:58:37-07:00",
        "updated_at": "2016-03-23T10:07:47-07:00",
        "order_id": null,
        "completed": true,
        "user_id": null,
        "status": "Active",
        "barcode_image_id": null,
        "roster_player_id": 11575453,
        "placed_at": "2016-03-23T09:58:47-07:00"
    },
    {
        "id": 16953223,
        "survey_id": 104553,
        "persona_id": 18922316,
        "created_at": "2016-03-23T10:03:36-07:00",
        "updated_at": "2016-03-23T10:07:48-07:00",
        "order_id": null,
        "completed": true,
        "user_id": null,
        "status": "Active",
        "barcode_image_id": null,
        "roster_player_id": 11575454,
        "placed_at": "2016-03-23T10:03:38-07:00"
    },
    {
        "id": 16953243,
        "survey_id": 104553,
        "persona_id": 18922324,
        "created_at": "2016-03-23T10:04:16-07:00",
        "updated_at": "2016-03-23T10:07:48-07:00",
        "order_id": null,
        "completed": true,
        "user_id": null,
        "status": "Active",
        "barcode_image_id": null,
        "roster_player_id": 11575455,
        "placed_at": "2016-03-23T10:04:24-07:00"
    },
    {
        "id": 16953262,
        "survey_id": 104553,
        "persona_id": 18922330,
        "created_at": "2016-03-23T10:04:55-07:00",
        "updated_at": "2016-03-23T10:07:52-07:00",
        "order_id": null,
        "completed": true,
        "user_id": null,
        "status": "Active",
        "barcode_image_id": null,
        "roster_player_id": 11575456,
        "placed_at": "2016-03-23T10:05:01-07:00"
    },
    {
        "id": 16953280,
        "survey_id": 104553,
        "persona_id": 18922338,
        "created_at": "2016-03-23T10:05:40-07:00",
        "updated_at": "2016-03-23T10:07:54-07:00",
        "order_id": null,
        "completed": true,
        "user_id": null,
        "status": "Active",
        "barcode_image_id": null,
        "roster_player_id": 11575457,
        "placed_at": "2016-03-23T10:05:42-07:00"
    },
...
]


{"_id":"57334d665bf1bb0e00e405e2","body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Unique id of the survey_result\",\n    \"1-0\": \"survey_id\",\n    \"1-1\": \"Integer\",\n    \"1-2\": \"Unique Id of the Survey the SurveyResult belongs to\",\n    \"2-0\": \"persona_id\",\n    \"2-1\": \"Integer\",\n    \"2-2\": \"Unique id representing the specific person or team that completed the survey\",\n    \"3-0\": \"created_at\",\n    \"3-1\": \"Datetime\",\n    \"3-2\": \"Timestamp of creation date\",\n    \"4-0\": \"updated_at\",\n    \"5-0\": \"order_id\",\n    \"6-0\": \"completed\",\n    \"7-0\": \"user_id\",\n    \"8-0\": \"status\",\n    \"9-0\": \"barcode_image_id\",\n    \"10-0\": \"roster_player_id\",\n    \"11-0\": \"placed_at\",\n    \"4-1\": \"Datetime\",\n    \"11-1\": \"Datetime\",\n    \"5-1\": \"Integer\",\n    \"7-1\": \"Integer\",\n    \"10-1\": \"Integer\",\n    \"6-1\": \"Boolean\",\n    \"8-1\": \"String\",\n    \"9-1\": \"String\",\n    \"4-2\": \"Timestamp of last update\",\n    \"5-2\": \"Unique id representing a specific order if the survey was part of a purchase transaction\",\n    \"6-2\": \"Boolean representing status of survey_result\",\n    \"7-2\": \"Unique id representing the user account attached to the survey_result\",\n    \"8-2\": \"Entry status used for sales transactions\",\n    \"9-2\": \"Unique id representing a barcode image file tied to a purchase transaction\",\n    \"10-2\": \"Unique id representing a registered player that has been placed on a team\",\n    \"11-2\": \"Timestamp of order placement\"\n  },\n  \"cols\": 3,\n  \"rows\": 12\n}\n[/block]","createdAt":"2016-04-15T18:12:33.951Z","excerpt":"The Survey Results _Answers_ Index endpoint returns the Answers to the Question Elements for the given `survey_result_id`.  A survey result represents a specific occurrence of a completed survey.  An error is thrown if any parameters are invalid.\n\n###Parameters","project":"57334d665bf1bb0e00e40565","type":"get","editedParams2":true,"githubsync":"","sync_unique":"","__v":0,"category":"57334d665bf1bb0e00e40582","editedParams":true,"isReference":true,"link_url":"","order":5,"title":"Survey Results Answers Index","api":{"examples":{"codes":[{"language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/survey_results/16953112/answers\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/survey_results/16953112/answers\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/survey_results/16953112/answers\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();"}]},"method":"get","params":[{"_id":"56b35f826abc9f2100e503ab","ref":"","required":true,"desc":"Id of the SurveyResult of interest","default":"","type":"int","name":"id","in":"path"}],"results":{"codes":[{"name":"","code":"{\n    \"first_name\": \"Christopher\",\n    \"last_name\": \"Breen\",\n    \"hometown\": \"UXBRIDGE, ON, CAN\",\n    \"birthdate\": \"06/29/1989\"\n}","language":"json","status":200}]},"settings":"","url":"/survey_results/:id/answers","auth":"required"},"hidden":false,"link_external":false,"parentDoc":null,"slug":"survey-results-answers","updates":[],"user":"56548c568975c70d002ea4b4","version":"57334d665bf1bb0e00e40566","childrenPages":[]}

getSurvey Results Answers Index

The Survey Results _Answers_ Index endpoint returns the Answers to the Question Elements for the given `survey_result_id`. A survey result represents a specific occurrence of a completed survey. An error is thrown if any parameters are invalid. ###Parameters

Path Params

id:
required
integer
Id of the SurveyResult of interest

Attributes

Name
Type
Description

id

Integer

Unique id of the survey_result

survey_id

Integer

Unique Id of the Survey the SurveyResult belongs to

persona_id

Integer

Unique id representing the specific person or team that completed the survey

created_at

Datetime

Timestamp of creation date

updated_at

Datetime

Timestamp of last update

order_id

Integer

Unique id representing a specific order if the survey was part of a purchase transaction

completed

Boolean

Boolean representing status of survey_result

user_id

Integer

Unique id representing the user account attached to the survey_result

status

String

Entry status used for sales transactions

barcode_image_id

String

Unique id representing a barcode image file tied to a purchase transaction

roster_player_id

Integer

Unique id representing a registered player that has been placed on a team

placed_at

Datetime

Timestamp of order placement

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/survey_results/16953112/answers"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/survey_results/16953112/answers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/survey_results/16953112/answers")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

{
    "first_name": "Christopher",
    "last_name": "Breen",
    "hometown": "UXBRIDGE, ON, CAN",
    "birthdate": "06/29/1989"
}


{"_id":"57334d665bf1bb0e00e4065c","project":"57334d665bf1bb0e00e40565","slug":"survey-results-answers-update","editedParams":true,"order":6,"hidden":false,"type":"put","updates":[],"user":"56548c568975c70d002ea4b4","__v":0,"createdAt":"2016-04-15T18:17:23.716Z","excerpt":"The Update method accepts a single Survey Result and updates the matching record in Sport Ngin.  A survey result represents a specific occurrence of a completed survey.  An error is thrown if any parameters are invalid.\n\n###Parameters","parentDoc":null,"sync_unique":"","body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Unique id of the survey_result\",\n    \"1-0\": \"survey_id\",\n    \"1-1\": \"Integer\",\n    \"1-2\": \"Unique Id of the Survey the SurveyResult belongs to\",\n    \"2-0\": \"persona_id\",\n    \"2-1\": \"Integer\",\n    \"2-2\": \"Unique id representing the specific person or team that completed the survey\",\n    \"3-0\": \"created_at\",\n    \"3-1\": \"Datetime\",\n    \"3-2\": \"Timestamp of creation date\",\n    \"4-0\": \"updated_at\",\n    \"5-0\": \"order_id\",\n    \"6-0\": \"completed\",\n    \"7-0\": \"user_id\",\n    \"8-0\": \"status\",\n    \"9-0\": \"barcode_image_id\",\n    \"10-0\": \"roster_player_id\",\n    \"11-0\": \"placed_at\",\n    \"4-1\": \"Datetime\",\n    \"11-1\": \"Datetime\",\n    \"5-1\": \"Integer\",\n    \"7-1\": \"Integer\",\n    \"10-1\": \"Integer\",\n    \"6-1\": \"Boolean\",\n    \"8-1\": \"String\",\n    \"9-1\": \"String\",\n    \"4-2\": \"Timestamp of last update\",\n    \"5-2\": \"Unique id representing a specific order if the survey was part of a purchase transaction\",\n    \"6-2\": \"Boolean representing status of survey_result\",\n    \"7-2\": \"Unique id representing the user account attached to the survey_result\",\n    \"8-2\": \"Entry status used for sales transactions\",\n    \"9-2\": \"Unique id representing a barcode image file tied to a purchase transaction\",\n    \"10-2\": \"Unique id representing a registered player that has been placed on a team\",\n    \"11-2\": \"Timestamp of order placement\"\n  },\n  \"cols\": 3,\n  \"rows\": 12\n}\n[/block]","editedParams2":true,"link_url":"","isReference":true,"link_external":false,"title":"Survey Results Answers Update","version":"57334d665bf1bb0e00e40566","api":{"auth":"required","examples":{"codes":[{"language":"curl","code":"curl -X PUT -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" -H \"Content-Type: application/json\" -d '{\n    \"last_name\": \"Smith\"\n}' \"https://api.sportngin.com/survey_results/16953112/answers\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/survey_results/16953112/answers\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Put.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\nrequest[\"content-type\"] = 'application/json'\nrequest.body = \"{\\n    \\\"last_name\\\": \\\"Smith\\\"\\n}\"\n\nresponse = http.request(request)\nputs response.read_body"},{"language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nMediaType mediaType = MediaType.parse(\"application/json\");\nRequestBody body = RequestBody.create(mediaType, \"{\\n    \\\"last_name\\\": \\\"Smith\\\"\\n}\");\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/survey_results/16953112/answers\")\n  .put(body)\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .addHeader(\"content-type\", \"application/json\")\n  .build();\n\nResponse response = client.newCall(request).execute();"}]},"method":"put","params":[{"default":"","type":"int","name":"id","in":"path","_id":"56b35f826abc9f2100e503ab","ref":"","required":true,"desc":"Id of the SurveyResult of interest"}],"results":{"codes":[{"code":"{\n    \"first_name\": \"Christopher\",\n    \"last_name\": \"Smith\",\n    \"hometown\": \"UXBRIDGE, ON, CAN\",\n    \"birthdate\": \"06/29/1989\"\n}","language":"json","status":200,"name":""}]},"settings":"","url":"/survey_results/:id/answers"},"category":"57334d665bf1bb0e00e40582","githubsync":"","childrenPages":[]}

putSurvey Results Answers Update

The Update method accepts a single Survey Result and updates the matching record in Sport Ngin. A survey result represents a specific occurrence of a completed survey. An error is thrown if any parameters are invalid. ###Parameters

Path Params

id:
required
integer
Id of the SurveyResult of interest

Attributes

Name
Type
Description

id

Integer

Unique id of the survey_result

survey_id

Integer

Unique Id of the Survey the SurveyResult belongs to

persona_id

Integer

Unique id representing the specific person or team that completed the survey

created_at

Datetime

Timestamp of creation date

updated_at

Datetime

Timestamp of last update

order_id

Integer

Unique id representing a specific order if the survey was part of a purchase transaction

completed

Boolean

Boolean representing status of survey_result

user_id

Integer

Unique id representing the user account attached to the survey_result

status

String

Entry status used for sales transactions

barcode_image_id

String

Unique id representing a barcode image file tied to a purchase transaction

roster_player_id

Integer

Unique id representing a registered player that has been placed on a team

placed_at

Datetime

Timestamp of order placement

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X PUT -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" -H "Content-Type: application/json" -d '{
    "last_name": "Smith"
}' "https://api.sportngin.com/survey_results/16953112/answers"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/survey_results/16953112/answers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Put.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'
request["content-type"] = 'application/json'
request.body = "{\n    \"last_name\": \"Smith\"\n}"

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n    \"last_name\": \"Smith\"\n}");
Request request = new Request.Builder()
  .url("https://api.sportngin.com/survey_results/16953112/answers")
  .put(body)
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();

Result Format

{
    "first_name": "Christopher",
    "last_name": "Smith",
    "hometown": "UXBRIDGE, ON, CAN",
    "birthdate": "06/29/1989"
}


{"_id":"57334d665bf1bb0e00e4060f","type":"get","parentDoc":null,"project":"57334d665bf1bb0e00e40565","sync_unique":"","title":"Question Elements Index","updates":[],"user":"56548c568975c70d002ea4b4","githubsync":"","isReference":true,"order":0,"excerpt":"The Index method returns the structure of a Survey represented as an array of Question Elements for the given `survey_id`. An error is thrown if any of the parameters are invalid.  Question Elements belong to Surveys.\n\n###Parameters","hidden":false,"link_external":false,"slug":"question-elements-index","version":"57334d665bf1bb0e00e40566","__v":0,"category":"573360983ba4902400171c6e","editedParams":true,"createdAt":"2016-03-08T21:46:14.476Z","editedParams2":true,"link_url":"","api":{"params":[{"ref":"","required":true,"desc":"Id of survey the questions belong to","default":"","type":"int","name":"survey_id","in":"query","_id":"56df4be11a50f60e00cc40ff"}],"results":{"codes":[{"language":"json","status":200,"name":"","code":"[\n    {\n        \"id\": 3526476,\n        \"question_id\": 1,\n        \"report_name\": \"First Name\"\n    },\n    {\n        \"id\": 3526477,\n        \"question_id\": 2,\n        \"report_name\": \"Last Name\"\n    },\n    {\n        \"id\": 3526481,\n        \"question_id\": 550614,\n        \"report_name\": \"Hometown\"\n    },\n    {\n        \"id\": 3526483,\n        \"question_id\": 4,\n        \"report_name\": \"Birthdate\"\n    },\n    {\n        \"id\": 3526672,\n        \"question_id\": 1500247,\n        \"report_name\": \"Position\"\n    }\n]"}]},"settings":"","url":"/question_elements","auth":"required","examples":{"codes":[{"language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\"  \"https://api.sportngin.com/question_elements?survey_id=104553\""},{"language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/question_elements?survey_id=104553\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/question_elements?survey_id=104553\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();"}]},"method":"get"},"body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Question Element id. Unique to every survey\",\n    \"1-0\": \"report_name\",\n    \"1-1\": \"String\",\n    \"1-2\": \"Name of the question element\",\n    \"2-0\": \"question_id\",\n    \"2-1\": \"Integer\",\n    \"2-2\": \"Question id. May be reused over multiple surveys\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]","childrenPages":[]}

getQuestion Elements Index

The Index method returns the structure of a Survey represented as an array of Question Elements for the given `survey_id`. An error is thrown if any of the parameters are invalid. Question Elements belong to Surveys. ###Parameters

Query Params

survey_id:
required
integer
Id of survey the questions belong to

Attributes

Name
Type
Description

id

Integer

Question Element id. Unique to every survey

report_name

String

Name of the question element

question_id

Integer

Question id. May be reused over multiple surveys

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1"  "https://api.sportngin.com/question_elements?survey_id=104553"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/question_elements?survey_id=104553")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/question_elements?survey_id=104553")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

[
    {
        "id": 3526476,
        "question_id": 1,
        "report_name": "First Name"
    },
    {
        "id": 3526477,
        "question_id": 2,
        "report_name": "Last Name"
    },
    {
        "id": 3526481,
        "question_id": 550614,
        "report_name": "Hometown"
    },
    {
        "id": 3526483,
        "question_id": 4,
        "report_name": "Birthdate"
    },
    {
        "id": 3526672,
        "question_id": 1500247,
        "report_name": "Position"
    }
]


{"_id":"57334d665bf1bb0e00e405ea","category":"573360a5b90dba1900b3d961","updates":[],"project":"57334d665bf1bb0e00e40565","sync_unique":"","__v":1,"githubsync":"","link_external":false,"order":0,"hidden":false,"title":"Surveys Report","type":"get","user":"56548c568975c70d002ea4b4","body":"###Attributes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"survey_result_id\",\n    \"0-1\": \"Integer\",\n    \"0-2\": \"Id of the survey result specific to the provided survey\",\n    \"8-0\": \"qu_el_xxxxxxx\",\n    \"8-1\": \"String\",\n    \"8-2\": \"The answer for the listed question element\",\n    \"1-0\": \"order_number\",\n    \"1-1\": \"Integer\",\n    \"2-0\": \"item_payment_status\",\n    \"3-0\": \"registration_date\",\n    \"3-1\": \"DateTime\",\n    \"3-2\": \"Date and time the survey was completed\",\n    \"4-0\": \"account_email\",\n    \"4-1\": \"String\",\n    \"5-0\": \"secondary_email\",\n    \"5-1\": \"String\",\n    \"6-0\": \"entry_status\",\n    \"6-1\": \"Enum\",\n    \"6-2\": \"Status of  a particular entry on a survey (Active or Inactive)\",\n    \"7-0\": \"is_orphan\",\n    \"7-1\": \"Boolean\",\n    \"2-1\": \"String\",\n    \"1-2\": \"Unique ID generated when a survey is monetary registration\",\n    \"2-2\": \"Payment status of the monetary registration\",\n    \"4-2\": \"Email of the account filling out the survey\",\n    \"5-2\": \"Secondary email of the account filling out the survey\",\n    \"7-2\": \"When true, the user that filled out the survey has not yet accepted their invitation to the Sport Ngin platform\"\n  },\n  \"cols\": 3,\n  \"rows\": 9\n}\n[/block]","editedParams":true,"editedParams2":true,"version":"57334d665bf1bb0e00e40566","link_url":"","parentDoc":null,"slug":"surveys-report","api":{"settings":"","url":"/surveys/:id/report","auth":"required","examples":{"codes":[{"language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/surveys/104553/report\""},{"code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/surveys/104553/report\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body","language":"ruby"},{"language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/surveys/104553/report\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();"},{"name":"cURL - Saved Report","language":"curl","code":"curl -X GET -H \"Authorization: Bearer ACCESS_TOKEN\" -H \"Accept: application/json\" -H \"NGIN-API-VERSION: 0.1\" \"https://api.sportngin.com/surveys/104553/report?saved_report_id=724874\""},{"name":"Ruby - Saved Report","language":"ruby","code":"require 'uri'\nrequire 'net/http'\n\nurl = URI(\"https://api.sportngin.com/surveys/104553/report?saved_report_id=724874\")\n\nhttp = Net::HTTP.new(url.host, url.port)\nhttp.use_ssl = true\nhttp.verify_mode = OpenSSL::SSL::VERIFY_NONE\n\nrequest = Net::HTTP::Get.new(url)\nrequest[\"authorization\"] = 'Bearer ACCESS_TOKEN'\nrequest[\"accept\"] = 'application/json'\nrequest[\"ngin-api-version\"] = '0.1'\n\nresponse = http.request(request)\nputs response.read_body"},{"name":"Java - Saved Report","language":"java","code":"OkHttpClient client = new OkHttpClient();\n\nRequest request = new Request.Builder()\n  .url(\"https://api.sportngin.com/surveys/104553/report?saved_report_id=724874\")\n  .get()\n  .addHeader(\"authorization\", \"Bearer ACCESS_TOKEN\")\n  .addHeader(\"accept\", \"application/json\")\n  .addHeader(\"ngin-api-version\", \"0.1\")\n  .build();\n\nResponse response = client.newCall(request).execute();"}]},"method":"get","params":[{"_id":"56b35f826abc9f2100e503ab","ref":"","in":"path","required":true,"desc":"Id of the survey of interest","default":"","type":"int","name":"id"},{"_id":"5ad7756d7097f700030f63bd","ref":"","in":"query","required":false,"desc":"Id of the saved report of interest","default":"","type":"int","name":"saved_report_id"}],"results":{"codes":[{"name":"","code":"[\n    {\n        \"survey_result_id\": 16953112,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 9:58am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Christopher\",\n        \"qu_el_3526477\": \"Breen\",\n        \"qu_el_3526481\": \"UXBRIDGE, ON, CAN\",\n        \"qu_el_3526483\": \"06/29/1989\",\n        \"qu_el_3526672\": \"Defense\",\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n    {\n        \"survey_result_id\": 16953223,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 10:03am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Craig\",\n        \"qu_el_3526477\": \"Cunningham\",\n        \"qu_el_3526481\": \"TRAIL, BC, CAN\",\n        \"qu_el_3526483\": \"09/13/1990\",\n        \"qu_el_3526672\": \"Right Wing\",\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n    {\n        \"survey_result_id\": 16953243,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 10:04am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Justin\",\n        \"qu_el_3526477\": \"Florek\",\n        \"qu_el_3526481\": \"MARQUETTE, MI, USA\",\n        \"qu_el_3526483\": \"05/18/1990\",\n        \"qu_el_3526672\": \"Left Wing\",\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n    {\n        \"survey_result_id\": 16953262,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 10:05am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Alexander\",\n        \"qu_el_3526477\": \"Khokhlachev\",\n        \"qu_el_3526481\": \"MOSCOW, RUS\",\n        \"qu_el_3526483\": \"09/09/1993\",\n        \"qu_el_3526672\": null,\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n    {\n        \"survey_result_id\": 16953280,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 10:05am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Torey\",\n        \"qu_el_3526477\": \"Krug\",\n        \"qu_el_3526481\": \"LIVONIA, MI, USA\",\n        \"qu_el_3526483\": \"04/12/1991\",\n        \"qu_el_3526672\": \"Defense\",\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n    {\n        \"survey_result_id\": 16953303,\n        \"order_number\": null,\n        \"item_payment_status\": \"''\",\n        \"registration_date\": \"03/23/2016, 10:06am PDT\",\n        \"account_email\": \"\",\n        \"secondary_email\": \"\",\n        \"entry_status\": \"Active\",\n        \"is_orphan\": \"Unclaimed\",\n        \"qu_el_3526476\": \"Tuukka\",\n        \"qu_el_3526477\": \"Rask\",\n        \"qu_el_3526481\": \"SAVONLINNA, FIN\",\n        \"qu_el_3526483\": \"03/10/1987\",\n        \"qu_el_3526672\": \"Goalie\",\n        \"rostering_assignment\": \"Eastern Conference Boston Bears 2016\"\n    },\n...\n]","language":"json","status":200}]}},"createdAt":"2016-02-09T22:10:36.355Z","excerpt":"The specialized Report method returns a list of all answers provided by the registrants for the a survey for the given `survey_id` in a de-normalized format.  An error is thrown if any of the parameters are invalid.\n\n###Parameters","isReference":false,"next":{"description":"","pages":[]},"childrenPages":[]}

getSurveys Report

The specialized Report method returns a list of all answers provided by the registrants for the a survey for the given `survey_id` in a de-normalized format. An error is thrown if any of the parameters are invalid. ###Parameters

Path Params

id:
required
integer
Id of the survey of interest

Query Params

saved_report_id:
integer
Id of the saved report of interest

Attributes

Name
Type
Description

survey_result_id

Integer

Id of the survey result specific to the provided survey

order_number

Integer

Unique ID generated when a survey is monetary registration

item_payment_status

String

Payment status of the monetary registration

registration_date

DateTime

Date and time the survey was completed

account_email

String

Email of the account filling out the survey

secondary_email

String

Secondary email of the account filling out the survey

entry_status

Enum

Status of a particular entry on a survey (Active or Inactive)

is_orphan

Boolean

When true, the user that filled out the survey has not yet accepted their invitation to the Sport Ngin platform

qu_el_xxxxxxx

String

The answer for the listed question element

Definition

{{ api_url }}{{ page_api_url }}

Examples

curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/surveys/104553/report"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/surveys/104553/report")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/surveys/104553/report")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();
curl -X GET -H "Authorization: Bearer ACCESS_TOKEN" -H "Accept: application/json" -H "NGIN-API-VERSION: 0.1" "https://api.sportngin.com/surveys/104553/report?saved_report_id=724874"
require 'uri'
require 'net/http'

url = URI("https://api.sportngin.com/surveys/104553/report?saved_report_id=724874")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)
request["authorization"] = 'Bearer ACCESS_TOKEN'
request["accept"] = 'application/json'
request["ngin-api-version"] = '0.1'

response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("https://api.sportngin.com/surveys/104553/report?saved_report_id=724874")
  .get()
  .addHeader("authorization", "Bearer ACCESS_TOKEN")
  .addHeader("accept", "application/json")
  .addHeader("ngin-api-version", "0.1")
  .build();

Response response = client.newCall(request).execute();

Result Format

[
    {
        "survey_result_id": 16953112,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 9:58am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Christopher",
        "qu_el_3526477": "Breen",
        "qu_el_3526481": "UXBRIDGE, ON, CAN",
        "qu_el_3526483": "06/29/1989",
        "qu_el_3526672": "Defense",
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
    {
        "survey_result_id": 16953223,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 10:03am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Craig",
        "qu_el_3526477": "Cunningham",
        "qu_el_3526481": "TRAIL, BC, CAN",
        "qu_el_3526483": "09/13/1990",
        "qu_el_3526672": "Right Wing",
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
    {
        "survey_result_id": 16953243,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 10:04am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Justin",
        "qu_el_3526477": "Florek",
        "qu_el_3526481": "MARQUETTE, MI, USA",
        "qu_el_3526483": "05/18/1990",
        "qu_el_3526672": "Left Wing",
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
    {
        "survey_result_id": 16953262,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 10:05am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Alexander",
        "qu_el_3526477": "Khokhlachev",
        "qu_el_3526481": "MOSCOW, RUS",
        "qu_el_3526483": "09/09/1993",
        "qu_el_3526672": null,
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
    {
        "survey_result_id": 16953280,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 10:05am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Torey",
        "qu_el_3526477": "Krug",
        "qu_el_3526481": "LIVONIA, MI, USA",
        "qu_el_3526483": "04/12/1991",
        "qu_el_3526672": "Defense",
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
    {
        "survey_result_id": 16953303,
        "order_number": null,
        "item_payment_status": "''",
        "registration_date": "03/23/2016, 10:06am PDT",
        "account_email": "",
        "secondary_email": "",
        "entry_status": "Active",
        "is_orphan": "Unclaimed",
        "qu_el_3526476": "Tuukka",
        "qu_el_3526477": "Rask",
        "qu_el_3526481": "SAVONLINNA, FIN",
        "qu_el_3526483": "03/10/1987",
        "qu_el_3526672": "Goalie",
        "rostering_assignment": "Eastern Conference Boston Bears 2016"
    },
...
]