If you have a document uploaded into your instance of Salesforce, it will have a record in the database in the ContentVersion table. The ContentVersion object allows for versioning of the ContentDocument which is linked to a Salesforce record via the ContentDocumentLink.
For Salesforce files smaller than 25 MB, you can use this method to retrieve and display them in WebViewer.

When working with Salesforce files that are 25 MB or larger, attempting to load the file’s VersionData will trigger an Apex memory error. To avoid this issue, you have two options:
In this guide, we’ll focus on the proxy server option.

This is a sample proxy server using express.
You can find a full code sample that implements opening documents in Salesforce on our Github repository.
Did you find this helpful?
Trial setup questions?
Ask experts on DiscordNeed other help?
Contact SupportPricing or product questions?
Contact Sales