/* Options: Date: 2025-12-10 20:20:24 Version: 6.50 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://galaxymobile.api.dev.86degrees.com //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: PostMessage.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; abstract class IHasApiKey { String? ApiKey; } abstract class ILogRequest { } // @Flags() class MessageType { static const MessageType Info = const MessageType._(1); static const MessageType Marketing = const MessageType._(2); static const MessageType Policy = const MessageType._(3); static const MessageType Announcement = const MessageType._(4); static const MessageType General = const MessageType._(5); static const MessageType Claim = const MessageType._(6); final int _value; const MessageType._(this._value); int get value => _value; static List get values => const [Info,Marketing,Policy,Announcement,General,Claim]; } class UserDetails implements IConvertible { String? IdNumber; int? GalaxyCompanyId; UserDetails({this.IdNumber,this.GalaxyCompanyId}); UserDetails.fromJson(Map json) { fromMap(json); } fromMap(Map json) { IdNumber = json['IdNumber']; GalaxyCompanyId = json['GalaxyCompanyId']; return this; } Map toJson() => { 'IdNumber': IdNumber, 'GalaxyCompanyId': GalaxyCompanyId }; getTypeName() => "UserDetails"; TypeContext? context = _ctx; } class ApiServiceResponse implements IServiceResponse, IConvertible { String? Description; String? Heading; bool? WasSuccessful; dynamic? ModelState; ApiServiceResponse({this.Description,this.Heading,this.WasSuccessful,this.ModelState}); ApiServiceResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Description = json['Description']; Heading = json['Heading']; WasSuccessful = json['WasSuccessful']; ModelState = JsonConverters.fromJson(json['ModelState'],'dynamic',context!); return this; } Map toJson() => { 'Description': Description, 'Heading': Heading, 'WasSuccessful': WasSuccessful, 'ModelState': JsonConverters.toJson(ModelState,'dynamic',context!) }; getTypeName() => "ApiServiceResponse"; TypeContext? context = _ctx; } class PostMessageResponse extends ApiServiceResponse implements IConvertible { PostMessageResponse(); PostMessageResponse.fromJson(Map json) : super.fromJson(json); fromMap(Map json) { super.fromMap(json); return this; } Map toJson() => super.toJson(); getTypeName() => "PostMessageResponse"; TypeContext? context = _ctx; } // @Route("/galaxy/sendmessage", "POST") class PostMessage implements IReturn, ILogRequest, IHasApiKey, IConvertible { /** * The type of message being sent. */ // @ApiMember(DataType="MessageType", Description="The type of message being sent.", IsRequired=true) MessageType? Type; /** * The subject of the message */ // @ApiMember(DataType="string", Description="The subject of the message", IsRequired=true) String? Subject; /** * The content of the message */ // @ApiMember(DataType="string", Description="The content of the message", IsRequired=true) String? Content; /** * The recipients who will be receiving the message */ // @ApiMember(Description="The recipients who will be receiving the message", IsRequired=true) List? Recipients; /** * The API Key required for authentication */ // @ApiMember(Description="The API Key required for authentication", IsRequired=true) String? ApiKey; /** * If set, the message will be displayed in the user's inbox in the app. Otherwise will just be a push notification. */ // @ApiMember(Description="If set, the message will be displayed in the user's inbox in the app. Otherwise will just be a push notification.", IsRequired=true) bool? ShowInInbox; PostMessage({this.Type,this.Subject,this.Content,this.Recipients,this.ApiKey,this.ShowInInbox}); PostMessage.fromJson(Map json) { fromMap(json); } fromMap(Map json) { Type = JsonConverters.fromJson(json['Type'],'MessageType',context!); Subject = json['Subject']; Content = json['Content']; Recipients = JsonConverters.fromJson(json['Recipients'],'List',context!); ApiKey = json['ApiKey']; ShowInInbox = json['ShowInInbox']; return this; } Map toJson() => { 'Type': JsonConverters.toJson(Type,'MessageType',context!), 'Subject': Subject, 'Content': Content, 'Recipients': JsonConverters.toJson(Recipients,'List',context!), 'ApiKey': ApiKey, 'ShowInInbox': ShowInInbox }; createResponse() => PostMessageResponse(); getResponseTypeName() => "PostMessageResponse"; getTypeName() => "PostMessage"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'galaxymobile.api.dev.86degrees.com', types: { 'IHasApiKey': TypeInfo(TypeOf.Interface), 'ILogRequest': TypeInfo(TypeOf.Interface), 'MessageType': TypeInfo(TypeOf.Enum, enumValues:MessageType.values), 'UserDetails': TypeInfo(TypeOf.Class, create:() => UserDetails()), 'ApiServiceResponse': TypeInfo(TypeOf.Class, create:() => ApiServiceResponse()), 'PostMessageResponse': TypeInfo(TypeOf.Class, create:() => PostMessageResponse()), 'PostMessage': TypeInfo(TypeOf.Class, create:() => PostMessage()), 'List': TypeInfo(TypeOf.Class, create:() => []), });