Upload local files
Python
Our Python SDK rcs-py provides both a synchronous and an asynchronous method to upload files to Pinnacle. The upload(self, file_path: str) takes in a local file path that is uploaded and return a download URL that can be used as the media url for messages. The upload method
can be used in both synchronous and asynchronous mode depending on the type of PinnacleClient that is used.
Synchronous
Asynchronous
TypeScript
Our TypeScript SDK rcs-js provides a method to upload files to Pinnacle. The async upload method takes in a File object and return a download URL that can be used as the media url for messages.
Other languages
At this time, this upload functionality is not natively supported in other languages (notably Ruby). However, you can still use the Create Upload URL which generates a presigned upload URL (to upload your media asset) and also a download URL (to use as the media URL in your message).
To do so, first create the upload and download URLs using the POST /tools/upload-url endpoint.
Then, make a PUT request to the upload URL with the proper content_type header to upload the file to Pinnacle.
Finally, use the download URL as the media URL in your message.

