public async Task <string> SendLargeMessage(StandardBusinessDocument sbd, string contentPath) { var result = await httpClient.PostAsync("/api/messages/out", new StringContent(sbd.ToJson())); //var conversationId = sbd.StandardBusinessDocumentHeader.DocumentIdentification. return(""); }
public async Task <string> SendSmallMessage(StandardBusinessDocument sbd, string filename) { var content = new MultipartFormDataContent(); Debug.Write(sbd.ToJson()); content.Add(new StringContent(sbd.ToJson()), "sbd"); content.Add(new StreamContent(File.OpenRead(filename)), "test.pdf", "test.pdf"); var result = await httpClient.PostAsync("/api/messages/out/multipart", content); result.EnsureSuccessStatusCode(); return(""); }