Trendsic Platform Service

<back to all web services

FormZipStartRequest

Requires Authentication
The following routes are available for this service:
POST/v1/forms/submissions/zip
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    public static class FormZipStartRequest
    {
        public FormSubmissionSearchRequest Query = null;
        public ArrayList<UUID> SubmissionUIDs = new ArrayList<UUID>();
        
        public FormSubmissionSearchRequest getQuery() { return Query; }
        public FormZipStartRequest setQuery(FormSubmissionSearchRequest value) { this.Query = value; return this; }
        public ArrayList<UUID> getSubmissionUIDs() { return SubmissionUIDs; }
        public FormZipStartRequest setSubmissionUIDs(ArrayList<UUID> value) { this.SubmissionUIDs = value; return this; }
    }

    public static class FormSubmissionSearchRequest
    {
        public UUID FormUID = null;
        public String Mode = null;
        public ArrayList<UUID> Forms = new ArrayList<UUID>();
        public ArrayList<String> Stages = new ArrayList<String>();
        public ArrayList<Integer> Assignees = new ArrayList<Integer>();
        public ArrayList<String> Branches = new ArrayList<String>();
        public ArrayList<String> Tags = new ArrayList<String>();
        public String Search = null;
        public String SortKey = null;
        public Integer SortDir = null;
        public Integer Skip = null;
        public Integer Take = null;
        public ArrayList<FormAnswerCond> Conds = new ArrayList<FormAnswerCond>();
        public ArrayList<String> Flags = new ArrayList<String>();
        
        public UUID getFormUID() { return FormUID; }
        public FormSubmissionSearchRequest setFormUID(UUID value) { this.FormUID = value; return this; }
        public String getMode() { return Mode; }
        public FormSubmissionSearchRequest setMode(String value) { this.Mode = value; return this; }
        public ArrayList<UUID> getForms() { return Forms; }
        public FormSubmissionSearchRequest setForms(ArrayList<UUID> value) { this.Forms = value; return this; }
        public ArrayList<String> getStages() { return Stages; }
        public FormSubmissionSearchRequest setStages(ArrayList<String> value) { this.Stages = value; return this; }
        public ArrayList<Integer> getAssignees() { return Assignees; }
        public FormSubmissionSearchRequest setAssignees(ArrayList<Integer> value) { this.Assignees = value; return this; }
        public ArrayList<String> getBranches() { return Branches; }
        public FormSubmissionSearchRequest setBranches(ArrayList<String> value) { this.Branches = value; return this; }
        public ArrayList<String> getTags() { return Tags; }
        public FormSubmissionSearchRequest setTags(ArrayList<String> value) { this.Tags = value; return this; }
        public String getSearch() { return Search; }
        public FormSubmissionSearchRequest setSearch(String value) { this.Search = value; return this; }
        public String getSortKey() { return SortKey; }
        public FormSubmissionSearchRequest setSortKey(String value) { this.SortKey = value; return this; }
        public Integer getSortDir() { return SortDir; }
        public FormSubmissionSearchRequest setSortDir(Integer value) { this.SortDir = value; return this; }
        public Integer getSkip() { return Skip; }
        public FormSubmissionSearchRequest setSkip(Integer value) { this.Skip = value; return this; }
        public Integer getTake() { return Take; }
        public FormSubmissionSearchRequest setTake(Integer value) { this.Take = value; return this; }
        public ArrayList<FormAnswerCond> getConds() { return Conds; }
        public FormSubmissionSearchRequest setConds(ArrayList<FormAnswerCond> value) { this.Conds = value; return this; }
        public ArrayList<String> getFlags() { return Flags; }
        public FormSubmissionSearchRequest setFlags(ArrayList<String> value) { this.Flags = value; return this; }
    }

    public static class FormAnswerCond
    {
        public String F = null;
        public String Op = null;
        public String V = null;
        
        public String getF() { return F; }
        public FormAnswerCond setF(String value) { this.F = value; return this; }
        public String getOp() { return Op; }
        public FormAnswerCond setOp(String value) { this.Op = value; return this; }
        public String getV() { return V; }
        public FormAnswerCond setV(String value) { this.V = value; return this; }
    }

    public static class FormZipStartResponse
    {
        public Boolean Started = null;
        public String Message = null;
        public FormZipJobView Job = null;
        public ResponseStatus ResponseStatus = null;
        
        public Boolean isStarted() { return Started; }
        public FormZipStartResponse setStarted(Boolean value) { this.Started = value; return this; }
        public String getMessage() { return Message; }
        public FormZipStartResponse setMessage(String value) { this.Message = value; return this; }
        public FormZipJobView getJob() { return Job; }
        public FormZipStartResponse setJob(FormZipJobView value) { this.Job = value; return this; }
        public ResponseStatus getResponseStatus() { return ResponseStatus; }
        public FormZipStartResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
    }

    public static class FormZipJobView
    {
        public UUID ZipUID = null;
        public UUID FormUID = null;
        public String FormName = null;
        public String Status = null;
        public String StatusText = null;
        public String Message = null;
        public String FileName = null;
        public Integer Submissions = null;
        public Integer Files = null;
        public Long Bytes = null;
        public Integer LeftOut = null;
        public Integer FilesIn = null;
        public Long BytesIn = null;
        public Integer LeftOutIn = null;
        public Long ZipBytes = null;
        public String SizeText = null;
        public Date CreatedAt = null;
        public String CreatedText = null;
        public Date CompletedAt = null;
        public Date ExpiresAt = null;
        public String ExpiresText = null;
        public Integer Downloads = null;
        public String LastDownloadText = null;
        
        public UUID getZipUID() { return ZipUID; }
        public FormZipJobView setZipUID(UUID value) { this.ZipUID = value; return this; }
        public UUID getFormUID() { return FormUID; }
        public FormZipJobView setFormUID(UUID value) { this.FormUID = value; return this; }
        public String getFormName() { return FormName; }
        public FormZipJobView setFormName(String value) { this.FormName = value; return this; }
        public String getStatus() { return Status; }
        public FormZipJobView setStatus(String value) { this.Status = value; return this; }
        public String getStatusText() { return StatusText; }
        public FormZipJobView setStatusText(String value) { this.StatusText = value; return this; }
        public String getMessage() { return Message; }
        public FormZipJobView setMessage(String value) { this.Message = value; return this; }
        public String getFileName() { return FileName; }
        public FormZipJobView setFileName(String value) { this.FileName = value; return this; }
        public Integer getSubmissions() { return Submissions; }
        public FormZipJobView setSubmissions(Integer value) { this.Submissions = value; return this; }
        public Integer getFiles() { return Files; }
        public FormZipJobView setFiles(Integer value) { this.Files = value; return this; }
        public Long getBytes() { return Bytes; }
        public FormZipJobView setBytes(Long value) { this.Bytes = value; return this; }
        public Integer getLeftOut() { return LeftOut; }
        public FormZipJobView setLeftOut(Integer value) { this.LeftOut = value; return this; }
        public Integer getFilesIn() { return FilesIn; }
        public FormZipJobView setFilesIn(Integer value) { this.FilesIn = value; return this; }
        public Long getBytesIn() { return BytesIn; }
        public FormZipJobView setBytesIn(Long value) { this.BytesIn = value; return this; }
        public Integer getLeftOutIn() { return LeftOutIn; }
        public FormZipJobView setLeftOutIn(Integer value) { this.LeftOutIn = value; return this; }
        public Long getZipBytes() { return ZipBytes; }
        public FormZipJobView setZipBytes(Long value) { this.ZipBytes = value; return this; }
        public String getSizeText() { return SizeText; }
        public FormZipJobView setSizeText(String value) { this.SizeText = value; return this; }
        public Date getCreatedAt() { return CreatedAt; }
        public FormZipJobView setCreatedAt(Date value) { this.CreatedAt = value; return this; }
        public String getCreatedText() { return CreatedText; }
        public FormZipJobView setCreatedText(String value) { this.CreatedText = value; return this; }
        public Date getCompletedAt() { return CompletedAt; }
        public FormZipJobView setCompletedAt(Date value) { this.CompletedAt = value; return this; }
        public Date getExpiresAt() { return ExpiresAt; }
        public FormZipJobView setExpiresAt(Date value) { this.ExpiresAt = value; return this; }
        public String getExpiresText() { return ExpiresText; }
        public FormZipJobView setExpiresText(String value) { this.ExpiresText = value; return this; }
        public Integer getDownloads() { return Downloads; }
        public FormZipJobView setDownloads(Integer value) { this.Downloads = value; return this; }
        public String getLastDownloadText() { return LastDownloadText; }
        public FormZipJobView setLastDownloadText(String value) { this.LastDownloadText = value; return this; }
    }

}

