1. RunSignup
  2. API
  3. Methods
  4. Setup Race Questions

Setup Race Questions

Call this API method to set up race questions. To edit a question, include the question_id field with the question information. Any existing question not in the request will be deleted unless append_questions is set to "T". The order that the questions appear here will be the order they are displayed to users (with the exception that all overall questions are asked before individual questions). The response includes the question ids in the order defined.

Each question has the following fields:

  • question_id - Question id (A new question will be created if omitted or blank)
  • question_text - Question text
  • question_type_code - Question type code:
    • F: Freeform
    • B: Boolean (T/F)
    • S: Select box list of predefined responses.
    • R: Radio buttons of predefined responses.
    • C: Checkboxes of predefined responses (Allows multiple selection).
    • T: Time input.
    • A: Text box.
  • standard_question_type - Standard question type code:
    • ice_name: Emergency Contact Name
    • ice_phone: Emergency Contact Phone
    • sms_race_updates: Sign up for text message updates from the race.
    Note that standard questions may override certain question settings such as response type.
  • question_validation_type - Freeform questions may have a validation type. This can none, uint, int, float, email, phone, url, date, char_limit, or allowed_values.
  • validation_options - Depending on the validation type, you may need to include information in validation_options as shown in the examples.
  • individual - "T" if this question should be asked for each registrant. "F" if it should be asked once per transaction.
  • corporate_team_only - Is the question for corporate team setup only? T/F
  • internal_question - Is the question for that participants should not see during registration? T/F
  • response_uniqueness_constraint - Response uniqueness constraint
    • 0: Not Unique
    • 1: Unique to Race
    • 2: Unique to Event
    • 3: Unique to Group
  • visible_to_corporate_team_captain - Should the question response be visible to corporate team captains? T/F
  • team_captains_only - Should the question be visible to group captains only? T/F
  • required - Is the question required? T/F
  • skip_for_event_ids - List of event ids that the question should NOT be asked for
  • responses - Predefined responses if applicable. If editing responses, send the response_id with each response.
  • parent_question_id - Id of parent question, if applicable. The parent question must be a boolean response or have predefined responses.
    • parent_visible_bool_response - If the parent question is a T/F question, the response for the parent question that indicates that this question should be asked.
    • parent_visible_response_ids - If the parent question has possible responses, the response id(s) for the parent question that indicates that this question should be asked.

Question Application Types

Certain questions are set up for use with specific features. They do not show with normal questions during race registration. If you do not set supports_question_application_types to T when you call this API, we will not delete any question that has an application type that you omit from the API request.

For JSON requests, the request should look like the example below.

{
	"questions": [
		{
			"question_id": 12345,
			"question_text": "What browser are you using?",
			"question_type_code": "S",
			"individual": "F",
			"required": "F",
			"skip_for_event_ids": [123,124],
			"responses": [
				{
					"response_id": 6000,
					"response": "Chrome"
				},
				{
					"response_id": 6001,
					"response": "Internet Explorer"
				},
				{
					"response_id": 6002,
					"response": "Firefox"
				},
				{
					"response_id": 6003,
					"response": "Safari"
				}
			],
			"more_details": "This can include additional information to explain the question to registrants.",
			"more_details_html": "This can include additional information (formatted in HTML) to explain the question to registrants. This option takes precedent over more_details if both are submitted."
		},
		{
			"question_id": null,
			"question_text": "Where did you go to high school?",
			"question_type_code": "F",
			"individual": "T",
			"required": "F",
			"skip_for_event_ids": [],
			"question_validation_type": "none"
		},
		{
			"question_id": null,
			"question_text": "Emergency Contact Phone Number",
			"question_type_code": "F",
			"question_validation_type": "phone",
			"individual": "T",
			"corporate_team_only": "F",
			"internal_question": "F",
			"response_uniqueness_constraint": 0,
			"visible_to_corporate_team_captain": "F",
			"team_captains_only": "F",
			"required": "T",
			"skip_for_event_ids": [],
			"parent_question_id": 12345,
			"parent_visible_response_ids": [6001,6002]
		},
		{
			"question_id": null,
			"question_text": "Estimated Finish Time",
			"question_type_code": "T",
			"validation_options": {
				"min_time": "0:05:00",
				"max_time": "6:00:00"
			},
			"individual": "T",
			"corporate_team_only": "F",
			"internal_question": "F",
			"response_uniqueness_constraint": 0,
			"visible_to_corporate_team_captain": "F",
			"team_captains_only": "F",
			"required": "T",
			"skip_for_event_ids": [],
			"parent_question_id": null
		},
		{
			"question_id": null,
			"question_text": "Name on Bib",
			"question_type_code": "F",
			"question_validation_type": "char_limit",
			"validation_options": {
				"max_chars": 10
			},
			"individual": "T",
			"corporate_team_only": "F",
			"internal_question": "F",
			"response_uniqueness_constraint": 0,
			"visible_to_corporate_team_captain": "F",
			"team_captains_only": "F",
			"required": "T",
			"skip_for_event_ids": [],
			"parent_question_id": null
		},
		{
			"question_id": null,
			"question_text": "Registration Password",
			"question_type_code": "F",
			"question_validation_type": "allowed_values",
			"validation_options": {
				"allowed_values": ["value1", "value2"]
			},
			"individual": "T",
			"corporate_team_only": "F",
			"internal_question": "F",
			"response_uniqueness_constraint": 0,
			"visible_to_corporate_team_captain": "F",
			"team_captains_only": "F",
			"required": "T",
			"skip_for_event_ids": [],
			"parent_question_id": null
		}
	]
}

