Ejemplo n.º 1
0
        public void CreateMessageTest()
        {
            var r      = BroadcastMessageResult.CreateFailed <BroadcastMessageResult>();
            var result = client.CreateMessageAsync("Broadcasted message").Result;

            message = result;
            Trace.WriteLine($"Message Id: {result.Id}");
        }
Ejemplo n.º 2
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="text"></param>
 /// <param name="quickReplies"></param>
 /// <returns>
 ///
 /// </returns>
 public async Task <BroadcastMessageResult> CreateBroadcastMessageAsync(string text, List <QuickReply> quickReplies)
 {
     try
     {
         return(await broadcastClient.CreateMessageAsync(text, quickReplies));
     }
     catch (Exception e)
     {
         Logger.LogError(e, e.Message);
         return(BaseResult.CreateFailed <BroadcastMessageResult>());
     }
 }