News & Announcements User Community Developer Community

Welcome to the RingCentral Community

Please note the community is currently under maintenance and is read-only.

Search
Make sure to review our Terms of Use and Community Guidelines.
  Please note the community is currently under maintenance and is read-only.
Home » Developers
How do I name an attached pdf document with a name differing from its file path name, using a curl script?
Tags: rest api
May 23, 2020 at 10:07am   •   1 replies  •  0 likes
alan-kimelman-md

How do I name an attached pdf document with a name differing from its file path name, using a curl script?

A curl example formulated at https://developers.ringcentral.com/api-reference/Fax/createFaxMessage yields the following data string:

--data '{
   
   "attachment":"data:application/pdf;name=A%20different%20name.pdf;base64,<<base64>>","to":["1234567890"] }'.


I created a curl data post, which delivered a fully rendered pdf, but without a new name using the following string:

"-F \"attachment=@$PDF_Container_Field;name=A%20different%20name.pdf;type=application/pdf\" -F \"to=" & $toRecipientTenDigit & "\" "


As an aside, regarding my not using base64 encoding, my script is executed via FilemakerPro via "insert from url" with curl options. I guess that base64 encoding occurs when a curl option -F is streamed via Filemaker's "insert from url" command, as the script delivers a fully rendered pdf.

Question:

What might be correct curl syntax possibilities to simulate the syntax found in the curl command generated at developers.ringcentral.com/api-reference/Fax/createFaxMessage?


1 Answer
answered on Jun 2, 2020 at 10:29am  

What is the reason you want to change the file name? Is it the big impact for your project? As for sending Fax using curl, check out the discussion on this thread.


 0



A new Community is coming to RingCentral!

Posts are currently read-only as we transition into our new platform.

We thank you for your patience
during this downtime.

Try Workflow Builder

Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!

Try RingCentral Workflow Builder

PRODUCTS
RingEX
Message
Video
Phone
OPEN ECOSYSTEM
Developer Platform
APIs
Integrated Apps
App Gallery
Developer support
Games and rewards

RESOURCES
Resource center
Blog
Product Releases
Accessibility
QUICK LINKS
App Download
RingCentral App login
Admin Portal Login
Contact Sales
© 1999-2024 RingCentral, Inc. All rights reserved. Legal Privacy Notice Site Map Contact Us