Creates a new Survey object required to authenticate end users

Request Parameters

Name Type Description Required?
DataSurvey[]UnavailableRequired
ProjectIdSystem.Int32UnavailableRequired
ProjectIdSystem.Int32UnavailableRequired

Validation

Name Type Description Required?
ProjectIdSystem.Int32IdRequired

Endpoints

Sample Request
 <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:api="http://api.phoenixplatform.net" xmlns:tig="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Services" xmlns:arr="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns:tig1="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Services.Filters">
    <soapenv:Header>
      <PhoenixHeader xmlns="http://api.phoenixplatform.com" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
         <AccessToken>[YOUR ACCESS TOKEN]</AccessToken>
         <Phoenix-ProjectId>1</Phoenix-ProjectId>
      </PhoenixHeader>
   </soapenv:Header>
   <soapenv:Body>
      <api1:CreateSurvey xmlns:api1="http://api.phoenixplatform.com">
         <api1:request>
             <tig:Id>1</tig:Id>
             <tig:ProjectId>1</tig:ProjectId>
             <tig:InitialScreenId>1</tig:InitialScreenId>
             <tig:Title>TestValue[09a25c028adf4f48811536522314993f]</tig:Title>
             <tig:RecipientCount>1</tig:RecipientCount>
             <tig:ReportIndividuals>1</tig:ReportIndividuals>
             <tig:Score>1</tig:Score>
             <tig:UIColorsPrimary>TestValue[0e00eeae8da84072833f8c0f786c59f4]</tig:UIColorsPrimary>
             <tig:UIColorsSecondary>TestValue[d42a4b06f0204378b5b7f925fc6315b0]</tig:UIColorsSecondary>
             <tig:UIColorsBackground>TestValue[5f96fa5f9dec4c80813e053fcd34d48a]</tig:UIColorsBackground>
             <tig:ImageDir>TestValue[f88cc4a0c9664fc6bc651ac682aa5460]</tig:ImageDir>
             <tig:ProgressLabel>TestValue[29284a7ebfec471391e2bf0b58c3d7c9]</tig:ProgressLabel>
             <tig:Uuid>TestValue[87e74d3f12d74bc78b9cebe73ec09f89]</tig:Uuid>
             <tig:LaunchScreenShow>true</tig:LaunchScreenShow>
             <tig:LaunchScreenTextDesktop>TestValue[44949606ba4b484692296c46589f32aa]</tig:LaunchScreenTextDesktop>
             <tig:LaunchScreenTextMobile>TestValue[bed52e1b415b4aebbeb8ffbdcb910119]</tig:LaunchScreenTextMobile>
             <tig:LaunchScreenTextColor>TestValue[25d70cd2e6904893b290b33578e3249c]</tig:LaunchScreenTextColor>
             <tig:LaunchScreenButtonText>TestValue[0bfb74ddaace45cabaebd4e8ed6a915f]</tig:LaunchScreenButtonText>
             <tig:LaunchScreenBgFilename>TestValue[6674e3d3cf644c1d98705359b402f50c]</tig:LaunchScreenBgFilename>
             <tig:FinalScreenTextSuccess>TestValue[e0b3b4e0f7da4bfb999b2107236084f7]</tig:FinalScreenTextSuccess>
             <tig:FinalScreenTextError>TestValue[506466e0442847e781570b96a955cc6d]</tig:FinalScreenTextError>
             <tig:FinalScreenTextColor>TestValue[69e28a5153c648cea517d98820dcba09]</tig:FinalScreenTextColor>
             <tig:FinalScreenBgFilename>TestValue[7e71ad6ce6c34847adae90e14b9d2fb8]</tig:FinalScreenBgFilename>
             <tig:EditUuid>TestValue[f3993a52289740ba82545e0cd12f01c6]</tig:EditUuid>
             <tig:DisplayUrlParam>TestValue[d9863d1b7db6449cb2fa6e089c649a67]</tig:DisplayUrlParam>
             <tig:ReportStatusFilter>TestValue[ce4e19a5bf5e456fbfad0de4cfe5ea8c]</tig:ReportStatusFilter>
             <tig:ModifyDate>2019-06-17T13:51:30.7048871+00:00</tig:ModifyDate>
             <tig:NameUrlField>TestValue[e327a3b3e34f4a4b88da437f5be951ab]</tig:NameUrlField>
             <tig:IsActive>true</tig:IsActive>
             <tig:StatusTypeId>Testing</tig:StatusTypeId>
             <tig:HasNamedRecipients>true</tig:HasNamedRecipients>
             <tig:ClosedText>TestValue[168d2ed7e6f44e28b0e19071d00c6e59]</tig:ClosedText>
             <tig:BadLinkText>TestValue[84cd886056a04c5dbe30ced03df2db41]</tig:BadLinkText>
             <tig:ReportIndividualNames>true</tig:ReportIndividualNames>
             <tig:CustomFont>TestValue[6bd6612e03224af8838d2f218cbecd94]</tig:CustomFont>
             <tig:CustomCss>TestValue[e4daf5f9b3d34bbc9bdaae15e0afb968]</tig:CustomCss>
             <tig:NotificationAddresses>TestValue[742a94a27fdc4e078a895efd460a1295]</tig:NotificationAddresses>
             <tig:MessageId>1</tig:MessageId>
             <tig:MetaDataParameters>new List<KeyValuePair<string, string>>().ToArray()</tig:MetaDataParameters>
         </api1:request>
      </api1:CreateSurvey>
   </soapenv:Body>
