Trendsic Platform Service

<back to all web services

FormNoticePreviewRequest

Requires Authentication
The following routes are available for this service:
POST/v1/forms/{FormUID}/notices/preview
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    public static class FormNoticePreviewRequest
    {
        public UUID FormUID = null;
        public String Id = null;
        public String Lang = null;
        public String Channel = null;
        public String Subject = null;
        public String Body = null;
        public String Text = null;
        public String Closing = null;
        public UUID SubmissionUID = null;
        
        public UUID getFormUID() { return FormUID; }
        public FormNoticePreviewRequest setFormUID(UUID value) { this.FormUID = value; return this; }
        public String getId() { return Id; }
        public FormNoticePreviewRequest setId(String value) { this.Id = value; return this; }
        public String getLang() { return Lang; }
        public FormNoticePreviewRequest setLang(String value) { this.Lang = value; return this; }
        public String getChannel() { return Channel; }
        public FormNoticePreviewRequest setChannel(String value) { this.Channel = value; return this; }
        public String getSubject() { return Subject; }
        public FormNoticePreviewRequest setSubject(String value) { this.Subject = value; return this; }
        public String getBody() { return Body; }
        public FormNoticePreviewRequest setBody(String value) { this.Body = value; return this; }
        public String getText() { return Text; }
        public FormNoticePreviewRequest setText(String value) { this.Text = value; return this; }
        public String getClosing() { return Closing; }
        public FormNoticePreviewRequest setClosing(String value) { this.Closing = value; return this; }
        public UUID getSubmissionUID() { return SubmissionUID; }
        public FormNoticePreviewRequest setSubmissionUID(UUID value) { this.SubmissionUID = value; return this; }
    }

    public static class FormNoticePreviewResponse
    {
        public String Subject = null;
        public String Body = null;
        public String Meta = null;
        public String SubmissionUID = null;
        public Boolean Sample = null;
        public String SampleNote = null;
        public Integer TextLength = null;
        public Integer Segments = null;
        public Boolean Wide = null;
        public ArrayList<String> Problems = new ArrayList<String>();
        public ArrayList<FormInboxCount> Samples = new ArrayList<FormInboxCount>();
        public ResponseStatus ResponseStatus = null;
        
        public String getSubject() { return Subject; }
        public FormNoticePreviewResponse setSubject(String value) { this.Subject = value; return this; }
        public String getBody() { return Body; }
        public FormNoticePreviewResponse setBody(String value) { this.Body = value; return this; }
        public String getMeta() { return Meta; }
        public FormNoticePreviewResponse setMeta(String value) { this.Meta = value; return this; }
        public String getSubmissionUID() { return SubmissionUID; }
        public FormNoticePreviewResponse setSubmissionUID(String value) { this.SubmissionUID = value; return this; }
        public Boolean isSample() { return Sample; }
        public FormNoticePreviewResponse setSample(Boolean value) { this.Sample = value; return this; }
        public String getSampleNote() { return SampleNote; }
        public FormNoticePreviewResponse setSampleNote(String value) { this.SampleNote = value; return this; }
        public Integer getTextLength() { return TextLength; }
        public FormNoticePreviewResponse setTextLength(Integer value) { this.TextLength = value; return this; }
        public Integer getSegments() { return Segments; }
        public FormNoticePreviewResponse setSegments(Integer value) { this.Segments = value; return this; }
        public Boolean isWide() { return Wide; }
        public FormNoticePreviewResponse setWide(Boolean value) { this.Wide = value; return this; }
        public ArrayList<String> getProblems() { return Problems; }
        public FormNoticePreviewResponse setProblems(ArrayList<String> value) { this.Problems = value; return this; }
        public ArrayList<FormInboxCount> getSamples() { return Samples; }
        public FormNoticePreviewResponse setSamples(ArrayList<FormInboxCount> value) { this.Samples = value; return this; }
        public ResponseStatus getResponseStatus() { return ResponseStatus; }
        public FormNoticePreviewResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
    }

    public static class FormInboxCount
    {
        public String V = null;
        public String L = null;
        public Integer N = null;
        
        public String getV() { return V; }
        public FormInboxCount setV(String value) { this.V = value; return this; }
        public String getL() { return L; }
        public FormInboxCount setL(String value) { this.L = value; return this; }
        public Integer getN() { return N; }
        public FormInboxCount setN(Integer value) { this.N = value; return this; }
    }

}

Java FormNoticePreviewRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/forms/{FormUID}/notices/preview HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<FormNoticePreviewRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Body>String</Body>
  <Channel>String</Channel>
  <Closing>String</Closing>
  <FormUID>00000000-0000-0000-0000-000000000000</FormUID>
  <Id>String</Id>
  <Lang>String</Lang>
  <Subject>String</Subject>
  <SubmissionUID>00000000-0000-0000-0000-000000000000</SubmissionUID>
  <Text>String</Text>
</FormNoticePreviewRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<FormNoticePreviewResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Body>String</Body>
  <Meta>String</Meta>
  <Problems xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>String</d2p1:string>
  </Problems>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
  <Sample>false</Sample>
  <SampleNote>String</SampleNote>
  <Samples>
    <FormInboxCount>
      <L>String</L>
      <N>0</N>
      <V>String</V>
    </FormInboxCount>
  </Samples>
  <Segments>0</Segments>
  <Subject>String</Subject>
  <SubmissionUID>String</SubmissionUID>
  <TextLength>0</TextLength>
  <Wide>false</Wide>
</FormNoticePreviewResponse>