Java FormZipStartRequest DTOs

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

HTTP + JSV

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

POST /v1/forms/submissions/zip HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	Query: 
	{
		FormUID: 00000000000000000000000000000000,
		Mode: String,
		Forms: 
		[
			00000000000000000000000000000000
		],
		Stages: 
		[
			String
		],
		Assignees: 
		[
			0
		],
		Branches: 
		[
			String
		],
		Tags: 
		[
			String
		],
		Search: String,
		SortKey: String,
		SortDir: 0,
		Skip: 0,
		Take: 0,
		Conds: 
		[
			{
				F: String,
				Op: String,
				V: String
			}
		],
		Flags: 
		[
			String
		]
	},
	SubmissionUIDs: 
	[
		00000000000000000000000000000000
	]
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Started: False,
	Message: String,
	Job: 
	{
		ZipUID: 00000000000000000000000000000000,
		FormUID: 00000000000000000000000000000000,
		FormName: String,
		Status: String,
		StatusText: String,
		Message: String,
		FileName: String,
		Submissions: 0,
		Files: 0,
		Bytes: 0,
		LeftOut: 0,
		FilesIn: 0,
		BytesIn: 0,
		LeftOutIn: 0,
		ZipBytes: 0,
		SizeText: String,
		CreatedAt: 0001-01-01,
		CreatedText: String,
		CompletedAt: 0001-01-01,
		ExpiresAt: 0001-01-01,
		ExpiresText: String,
		Downloads: 0,
		LastDownloadText: String
	},
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}