</soapenv:Envelope>
Sample Response
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
   <s:Header>
      <ActivityId CorrelationId="d088e8c6-bf1e-4a9d-9e96-3f5faf232af5" xmlns="http://schemas.microsoft.com/2004/09/ServiceModel/Diagnostics">17abb643-6b2f-4485-b4ff-0afc30697b7d</ActivityId>
   </s:Header>
   <s:Body>
      <SurveyResponse xmlns="http://api.phoenixplatform.com">
         <SurveyResult xmlns:a="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Syndicate.Services.Contracts.Article" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
            <b:Data xmlns="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Services" xmlns:b="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Survey.Model">
              <b:Survey>
                <b:CreateDate>2019-06-17T13:51:30.7048871Z</b:CreateDate>
                <b:IsActive>false</b:IsActive>
                <b:Media />
                <b:ModifyDate>2019-06-17T13:51:30.7048871Z</b:ModifyDate>
                <b:ProjectId>0</b:ProjectId>
                <b:ReportIndividuals>0</b:ReportIndividuals>
                <b:Score>0</b:Score>
                <b:SurveyUrls />
  </b:Survey>
</b:Data>
            <TotalRecords xmlns="http://schemas.datacontract.org/2004/07/Tigerspike.Phoenix.Services">1</TotalRecords>
         </SurveyResult>
      </SurveyResponse>
   </s:Body>
</s:Envelope>
Resource URL

Sample Request

POST /projects/{projectId}/surveys? HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: application/json; charset=utf-8
Authorization: Bearer [YOUR SUPER SECURE TOKEN]
Content-Length: 4312
Host: [CallHost]
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)-
 
