public void CreateMessageTest() { var r = BroadcastMessageResult.CreateFailed <BroadcastMessageResult>(); var result = client.CreateMessageAsync("Broadcasted message").Result; message = result; Trace.WriteLine($"Message Id: {result.Id}"); }
public async Task <BroadcastResult> BroadcastMessageAsync(BroadcastMessageResult message, NotificationTypes notification) { BroadcastContainer container = new BroadcastContainer() { CreativeMessageId = message.Id, NotificationType = notification }; var result = await PostAsync <BroadcastResult>(container, BroadcastApiUri); return(result); }
public async Task <BroadcastResult> BroadcastMessageAsync(BroadcastMessageResult message, NotificationTypes notification, DateTime scheduleTime) { BroadcastContainer container = new BroadcastContainer() { CreativeMessageId = message.Id, NotificationType = notification, ScheduleTime = scheduleTime.ToUnixTimestamp().ToString() }; var result = await PostAsync <BroadcastResult>(container, BroadcastApiUri); return(result); }