Trendsic Platform Service

<back to all web services

FormContactPanelRequest

Requires Authentication
The following routes are available for this service:
GET/v1/forms/contacts/{ContactId}
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class FormContactPanelSub implements IConvertible
{
    String? SubmissionUID;
    String? Number;
    String? FormName;
    String? Stage;
    String? Tone;
    String? SubmittedAt;
    String? BranchName;

    FormContactPanelSub({this.SubmissionUID,this.Number,this.FormName,this.Stage,this.Tone,this.SubmittedAt,this.BranchName});
    FormContactPanelSub.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        SubmissionUID = json['SubmissionUID'];
        Number = json['Number'];
        FormName = json['FormName'];
        Stage = json['Stage'];
        Tone = json['Tone'];
        SubmittedAt = json['SubmittedAt'];
        BranchName = json['BranchName'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'SubmissionUID': SubmissionUID,
        'Number': Number,
        'FormName': FormName,
        'Stage': Stage,
        'Tone': Tone,
        'SubmittedAt': SubmittedAt,
        'BranchName': BranchName
    };

    getTypeName() => "FormContactPanelSub";
    TypeContext? context = _ctx;
}

class FormOfficeDraftRow implements IConvertible
{
    String? SubmissionUID;
    String? FormUID;
    String? FormName;
    String? ForName;
    String? BranchName;
    int? ContactId;
    int? Page;
    int? Pages;
    String? SavedBy;
    String? SavedAt;

    FormOfficeDraftRow({this.SubmissionUID,this.FormUID,this.FormName,this.ForName,this.BranchName,this.ContactId,this.Page,this.Pages,this.SavedBy,this.SavedAt});
    FormOfficeDraftRow.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        SubmissionUID = json['SubmissionUID'];
        FormUID = json['FormUID'];
        FormName = json['FormName'];
        ForName = json['ForName'];
        BranchName = json['BranchName'];
        ContactId = json['ContactId'];
        Page = json['Page'];
        Pages = json['Pages'];
        SavedBy = json['SavedBy'];
        SavedAt = json['SavedAt'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'SubmissionUID': SubmissionUID,
        'FormUID': FormUID,
        'FormName': FormName,
        'ForName': ForName,
        'BranchName': BranchName,
        'ContactId': ContactId,
        'Page': Page,
        'Pages': Pages,
        'SavedBy': SavedBy,
        'SavedAt': SavedAt
    };

    getTypeName() => "FormOfficeDraftRow";
    TypeContext? context = _ctx;
}

class FormOfficeApp implements IConvertible
{
    String? FormUID;
    String? Name;
    String? Noun;
    String? DefaultBranchId;
    bool? IsRecord;
    String? RoleName;

    FormOfficeApp({this.FormUID,this.Name,this.Noun,this.DefaultBranchId,this.IsRecord,this.RoleName});
    FormOfficeApp.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        FormUID = json['FormUID'];
        Name = json['Name'];
        Noun = json['Noun'];
        DefaultBranchId = json['DefaultBranchId'];
        IsRecord = json['IsRecord'];
        RoleName = json['RoleName'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'FormUID': FormUID,
        'Name': Name,
        'Noun': Noun,
        'DefaultBranchId': DefaultBranchId,
        'IsRecord': IsRecord,
        'RoleName': RoleName
    };

    getTypeName() => "FormOfficeApp";
    TypeContext? context = _ctx;
}

class FormContactPanelResponse implements IConvertible
{
    List<FormContactPanelSub>? Subs = [];
    List<FormOfficeDraftRow>? Drafts = [];
    List<FormOfficeApp>? Forms = [];
    bool? CanStart;
    String? ContactName;
    ResponseStatus? ResponseStatus;

    FormContactPanelResponse({this.Subs,this.Drafts,this.Forms,this.CanStart,this.ContactName,this.ResponseStatus});
    FormContactPanelResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        Subs = JsonConverters.fromJson(json['Subs'],'List<FormContactPanelSub>',context!);
        Drafts = JsonConverters.fromJson(json['Drafts'],'List<FormOfficeDraftRow>',context!);
        Forms = JsonConverters.fromJson(json['Forms'],'List<FormOfficeApp>',context!);
        CanStart = json['CanStart'];
        ContactName = json['ContactName'];
        ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'Subs': JsonConverters.toJson(Subs,'List<FormContactPanelSub>',context!),
        'Drafts': JsonConverters.toJson(Drafts,'List<FormOfficeDraftRow>',context!),
        'Forms': JsonConverters.toJson(Forms,'List<FormOfficeApp>',context!),
        'CanStart': CanStart,
        'ContactName': ContactName,
        'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!)
    };

    getTypeName() => "FormContactPanelResponse";
    TypeContext? context = _ctx;
}

class FormContactPanelRequest implements IConvertible
{
    int? ContactId;

    FormContactPanelRequest({this.ContactId});
    FormContactPanelRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ContactId = json['ContactId'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ContactId': ContactId
    };

    getTypeName() => "FormContactPanelRequest";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: <String, TypeInfo> {
    'FormContactPanelSub': TypeInfo(TypeOf.Class, create:() => FormContactPanelSub()),
    'FormOfficeDraftRow': TypeInfo(TypeOf.Class, create:() => FormOfficeDraftRow()),
    'FormOfficeApp': TypeInfo(TypeOf.Class, create:() => FormOfficeApp()),
    'FormContactPanelResponse': TypeInfo(TypeOf.Class, create:() => FormContactPanelResponse()),
    'List<FormContactPanelSub>': TypeInfo(TypeOf.Class, create:() => <FormContactPanelSub>[]),
    'List<FormOfficeDraftRow>': TypeInfo(TypeOf.Class, create:() => <FormOfficeDraftRow>[]),
    'List<FormOfficeApp>': TypeInfo(TypeOf.Class, create:() => <FormOfficeApp>[]),
    'FormContactPanelRequest': TypeInfo(TypeOf.Class, create:() => FormContactPanelRequest()),
});

Dart FormContactPanelRequest DTOs

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

HTTP + OTHER

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

GET /v1/forms/contacts/{ContactId} HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"Subs":[{"SubmissionUID":"String","Number":"String","FormName":"String","Stage":"String","Tone":"String","SubmittedAt":"String","BranchName":"String"}],"Drafts":[{"SubmissionUID":"String","FormUID":"String","FormName":"String","ForName":"String","BranchName":"String","ContactId":0,"Page":0,"Pages":0,"SavedBy":"String","SavedAt":"String"}],"Forms":[{"FormUID":"String","Name":"String","Noun":"String","DefaultBranchId":"String","IsRecord":false,"RoleName":"String"}],"CanStart":false,"ContactName":"String","ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}