IMPORTANT: You need to setup Postman first, use this link to setup PDF.co for Postman.

Step 1 – Go to Collections Tab and click on PDF.co API v.1 folder

Collections Tab

Step 2 – Look for and click on File Uploader folder

File Uploader Folder

Step 3 – Click on Upload Files folder and click GET generate secure URL

Upload Files Folder

Step 4 – Go to the Params Tab

File Upload Params Tab

Step 5 – You can send your request with cURL

curl --location --request GET 'https://api.pdf.co/v1/file/upload/get-presigned-url?name=test.pdf&encrypt=true' \
--header 'x-api-key: INSERT_YOUR_API_KEY_HERE'

Step 6 – Or you can send it with Postman. To do that, enter the name of file you want it to be stored with on the name key’s value. I will name my file as test.pdf and then set encrypt to true

File Upload Params

Note: Make sure to use the correct file extension. If you are going to upload a CSV file, enter the .csv extension for your file.

Step 7 – Click on Send button

Send button

Step 8 – Scroll down and make sure that the Status is 200 OK.

HTML to PDF Status

Step 9 – Scroll down and copy the presignedURL link

File Upload PresignedURL

Note: The presignedUrl is only valid for 30 minutes. If left unused within 30 minutes, a new presignedUrl has to be generated.

Step 10 – Go back to Upload Files subfolder and click Put Upload File

File Upload Put

Step 11 – Paste the presignedUrl on the Put Tab’s address bar

File Upload Put Address Bar

Step 12 – You can send your request with cURL

curl --location --request PUT '' \
--header 'x-api-key: INSERT_YOUR_API_KEY_HERE' \
--form 'file=@/Users/em/Downloads/logo.png'

Step 13 – Or you can send it with Postman by going to the Body tab and select the Form-Data

File Upload Body

Step 14 – Click the down facing arrow on file key and select File

File Upload file key

Step 15 – Click on Select Files button under Value column and select the file you want to upload

File Upload Select Files Button

Step 16 – Click on Send button

Send button

Step 17 – Scroll down and make sure that the Status is 200 OK.

HTML to PDF Status

Step 18 – Go back to the Get presignedUrl tab

File Upload Get tab

Step 19– You can now use the url link that holds your uploaded file in the temporary storage.

File Upload URL

Note: The url is only valid for 1 hour. The file will automatically be deleted once the 1 hour has expired. You can upload a file size of up to 2GB. It is recommended to set async key to true.