For XML requests, the request should look like the example below.

<questions>
	<question>
		<question_id>12345</question_id>
		<question_text>What browser are you using?</question_text>
		<question_type_code>S</question_type_code>
		<individual>F</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>F</required>
		<skip_for_event_ids>
			<event_id>123</event_id>
			<event_id>124</event_id>
		</skip_for_event_ids>
		<responses>
			<response>
				<response_id>6000</response_id>
				<response>Chrome</response>
			</response>
			<response>
				<response_id>6001</response_id>
				<response>Internet Explorer</response>
			</response>
			<response>
				<response_id>6002</response_id>
				<response>Firefox</response>
			</response>
			<response>
				<response_id>6003</response_id>
				<response>Safari</response>
			</response>
		</responses>
		<more_details>This can include additional information to explain the question to registrants.</more_details>
		<more_details_html>This can include additional information (formatted in HTML) to explain the question to registrants. This option takes precedent over more_details if both are submitted.</more_details_html>
	</question>
	<question>
		<question_id></question_id>
		<question_text>Where did you go to high school?</question_text>
		<question_type_code>F</question_type_code>
		<question_validation_type>none</question_validation_type>
		<individual>T</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>F</required>
		<skip_for_event_ids></skip_for_event_ids>
		<parent_question_id>12345</parent_question_id>
		<parent_visible_response_ids>
			<parent_visible_response_id>6001</parent_visible_response_id>
			<parent_visible_response_id>6002</parent_visible_response_id>
		</parent_visible_response_ids>
	</question>
	<question>
		<question_id></question_id>
		<question_text>Emergency Contact Phone Number</question_text>
		<question_type_code>F</question_type_code>
		<question_validation_type>phone</question_validation_type>
		<individual>T</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>T</required>
		<skip_for_event_ids></skip_for_event_ids>
	</question>
	<question>
		<question_id></question_id>
		<question_text>Estimated Finish Time</question_text>
		<question_type_code>T</question_type_code>
		<validation_options>
			<min_time>0:05:00</min_time>
			<max_time>6:00:00</max_time>
		</validation_options>
		<individual>T</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>T</required>
		<skip_for_event_ids></skip_for_event_ids>
	</question>
	<question>
		<question_id></question_id>
		<question_text>Name on Bib</question_text>
		<question_type_code>F</question_type_code>
		<question_validation_type>char_limit</question_validation_type>
		<validation_options>
			<max_chars>10</max_chars>
		</validation_options>
		<individual>T</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>T</required>
		<skip_for_event_ids></skip_for_event_ids>
	</question>
	<question>
		<question_id></question_id>
		<question_text>Registration Password</question_text>
		<question_type_code>F</question_type_code>
		<question_validation_type>allowed_values</question_validation_type>
		<validation_options>
			<allowed_values>
				<allowed_value>value1</allowed_value>
				<allowed_value>value2</allowed_value>
			</allowed_values>
		</validation_options>
		<individual>T</individual>
		<corporate_team_only>F</corporate_team_only>
		<internal_question>F</internal_question>
		<response_uniqueness_constraint>0</response_uniqueness_constraint>
		<visible_to_corporate_team_captain>F</visible_to_corporate_team_captain>
		<team_captains_only>F</team_captains_only>
		<required>T</required>
		<skip_for_event_ids></skip_for_event_ids>
	</question>
</questions>

URL

https://runsignup.com/rest/race/:race_id/questions

HTTP Method

POST

Standard Parameters

Parameter HTTP Method Default Description Datatype
api_key GET API Key string
api_secret GET API Secret string
tmp_key GET Temporary API Key from login API call. This should NOT be used in combination with API Key. string
tmp_secret GET Temporary API Secret from login API call. This should NOT be used in combination with API Secret. string
rsu_api_key GET API v2 key. If used, you must send the API secret in an HTTP header named X-RSU-API-SECRET. string
sp_api_key GET Super partner API key. If used, you must send the API secret in an HTTP header named X-RSU-API-SECRET. string
X-RSU-API-SECRET HTTP Header API v2 or super partner secret. string
format GET xml Format of response. The default if not sent is `xml`, but `json` is preferred. format

Parameters

Parameter HTTP Method Default Description Datatype
race_id
Required
POST ID of race. uint
append_questions POST F Should the questions be appended to the existing questions? bool
supports_question_application_types GET F Does your integration support question application types? bool
request_format POST xml Format of request. The default if not sent is `xml`, but `json` is preferred. format
request
Required
POST Request in proper format. string

If you continue to use this site, you consent to use all cookies. We use cookies to offer you a better browsing experience. Read how we use cookies and how you can control them by visiting our Privacy Policy.

If you continue to use this site, you consent to use all cookies.