【问题标题】:How to send Fax attaching PDF in RingCentral in Java如何在 Java 中的 RingCentral 中发送传真附件 PDF
【发布时间】:2020-06-19 21:40:14
【问题描述】:

我们正在探索 RingCentral 传真以发送传真。我们想附上 pdf 文档并将其与 Java 代码一起发送。但是对于 RingCentral SDK,我只想知道如何在代码中设置 MIME 类型或内容类型。任何示例都会有所帮助。

我试过了:

Attachment attachment = new Attachment(); 
attachment.fileName = "c:\\ testRun.pdf";

有没有办法设置文档的MIME类型?

【问题讨论】:

    标签: java mime-types content-type fax ringcentral


    【解决方案1】:

    如果您可以在此处查看示例文档,attachment.contentType 用于设置文档内容类型:https://developers.ringcentral.com/guide/messaging/fax/sending-faxes

    Attachment attachment = new Attachment();
    attachment.fileName = "testRun.pdf";
    attachment.contentType = "application/pdf";
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-12-27
      相关资源
      最近更新 更多