Skip to main content
The First Step
Aug 8, 2018 3:11 PM UTC
Question

php sample code to retrieving message attachments

Please help me with php sample code to download attachment stream object.



2 replies

PhongVu
Community Manager
Community Manager
Aug 8, 2018 8:34 PM UTC
Since you are using the RingCentral PHP SDK, you can have a look at this demo code (https://github.com/ringcentral/ringcentral-php/blob/master/demo/callRecording.php), where it's shown how to read the call log and download the call recording binary file to a local folder.

For the message attachment, I guess that you get access to the message store. You can modify the demo code to read the message store, get the message attachment $URI and use the $apiResponse = $platform->get($URI); to get the attachment.

+ Phong
The First Step
Feb 7, 2019 10:45 AM UTC
I am using curl to download attachment of fax. Please help me as I am not able to download it using curl