<xsd:schema targetNamespace="http://convio.com/crm/v1.0"
xmlns:crm="http://convio.com/crm/v1.0"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc"
xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
jaxb:version="1.0"
jaxb:extensionBindingPrefixes="xjc"
elementFormDefault="qualified">
<xsd:annotation>
<xsd:documentation xml:lang="en">
Convio Open ReST API Version 1.0 Survey API Types.
Convio All Rights Reserved.
</xsd:documentation>
</xsd:annotation>
<xsd:include schemaLocation="crm.public.common.v1.xsd"/>
<xsd:include schemaLocation="crm.public.content.v1.xsd"/>
<xsd:complexType name="getSurveyResult">
<xsd:sequence>
<xsd:element name="survey" type="crm:surveyRecord" maxOccurs="1" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="listSurveysResult">
<xsd:annotation>
<xsd:documentation>
Provides a list of surveys.
</xsd:documentation>
</xsd:annotation>
<xsd:sequence>
<xsd:element name="pagingMetadata" type="crm:pagingMetadata" />
<xsd:element name="surveys" type="crm:surveyRecord" minOccurs="0" maxOccurs="unbounded" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="submitSurveyResult">
<xsd:sequence>
<xsd:element name="success" type="xsd:boolean" />
<xsd:element name="userCanceled" type="xsd:boolean" />
<xsd:element name="nextUrl" type="xsd:string" nillable="true" minOccurs="0" />
<xsd:element name="thankYouPageContent" type="xsd:string" nillable="true" minOccurs="0" maxOccurs="1" />
<xsd:element name="errors" type="crm:surveyError" minOccurs="0" maxOccurs="unbounded" nillable="true" />
<xsd:element name="userResponses" type="crm:userResponse" minOccurs="0" maxOccurs="unbounded" nillable="true" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="surveyError">
<xsd:sequence>
<xsd:element name="questionInError" type="xsd:integer" />
<xsd:element name="errorCode" type="xsd:integer" />
<xsd:element name="errorField" type="xsd:string" nillable="true" />
<xsd:element name="errorMessage" type="xsd:string" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="surveyRecord">
<xsd:sequence>
<xsd:element name="surveyId" type="xsd:integer" />
<xsd:element name="surveyName" type="xsd:string" />
<xsd:element name="viewSecurityCategory" type="crm:securityCategory" />
<xsd:element name="reportSecurityCategory" type="crm:securityCategory" />
<xsd:element name="surveyIntroduction" type="xsd:string" nillable="true" />
<xsd:element name="resetButtonLabel" type="xsd:string" nillable="true" />
<xsd:element name="skipButtonLabel" type="xsd:string" nillable="true" />
<xsd:element name="submitButtonLabel" type="xsd:string" nillable="true" />
<xsd:element name="isAllowMultipleSubmission" type="xsd:boolean" />
<xsd:element name="isSecureSurvey" type="xsd:boolean" />
<xsd:element name="isNumberQuestions" type="xsd:boolean" />
<xsd:element name="submitSurveyUrl" type="xsd:string" nillable="true" />
<xsd:element name="cancelSurveyUrl" type="xsd:string" nillable="true" />
<xsd:element name="state" type="crm:surveyState" nillable="true" />
<xsd:element name="publishedDate" type="xsd:dateTime" nillable="true" />
<xsd:element name="stopDate" type="xsd:dateTime" nillable="true" />
<xsd:element name="surveyQuestions" type="crm:questionRecord" nillable="true" maxOccurs="unbounded" minOccurs="0" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="questionRecord">
<xsd:all>
<xsd:element name="questionText" type="xsd:string" />
<xsd:element name="questionRequired" type="xsd:boolean" />
<xsd:element name="questionOrderNumber" type="xsd:integer" />
<xsd:element name="questionMinResponses" type="xsd:integer" nillable="true" />
<xsd:element name="questionMaxResponses" type="xsd:integer" nillable="true" />
<xsd:element name="questionId" type="xsd:integer" />
<xsd:element name="categoryId" type="xsd:integer" />
<xsd:element name="surveyInstanceId" type="xsd:integer" />
<!-- TODO ecapps this should probably be an enum -->
<xsd:element name="questionType" type="xsd:string" />
<xsd:element name="questionHint" type="xsd:string" minOccurs="0" />
<xsd:element name="questionTypeData" type="crm:questionTypeData" minOccurs="0"/>
<xsd:element name="prefillValue" type="xsd:string" minOccurs="0" maxOccurs="1" />
<xsd:element name="key" type="xsd:string" nillable="true" minOccurs="0"/>
<xsd:element name="hidden" type="xsd:boolean" nillable="true" minOccurs="0"/>
</xsd:all>
</xsd:complexType>
<xsd:complexType name="questionTypeData">
<xsd:choice>
<xsd:element name="surveyQuestionData" type="crm:availableAnswers" />
<xsd:element name="consRegInfoData" type="crm:consRegInfoData" />
<xsd:element name="captchaData" type="crm:captchaData" />
<xsd:element name="recaptchaData" type="crm:recaptchaData" />
</xsd:choice>
</xsd:complexType>
<xsd:complexType name="availableAnswers">
<xsd:sequence>
<xsd:element name="availableAnswer" type="crm:questionPossibleAnswer" maxOccurs="unbounded" nillable="true" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="questionPossibleAnswer">
<xsd:all>
<xsd:element name="value" type="xsd:string" />
<xsd:element name="label" type="xsd:string" />
<xsd:element name="selected" type="xsd:boolean" minOccurs="0" nillable="true" />
</xsd:all>
</xsd:complexType>
<xsd:complexType name="consRegInfoData">
<xsd:sequence>
<xsd:element name="contactInfoField" type="crm:criField" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="email_auto_opt_in_text" type="xsd:string" nillable="true" />
<xsd:element name="full_name_row_label" type="xsd:string" nillable="true" />
<xsd:element name="city_state_zip_row_label" type="xsd:string" nillable="true" />
<xsd:element name="layout" type="crm:criLayout" minOccurs="0" nillable="true" />
<xsd:element name="loginPrompt" type="crm:criLoginPrompt" minOccurs="0" nillable="true" />
<xsd:element name="passwordComponent" type="crm:criPasswordComponent" minOccurs="0" nillable="true" />
<xsd:element name="rememberMe" type="crm:criRememberMe" minOccurs="0" nillable="true" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="criField">
<xsd:sequence>
<xsd:element name="fieldName" type="xsd:string" />
<xsd:element name="label" type="xsd:string" />
<xsd:element name="fieldStatus" type="crm:fieldStatus" />
<xsd:element name="minLength" type="xsd:integer" minOccurs="0" maxOccurs="1" />
<xsd:element name="maxLength" type="xsd:integer" minOccurs="0" maxOccurs="1" />
<xsd:element name="prefillValue" type="xsd:string" minOccurs="0" maxOccurs="1" />
<xsd:element name="fieldOptionValues" type="crm:questionPossibleAnswer" maxOccurs="unbounded" minOccurs="0" nillable="true" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="criPasswordComponent">
<xsd:sequence>
<xsd:element name="instructions" type="xsd:string" />
<xsd:element name="userName" type="crm:criField" />
<xsd:element name="userNameHint" type="xsd:string" />
<xsd:element name="password" type="crm:criField" />
<xsd:element name="passwordHint" type="xsd:string" />
<xsd:element name="verifyPassword" type="crm:criField" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="criRememberMe">
<xsd:sequence>
<xsd:element name="fieldName" type="xsd:string" />
<xsd:element name="label" type="xsd:string" />
<xsd:element name="checked" type="xsd:boolean" minOccurs="0" nillable="true" />
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="captchaData">
<xsd:all>
<xsd:element name="audioLink" type="xsd:string" />
<xsd:element name="audioLinkLabel" type="xsd:string" />
<xsd:element name="imageSource" type="xsd:string" />
<xsd:element name="changeImageLabel" type="xsd:string" />
<xsd:element name="newWindowLabel" type="xsd:string" />
<xsd:element name="standAlonePlayerLabel" type="xsd:string" />
</xsd:all>
</xsd:complexType>
<xsd:complexType name="recaptchaData">
<xsd:all>
<xsd:element name="publicKey" type="xsd:string" />
</xsd:all>
</xsd:complexType>
<xsd:simpleType name="surveyState">
<xsd:annotation>
<xsd:documentation>
Indicates the state of the survey: Draft, Unpublished, Published, or Expired (published, but beyond the stop date).
</xsd:documentation>
</xsd:annotation>
<xsd:restriction base="xsd:token">
<xsd:enumeration value="DRAFT" />
<xsd:enumeration value="UNPUBLISHED" />
<xsd:enumeration value="PUBLISHED" />
<xsd:enumeration value="EXPIRED" />
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="criLayout">
<xsd:annotation>
<xsd:documentation>
Indicates the selected layout option for a Constituent Registration Information question.
</xsd:documentation>
</xsd:annotation>
<xsd:restriction base="xsd:token">
<xsd:enumeration value="STANDARD" />
<xsd:enumeration value="VERTICAL" />
<xsd:enumeration value="NARROW" />
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="criLoginPrompt">
<xsd:annotation>
<xsd:documentation>
Indicates the selected option for a Constituent Registration Information question to handle prompting registered constituents to login.
</xsd:documentation>
</xsd:annotation>
<xsd:restriction base="xsd:token">
<xsd:enumeration value="NONE" />
<xsd:enumeration value="LINK" />
<xsd:enumeration value="POPUP" />
</xsd:restriction>
</xsd:simpleType>
<xsd:complexType name="userResponse">
<xsd:annotation>
<xsd:documentation>
Contains a question ID, the question's text, and the user's response to the question, but does not echo back the values provided for
a Constituent Registration Information Question or any of the Hidden Question Types.
</xsd:documentation>
</xsd:annotation>
<xsd:sequence>
<xsd:element name="questionId" type="xsd:integer" minOccurs="0" maxOccurs="1" />
<xsd:element name="questionText" type="xsd:string" minOccurs="0" maxOccurs="1" />
<xsd:element name="responseValue" type="xsd:string" maxOccurs="unbounded" minOccurs="0" nillable="true" />
</xsd:sequence>
</xsd:complexType>
</xsd:schema>