Esempio n. 1
0
 public async Task <IActionResult> UploadFileAsync([FromForm] SLackAttachmentRequest attRequest)
 {
     if (attRequest.File.Length > 0)
     {
         await slackBotService.UploadFileAsync("xoxp-914359964370-927168311733-936338397655-4436342264bccf221f3d3683e5497fdf", attRequest.File.OpenReadStream(), attRequest.File.FileName, attRequest.channel);
     }
     return(Ok());
 }
 public async Task <IActionResult> UploadFileAsync([FromForm] SlackAttachmentRequest attRequest)
 {
     if (attRequest.File.Length > 0)
     {
         await slackBotService.UploadFileAsync("userToken", attRequest.File.OpenReadStream(), attRequest.File.FileName, attRequest.channel);
     }
     return(Ok());
 }