[{
 "Id" : 1,
 "ProjectId" : 1,
 "InitialScreenId" : 1,
 "Title" : "TestValue[211620669781421bb67750f93bacc508]",
 "RecipientCount" : 1,
 "ReportIndividuals" : 1,
 "Score" : 1,
 "UIColorsPrimary" : "TestValue[74809b4a66364a78a158bb468085d7bf]",
 "UIColorsSecondary" : "TestValue[d02cad3844b544af86bf204a7889a366]",
 "UIColorsBackground" : "TestValue[b55f15eda21949ec8f3bf30cb0d14ded]",
 "ImageDir" : "TestValue[9bf29c17db8846b09e9a56fc762631fa]",
 "ProgressLabel" : "TestValue[88430b272c764078964166b8748c34ff]",
 "Uuid" : "TestValue[080da3328a0349a3aacb94a898bc9caf]",
 "LaunchScreenShow" : true,
 "LaunchScreenTextDesktop" : "TestValue[1612c9b013694b018860d39c3e58e9b7]",
 "LaunchScreenTextMobile" : "TestValue[86b0141d19f64b0397052d7b7b3a83c4]",
 "LaunchScreenTextColor" : "TestValue[13baad9b03a84a799ca9cc0f0fb6b543]",
 "LaunchScreenButtonText" : "TestValue[5177a5a7574d4dacb50f27fb9a6d39e8]",
 "LaunchScreenBgFilename" : "TestValue[125f71cf13a146518fa43d60b57de4ea]",
 "FinalScreenTextSuccess" : "TestValue[4b4aa407127748cc975170bdb77bfd15]",
 "FinalScreenTextError" : "TestValue[341f1f1759684553af344d2bf4f6127e]",
 "FinalScreenTextColor" : "TestValue[1a83dc17b17b4b3fb1067b0a9ebd0729]",
 "FinalScreenBgFilename" : "TestValue[93b88f243c1c4dcd9fda7a8edb11352e]",
 "EditUuid" : "TestValue[368da54323cf4b38ae917259010e0cb8]",
 "DisplayUrlParam" : "TestValue[54656021caad4658b2c8a437fa247dd3]",
 "ReportStatusFilter" : "TestValue[6cdd7693b37d462eb9dc04c38eca5f7c]",
 "ModifyDate" : "2019-06-17T13:51:30.7038869+00:00",
 "NameUrlField" : "TestValue[37e96f8247df483a99fec5df3c60ce20]",
 "IsActive" : true,
 "StatusTypeId" : "Open",
 "HasNamedRecipients" : true,
 "ClosedText" : "TestValue[e5c4cf249e4443aebc92f9b4e969d0b8]",
 "BadLinkText" : "TestValue[cfffa9e705b34719a566eb6ad0774412]",
 "ReportIndividualNames" : true,
 "CustomFont" : "TestValue[34edfd2a916e4744ac695c070cee43a7]",
 "CustomCss" : "TestValue[7d72824c2c5f4368877a280090573cfd]",
 "NotificationAddresses" : "TestValue[b2e71f29ea7b4a709fcf39724f47e2fc]",
 "MessageId" : 1,
 "MetaDataParameters" : new List<KeyValuePair<string, string>>().ToArray()
}] 
Sample Response
HTTP/1.1 200 OK
Cache-Control: private
Content-Length: 200
Content-Type: application/json; charset=utf-8
Server: Microsoft-IIS/8.5
X-AspNet-Version: 4.0.30319
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET,PUT,POST,DELETE,OPTIONS
Access-Control-Allow-Headers: Content-Type

[{
  "ProjectId": 0,
  "ReportIndividuals": 0,
  "Score": 0,
  "CreateDate": "2019-06-17T14:08:16.2011437Z",
  "ModifyDate": "2019-06-17T14:08:16.2011437Z",
  "IsActive": false,
  "Media": [],
  "SurveyUrls": []
}]

Nuget

PM> Install-Package PhoenixServiceHelper

PhoenixServiceHelper Sample

using System;
using System.Collections.Generic;

using Tigerspike.Phoenix.Services.Api.ServiceConfiguration;
using Tigerspike.Phoenix.Services.Api.ServiceRequest;
using PhoenixService = Tigerspike.PhoenixSurvey.V1;
using Tigerspike.Phoenix.Services.Api;

var request = new SoapServiceRequest() { Token = "[YOUR SUPER SECURE TOKEN]", ProjectId = 1 };
var configuration = CustomConfigurationFactory.CreateServiceConfiguration(Assembly.GetExecutingAssembly());

var proxy = new PhoenixServiceHelper<PhoenixService.IPhoenixSurveyService>(configuration);
var response = proxy.Execute(request, o => o.CreateSurvey(new PhoenixService.CreateSurveyRequest() 
{ 
    Data = new[] 
    { 
        new PhoenixService.Survey() 
        {
          Id = 1,
          ProjectId = 1,
          InitialScreenId = 1,
          Title = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          RecipientCount = 1,
          ReportIndividuals = 1,
          Score = 1,
          UIColorsPrimary = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          UIColorsSecondary = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          UIColorsBackground = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          ImageDir = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          ProgressLabel = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          Uuid = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          LaunchScreenShow = true,
          LaunchScreenTextDesktop = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          LaunchScreenTextMobile = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          LaunchScreenTextColor = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          LaunchScreenButtonText = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          LaunchScreenBgFilename = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          FinalScreenTextSuccess = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          FinalScreenTextError = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          FinalScreenTextColor = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          FinalScreenBgFilename = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          EditUuid = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          DisplayUrlParam = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          ReportStatusFilter = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          ModifyDate = DateTime.UtcNow,
          NameUrlField = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          IsActive = true,
          StatusTypeId = PhoenixService.StatusTypeEnum.Archived,
          HasNamedRecipients = true,
          ClosedText = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          BadLinkText = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          ReportIndividualNames = true,
          CustomFont = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          CustomCss = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          NotificationAddresses = "TestValue["Guid.NewGuid().ToString().Replace("-",string.Empty)+"]",
          MessageId = 1,
          MetaDataParameters = new List<KeyValuePair<string, string>>().ToArray()
        }
    } 
}));