File Upload Overview
You can upload files as temporary files into PDF.co. Temporary files are stored for 1 hour by default and then auto removed.
To store files permanently (pdf templates, images you want to reuse) please use PDF.co Built-In Files Storage instead.
You can also use 3rd party cloud services:
- Dropbox: you can use
public link
to a file from Dropbox. - Google Drive: you can use link to a file that was shared as
anyone with a link
. - Google Docs/Sheets/Slides: you can use a link to a document in Google Docs that was shared as
anyone with a link
. - Any publicly accessible URL from any cloud service or web source that provides a direct link to the uploaded file.
Temporary Files Upload
You can upload temporary files up to 2GB in size. Please note that to process these files you should use async=true
mode with data extraction and tools endpoints along with /job/check to check status of background jobs you create.
Steps to Upload File
-
First, call /file/upload/get-presigned-url. It will generate link for uploading (
presignedUrl
) and final link (url
). -
Now send your file to the
presignedUrl
link using thePUT
method within the next 30 minutes. -
Once finished, use
url
to access the file you have just uploaded.
Note: all uploaded files are considered to be temporary files and are automatically permanently removed after 1 hour.