/* Options: Date: 2026-10-12 01:15:59 Version: 8.80 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://api.dev.dynamics.trendsic.com //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: CustomerThreadPostRequest.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class JobThreadMessageView implements IConvertible { int? Id; String? Party; bool? Mine; String? Who; String? Body; bool? ViaVoice; bool? IsStatusChip; String? ChipKey; DateTime? SentUtc; String? SentLocal; bool? Seen; JobThreadMessageView({this.Id,this.Party,this.Mine,this.Who,this.Body,this.ViaVoice,this.IsStatusChip,this.ChipKey,this.SentUtc,this.SentLocal,this.Seen}); JobThreadMessageView.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Id = json['Id']; Party = json['Party']; Mine = json['Mine']; Who = json['Who']; Body = json['Body']; ViaVoice = json['ViaVoice']; IsStatusChip = json['IsStatusChip']; ChipKey = json['ChipKey']; SentUtc = JsonConverters.fromJson(json['SentUtc'],'DateTime',context!); SentLocal = json['SentLocal']; Seen = json['Seen']; return this; } Map toJson() => { 'Id': Id, 'Party': Party, 'Mine': Mine, 'Who': Who, 'Body': Body, 'ViaVoice': ViaVoice, 'IsStatusChip': IsStatusChip, 'ChipKey': ChipKey, 'SentUtc': JsonConverters.toJson(SentUtc,'DateTime',context!), 'SentLocal': SentLocal, 'Seen': Seen }; getTypeName() => "JobThreadMessageView"; TypeContext? context = _ctx; } class JobThreadView implements IConvertible { int? Id; String? Kind; int? RefId; String? RefCode; int? WorkerContactId; String? Who; bool? Closed; String? ClosesLocal; int? Unread; String? Note; List? QuickReplies = []; List? Messages = []; JobThreadView({this.Id,this.Kind,this.RefId,this.RefCode,this.WorkerContactId,this.Who,this.Closed,this.ClosesLocal,this.Unread,this.Note,this.QuickReplies,this.Messages}); JobThreadView.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Id = json['Id']; Kind = json['Kind']; RefId = json['RefId']; RefCode = json['RefCode']; WorkerContactId = json['WorkerContactId']; Who = json['Who']; Closed = json['Closed']; ClosesLocal = json['ClosesLocal']; Unread = json['Unread']; Note = json['Note']; QuickReplies = JsonConverters.fromJson(json['QuickReplies'],'List',context!); Messages = JsonConverters.fromJson(json['Messages'],'List',context!); return this; } Map toJson() => { 'Id': Id, 'Kind': Kind, 'RefId': RefId, 'RefCode': RefCode, 'WorkerContactId': WorkerContactId, 'Who': Who, 'Closed': Closed, 'ClosesLocal': ClosesLocal, 'Unread': Unread, 'Note': Note, 'QuickReplies': JsonConverters.toJson(QuickReplies,'List',context!), 'Messages': JsonConverters.toJson(Messages,'List',context!) }; getTypeName() => "JobThreadView"; TypeContext? context = _ctx; } class ProblemReasonView implements IConvertible { String? Key; String? Label; ProblemReasonView({this.Key,this.Label}); ProblemReasonView.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Key = json['Key']; Label = json['Label']; return this; } Map toJson() => { 'Key': Key, 'Label': Label }; getTypeName() => "ProblemReasonView"; TypeContext? context = _ctx; } class CustomerThreadResponse implements IConvertible { List? Threads = []; List? ProblemReasons = []; String? Message; ResponseStatus? ResponseStatus; CustomerThreadResponse({this.Threads,this.ProblemReasons,this.Message,this.ResponseStatus}); CustomerThreadResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Threads = JsonConverters.fromJson(json['Threads'],'List',context!); ProblemReasons = JsonConverters.fromJson(json['ProblemReasons'],'List',context!); Message = json['Message']; ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!); return this; } Map toJson() => { 'Threads': JsonConverters.toJson(Threads,'List',context!), 'ProblemReasons': JsonConverters.toJson(ProblemReasons,'List',context!), 'Message': Message, 'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!) }; getTypeName() => "CustomerThreadResponse"; TypeContext? context = _ctx; } // @Route("/v1/c/thread/{Kind}/{RefId}", "POST") class CustomerThreadPostRequest implements IReturn, IConvertible, IPost { String? Kind; int? RefId; int? WorkerContactId; String? Body; CustomerThreadPostRequest({this.Kind,this.RefId,this.WorkerContactId,this.Body}); CustomerThreadPostRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Kind = json['Kind']; RefId = json['RefId']; WorkerContactId = json['WorkerContactId']; Body = json['Body']; return this; } Map toJson() => { 'Kind': Kind, 'RefId': RefId, 'WorkerContactId': WorkerContactId, 'Body': Body }; createResponse() => CustomerThreadResponse(); getResponseTypeName() => "CustomerThreadResponse"; getTypeName() => "CustomerThreadPostRequest"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: { 'JobThreadMessageView': TypeInfo(TypeOf.Class, create:() => JobThreadMessageView()), 'JobThreadView': TypeInfo(TypeOf.Class, create:() => JobThreadView()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'ProblemReasonView': TypeInfo(TypeOf.Class, create:() => ProblemReasonView()), 'CustomerThreadResponse': TypeInfo(TypeOf.Class, create:() => CustomerThreadResponse()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'List': TypeInfo(TypeOf.Class, create:() => []), 'CustomerThreadPostRequest': TypeInfo(TypeOf.Class, create:() => CustomerThreadPostRequest()), });