The PDF.co PDF Merger API can merge a mix of different document formats into a single PDF. This API function can save you time and effort by taking away the hassle of converting the non-PDF to PDF before they can be merged.
I’ve been struggling with PDF documents (reading text from PDF documents and searching for a text inside), we use a lot of different ones, and it’s always been difficult to find one API and that can do everything we need at an affordable price. Well, I’ve just stumbled across PDF.co (PDF.co Document Parser and PDF text search), what a difference it’s made! I’m sure most of you know it, but if you don’t and you want to manipulate PDFs – check it out. I’m doing stuff automatically that I wasn’t able to do manually with Adobe Acrobat. I wish I’d found it earlier.
Joshua Smith
LOKTAH
I used PDF.co’s API and Zapier integration for filling and flattening a PDF form as well as combining all the reports into one PDF. Before my integration, my clients were spending upwards of 10 hours per month putting reports together and sending to their clients. Now, that process is all entirely automated!
Andrew Mitchell
PDF.co was used to determine the structure of each document, to extract each document’s field names, and to have those mapped to different database values. Using PDF.co reduced the time to fill documents by more than 90%.
Stephen O’Grady
Orishnal Digital Services
The employee saves around 22 hours a month. The modified document contains no errors anymore. The delivery department got the modified document in 15-30 min right after the supplier’s inquiry instead of 2-6 hours as it was before.
Alexander Zhitmarev
PDF.co makes the general handling and processing of PDF documents easier – which is highly useful for a number of automated processes. Using PDF.co + Zapier to help manage the preparation of documents for filing claims has saved the client dozens of work hours and associated costs per week – and allowed them to scale the number of clients they can support.
Andrew Davison
Luhhu
The previous solution was fully custom coded via PHP and hosted on wordpress. This made any minor change to the data and/or PDF files a major hassle to update. WIth PDF.co we are able to make changes a few times a year very easily. This will save the client in development expenses down the line.
Andrew Silva
Support Sidekick
PDF.co + Zapier was key in automating the delivery of unique assets from the collection of PDFs, which allowed the business to put this revenue stream on autopilot.
Troy Tessalone
Automation Ace
We’re going to save so much time every month using this new process, which in turn, allows us to focus even more on our clients’ projects.
Joe Unsworth
Joe Unsworth Creative
Extremely efficient and no code tools to help extract and automate tasks. The tools are highly customizable. Perfectly custom and tailored workflows to help our customers automate both easy and complex manual tasks.
Endre M.
Carrotz
As a part of a workflow in Zapier & Make, PDF.co is used to generate and merge documents with data from other sources. Time and Money are saved by processing the documents automatically.
Mohammad Zubair Sadiek
Debesis
There are two PDF Merger API endpoints.
Our PDF.co Web API engine supports different document formats. You can mix and merge different file formats in one go. The supported formats are listed in the table above.
The PDF Merger API can process large files using the async parameter.
The PDF Merger API output format is in PDF. When images or other non-PDF files are merged using the /v1/pdf/merge2
endpoint the output format is in PDF as well.
PDF.co platform can be used by software developers from programming languages such as PHP, Javascript, .NET and ASP.NET, C#, Java, Visual Basic, and many others. Find source code samples in our API documentation.
If you are not a developer, you can also easily automate your PDF operations via popular business automation platforms: Zapier, Make, Airtable, Salesforce, Google Apps Script, and 300+ more.
As mentioned above, there are 2 PDF Merger endpoints.
Because of the difference in file support, we will show different source code samples for each endpoint.
To demonstrate the /v1/pdf/merge2 endpoint, we will use these five (5) sample documents with different file formats. There’s a PDF file, a Word document, a Spreadsheet, a JPG, and a PNG.
Screenshots of PDF Merger 2 Source Files With Different Formats
Once the request has been processed.
All the documents will be merged into a single PDF.
Screenshots of PDF Merger 2 Output PDF
URL: | https://api.pdf.co/v1/pdf/merge2 |
Method: | POST |
Parameter | Description |
url | required. Comma-separated links to source files. |
encrypt | optional. Enable encryption for the output file: true or false |
async | optional. Runs processing asynchronously. Returns jobId to use with job/check : true or false |
name | optional. Output file name. |
profiles | optional. Must be a String. Set custom configuration. See profiles examples here |
curl --location --request POST 'https://api.pdf.co/v1/pdf/merge2' --header 'x-api-key: {{x-api-key}}' --form 'url=https://bytescout-com.s3-us-west-2.amazonaws.com/files/demo-files/cloud-api/pdf-merge/sample1.pdf,https://bytescout-com.s3-us-west-2.amazonaws.com/files/demo-files/cloud-api/doc-to-pdf/sample.docx' --form 'name=result.pdf'
Call /v1/pdf/merge2 Endpoint Using cURL
The /v1/pdf/merge has the same function as PDF Merge 2 except that the file support for this endpoint is exclusively in PDF format. If all of your source files are in PDF format, we recommend that you use this endpoint, otherwise, the /v1/pdf/merge2 endpoint would work best for you.
To demonstrate /v1/pdf/merge, we will use these two (2) PDF files and merge them into a single file.
Screenshots of Two PDF Files to Merge
When PDF.co process the request successfully, the output file will look like this.
Screenshot of Merged PDF Output File
URL: | https://api.pdf.co/v1/pdf/merge |
Method: | POST |
Parameter | Description |
url | required. Comma-separated links to source files. |
encrypt | optional. Enable encryption for the output file: true or false |
async | optional. Runs processing asynchronously. Returns jobId to use with job/check : true or false |
name | optional. Output file name. |
profiles | optional. Must be a String. Set custom configuration. See profiles examples here |
curl --location --request POST 'https://api.pdf.co/v1/pdf/merge' --header 'x-api-key: {{x-api-key}}' --form 'url=https://bytescout-com.s3-us-west-2.amazonaws.com/files/demo-files/cloud-api/pdf-merge/sample1.pdf,https://bytescout-com.s3-us-west-2.amazonaws.com/files/demo-files/cloud-api/pdf-merge/sample2.pdf' --form 'name=result.pdf'
Calling /v1/pdf/merge Endpoint using cURL
PDF Merge JavaScript code snippets are available in our repository here.
PDF Merge PHP code snippets are available in our repository here.
The sample code for PDF Merge in Python is here.
PDF Merge Java code snippets are available in our repository here.
PDF Merge C# code snippets are available in our repository here.