| POST | /v1/forms/submissions/export |
|---|
import 'package:servicestack/servicestack.dart';
class FormAnswerCond implements IConvertible
{
String? F;
String? Op;
String? V;
FormAnswerCond({this.F,this.Op,this.V});
FormAnswerCond.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
F = json['F'];
Op = json['Op'];
V = json['V'];
return this;
}
Map<String, dynamic> toJson() => {
'F': F,
'Op': Op,
'V': V
};
getTypeName() => "FormAnswerCond";
TypeContext? context = _ctx;
}
class FormSubmissionSearchRequest implements IConvertible
{
String? FormUID;
String? Mode;
List<String>? Forms = [];
List<String>? Stages = [];
List<int>? Assignees = [];
List<String>? Branches = [];
List<String>? Tags = [];
String? Search;
String? SortKey;
int? SortDir;
int? Skip;
int? Take;
List<FormAnswerCond>? Conds = [];
List<String>? Flags = [];
FormSubmissionSearchRequest({this.FormUID,this.Mode,this.Forms,this.Stages,this.Assignees,this.Branches,this.Tags,this.Search,this.SortKey,this.SortDir,this.Skip,this.Take,this.Conds,this.Flags});
FormSubmissionSearchRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
FormUID = json['FormUID'];
Mode = json['Mode'];
Forms = JsonConverters.fromJson(json['Forms'],'List<String>',context!);
Stages = JsonConverters.fromJson(json['Stages'],'List<String>',context!);
Assignees = JsonConverters.fromJson(json['Assignees'],'List<int>',context!);
Branches = JsonConverters.fromJson(json['Branches'],'List<String>',context!);
Tags = JsonConverters.fromJson(json['Tags'],'List<String>',context!);
Search = json['Search'];
SortKey = json['SortKey'];
SortDir = json['SortDir'];
Skip = json['Skip'];
Take = json['Take'];
Conds = JsonConverters.fromJson(json['Conds'],'List<FormAnswerCond>',context!);
Flags = JsonConverters.fromJson(json['Flags'],'List<String>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'FormUID': FormUID,
'Mode': Mode,
'Forms': JsonConverters.toJson(Forms,'List<String>',context!),
'Stages': JsonConverters.toJson(Stages,'List<String>',context!),
'Assignees': JsonConverters.toJson(Assignees,'List<int>',context!),
'Branches': JsonConverters.toJson(Branches,'List<String>',context!),
'Tags': JsonConverters.toJson(Tags,'List<String>',context!),
'Search': Search,
'SortKey': SortKey,
'SortDir': SortDir,
'Skip': Skip,
'Take': Take,
'Conds': JsonConverters.toJson(Conds,'List<FormAnswerCond>',context!),
'Flags': JsonConverters.toJson(Flags,'List<String>',context!)
};
getTypeName() => "FormSubmissionSearchRequest";
TypeContext? context = _ctx;
}
class FormSubmissionExportRequest implements IConvertible
{
FormSubmissionSearchRequest? Query;
List<String>? SubmissionUIDs = [];
FormSubmissionExportRequest({this.Query,this.SubmissionUIDs});
FormSubmissionExportRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Query = JsonConverters.fromJson(json['Query'],'FormSubmissionSearchRequest',context!);
SubmissionUIDs = JsonConverters.fromJson(json['SubmissionUIDs'],'List<String>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'Query': JsonConverters.toJson(Query,'FormSubmissionSearchRequest',context!),
'SubmissionUIDs': JsonConverters.toJson(SubmissionUIDs,'List<String>',context!)
};
getTypeName() => "FormSubmissionExportRequest";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: <String, TypeInfo> {
'FormAnswerCond': TypeInfo(TypeOf.Class, create:() => FormAnswerCond()),
'FormSubmissionSearchRequest': TypeInfo(TypeOf.Class, create:() => FormSubmissionSearchRequest()),
'List<FormAnswerCond>': TypeInfo(TypeOf.Class, create:() => <FormAnswerCond>[]),
'FormSubmissionExportRequest': TypeInfo(TypeOf.Class, create:() => FormSubmissionExportRequest()),
});
Dart FormSubmissionExportRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/forms/submissions/export HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsonl
Content-Type: text/jsonl
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"]}